2017 © Pedro Peláez
 

library neo4j-php-ogm

Brings Neo4J PHP OGM to Laravel4

image

niterain/neo4j-php-ogm

Brings Neo4J PHP OGM to Laravel4

  • Thursday, December 12, 2013
  • by niterain
  • Repository
  • 1 Watchers
  • 0 Stars
  • 19 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 1 Forks
  • 0 Open issues
  • 1 Versions
  • 0 % Grown

The README.md

Allows you to use Neo4j with Laravel4, (*1)

Installation

Add niterain\Neo4jPhpOgm as a requirement to composer.json:, (*2)

{
    "require": {
        "niterain/neo4j-php-ogm": "dev-master"
    }
}

Update your packages with composer update or install with composer install., (*3)

Once Composer has installed or updated your packages you need to register Neo4jPhpOgm with Laravel. Open up app/config/app.php and find the providers key towards the bottom and add:, (*4)

'Niterain\Neo4jPhpOgm\Neo4jPhpOgmServiceProvider',

Configuration

Since I like having my config files in one directory, this library checks to see if the settings are in the database.php file in the app/config directory as one of the connections under the 'neo4j' key, but if there isn't one defined, it looks in its local config.php file., (*5)

Usage

You add your entities in an Entity folder, from there everything feels much like Doctrine2., (*6)

$em = App::make('entityManager');
$user = $em->getRepository('Entity\\User');
$user->add(array('firstName' => 'levi', 'lastName' => 'stanley'));
$em->persist($user);
$em->flush();

The Versions

12/12 2013

dev-master

9999999-dev

Brings Neo4J PHP OGM to Laravel4

  Sources   Download

MIT

The Requires

 

laravel php