Class TemporalMapping
java.lang.Object
org.datanucleus.store.rdbms.mapping.java.JavaTypeMapping
org.datanucleus.store.rdbms.mapping.java.SingleFieldMapping
org.datanucleus.store.rdbms.mapping.java.TemporalMapping
- Direct Known Subclasses:
DateMapping, SqlDateMapping, SqlTimeMapping, SqlTimestampMapping
Abstract base mapping for all temporal types.
-
Field Summary
Fields inherited from class SingleFieldMapping
EXTENSION_CHECK_CONSTRAINT_VALUESFields inherited from class JavaTypeMapping
absFieldNumber, columnMappings, mmd, referenceMapping, roleForMember, storeMgr, table, type -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintgetDefaultLength(int index) Accessor for the default length for this type in the datastore (if applicable).protected abstract intgetJavaTypeForColumnMapping(int index) Accessor for the name of the java-type actually used when mapping the particular datastore field.Methods inherited from class SingleFieldMapping
getBoolean, getByte, getChar, getDouble, getFloat, getInt, getLong, getObject, getShort, getString, getValidValues, initialize, prepareColumnMapping, setBoolean, setByte, setChar, setDouble, setFloat, setInt, setLong, setObject, setShort, setStringMethods inherited from class JavaTypeMapping
addColumnMapping, equals, failureMessage, getAbsoluteFieldNumber, getColumnMapping, getColumnMappings, getColumnMetaDataForMember, getJavaType, getMemberMetaData, getNumberOfColumnMappings, getObject, getReferenceMapping, getRoleForMember, getStoreManager, getTable, getType, getValueForColumnMapping, hashCode, hasSimpleDatastoreRepresentation, includeInFetchStatement, includeInInsertStatement, includeInUpdateStatement, initialize, isNullable, isSerialised, performSetPostProcessing, representableAsStringLiteralInStatement, requiresSetPostProcessing, setAbsFieldNumber, setMemberMetaData, setObject, setReferenceMapping, setRoleForMember, setTable
-
Constructor Details
-
TemporalMapping
public TemporalMapping()
-
-
Method Details
-
getDefaultLength
public int getDefaultLength(int index) Description copied from class:SingleFieldMappingAccessor for the default length for this type in the datastore (if applicable).- Overrides:
getDefaultLengthin classSingleFieldMapping- Parameters:
index- requested column index.- Returns:
- Default length
-
getDefaultLengthAsString
protected abstract int getDefaultLengthAsString() -
getJavaTypeForColumnMapping
Description copied from class:SingleFieldMappingAccessor for the name of the java-type actually used when mapping the particular datastore field. This java-type must have an entry in the datastore mappings.- Overrides:
getJavaTypeForColumnMappingin classSingleFieldMapping- Parameters:
index- requested column index.- Returns:
- the name of java-type for the requested column.
-