Class AbstractReadOperation
- java.lang.Object
-
- org.odpi.egeria.connectors.juxt.xtdb.readops.AbstractReadOperation
-
- Direct Known Subclasses:
AbstractGraphOperation,AbstractHistoryOperation,AbstractSearchOperation,GetEntity,GetRelationship
public abstract class AbstractReadOperation extends Object
Base class that all read operations should implement.
-
-
Field Summary
Fields Modifier and Type Field Description protected DateasOfTimeprotected xtdb.api.IXtdbDatasourceexistingDBprotected XtdbOMRSRepositoryConnectorxtdb
-
Constructor Summary
Constructors Modifier Constructor Description protectedAbstractReadOperation(XtdbOMRSRepositoryConnector xtdb, Date asOfTime)Default constructor ensures that a consistent datasource is created and used for the entirety of the operation, and further ensures it is fully-closed afterwards irrespective of any exceptions.protectedAbstractReadOperation(XtdbOMRSRepositoryConnector xtdb, xtdb.api.IXtdbDatasource existingDB)Alternative constructor to use if an existing datasource is already open that we want to re-use for this operation.
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static xtdb.api.XtdbDocumentgetXtdbObjectByReference(xtdb.api.IXtdbDatasource db, String reference)Retrieve the requested reference's details from an already-open XTDB datasource.
-
-
-
Field Detail
-
xtdb
protected final XtdbOMRSRepositoryConnector xtdb
-
asOfTime
protected final Date asOfTime
-
existingDB
protected final xtdb.api.IXtdbDatasource existingDB
-
-
Constructor Detail
-
AbstractReadOperation
protected AbstractReadOperation(XtdbOMRSRepositoryConnector xtdb, Date asOfTime)
Default constructor ensures that a consistent datasource is created and used for the entirety of the operation, and further ensures it is fully-closed afterwards irrespective of any exceptions.- Parameters:
xtdb- connectivity to XTDBasOfTime- (optional) validity time for which to open the datasource
-
AbstractReadOperation
protected AbstractReadOperation(XtdbOMRSRepositoryConnector xtdb, xtdb.api.IXtdbDatasource existingDB)
Alternative constructor to use if an existing datasource is already open that we want to re-use for this operation.- Parameters:
xtdb- connectivity to XTDBexistingDB- already-opened datasource to re-use
-
-
Method Detail
-
getXtdbObjectByReference
public static xtdb.api.XtdbDocument getXtdbObjectByReference(xtdb.api.IXtdbDatasource db, String reference)Retrieve the requested reference's details from an already-open XTDB datasource.- Parameters:
db- from which to retrieve the detailsreference- indicating the primary key of the XTDB object to retrieve- Returns:
- XtdbDocument of the object's properties
-
-