com.ontotext.ordi.trree
Class TRREEConnection

java.lang.Object
  extended by com.ontotext.ordi.tripleset.WarningAwareImpl
      extended by com.ontotext.ordi.tripleset.ConnectionImpl
          extended by com.ontotext.ordi.tripleset.impl.TConnectionImpl
              extended by com.ontotext.ordi.tripleset.impl.TQueryConnectionImpl
                  extended by com.ontotext.ordi.trree.TRREEConnection
All Implemented Interfaces:
Connection, TConnection, WarningAware, Wrapper

public class TRREEConnection
extends TQueryConnectionImpl


Nested Class Summary
 
Nested classes/interfaces inherited from class com.ontotext.ordi.tripleset.impl.TQueryConnectionImpl
TQueryConnectionImpl.ORDITripleSource
 
Field Summary
 
Fields inherited from class com.ontotext.ordi.tripleset.impl.TQueryConnectionImpl
tsource
 
Fields inherited from class com.ontotext.ordi.tripleset.impl.TConnectionImpl
listeners
 
Fields inherited from class com.ontotext.ordi.tripleset.ConnectionImpl
isAutoCommit, isolationLevel, source
 
Fields inherited from class com.ontotext.ordi.tripleset.WarningAwareImpl
warning
 
Constructor Summary
TRREEConnection(TRREEAdapter source, com.ontotext.trree.owlim_ext.AbstractRepository repository, com.ontotext.trree.owlim_ext.EntityPool pool, com.ontotext.trree.owlim_ext.AbstractInferencer inferencer)
           
 
Method Summary
 void addListener(Listener listener)
          Adds a new connection listener.
 TStatement addStatement(Resource subj, URI pred, Value obj, URI namedGraph)
          Adds a new statement.
 TStatement addStatement(Resource subj, URI pred, Value obj, URI namedGraph, URI... ts)
          Adds a new statement and associated it with a collection of tripleses.
 int associateTripleset(Resource subj, URI pred, Value obj, URI namedGraph, URI... ts)
          Associates one or multiple statements.
 void close()
          Releases all resources hold by this instance.
 int deassociateTripleset(Resource subj, URI pred, Value obj, URI namedGraph, URI... ts)
          Deassociates one or multiple statements.
 CloseableIterator<? extends Value> getValuesOfType(URI uri)
          Gets iterator to specific type of values.
 boolean isOpen()
          Checks if this session is opened.
 boolean isReadOnly()
          Checks if the current session to data provider is read-only.
 void removeListener(Listener listener)
          Removes previously associated connection listener.
 int removeStatement(Resource subj, URI pred, Value obj, URI namedGraph)
          Removes one or multiple statements.
 CloseableIterator<? extends TStatement> search(Resource subj, URI pred, Value obj, URI namedGraph, URI ts)
          Gets all statements based on a pattern match.
 
Methods inherited from class com.ontotext.ordi.tripleset.impl.TQueryConnectionImpl
evaluate, evaluate
 
Methods inherited from class com.ontotext.ordi.tripleset.impl.TConnectionImpl
commit, listListeners, rollback
 
Methods inherited from class com.ontotext.ordi.tripleset.ConnectionImpl
getDataSource, getTransactionIsolationLevel, isAutoCommit, isWrapperFor, setAutoCommit, setTransactionIsolationLevel, unwrap
 
Methods inherited from class com.ontotext.ordi.tripleset.WarningAwareImpl
clearWarnings, getWarning
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.ontotext.ordi.Connection
getDataSource, getTransactionIsolationLevel, isAutoCommit, setAutoCommit, setTransactionIsolationLevel
 
Methods inherited from interface com.ontotext.ordi.Wrapper
isWrapperFor, unwrap
 
Methods inherited from interface com.ontotext.ordi.WarningAware
clearWarnings, getWarning
 

Constructor Detail

TRREEConnection

public TRREEConnection(TRREEAdapter source,
                       com.ontotext.trree.owlim_ext.AbstractRepository repository,
                       com.ontotext.trree.owlim_ext.EntityPool pool,
                       com.ontotext.trree.owlim_ext.AbstractInferencer inferencer)
Method Detail

addStatement

public TStatement addStatement(Resource subj,
                               URI pred,
                               Value obj,
                               URI namedGraph)
                        throws ORDIException
Description copied from interface: TConnection
Adds a new statement.

Returns:
the newly added statement to the store
Throws:
ORDIException

addStatement

public TStatement addStatement(Resource subj,
                               URI pred,
                               Value obj,
                               URI namedGraph,
                               URI... ts)
                        throws ORDIException
Description copied from interface: TConnection
Adds a new statement and associated it with a collection of tripleses.

Returns:
the newly added statement to the store
Throws:
ORDIException

associateTripleset

public int associateTripleset(Resource subj,
                              URI pred,
                              Value obj,
                              URI namedGraph,
                              URI... ts)
Description copied from interface: TConnection
Associates one or multiple statements.

Returns:
the number of newly associated statements

deassociateTripleset

public int deassociateTripleset(Resource subj,
                                URI pred,
                                Value obj,
                                URI namedGraph,
                                URI... ts)
Description copied from interface: TConnection
Deassociates one or multiple statements.

Returns:
the number of modified statements

getValuesOfType

public CloseableIterator<? extends Value> getValuesOfType(URI uri)
                                                   throws ORDIException
Description copied from interface: TConnection
Gets iterator to specific type of values.

Parameters:
uri - of the value types
Returns:
iterators to all values of the specified type
Throws:
ORDIException

removeStatement

public int removeStatement(Resource subj,
                           URI pred,
                           Value obj,
                           URI namedGraph)
                    throws ORDIException
Description copied from interface: TConnection
Removes one or multiple statements.

Returns:
the number of deleted statements
Throws:
ORDIException

search

public CloseableIterator<? extends TStatement> search(Resource subj,
                                                      URI pred,
                                                      Value obj,
                                                      URI namedGraph,
                                                      URI ts)
                                               throws ORDIException
Description copied from interface: TConnection
Gets all statements based on a pattern match.

Returns:
iterator to the matched statements
Throws:
ORDIException

close

public void close()
           throws ORDIException
Description copied from interface: Connection
Releases all resources hold by this instance.

Specified by:
close in interface Connection
Overrides:
close in class TConnectionImpl
Throws:
ORDIException

isOpen

public boolean isOpen()
Description copied from interface: Connection
Checks if this session is opened.

Returns:
true if closed, false otherwise.

isReadOnly

public boolean isReadOnly()
Description copied from interface: Connection
Checks if the current session to data provider is read-only.

Returns:
true if read-only

addListener

public void addListener(Listener listener)
Description copied from interface: TConnection
Adds a new connection listener.

Specified by:
addListener in interface TConnection
Overrides:
addListener in class TConnectionImpl

removeListener

public void removeListener(Listener listener)
Description copied from interface: TConnection
Removes previously associated connection listener.

Specified by:
removeListener in interface TConnection
Overrides:
removeListener in class TConnectionImpl


Copyright © 2008. All Rights Reserved.