Mercurial > code > home > repos > rdfdb
diff stubs/rdflib/__init__.pyi @ 33:4f71d2a7a8d1
some low-quality mostly generated mypy stubs. should be shared with my other builds
Ignore-this: 99c013ca3860da8917b3ca52c24308fc
author | Drew Perttula <drewp@bigasterisk.com> |
---|---|
date | Sat, 25 May 2019 02:53:14 +0000 |
parents | |
children | 099c0a815bb7 |
line wrap: on
line diff
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/stubs/rdflib/__init__.pyi Sat May 25 02:53:14 2019 +0000 @@ -0,0 +1,23 @@ +# Stubs for rdflib (Python 3.4) +# +from typing import Tuple, Union + + +# this is the 1st way that worked. 'from rdflib.term import URIRef' did not work. +import rdflib.namespace as _n +Namespace = _n.Namespace + +RDF: Namespace +RDFS: Namespace + +import rdflib.term as _t +URIRef = _t.URIRef +Literal = _t.Literal +BNode = _t.BNode + +import rdflib.graph as _g +ConjunctiveGraph = _g.ConjunctiveGraph +Graph = _g.Graph + +# not part of rdflib +StatementType = Tuple[Union[URIRef, BNode], URIRef, _t.Node, URIRef]