Class OracleNoSQLPlatform
- java.lang.Object
-
- org.eclipse.persistence.internal.databaseaccess.DatasourcePlatform
-
- org.eclipse.persistence.eis.EISPlatform
-
- org.eclipse.persistence.nosql.adapters.sdk.OracleNoSQLPlatform
-
- All Implemented Interfaces:
Serializable,Cloneable,CorePlatform<ConversionManager>,Platform
public class OracleNoSQLPlatform extends EISPlatform
Platform for Oracle NoSQL database.- Since:
- EclipseLink 4.0
- Author:
- Radek Felcman
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static StringCONSISTENCYstatic StringDURABILITYstatic StringOPERATIONOracleNoSQL interaction spec properties.static StringQUERYstatic StringQUERY_ARGUMENT_TYPE_SUFFIXstatic StringQUERY_ARGUMENT_VALUE_SUFFIXstatic StringQUERY_ARGUMENTSstatic StringTIMEOUTstatic StringVERSION-
Fields inherited from class org.eclipse.persistence.eis.EISPlatform
domMethod, isDOMRecordSupported, isIndexedRecordSupported, isMappedRecordSupported, recordConverter, requiresAutoCommit, shouldConvertDataToStrings, supportsLocalTransactions, xmlConversionManager
-
Fields inherited from class org.eclipse.persistence.internal.databaseaccess.DatasourcePlatform
conversionManager, dataTypesConvertedFromAClass, dataTypesConvertedToAClass, defaultNativeSequenceToTable, defaultSeqenceAtNextValue, defaultSequence, endDelimiter, platformOperators, sequences, sequencesLock, startDelimiter, supportsReturnGeneratedKeys, tableQualifier, timestampQuery, uuidQuery
-
-
Constructor Summary
Constructors Constructor Description OracleNoSQLPlatform()Default constructor.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description DatasourceCallbuildCallFromStatement(SQLStatement statement, DatabaseQuery query, AbstractSession session)jakarta.resource.cci.InteractionSpecbuildInteractionSpec(EISInteraction interaction)Allow the platform to build the interaction spec based on properties defined in the interaction.AbstractRecordbuildRow(jakarta.resource.cci.Record record, EISInteraction interaction, EISAccessor accessor)INTERNAL: Allow the platform to handle record to row conversion.Vector<AbstractRecord>buildRows(jakarta.resource.cci.Record record, EISInteraction interaction, EISAccessor accessor)Allow the platform to handle record to row conversion.<T> TconvertObject(Object sourceObject, Class<T> javaClass)INTERNAL: Allow for conversion from the Oracle type to the Java type.AbstractRecordcreateDatabaseRowFromDOMRecord(jakarta.resource.cci.Record record, EISInteraction call, EISAccessor accessor)Allow the platform to handle the creation of the Record for the DOM record.jakarta.resource.cci.RecordcreateInputRecord(EISInteraction interaction, EISAccessor accessor)Allow the platform to create the appropriate type of record for the interaction.protected ObjectcreateMajorKey(ClassDescriptor descriptor, AbstractRecord record, EISInteraction interaction, EISAccessor accessor)NoSQL stores the data in a single big map.protected SequencecreatePlatformDefaultSequence()INTERNAL: NoSQL does not support id generation, so use UUID as the default.static oracle.nosql.driver.values.FieldValuegetFieldValue(String typeName, Object value, boolean isLob)voidinitializeDefaultQueries(DescriptorQueryManager queryManager, AbstractSession session)INTERNAL: Allow the platform to initialize the CRUD queries to defaults.static booleanisLob(String typeName)voidsetDOMInRecord(Element dom, jakarta.resource.cci.Record record, EISInteraction interaction, EISAccessor accessor)Stores the XML DOM value into the record.booleanshouldPrepare(DatabaseQuery query)Do not prepare to avoid errors being triggered for id and all queries.-
Methods inherited from class org.eclipse.persistence.eis.EISPlatform
appendParameter, buildNativeCall, createDOMRecord, createOutputRecord, getConversionManager, getRecordConverter, getValueFromRecord, isDOMRecordSupported, isIndexedRecordSupported, isMappedRecordSupported, requiresAutoCommit, setIsDOMRecordSupported, setIsIndexedRecordSupported, setIsMappedRecordSupported, setRecordConverter, setRequiresAutoCommit, setShouldConvertDataToStrings, setSupportsLocalTransactions, setValueInRecord, shouldConvertDataToStrings, supportsLocalTransactions
-
Methods inherited from class org.eclipse.persistence.internal.databaseaccess.DatasourcePlatform
addOperator, addSequence, addSequence, buildSelectQueryForIdentity, buildSelectQueryForIdentity, buildSelectQueryForSequenceObject, buildSelectQueryForSequenceObject, clone, copyInto, createConnectionCustomizer, createExpressionFor, getCustomModifyValueForCall, getDataTypesConvertedFrom, getDataTypesConvertedTo, getDefaultNativeSequenceToTable, getDefaultSeqenceAtNextValue, getDefaultSequence, getDefaultSequenceToWrite, getEndDelimiter, getINClauseLimit, getOperator, getPlatformOperators, getSelectSequenceQuery, getSequence, getSequencePreallocationSize, getSequences, getSequencesToWrite, getStartDelimiter, getTableQualifier, getTimestampFromServer, getTimestampQuery, getUpdateSequenceQuery, getUUIDQuery, hasDefaultSequence, initialize, initializePlatformOperators, initIdentitySequences, isAccess, isAttunity, isCloudscape, isDB2, isDB2Z, isDBase, isDerby, isFirebird, isH2, isHANA, isHSQL, isInformix, isMariaDB, isMaxDB, isMySQL, isODBC, isOracle, isOracle12, isOracle9, isPervasive, isPointBase, isPostgreSQL, isSQLAnywhere, isSQLServer, isSybase, isSymfoware, isTimesTen, isTimesTen7, removeAllSequences, removeIdentitySequences, removeSequence, sequencesAfterCloneCleanup, setConversionManager, setDefaultNativeSequenceToTable, setDefaultSeqenceAtNextValue, setDefaultSequence, setEndDelimiter, setSelectSequenceNumberQuery, setSequencePreallocationSize, setSequences, setStartDelimiter, setSupportsReturnGeneratedKeys, setTableQualifier, setTimestampQuery, setUpdateSequenceQuery, setUUIDQuery, shouldNativeSequenceUseTransaction, shouldSelectDistinctIncludeOrderBy, shouldSelectIncludeOrderBy, shouldUseCustomModifyForCall, supportsIdentity, supportsNativeSequenceNumbers, supportsReturnGeneratedKeys, supportsSequenceObjects, toString, usesPlatformDefaultSequence
-
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.eclipse.persistence.internal.databaseaccess.Platform
connectionProperties
-
-
-
-
Field Detail
-
OPERATION
public static String OPERATION
OracleNoSQL interaction spec properties.
-
CONSISTENCY
public static String CONSISTENCY
-
DURABILITY
public static String DURABILITY
-
TIMEOUT
public static String TIMEOUT
-
VERSION
public static String VERSION
-
QUERY
public static String QUERY
-
QUERY_ARGUMENTS
public static String QUERY_ARGUMENTS
-
QUERY_ARGUMENT_TYPE_SUFFIX
public static String QUERY_ARGUMENT_TYPE_SUFFIX
-
QUERY_ARGUMENT_VALUE_SUFFIX
public static String QUERY_ARGUMENT_VALUE_SUFFIX
-
-
Method Detail
-
buildInteractionSpec
public jakarta.resource.cci.InteractionSpec buildInteractionSpec(EISInteraction interaction)
Allow the platform to build the interaction spec based on properties defined in the interaction.- Overrides:
buildInteractionSpecin classEISPlatform
-
buildRow
public AbstractRecord buildRow(jakarta.resource.cci.Record record, EISInteraction interaction, EISAccessor accessor)
INTERNAL: Allow the platform to handle record to row conversion.- Overrides:
buildRowin classEISPlatform
-
buildRows
public Vector<AbstractRecord> buildRows(jakarta.resource.cci.Record record, EISInteraction interaction, EISAccessor accessor)
Allow the platform to handle record to row conversion.- Overrides:
buildRowsin classEISPlatform
-
createInputRecord
public jakarta.resource.cci.Record createInputRecord(EISInteraction interaction, EISAccessor accessor)
Allow the platform to create the appropriate type of record for the interaction. Convert the nested local mapped record to a flat global keyed record.- Overrides:
createInputRecordin classEISPlatform
-
setDOMInRecord
public void setDOMInRecord(Element dom, jakarta.resource.cci.Record record, EISInteraction interaction, EISAccessor accessor)
Stores the XML DOM value into the record. XML is stored in Oracle NoSQL but storing the XML text, keyed on the object's "<dataTypeName>/<id>".- Overrides:
setDOMInRecordin classEISPlatform
-
createMajorKey
protected Object createMajorKey(ClassDescriptor descriptor, AbstractRecord record, EISInteraction interaction, EISAccessor accessor)
NoSQL stores the data in a single big map. The keys are called major keys (minor keys are used to store the attributes). Major keys can have multiple values (and normally do). The first value is normally the type, then the id.
-
createDatabaseRowFromDOMRecord
public AbstractRecord createDatabaseRowFromDOMRecord(jakarta.resource.cci.Record record, EISInteraction call, EISAccessor accessor)
Allow the platform to handle the creation of the Record for the DOM record. Creates a DOM record from the XML data stored as a value in the OracleNoSQLRecord.- Overrides:
createDatabaseRowFromDOMRecordin classEISPlatform
-
initializeDefaultQueries
public void initializeDefaultQueries(DescriptorQueryManager queryManager, AbstractSession session)
INTERNAL: Allow the platform to initialize the CRUD queries to defaults. Configure the CRUD operations using GET/PUT and DELETE.- Overrides:
initializeDefaultQueriesin classDatasourcePlatform
-
buildCallFromStatement
public DatasourceCall buildCallFromStatement(SQLStatement statement, DatabaseQuery query, AbstractSession session)
- Overrides:
buildCallFromStatementin classEISPlatform
-
shouldPrepare
public boolean shouldPrepare(DatabaseQuery query)
Do not prepare to avoid errors being triggered for id and all queries.- Overrides:
shouldPreparein classDatasourcePlatform
-
createPlatformDefaultSequence
protected Sequence createPlatformDefaultSequence()
INTERNAL: NoSQL does not support id generation, so use UUID as the default.- Overrides:
createPlatformDefaultSequencein classDatasourcePlatform
-
getFieldValue
public static oracle.nosql.driver.values.FieldValue getFieldValue(String typeName, Object value, boolean isLob)
-
isLob
public static boolean isLob(String typeName)
-
convertObject
public <T> T convertObject(Object sourceObject, Class<T> javaClass) throws ConversionException, DatabaseException
INTERNAL: Allow for conversion from the Oracle type to the Java type.- Specified by:
convertObjectin interfaceCorePlatform<ConversionManager>- Specified by:
convertObjectin interfacePlatform- Overrides:
convertObjectin classDatasourcePlatform- Throws:
ConversionExceptionDatabaseException
-
-