rdflib-django3
=============
fork from rdflib-django with multi store architecture, python3 and recent rdflib
compatibility.
A store implementation for `rdflib`_ that uses Django as its backend.
The current implementation is context-aware but not formula-aware.
The implementation assumes that contexts are used for named graphs.
.. image:: https://secure.travis-ci.org/devkral/rdflib-django3.png
:target: https://travis-ci.org/#!/devkral/rdflib-django3
Quick start
-----------
Install rdflib-django3 with your package manager:
::
pip install rdflib-django3
Add ``rdflib_django`` to your ``INSTALLED_APPS``:
::
INSTALLED_APPS = (
# other apps
'rdflib_django'.
)
You can now use the following examples to obtain a graph.
Getting a graph using rdflib's store API:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
::
from rdflib import Graph
graph = Graph('Django', identifier="fooo")
graph.open(create=True)
This example will give you a graph identified by a blank node within the
default store.
Getting a conjunctive graph using rdflib's store API:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
::
from rdflib import ConjunctiveGraph
graph = ConjunctiveGraph('Django')
This example will give you a conjunctive graph in the default store.
Getting a named graph using rdflib-django's API:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
::
from rdflib_django import utils
graph = utils.get_named_graph('http://example.com')
Getting the conjunctive graph using rdflib-django3's API:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
::
from rdflib_django import utils
graph = utils.get_conjunctive_graph()
Management commands
-------------------
``rdflib-django3`` includes two management commands to import and export
RDF:
::
$ python manage.py import_rdf --context=http://example.com my_file.rdf
$ python manage.py export_rdf --context=http://example.com
License
-------
``rdflib-django3`` is licensed under the `MIT license`_.
.. _rdflib: http://pypi.python.org/pypi/rdflib/
.. _MIT license: https://raw.github.com/devkral/rdflib-django3/master/LICENSE
.. _MIT license: https://raw.github.com/devkral/rdflib-django/master/LICENSE.publysher
=============
fork from rdflib-django with multi store architecture, python3 and recent rdflib
compatibility.
A store implementation for `rdflib`_ that uses Django as its backend.
The current implementation is context-aware but not formula-aware.
The implementation assumes that contexts are used for named graphs.
.. image:: https://secure.travis-ci.org/devkral/rdflib-django3.png
:target: https://travis-ci.org/#!/devkral/rdflib-django3
Quick start
-----------
Install rdflib-django3 with your package manager:
::
pip install rdflib-django3
Add ``rdflib_django`` to your ``INSTALLED_APPS``:
::
INSTALLED_APPS = (
# other apps
'rdflib_django'.
)
You can now use the following examples to obtain a graph.
Getting a graph using rdflib's store API:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
::
from rdflib import Graph
graph = Graph('Django', identifier="fooo")
graph.open(create=True)
This example will give you a graph identified by a blank node within the
default store.
Getting a conjunctive graph using rdflib's store API:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
::
from rdflib import ConjunctiveGraph
graph = ConjunctiveGraph('Django')
This example will give you a conjunctive graph in the default store.
Getting a named graph using rdflib-django's API:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
::
from rdflib_django import utils
graph = utils.get_named_graph('http://example.com')
Getting the conjunctive graph using rdflib-django3's API:
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
::
from rdflib_django import utils
graph = utils.get_conjunctive_graph()
Management commands
-------------------
``rdflib-django3`` includes two management commands to import and export
RDF:
::
$ python manage.py import_rdf --context=http://example.com my_file.rdf
$ python manage.py export_rdf --context=http://example.com
License
-------
``rdflib-django3`` is licensed under the `MIT license`_.
.. _rdflib: http://pypi.python.org/pypi/rdflib/
.. _MIT license: https://raw.github.com/devkral/rdflib-django3/master/LICENSE
.. _MIT license: https://raw.github.com/devkral/rdflib-django/master/LICENSE.publysher
Release files for rdflib-django3 0.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| rdflib-django3-0.1.tar.gz | 19.8 kB | Details |
Release files / rdflib-django3-0.1.tar.gz
| Download URL | rdflib-django3-0.1.tar.gz |
|---|---|
| Size | 19.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
be1d45019f37e4803db855e329c1031024d5866d4bc7ce3e7b2e2d3d211ae16e
|
|
BLAKE2b-256 checksum How to use checksums |
4e25e868441d5bf52115901d0849251bf7388fc48b43d8437473957ae60ab283
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.12.1 pkginfo/1.4.2 requests/2.20.1 setuptools/40.5.0 requests-toolbelt/0.8.0 tqdm/4.28.1 CPython/3.7.1
|