You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Enable nitpicky mode for Sphinx and fix all warnings and errors
that occur when running with nitpicky enabled.
Other changes:
- Add a tox environment for building docs (-docs). This is so we can
test building docs on various versions of python as there seems to be
some differences in warnings between different versions. This tox
environment is enabled for linux CI builds.
- Change readthedocs to use python 3.9 as earlier versions do not handle
`@typing.overload` with type aliases.
- Fixes#1878
Copy file name to clipboardExpand all lines: docs/namespaces_and_bindings.rst
+6-6Lines changed: 6 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -29,7 +29,7 @@ namespaces provided grows with user contributions to RDFLib.
29
29
30
30
These Namespaces, and any others that users define, can also be associated with prefixes using the :class:`rdflib.namespace.NamespaceManager`, e.g. using ``foaf`` for ``http://xmlns.com/foaf/0.1/``.
31
31
32
-
Each RDFLib graph has a :attr:`~rdflib.graph.Graph.namespace_manager` that keeps a list of namespace to prefix mappings. The namespace manager is populated when reading in RDF, and these prefixes are used when serialising RDF, or when parsing SPARQL queries. Prefixes can be bound with the :meth:`rdflib.graph.bind` method::
32
+
Each RDFLib graph has a :attr:`~rdflib.graph.Graph.namespace_manager` that keeps a list of namespace to prefix mappings. The namespace manager is populated when reading in RDF, and these prefixes are used when serialising RDF, or when parsing SPARQL queries. Prefixes can be bound with the :meth:`rdflib.graph.Graph.bind` method::
33
33
34
34
from rdflib import Graph, Namespace
35
35
from rdflib.namespace import FOAF
@@ -41,15 +41,15 @@ Each RDFLib graph has a :attr:`~rdflib.graph.Graph.namespace_manager` that keeps
41
41
g.bind("ex", EX) # bind a user-declared namespace to a prefix
42
42
43
43
44
-
The :meth:`rdflib.graph.bind` method is actually supplied by the :class:`rdflib.namespace.NamespaceManager` class - see next.
44
+
The :meth:`rdflib.graph.Graph.bind` method is actually supplied by the :class:`rdflib.namespace.NamespaceManager` class - see next.
45
45
46
46
NamespaceManager
47
47
----------------
48
48
49
-
Each RDFLib graph comes with a :class:`rdflib.namespace.NamespaceManager` instance in the `namespace_manager` field; you can use the `bind` method of this instance to bind a prefix to a namespace URI,
50
-
as above, however note that the `NamespaceManager` automatically performs some bindings according to a selected strategy.
49
+
Each RDFLib graph comes with a :class:`rdflib.namespace.NamespaceManager` instance in the :attr:`~rdflib.graph.Graph.namespace_manager` field; you can use the :meth:`~rdflib.namespace.NamespaceManager.bind` method of this instance to bind a prefix to a namespace URI,
50
+
as above, however note that the :class:`~rdflib.namespace.NamespaceManager` automatically performs some bindings according to a selected strategy.
51
51
52
-
Namespace binding strategies are indicated with the `bind_namespaces` input parameter to `NamespaceManager` instances
52
+
Namespace binding strategies are indicated with the ``bind_namespaces`` input parameter to :class:`~rdflib.namespace.NamespaceManager` instances
53
53
and may be set via ``Graph`` also::
54
54
55
55
from rdflib import Graph
@@ -95,7 +95,7 @@ for example::
95
95
96
96
97
97
98
-
`NamespaceManager` also has a method to normalize a given url::
98
+
:class:`~rdflib.namespace.NamespaceManager` also has a method to normalize a given url::
Copy file name to clipboardExpand all lines: docs/persisting_n3_terms.rst
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -77,7 +77,7 @@ A formula-aware store could also support the persistence of this distinction by
77
77
78
78
This function would return all the Blank Node identifiers assigned to formulae or just those that contain statements matching the given triple pattern and would be the way a serializer determines if a term refers to a formula (in order to properly serializer it).
79
79
80
-
How much would such an interface reduce the need to model formulae terms as first class objects (perhaps to be returned by the :meth:`~rdflib.Graph.triple` function)? Would it be more useful for the :class:`~rdflib.Graph` (or the store itself) to return a Context object in place of a formula term (using the formulae interface to make this determination)?
80
+
How much would such an interface reduce the need to model formulae terms as first class objects (perhaps to be returned by the :meth:`~rdflib.Graph.triples` function)? Would it be more useful for the :class:`~rdflib.Graph` (or the store itself) to return a Context object in place of a formula term (using the formulae interface to make this determination)?
81
81
82
82
Conversely, would these interfaces (variables and formulae) be considered optimizations only since you have the distinction by the kinds of terms triples returns (which would be expanded to include variables and formulae)?
0 commit comments