2017 © Pedro Peláez
 

library graphenedb-client

Http Client for the GrapheneDB Neo4j as as Service

image

neoxygen/graphenedb-client

Http Client for the GrapheneDB Neo4j as as Service

  • Thursday, October 23, 2014
  • by ikwattro
  • Repository
  • 3 Watchers
  • 3 Stars
  • 14 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 0 Forks
  • 0 Open issues
  • 6 Versions
  • 0 % Grown

The README.md

GrapheneDB Client for PHP 5.4+

A PHP Client for the popular GrapheneDB | Neo4j as a Service., (*1)

img, (*2)


Latest Stable Version License Build Status, (*3)

Requirements

  • A GrapheneDB account, you can create one here : https://app.graphenedb.com/signup

Usage

Require the library with composer :, (*4)

composer require neoxygen/graphenedb-client

Create the client by providing your GrapheneDB account e-mail and password :, (*5)


require_once 'vendor/autoload.php'; use Neoxygen\GrapheneDBClient\GrapheneDBClient; $client = new GrapheneDBClient('graphista@neo4jrocks.com', 'SuPeRp@sSwOrD');

Create a Neo4j database instance

You need to pass a name for your database, and optionally a neo4j version :, (*6)

$myNewDB = $client->createDatabase('test');

By default, the latest neo4j version will be used (currently 2.1.5), (*7)

This will return you a Neoxygen\GrapheneDBClient\Database instance, for the available methods of this class read the section The Database class., (*8)

Listing available versions :

$client->getVersions();
Array
(
    [default] => v215
    [versions] => Array
        (
            [0] => Array
                (
                    [version] => v198
                    [label] => Neo4j Community Edition 1.9.8
                )

            [1] => Array
                (
                    [version] => v204
                    [label] => Neo4j Community Edition 2.0.4
                )

            [2] => Array
                (
                    [version] => v215
                    [label] => Neo4j Community Edition 2.1.5
                )

        )

)

Getting all your databases

$databases = $client->getDatabases();

This will return you a collection of Neoxygen\GrapheneDBClient\Database instances., (*9)

Getting a specific database

You need to provide the name of your database :, (*10)

$db = $client->getDatabase('test');

This will return you an instance of Neoxygen\GrapheneDBClient\Database., (*11)

Deleting a database

You need to provide the id of the database you want to delete :, (*12)

$db = $client->getDatabase('test');
$client->deleteDatabase($db->getId());

This will return you true, or throw an exception if the database does not exist., (*13)

Deleting all databases

$client->deleteAllDatabases();

This will return you true, or throw an exception if an error occured on the GrapheneDB server., (*14)

The Database class

The Neoxygen\GrapheneDBClient\Database offers you methods to have informations about your GrapheneDB Neo4j instances :, (*15)

$db = $client->getDatabase('test');

echo $db->getId(); //42354265476534
echo $db->getName(); // test
echo $db->getNodesLimit(); // 1000
echo $db->getDbLocation(); // us-east-1-New York 

For the list of all available methods, check the Neoxygen\GrapheneDBClient\Database source code., (*16)


Author

Christophe Willemsen Twitter | Github, (*17)

License

This library is licensed under the MIT License, check out the LICENSE file packaged with the source code., (*18)

Bugs & Contributions

Simple report & PR on the Github Repository., (*19)

The Versions

23/10 2014

dev-master

9999999-dev

Http Client for the GrapheneDB Neo4j as as Service

  Sources   Download

MIT

The Requires

 

The Development Requires

php client graph neo4j graphenedb

23/10 2014

0.1.3

0.1.3.0

Http Client for the GrapheneDB Neo4j as as Service

  Sources   Download

MIT

The Requires

 

The Development Requires

php client graph neo4j graphenedb

23/10 2014

dev-credentials

dev-credentials

Http Client for the GrapheneDB Neo4j as as Service

  Sources   Download

MIT

The Requires

 

The Development Requires

php client graph neo4j graphenedb

23/10 2014

0.1.2

0.1.2.0

Http Client for the GrapheneDB Neo4j as as Service

  Sources   Download

MIT

The Requires

 

The Development Requires

php client graph neo4j graphenedb

23/10 2014

0.1.1

0.1.1.0

Http Client for the GrapheneDB Neo4j as as Service

  Sources   Download

MIT

The Requires

 

The Development Requires

php client graph neo4j graphenedb

23/10 2014

0.1.0

0.1.0.0

Http Client for the GrapheneDB Neo4j as as Service

  Sources   Download

MIT

The Requires

 

The Development Requires

php client graph neo4j graphenedb