java.lang.Object
org.apache.jena.tdb1.TDB1Factory
Public factory for creating objects datasets backed by TDB storage
-
Method Summary
Modifier and TypeMethodDescriptionstatic org.apache.jena.query.DatasetassembleDataset(String assemblerFile) Read the file and assembler a datasetstatic org.apache.jena.query.DatasetCreate or connect to a TDB dataset backed by an in-memory block manager.static org.apache.jena.query.DatasetcreateDataset(String dir) Create or connect to a TDB-backed datasetstatic org.apache.jena.query.DatasetcreateDataset(Location location) Create or connect to a TDB-backed datasetstatic org.apache.jena.sparql.core.DatasetGraphCreate a TDB-backed dataset (graph-level) in memory (for testing)static org.apache.jena.sparql.core.DatasetGraphcreateDatasetGraph(String directory) Create or connect to a TDB-backed dataset (graph-level)static org.apache.jena.sparql.core.DatasetGraphcreateDatasetGraph(Location location) Create or connect to a TDB-backed dataset (graph-level)static booleaninUseLocation(String directory) Test whether a location already has a TDB database or whether a call to TDBFactory will cause a new, fresh TDB database to be created (pragmatic tests).static booleaninUseLocation(Location location) Test whether a location already has a TDB database or whether a call to TDBFactory will cause a new, fresh TDB database to be created (pragmatic tests).static booleanisTDB1(org.apache.jena.query.Dataset dataset) Test whether a dataset is backed by TDB.static booleanisTDB1(org.apache.jena.sparql.core.DatasetGraph datasetGraph) Test whether a dataset is backed by TDB.static Locationlocation(org.apache.jena.query.Dataset dataset) Return the location of a dataset if it is backed by TDB, else nullstatic Locationlocation(org.apache.jena.sparql.core.DatasetGraph datasetGraph) Return the location of a DatasetGraph if it is backed by TDB, else nullstatic voidrelease(org.apache.jena.query.Dataset dataset) Release from the JVM.static voidrelease(org.apache.jena.sparql.core.DatasetGraph dataset) Release from the JVM.static voidsetup(Location location, StoreParams params) Set theStoreParamsfor specific Location.
-
Method Details
-
assembleDataset
Read the file and assembler a dataset -
createDataset
Create or connect to a TDB-backed dataset -
createDataset
Create or connect to a TDB-backed dataset -
createDataset
public static org.apache.jena.query.Dataset createDataset()Create or connect to a TDB dataset backed by an in-memory block manager. For testing. -
createDatasetGraph
Create or connect to a TDB-backed dataset (graph-level) -
createDatasetGraph
Create or connect to a TDB-backed dataset (graph-level) -
createDatasetGraph
public static org.apache.jena.sparql.core.DatasetGraph createDatasetGraph()Create a TDB-backed dataset (graph-level) in memory (for testing) -
release
public static void release(org.apache.jena.query.Dataset dataset) Release from the JVM. All caching is lost. -
release
public static void release(org.apache.jena.sparql.core.DatasetGraph dataset) Release from the JVM. All caching is lost. -
isTDB1
public static boolean isTDB1(org.apache.jena.query.Dataset dataset) Test whether a dataset is backed by TDB. -
isTDB1
public static boolean isTDB1(org.apache.jena.sparql.core.DatasetGraph datasetGraph) Test whether a dataset is backed by TDB. -
location
Return the location of a dataset if it is backed by TDB, else null -
location
Return the location of a DatasetGraph if it is backed by TDB, else null -
inUseLocation
Test whether a location already has a TDB database or whether a call to TDBFactory will cause a new, fresh TDB database to be created (pragmatic tests). The directory may be empty, or not exist. Existing databases return "true". -
inUseLocation
Test whether a location already has a TDB database or whether a call to TDBFactory will cause a new, fresh TDB database to be created (pragmatic tests). The directory may be empty, or not exist. Existing databases return "true". -
setup
Set theStoreParamsfor specific Location. This call must only be called before a dataset from Location is created. This operation should be used with care; bad choices ofStoreParamscan reduce performance. See documentation.- Parameters:
location- The persistent storage locationparams- StoreParams to use- Throws:
IllegalStateException- If the dataset has already been setup.
-