|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.trippi.impl.base.SynchronizedTriplestoreReader org.trippi.impl.base.SynchronizedTriplestoreWriter
public class SynchronizedTriplestoreWriter
A SynchronizedTriplestoreReader that also implements TriplestoreWriter with concurrent buffered write access.
Constructor Summary | |
---|---|
SynchronizedTriplestoreWriter(SynchronizedTriplestoreSession session,
AliasManager aliasManager,
int flushSize)
Construct. |
Method Summary | |
---|---|
void |
add(java.util.List triples,
boolean flush)
Immediately add all triples in the list to the store, then return. |
void |
add(org.jrdf.graph.Triple triple,
boolean flush)
Immediately add the given triple to the store, then return. |
void |
add(TripleIterator iter,
boolean flush)
Immediately add all triples in the iterator to the store, then return. |
void |
delete(java.util.List triples,
boolean flush)
Remove a series of triples from the store. |
void |
delete(org.jrdf.graph.Triple triple,
boolean flush)
Immediately delete the given triple from the store, then return. |
void |
delete(TripleIterator iter,
boolean flush)
Remove a series of triples from the store. |
java.util.List |
findBufferedUpdates(org.jrdf.graph.SubjectNode subject,
org.jrdf.graph.PredicateNode predicate,
org.jrdf.graph.ObjectNode object,
int updateType)
Returns an unmodifiable List of TripleUpdates currently in queue. |
void |
flushBuffer()
Flush the buffer (write the changes to the triplestore). |
int |
getBufferSize()
Get the current size of the buffer. |
void |
setFlushErrorHandler(FlushErrorHandler h)
Set the (optional) handler that will recieve failed flush notification. |
Methods inherited from class org.trippi.impl.base.SynchronizedTriplestoreReader |
---|
close, countTriples, countTriples, countTriples, countTuples, finalize, findTriples, findTriples, findTriples, findTuples, getAliasMap, listTripleLanguages, listTupleLanguages, setAliasMap |
Methods inherited from class java.lang.Object |
---|
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.trippi.TriplestoreReader |
---|
close, countTriples, countTriples, countTriples, countTuples, findTriples, findTriples, findTriples, findTuples, getAliasMap, listTripleLanguages, listTupleLanguages, setAliasMap |
Constructor Detail |
---|
public SynchronizedTriplestoreWriter(SynchronizedTriplestoreSession session, AliasManager aliasManager, int flushSize)
Method Detail |
---|
public void add(java.util.List triples, boolean flush) throws TrippiException
add
in interface TriplestoreWriter
triples
- a list of Triple
objectsflush
- whether to flush the buffer before returning
TrippiException
public void add(TripleIterator iter, boolean flush) throws java.io.IOException, TrippiException
add
in interface TriplestoreWriter
iter
- an iterator over the triplesflush
- whether to flush the buffer before returning
java.io.IOException
TrippiException
public void add(org.jrdf.graph.Triple triple, boolean flush) throws TrippiException
add
in interface TriplestoreWriter
triple
- the Triple
to addflush
- whether to flush the buffer before returning
TrippiException
public void delete(java.util.List triples, boolean flush) throws java.io.IOException, TrippiException
delete
in interface TriplestoreWriter
triples
- a list of Triple
objectsflush
- whether to flush the buffer before returning
java.io.IOException
TrippiException
public void delete(TripleIterator iter, boolean flush) throws java.io.IOException, TrippiException
TriplestoreWriter
delete
in interface TriplestoreWriter
iter
- an iterator over the triplesflush
- whether to flush the buffer before returning
java.io.IOException
TrippiException
public void delete(org.jrdf.graph.Triple triple, boolean flush) throws java.io.IOException, TrippiException
delete
in interface TriplestoreWriter
triple
- the Triple
to deleteflush
- whether to flush the buffer before returning
java.io.IOException
TrippiException
public void flushBuffer()
TriplestoreWriter
flushBuffer
in interface TriplestoreWriter
public void setFlushErrorHandler(FlushErrorHandler h)
TriplestoreWriter
setFlushErrorHandler
in interface TriplestoreWriter
public int getBufferSize()
TriplestoreWriter
getBufferSize
in interface TriplestoreWriter
public java.util.List findBufferedUpdates(org.jrdf.graph.SubjectNode subject, org.jrdf.graph.PredicateNode predicate, org.jrdf.graph.ObjectNode object, int updateType)
TriplestoreWriter
findBufferedUpdates
in interface TriplestoreWriter
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |