(construct-query dataset sparql-query)
Runs a CONSTRUCT query in the specified Jena dataset.
Runs a CONSTRUCT query in the specified Jena dataset.
(init-database path)
Connects to the triplestore at given filesystem path and returns a Jena Dataset object that represents the connection.
Connects to the triplestore at given filesystem path and returns a Jena Dataset object that represents the connection.
(insert-model dataset model)
Takes a tdb dataset and a model and inserts all triples from the model into the triplestore
Takes a tdb dataset and a model and inserts all triples from the model into the triplestore
(insert-rdf dataset rdf-path)
Takes a tdb dataset and a path to an rdf file and inserts all the triples from the rdf file into the triplestore
Takes a tdb dataset and a path to an rdf file and inserts all the triples from the rdf file into the triplestore
(mk-property s)
Creates a Jena Property object from a string
Creates a Jena Property object from a string
(mk-string-literal s)
Creates a Jena string literal object from a string
Creates a Jena string literal object from a string
(mk-uri s)
Creates a Jena Resource (URI) object from a string
Creates a Jena Resource (URI) object from a string
(resultset->seq resultset)
Returns a clojure lazy sequence from a Jena ResultSet
Returns a clojure lazy sequence from a Jena ResultSet
(select-query dataset sparql-query)
Runs a SELECT query in the specified Jena dataset.
Runs a SELECT query in the specified Jena dataset.
(with-transaction dataset rw-type & body)
Custom statement. Syntax: (with-transaction ReadWrite/[READ|WRITE] db ... body ...) The body is wrapped in a transaction of the supplied type (read or write) that works inside the supplied Jena Dataset. If an exception is thrown from whithin the body, the transaction is aborted and the exception is thrown. Otherwise the last expression in the body is returned. WARNING: Do not return the database or its contents (e.g. Dataset, Model) from this statement or the database will escape the scope of the transaction throwing an exception. WARNING2: Beware when creating a lazy sequence of the resultset. You must consume it fully before trying to add new triples into the triplestore. Use doall if needed.
Custom statement. Syntax: (with-transaction ReadWrite/[READ|WRITE] db ... body ...) The body is wrapped in a transaction of the supplied type (read or write) that works inside the supplied Jena Dataset. If an exception is thrown from whithin the body, the transaction is aborted and the exception is thrown. Otherwise the last expression in the body is returned. WARNING: Do not return the database or its contents (e.g. Dataset, Model) from this statement or the database will escape the scope of the transaction throwing an exception. WARNING2: Beware when creating a lazy sequence of the resultset. You must consume it fully before trying to add new triples into the triplestore. Use doall if needed.
cljdoc is a website building & hosting documentation for Clojure/Script libraries
× close