|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
public interface IAsynchronousWriteStatementBufferFactory<S extends Statement>
Factory interface for asynchronous writers on an ITripleStore.
| Method Summary | |
|---|---|
void |
awaitAll()
Close buffers and then await their Futures. |
void |
cancelAll(boolean mayInterruptIfRunning)
Cancel all Futures. |
void |
close()
Close the buffers. |
CounterSet |
getCounters()
Return performance counters defined by this factory. |
boolean |
isAnyDone()
Return true if the Future for any of the
asynchronous write buffers is done. |
IStatementBuffer<S> |
newStatementBuffer()
Return a new IStatementBuffer which may be used to bulk load
RDF data. |
| Method Detail |
|---|
IStatementBuffer<S> newStatementBuffer()
IStatementBuffer which may be used to bulk load
RDF data. The writes will proceed asynchronously using buffers shared
by all IStatementBuffers returned by this factory for a
given instance of this class. Each IStatementBuffer MAY be
recycled using IBuffer.reset() or simply discarded after its
use.
newStatementBuffer in interface IStatementBufferFactory<S extends Statement>boolean isAnyDone()
true if the Future for any of the
asynchronous write buffers is done.
Note: This method should be invoked periodically to verify that no
errors have been encountered by the asynchronous write buffers. If
this method returns true, invoke awaitAll(),
which will detect any error(s), cancel the other Futures,
and throw an error back to you.
void close()
void cancelAll(boolean mayInterruptIfRunning)
Futures. The buffers will be automatically closed
when their Futures are canceled.
mayInterruptIfRunning -
void awaitAll()
throws InterruptedException,
ExecutionException
Futures. Once closed, the
buffers will not accept further input and the consumers will
eventually drain the buffers and report that they are exhausted. The
Futures will become available once the iterators are
exhausted.
ExecutionException - if any Future fails.
InterruptedException - if interrupted while awaiting any of the Futures.CounterSet getCounters()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||