|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.openrdf.sesame.sailimpl.nativerdf.ValueStore
Class that provides indexed storage and retrieval of RDF values.
| Constructor Summary | |
ValueStore(File dataDir,
NamespaceStore namespaceStore,
NativeRdfRepository repository)
|
|
| Method Summary | |
void |
clear()
Removes all values from the ValueStore. |
void |
close()
Closes the ValueStore, releasing any file references, etc. |
void |
commitTransaction()
Commits a transaction, applying all updates that have been performed during the transaction. |
BNode |
createBNode()
Creates a new bNode. |
BNode |
createBNode(String nodeId)
creates a new bNode with the given node identifier. |
Literal |
createLiteral(String value)
Creates a new literal with the supplied value. |
Literal |
createLiteral(String value,
String language)
Creates a new literal with the supplied value and language attribute. |
Literal |
createLiteral(String value,
URI datatype)
Creates a new literal with the supplied value and datatype. |
Statement |
createStatement(Resource subject,
URI predicate,
Value object)
Creates a new statement with the supplied subject, predicate and object. |
URI |
createURI(String uri)
Creates a new URI from the supplied string-representation. |
URI |
createURI(String namespace,
String localName)
Creates a new URI that will get the supplied namespace and local name. |
int |
getID(Value value)
Gets the ID for the specified value. |
int |
getID(Value value,
boolean dirtyReads)
|
Value |
getValue(int id)
Gets the value for the specified ID. |
static void |
main(String[] args)
|
void |
rollbackTransaction()
Rolls back all updates that have been performed in the current transaction and closes it. |
void |
startTransaction()
Starts a transaction. |
int |
storeValue(Value value)
Stores the supplied value and returns the ID that has been assigned to it. |
| Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public ValueStore(File dataDir,
NamespaceStore namespaceStore,
NativeRdfRepository repository)
throws IOException
| Method Detail |
public Value getValue(int id)
throws IOException
id - A value ID.
IOException - If an I/O error occurred.
public int getID(Value value)
throws IOException
value - A value.
IOException - If an I/O error occurred.
public int getID(Value value,
boolean dirtyReads)
throws IOException
IOException
public void startTransaction()
throws IOException
IOException - If an I/O error occurred.
public void commitTransaction()
throws IOException
IOException - If an I/O error occurred.
public void rollbackTransaction()
throws IOException
IOException - If an I/O error occurred.
public int storeValue(Value value)
throws IOException
value - The Value to store.
IOException - If an I/O error occurred.startTransaction(),
commitTransaction()
public void clear()
throws IOException
IOException - If an I/O error occurred.startTransaction(),
commitTransaction()
public void close()
throws IOException
IOException - If an I/O error occurred.public URI createURI(String uri)
ValueFactory
createURI in interface ValueFactoryuri - A string-representation of a URI.
public URI createURI(String namespace,
String localName)
ValueFactory
createURI in interface ValueFactorynamespace - A namespace.localName - A legal local name. A legal local name adheres to the
definition of an NCName as specified at
http://www.w3.org/TR/REC-xml-names/#NT-NCName.public BNode createBNode()
ValueFactory
createBNode in interface ValueFactorypublic BNode createBNode(String nodeId)
ValueFactory
createBNode in interface ValueFactorynodeId - the bnode identifier
public Literal createLiteral(String value)
ValueFactory
createLiteral in interface ValueFactoryvalue - The literal's value.
public Literal createLiteral(String value,
String language)
ValueFactory
createLiteral in interface ValueFactoryvalue - The literal's value.language - The literal's language attribute, or null if the
literal doesn't have a language.
public Literal createLiteral(String value,
URI datatype)
ValueFactory
createLiteral in interface ValueFactoryvalue - The literal's value.datatype - The literal's datatype, or null if the literal
doesn't have a datatype.
public Statement createStatement(Resource subject,
URI predicate,
Value object)
ValueFactory
createStatement in interface ValueFactorysubject - The statement's subject.predicate - The statement's predicate.object - The statement's object.
public static void main(String[] args)
throws Exception
Exception
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||