public class DedupingInferencerConnection extends InferencerConnectionWrapper
Constructor and Description |
---|
DedupingInferencerConnection(InferencerConnection con,
ValueFactory vf) |
Modifier and Type | Method and Description |
---|---|
boolean |
addInferredStatement(Resource subj,
IRI pred,
Value obj,
Resource... contexts)
Adds an inferred statement to a specific context.
|
void |
clearInferred(Resource... contexts)
Removes all inferred statements from the specified/all contexts.
|
void |
commit()
Calls
InferencerConnectionWrapper.flushUpdates() before forwarding the call to the wrapped connection. |
boolean |
removeInferredStatement(Resource subj,
IRI pred,
Value obj,
Resource... contexts)
Removes an inferred statement from a specific context.
|
void |
rollback()
Rolls back the transaction, discarding any uncommitted changes that have been made in this SailConnection.
|
evaluate, flush, flushUpdates, getContextIDs, getStatements, getWrappedConnection, prepare, size
addConnectionListener, removeConnectionListener
addStatement, addStatement, begin, begin, clear, clearNamespaces, close, endUpdate, explain, getNamespace, getNamespaces, isActive, isOpen, pendingRemovals, prepareQuery, removeNamespace, removeStatement, removeStatements, setFederatedServiceResolver, setNamespace, size, startUpdate
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
addConnectionListener, removeConnectionListener
addStatement, addStatement, addStatement, addStatement, begin, begin, clear, clearNamespaces, close, endUpdate, explain, getNamespace, getNamespaces, getStatements, hasStatement, isActive, isOpen, pendingRemovals, prepareQuery, removeNamespace, removeStatement, removeStatement, removeStatements, removeStatements, setNamespace, startUpdate
public DedupingInferencerConnection(InferencerConnection con, ValueFactory vf)
public boolean addInferredStatement(Resource subj, IRI pred, Value obj, Resource... contexts) throws SailException
InferencerConnection
addInferredStatement
in interface InferencerConnection
addInferredStatement
in class InferencerConnectionWrapper
subj
- The subject of the statement to add.pred
- The predicate of the statement to add.obj
- The object of the statement to add.contexts
- The context(s) to add the statement to. Note that this parameter is a vararg and as such is
optional. If no contexts are supplied the method operates on the entire repository.SailException
- If the statement could not be added.public boolean removeInferredStatement(Resource subj, IRI pred, Value obj, Resource... contexts) throws SailException
InferencerConnection
removeInferredStatement
in interface InferencerConnection
removeInferredStatement
in class InferencerConnectionWrapper
subj
- The subject of the statement that should be removed.pred
- The predicate of the statement that should be removed.obj
- The object of the statement that should be removed.contexts
- The context(s) from which to remove the statements. Note that this parameter is a vararg and as
such is optional. If no contexts are supplied the method operates on the entire repository.SailException
- If the statement could not be removed.public void clearInferred(Resource... contexts) throws SailException
InferencerConnection
clearInferred
in interface InferencerConnection
clearInferred
in class InferencerConnectionWrapper
contexts
- The context(s) from which to remove the statements. Note that this parameter is a vararg and as
such is optional. If no contexts are supplied the method operates on the entire repository.SailException
- If the statements could not be removed.public void commit() throws SailException
InferencerConnectionWrapper
InferencerConnectionWrapper.flushUpdates()
before forwarding the call to the wrapped connection.commit
in interface SailConnection
commit
in class InferencerConnectionWrapper
UnknownSailTransactionStateException
- If the transaction state can not be determined (this can happen for
instance when communication between client and server fails or
times-out). It does not indicate a problem with the integrity of the
store.SailException
- If the SailConnection could not be committed.public void rollback() throws SailException
SailConnection
rollback
in interface SailConnection
rollback
in class SailConnectionWrapper
UnknownSailTransactionStateException
- If the transaction state can not be determined (this can happen for
instance when communication between client and server fails or
times-out). It does not indicate a problem with the integrity of the
store.SailException
- If the SailConnection could not be rolled back.Copyright © 2015-2020 Eclipse Foundation. All Rights Reserved.