rdf4j.repository
context
deprecated
context-array
deprecated
(context-array)
(context-array _)
(context-array kb a)
(context-array kb a & rest)
Create array of Resource.
Code was adapted from kr-sesame: sesame-context-array.
DEPRECATED: Use rdf4j.utils/context-array
instead.
count-items
(count-items result)
Counts statements in SPARQL result.
delete-context
deprecated
(delete-context)
(delete-context data-dir)
Delete temporary directory with content and close Lucene index. If data-dir
is given directry than delete it.
That method should be called manually somewhere at the end of code.
make-mem-repository
deprecated
(make-mem-repository)
Backward compatibility.
Replaced by rdf4j.repository.sail/make-sail-repository
.
make-repository
deprecated
(make-repository & [store])
Create repository for given store. By default it is MemoryStore.
Replaced by rdf4j.repository.sail/make-sail-repository
.
make-repository-with-lucene
deprecated
(make-repository-with-lucene & [store parameters])
Similar to make-repository but adds support for Lucene index. NB: See delete-context.
Replaced by rdf4j.repository.sail/make-sail-repository
.
make-sail-datadir
deprecated
(make-sail-datadir sail alternative-fn & args)
Gets or creates data directory.
If sail has set dataDir than just returns it. If sail contains no dataDir than creates it by (apply alternative-fn args)
, set as dataDir and returns.
with-open-repository
macro
(with-open-repository initseq & body)
initseq => [seq-var :memory] | [seq-var (HTTPRepository. server-url repository-id)]
Pesents opened connetion to RDF repository through CONNECTION-VARIABLE. Not transaction aware.
Where initseq is (CONNECTION-VARIABLE REPOSITORY). For example (cnx :memory) If REPOSITORY has value ‘:memory’ then memory repository is created.
with-open-repository*
macro
(with-open-repository* initseq & body)
Transaction aware version of with-open-repository.
NB: The transactinon is finished by (.commit)
so all changes will affect the repository.
It is requivalent of:
(with-open-repository [cnx sail-repo] (try (.begin cnx) ~@body (catch Exception e (.rollback connection) (throw e)) (finally .commit cnx)))