Class DirectAccessor
- 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
-
- Direct Known Subclasses:
ArrayAccessor,BasicAccessor,DirectCollectionAccessor
public abstract class DirectAccessor extends MappingAccessor
A direct accessor. Subclasses: BasicAccessor, BasicCollectionAccessor, BasicMapAccessor. 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
- Author:
- Guy Pelletier
-
-
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
Constructors Modifier Constructor Description protectedDirectAccessor(java.lang.String xmlElement)INTERNAL:protectedDirectAccessor(MetadataAnnotation annotation, MetadataAccessibleObject accessibleObject, ClassAccessor classAccessor)INTERNAL:
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected voidaddConvert(ConvertMetadata convert)INTERNAL: Subclasses that support key converts need to override this method.booleanequals(java.lang.Object objectToCompare)INTERNAL:java.lang.StringgetConvert()INTERNAL:java.util.List<ConvertMetadata>getConverts()INTERNAL: Used for OX mapping.abstract java.lang.StringgetDefaultFetchType()INTERNAL:EnumeratedMetadatagetEnumerated()INTERNAL: Used for OX mapping.EnumeratedMetadatagetEnumerated(boolean isForMapKey)INTERNAL: Return the enumerated metadata for this accessor.java.lang.StringgetFetch()INTERNAL: Used for OX mapping.LobMetadatagetLob()INTERNAL: Used for OX mapping.LobMetadatagetLob(boolean isForMapKey)INTERNAL: Return the lob metadata for this accessor.java.lang.BooleangetOptional()INTERNAL: Used for OX mapping.TemporalMetadatagetTemporal()INTERNAL: Used for OX mapping.TemporalMetadatagetTemporal(boolean isForMapKey)INTERNAL: Return the temporal metadata for this accessor.booleanhasEnumerated(boolean isForMapKey)INTERNAL: Return true if this accessor has enumerated metadata.inthashCode()booleanhasLob(boolean isForMapKey)INTERNAL: Return true if this accessor has lob metadata.booleanhasTemporal(boolean isForMapKey)INTERNAL: Return true if this accessor has temporal metadata.voidinitXMLObject(MetadataAccessibleObject accessibleObject, XMLEntityMappings entityMappings)INTERNAL:booleanisOptional()INTERNAL:voidsetConverts(java.util.List<ConvertMetadata> converts)INTERNAL: Used for OX mapping.voidsetEnumerated(EnumeratedMetadata enumerated)INTERNAL: Used for OX mapping.voidsetFetch(java.lang.String fetch)INTERNAL: Used for OX mapping.voidsetLob(LobMetadata lob)INTERNAL: Used for OX mapping.voidsetOptional(java.lang.Boolean optional)INTERNAL: Used for OX mapping.voidsetTemporal(TemporalMetadata temporalType)INTERNAL: Used for OX mapping.voidsetTemporal(TemporalMetadata metadata, boolean isForMapKey)INTERNAL: Set the temporal metadata for this accessor.protected booleanusesIndirection()INTERNAL:-
Methods inherited from class org.eclipse.persistence.internal.jpa.metadata.accessors.mappings.MappingAccessor
addConvertMetadata, addFieldNameTranslation, addMapKeyConvert, derivesId, getAnnotation, getAssociationOverrides, getAttributeName, getAttributeOverride, getAttributeOverrides, getAttributeType, getClassAccessor, getColumn, getConverts, getDatabaseField, getDefaultTableForEntityMapKey, getField, getForeignKey, getGetMethodName, getJoinColumns, getJoinColumnsAndValidate, getMapKey, getMapKeyConverts, getMapKeyReferenceClass, getMapKeyReferenceClassName, getMapKeyReferenceClassWithGenerics, getMapping, getOwningDescriptor, getOwningDescriptors, getRawClass, getRawClassWithGenerics, getReferenceAccessors, getReferenceClass, getReferenceClassFromGeneric, getReferenceClassName, getReferenceClassWithGenerics, getReferenceDatabaseTable, getReferenceDescriptor, getSetMethodName, hasAttributeOverride, hasAttributeType, hasMapKey, hasReturnInsert, hasReturnUpdate, initXMLMappingAccessor, isAnnotationPresent, isBasic, isBasicCollection, isBasicMap, isCollectionAccessor, isDerivedIdClass, isDirectCollection, isDirectEmbeddableCollection, isEmbedded, isEmbeddedId, isEnumerated, isId, isLob, isManyToMany, isManyToOne, isMapAccessor, isMappedKeyMapAccessor, isMultitenantId, isOneToMany, isOneToOne, isPrimitiveWrapperClass, isProcessed, isRelationship, isSerialized, isTemporal, isTimeClass, isTransient, isValidSerializedType, isVariableOneToOne, processAssociationOverride, processAssociationOverrides, processAttributeOverrides, processContainerPolicyAndIndirection, processConvert, processConverts, processDirectMapKeyClass, processEmbeddableMapKeyClass, processEntityMapKeyClass, processEnumerated, processForeignKeyRelationship, processIndirection, processJoinFetch, processLob, processMapKeyClass, processMappingConverter, processMappingKeyConverter, processMappingValueConverter, processProperties, processProperty, processReturnInsert, processReturnInsertAndUpdate, processReturnUpdate, processSerialized, processSerialized, processTemporal, 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, process, 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 Detail
-
DirectAccessor
protected DirectAccessor(java.lang.String xmlElement)
INTERNAL:
-
DirectAccessor
protected DirectAccessor(MetadataAnnotation annotation, MetadataAccessibleObject accessibleObject, ClassAccessor classAccessor)
INTERNAL:
-
-
Method Detail
-
addConvert
protected void addConvert(ConvertMetadata convert)
INTERNAL: Subclasses that support key converts need to override this method.- Overrides:
addConvertin classMappingAccessor
-
equals
public boolean equals(java.lang.Object objectToCompare)
INTERNAL:- Overrides:
equalsin classMappingAccessor
-
hashCode
public int hashCode()
- Overrides:
hashCodein classMappingAccessor
-
getConvert
public java.lang.String getConvert()
INTERNAL:
-
getConverts
public java.util.List<ConvertMetadata> getConverts()
INTERNAL: Used for OX mapping.
-
getDefaultFetchType
public abstract java.lang.String getDefaultFetchType()
INTERNAL:- Overrides:
getDefaultFetchTypein classMappingAccessor
-
getEnumerated
public EnumeratedMetadata getEnumerated()
INTERNAL: Used for OX mapping.
-
getEnumerated
public EnumeratedMetadata getEnumerated(boolean isForMapKey)
INTERNAL: Return the enumerated metadata for this accessor.- Overrides:
getEnumeratedin classMappingAccessor- See Also:
DirectAccessor,ElementCollectionAccessor,CollectionAccessor
-
getFetch
public java.lang.String getFetch()
INTERNAL: Used for OX mapping.
-
getLob
public LobMetadata getLob()
INTERNAL: Used for OX mapping.
-
getLob
public LobMetadata getLob(boolean isForMapKey)
INTERNAL: Return the lob metadata for this accessor.- Overrides:
getLobin classMappingAccessor- See Also:
DirectAccessor
-
getOptional
public java.lang.Boolean getOptional()
INTERNAL: Used for OX mapping.
-
getTemporal
public TemporalMetadata getTemporal()
INTERNAL: Used for OX mapping.
-
setTemporal
public void setTemporal(TemporalMetadata metadata, boolean isForMapKey)
Description copied from class:MappingAccessorINTERNAL: Set the temporal metadata for this accessor.- Overrides:
setTemporalin classMappingAccessor- See Also:
DirectAccessor,CollectionAccessor
-
getTemporal
public TemporalMetadata getTemporal(boolean isForMapKey)
INTERNAL: Return the temporal metadata for this accessor.- Overrides:
getTemporalin classMappingAccessor- See Also:
DirectAccessor,CollectionAccessor
-
hasEnumerated
public boolean hasEnumerated(boolean isForMapKey)
INTERNAL: Return true if this accessor has enumerated metadata.- Overrides:
hasEnumeratedin classMappingAccessor- See Also:
DirectAccessor,ElementCollectionAccessor,CollectionAccessor
-
hasLob
public boolean hasLob(boolean isForMapKey)
INTERNAL: Return true if this accessor has lob metadata.- Overrides:
hasLobin classMappingAccessor- See Also:
DirectAccessor,ElementCollectionAccessor,CollectionAccessor
-
hasTemporal
public boolean hasTemporal(boolean isForMapKey)
INTERNAL: Return true if this accessor has temporal metadata.- Overrides:
hasTemporalin classMappingAccessor- See Also:
DirectAccessor,ElementCollectionAccessor,CollectionAccessor
-
initXMLObject
public void initXMLObject(MetadataAccessibleObject accessibleObject, XMLEntityMappings entityMappings)
INTERNAL:- Overrides:
initXMLObjectin classMappingAccessor
-
isOptional
public boolean isOptional()
INTERNAL:
-
setConverts
public void setConverts(java.util.List<ConvertMetadata> converts)
INTERNAL: Used for OX mapping.
-
setEnumerated
public void setEnumerated(EnumeratedMetadata enumerated)
INTERNAL: Used for OX mapping.
-
setFetch
public void setFetch(java.lang.String fetch)
INTERNAL: Used for OX mapping.
-
setLob
public void setLob(LobMetadata lob)
INTERNAL: Used for OX mapping.
-
setOptional
public void setOptional(java.lang.Boolean optional)
INTERNAL: Used for OX mapping.
-
setTemporal
public void setTemporal(TemporalMetadata temporalType)
INTERNAL: Used for OX mapping.
-
usesIndirection
protected boolean usesIndirection()
INTERNAL:- Overrides:
usesIndirectionin classMappingAccessor- See Also:
RelationshipAccessor,DirectAccessor
-
-