PHPackages                             conjecto/nemrod - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Framework](/categories/framework)
4. /
5. conjecto/nemrod

ActiveLibrary[Framework](/categories/framework)

conjecto/nemrod
===============

Nemrod is a framework providing an abstraction layer for handling (consuming and producing) RDF in a Symfony2 project

v0.1.1(11y ago)237066BSD-3-ClausePHPPHP &gt;=5.3.3

Since Mar 26Pushed 9y ago11 watchersCompare

[ Source](https://github.com/conjecto/nemrod)[ Packagist](https://packagist.org/packages/conjecto/nemrod)[ Docs](http://www.conjecto.com)[ RSS](/packages/conjecto-nemrod/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (2)Dependencies (9)Versions (10)Used By (0)

Nemrod
======

[](#nemrod)

What is Nemrod?
---------------

[](#what-is-nemrod)

Nemrod is a framework providing an abstraction layer for handling (consuming and producing) RDF in a Symfony2 project, in the same way Symfony users are using Doctrine. The framework provides five main components:

- a resource manager (similar to Doctrine's resource manager)
- a SPARQL query builder allowing to interact directly with your sparql endpoint(s)
- a form extension allowing to build forms to create or update data
- a json-ld serializer allowing to produce framed json-ld representation of RDF
- Optionally, a set of services can be set up that populates and update an Elasticsearch server wrt triple store content.

Nemrod mainly relies on

- [EasyRdf](https://github.com/njh/easyrdf)
- [Json-ld](https://github.com/lanthaler/JsonLD)
- [Elastica](https://github.com/ruflin/Elastica)
- [jms/serializer](https://github.com/schmittjoh/serializer)

Demo project
------------

[](#demo-project)

A quick way to test Nemrod Abilities before installing it into your project is to try our [demo project](https://github.com/conjecto/nemrod-demo)

Requirements
------------

[](#requirements)

- Symfony &gt; 2.5, [Begin a Symfony Project](https://symfony.com/download)

Installation
------------

[](#installation)

Nemrod can be installed using composer :

```
composer require conjecto/nemrod easyrdf/easyrdf:@dev conjecto/json-ld:@dev

```

you can also add dependency directly in your composer.json file:

```
"conjecto/nemrod": "master"
"easyrdf/easyrdf": "@dev"
"conjecto/json-ld": "@dev"

```

Then you need to add one (or two) bundle(s) to the AppKernel.php:

```
class AppKernel extends Kernel
{
	public function registerBundles()
	{
    	$bundles = array(
		    ...
		    new Conjecto\Nemrod\Bundle\NemrodBundle\NemrodBundle(),
		    new Conjecto\Nemrod\Bundle\ElasticaBundle\ElasticaBundle(),
		    ...
		);
	}
}

```

The first bundle is the main framework bundle, the second should be enabled only if you wish to use an ElasticSearch server.

A little bit of configuration is necessary to let Nemrod know one thing or two about your environment:

```
nemrod:
  endpoints:
    my_endpoint: "http://www.foo.org/sparql"
	another_endpoint: "http://www.bar.net/sparql"
  default_endpoint: my_endpoint
  namespaces:
    rdfs: "http://www.w3.org/2000/01/rdf-schema#"
    foaf: "http://xmlns.com/foaf/0.1/"
    #add the namespaces you need
	mycompany: "http://www.example.org/mycompany"

```

At this point, Nemrod knows enough to access to your data. Use the 'rm' service's `findAll()` (which is an alias for 'nemrod.resource\_manager.my\_endpoint'):

```
