Class CustomGraphQueryInferencer.Connection
- java.lang.Object
-
- org.eclipse.rdf4j.sail.helpers.SailConnectionWrapper
-
- org.eclipse.rdf4j.sail.helpers.NotifyingSailConnectionWrapper
-
- org.eclipse.rdf4j.sail.inferencer.InferencerConnectionWrapper
-
- org.eclipse.rdf4j.sail.inferencer.fc.CustomGraphQueryInferencer.Connection
-
- All Implemented Interfaces:
java.lang.AutoCloseable,FederatedServiceResolverClient,ThreadSafetyAware,InferencerConnection,NotifyingSailConnection,SailConnection,SailConnectionListener
- Enclosing class:
- CustomGraphQueryInferencer
private class CustomGraphQueryInferencer.Connection extends InferencerConnectionWrapper implements SailConnectionListener
-
-
Field Summary
Fields Modifier and Type Field Description private booleanupdateNeededFlag indicating whether an update of the inferred statements is needed.
-
Constructor Summary
Constructors Modifier Constructor Description privateConnection(InferencerConnection con)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description private voidbuildDeltaSets(java.util.Collection<Statement> forRemoval, java.util.Collection<Statement> forAddition)private voidevaluateIntoStatements(ParsedGraphQuery query, java.util.Collection<Statement> statements)voidflushUpdates()Flushes any pending updates to be processed and the resulting changes to be reported to registeredSailConnectionListeners.voidrollback()Rolls back the transaction, discarding any uncommitted changes that have been made in this SailConnection.private voidsetUpdateNeededIfMatching(Statement statement)voidstatementAdded(Statement statement)Notifies the listener that a statement has been added in a transaction that it has registered itself with.voidstatementRemoved(Statement statement)Notifies the listener that a statement has been removed in a transaction that it has registered itself with.-
Methods inherited from class org.eclipse.rdf4j.sail.inferencer.InferencerConnectionWrapper
addInferredStatement, clearInferred, commit, evaluate, flush, getContextIDs, getStatements, getWrappedConnection, hasStatement, prepare, removeInferredStatement, size
-
Methods inherited from class org.eclipse.rdf4j.sail.helpers.NotifyingSailConnectionWrapper
addConnectionListener, removeConnectionListener
-
Methods inherited from class org.eclipse.rdf4j.sail.helpers.SailConnectionWrapper
addStatement, addStatement, begin, begin, clear, clearNamespaces, close, endUpdate, explain, getFederatedServiceResolver, getNamespace, getNamespaces, isActive, isOpen, pendingRemovals, prepareQuery, removeNamespace, removeStatement, removeStatements, setFederatedServiceResolver, setNamespace, setTransactionSettings, size, startUpdate, supportsConcurrentReads
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.eclipse.rdf4j.sail.NotifyingSailConnection
addConnectionListener, removeConnectionListener
-
Methods inherited from interface org.eclipse.rdf4j.sail.SailConnection
addStatement, addStatement, begin, begin, clear, clearNamespaces, close, endUpdate, explain, getNamespace, getNamespaces, isActive, isOpen, pendingRemovals, prepareQuery, removeNamespace, removeStatement, removeStatements, setNamespace, setTransactionSettings, startUpdate
-
-
-
-
Constructor Detail
-
Connection
private Connection(InferencerConnection con)
-
-
Method Detail
-
statementAdded
public void statementAdded(Statement statement)
Description copied from interface:SailConnectionListenerNotifies the listener that a statement has been added in a transaction that it has registered itself with.- Specified by:
statementAddedin interfaceSailConnectionListener- Parameters:
statement- The statement that was added.
-
statementRemoved
public void statementRemoved(Statement statement)
Description copied from interface:SailConnectionListenerNotifies the listener that a statement has been removed in a transaction that it has registered itself with.- Specified by:
statementRemovedin interfaceSailConnectionListener- Parameters:
statement- The statement that was removed.
-
setUpdateNeededIfMatching
private void setUpdateNeededIfMatching(Statement statement)
-
rollback
public void rollback() throws SailExceptionDescription copied from interface:SailConnectionRolls back the transaction, discarding any uncommitted changes that have been made in this SailConnection.- Specified by:
rollbackin interfaceSailConnection- Overrides:
rollbackin classSailConnectionWrapper- Throws:
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.
-
flushUpdates
public void flushUpdates() throws SailExceptionDescription copied from interface:InferencerConnectionFlushes any pending updates to be processed and the resulting changes to be reported to registeredSailConnectionListeners.- Specified by:
flushUpdatesin interfaceInferencerConnection- Overrides:
flushUpdatesin classInferencerConnectionWrapper- Throws:
SailException- If the updates could not be processed.
-
buildDeltaSets
private void buildDeltaSets(java.util.Collection<Statement> forRemoval, java.util.Collection<Statement> forAddition) throws SailException, RDFHandlerException, QueryEvaluationException
-
evaluateIntoStatements
private void evaluateIntoStatements(ParsedGraphQuery query, java.util.Collection<Statement> statements) throws SailException, RDFHandlerException, QueryEvaluationException
-
-