Module org.eclipse.persistence.jpa
Class BasicMapAccessor
java.lang.Object
org.eclipse.persistence.internal.jpa.metadata.ORMetadata
org.eclipse.persistence.internal.jpa.metadata.accessors.MetadataAccessor
org.eclipse.persistence.internal.jpa.metadata.accessors.mappings.MappingAccessor
org.eclipse.persistence.internal.jpa.metadata.accessors.mappings.DirectAccessor
org.eclipse.persistence.internal.jpa.metadata.accessors.mappings.DirectCollectionAccessor
org.eclipse.persistence.internal.jpa.metadata.accessors.mappings.BasicCollectionAccessor
org.eclipse.persistence.internal.jpa.metadata.accessors.mappings.BasicMapAccessor
INTERNAL:
A basic collection accessor.
Key notes:
- any metadata mapped from XML to this class must be compared in the
equals method.
- any metadata mapped from XML to this class must be handled in the merge
method. (merging is done at the accessor/mapping level)
- any metadata mapped from XML to this class must be initialized in the
initXMLObject method.
- methods should be preserved in alphabetical order.
- Since:
- TopLink 11g
-
Field Summary
Fields inherited from class org.eclipse.persistence.internal.jpa.metadata.accessors.mappings.MappingAccessor
KEY_DOT_NOTATION, m_field, VALUE_DOT_NOTATION
Fields inherited from class org.eclipse.persistence.internal.jpa.metadata.ORMetadata
m_project
-
Constructor Summary
ConstructorDescriptionINTERNAL: Used for OX mapping.BasicMapAccessor
(MetadataAnnotation basicMap, MetadataAccessibleObject accessibleObject, ClassAccessor classAccessor) INTERNAL: -
Method Summary
Modifier and TypeMethodDescriptionboolean
INTERNAL:protected ColumnMetadata
INTERNAL:protected String
INTERNAL:INTERNAL: Used for OX mapping.INTERNAL: Used for OX mapping.INTERNAL: Return the reference class for this accessor.INTERNAL: Used for OX mapping.int
hashCode()
boolean
INTERNAL: For all intent and purpose a basic map accessor always uses a map key.void
initXMLObject
(MetadataAccessibleObject accessibleObject, XMLEntityMappings entityMappings) INTERNAL:boolean
INTERNAL: Return true if this accessor represents a basic map mapping.void
process()
INTERNAL: The processing of JPA converters for a basic map has been disabled, since we will not know which part of the map (key or value) to apply the JPA converter.void
setKeyColumn
(ColumnMetadata keyColumn) INTERNAL: Used for OX mapping.void
setKeyConverter
(String keyConverter) INTERNAL: Used for OX mapping.void
setValueConverter
(String valueConverter) INTERNAL: Used for OX mapping.Methods inherited from class org.eclipse.persistence.internal.jpa.metadata.accessors.mappings.BasicCollectionAccessor
getReferenceClassWithGenerics, getValueColumn, isBasicCollection, processCollectionTable, setValueColumn
Methods inherited from class org.eclipse.persistence.internal.jpa.metadata.accessors.mappings.DirectCollectionAccessor
getBatchFetch, getCascadeOnDelete, getCollectionTable, getDefaultFetchType, getJoinFetch, getNonCacheable, getPrivateOwned, getReferenceDatabaseTable, getReferenceDescriptor, hasMapKeyClass, isCascadeOnDelete, isDirectCollection, isNonCacheable, isValidDirectCollectionType, isValidDirectMapType, process, processBatchFetch, processDirectCollectionMapping, processDirectMapMapping, setBatchFetch, setCascadeOnDelete, setCollectionTable, setJoinFetch, setNonCacheable
Methods inherited from class org.eclipse.persistence.internal.jpa.metadata.accessors.mappings.DirectAccessor
addConvert, getConvert, getConverts, getEnumerated, getEnumerated, getFetch, getLob, getLob, getOptional, getTemporal, getTemporal, hasEnumerated, hasLob, hasTemporal, isOptional, setConverts, setEnumerated, setFetch, setLob, setOptional, setTemporal, setTemporal, usesIndirection
Methods inherited from class org.eclipse.persistence.internal.jpa.metadata.accessors.mappings.MappingAccessor
addConvertMetadata, addFieldNameTranslation, addMapKeyConvert, derivesId, getAnnotation, getAssociationOverrides, getAttributeName, getAttributeOverride, getAttributeOverrides, getAttributeType, getClassAccessor, getConverts, getDatabaseField, getDefaultTableForEntityMapKey, getField, getForeignKey, getGetMethodName, getJoinColumns, getJoinColumnsAndValidate, getMapKey, getMapKeyConverts, getMapKeyReferenceClass, getMapKeyReferenceClassName, getMapKeyReferenceClassWithGenerics, getMapping, getOwningDescriptor, getOwningDescriptors, getRawClass, getRawClassWithGenerics, getReferenceAccessors, getReferenceClassFromGeneric, getReferenceClassName, getSetMethodName, hasAttributeOverride, hasAttributeType, hasReturnInsert, hasReturnUpdate, initXMLMappingAccessor, isAnnotationPresent, isBasic, isCollectionAccessor, isDerivedIdClass, isDirectEmbeddableCollection, isEmbedded, isEmbeddedId, isEnumerated, isId, isJson, isLob, isManyToMany, isManyToOne, isMapAccessor, isMappedKeyMapAccessor, isMultitenantId, isOneToMany, isOneToOne, isPrimitiveWrapperClass, isProcessed, isRelationship, isSerialized, isTemporal, isTimeClass, isTransient, isUUID, isValidJsonType, isValidSerializedType, isVariableOneToOne, processAssociationOverride, processAssociationOverrides, processAttributeOverrides, processContainerPolicyAndIndirection, processConvert, processConverts, processDirectMapKeyClass, processEmbeddableMapKeyClass, processEntityMapKeyClass, processEnumerated, processForeignKeyRelationship, processIndirection, processJoinFetch, processJson, processLob, processMapKeyClass, processMappingConverter, processMappingKeyConverter, processMappingValueConverter, processProperties, processProperty, processReturnInsert, processReturnInsertAndUpdate, processReturnUpdate, processSerialized, processSerialized, processTemporal, processUUID, setAccessorMethods, setAttributeType, setClassAccessor, setField, setIndirectionPolicy, setMapping, setOverrideMapping, toString, updatePrimaryKeyField, usesFieldAccess, usesPropertyAccess, usesVirtualAccess
Methods inherited from class org.eclipse.persistence.internal.jpa.metadata.accessors.MetadataAccessor
getAccess, getAccessibleObject, getAccessMethods, getAnnotatedElement, getAnnotatedElementName, getAnnotation, getConverters, getDefaultAttributeName, getDescriptor, getDescriptorJavaClass, getHashPartitioning, getIdentifier, getJavaClass, getJavaClassName, getName, getObjectTypeConverters, getPartitioned, getPartitioning, getPinnedPartitioning, getProperties, getRangePartitioning, getReferencedField, getReferencedField, getReplicationPartitioning, getRoundRobinPartitioning, getSerializedConverters, getStructConverters, getTypeConverters, getUnionPartitioning, getUpperCaseShortJavaClassName, getValue, getValue, getValuePartitioning, hasAccess, hasAccessMethods, initAccess, initXMLAccessor, isAnnotationPresent, merge, processConverters, processCustomConverters, processObjectTypeConverters, processPartitioned, processPartitioning, processPrimaryKeyJoinColumns, processSerializedConverters, processStructConverters, processTable, processTypeConverters, setAccess, setAccessMethods, setConverters, setDescriptor, setHashPartitioning, setName, setObjectTypeConverters, setPartitioned, setPartitioning, setPinnedPartitioning, setProperties, setRangePartitioning, setReplicationPartitioning, setRoundRobinPartitioning, setSerializedConverters, setStructConverters, setTypeConverters, setUnionPartitioning, setValuePartitioning
Methods inherited from class org.eclipse.persistence.internal.jpa.metadata.ORMetadata
getAccessibleObjectName, getAnnotation, getBoxedType, getDatabaseTypeEnum, getEntityMappings, getFullyQualifiedClassName, getJavaClass, getJavaClassName, getLoader, getLocation, getLogger, getMetadataClass, getMetadataClass, getMetadataClass, getMetadataFactory, getName, getPrimitiveClassForName, getProject, getText, getXMLElement, hasIdentifier, hasText, initXMLClassName, initXMLObject, initXMLObjects, initXMLTextObject, loadedFromAnnotation, loadedFromEclipseLinkXML, loadedFromXML, mergeORObjectLists, mergeORObjects, mergeSimpleObjects, reloadEntity, reloadMappedSuperclass, setAccessibleObject, setEntityMappings, setFieldName, setFieldName, setProject, shouldOverride, valuesMatch, valuesMatch
-
Constructor Details
-
BasicMapAccessor
public BasicMapAccessor()INTERNAL: Used for OX mapping. -
BasicMapAccessor
public BasicMapAccessor(MetadataAnnotation basicMap, MetadataAccessibleObject accessibleObject, ClassAccessor classAccessor) INTERNAL:
-
-
Method Details
-
equals
INTERNAL:- Overrides:
equals
in classBasicCollectionAccessor
-
hashCode
public int hashCode()- Overrides:
hashCode
in classBasicCollectionAccessor
-
getColumn
INTERNAL:- Overrides:
getColumn
in classBasicCollectionAccessor
- See Also:
-
getDefaultCollectionTableName
INTERNAL:- Overrides:
getDefaultCollectionTableName
in classBasicCollectionAccessor
-
getKeyColumn
INTERNAL: Used for OX mapping. -
getKeyConverter
INTERNAL: Used for OX mapping.- Overrides:
getKeyConverter
in classBasicCollectionAccessor
-
getReferenceClass
INTERNAL: Return the reference class for this accessor.- Overrides:
getReferenceClass
in classBasicCollectionAccessor
-
getValueConverter
INTERNAL: Used for OX mapping.- Overrides:
getValueConverter
in classDirectCollectionAccessor
- See Also:
-
hasMapKey
public boolean hasMapKey()INTERNAL: For all intent and purpose a basic map accessor always uses a map key. It is used to correctly set the indirection policy. This method is kinda overkill to make sure isMappedKeyMapAccessor returns false for BasicMapAccessors.- Overrides:
hasMapKey
in classMappingAccessor
- See Also:
-
initXMLObject
public void initXMLObject(MetadataAccessibleObject accessibleObject, XMLEntityMappings entityMappings) INTERNAL:- Overrides:
initXMLObject
in classBasicCollectionAccessor
-
isBasicMap
public boolean isBasicMap()INTERNAL: Return true if this accessor represents a basic map mapping.- Overrides:
isBasicMap
in classMappingAccessor
-
process
public void process()INTERNAL: The processing of JPA converters for a basic map has been disabled, since we will not know which part of the map (key or value) to apply the JPA converter. See isLob, isTemporal and isEnumerated calls for log warning details.- Overrides:
process
in classBasicCollectionAccessor
-
setKeyColumn
INTERNAL: Used for OX mapping. -
setKeyConverter
INTERNAL: Used for OX mapping. -
setValueConverter
INTERNAL: Used for OX mapping.
-