Package de.hybris.bootstrap.typesystem
Class YAttributeDescriptor
- java.lang.Object
-
- de.hybris.bootstrap.typesystem.YNameSpaceElement
-
- de.hybris.bootstrap.typesystem.YTypeSystemElement
-
- de.hybris.bootstrap.typesystem.YDescriptor
-
- de.hybris.bootstrap.typesystem.YAttributeDescriptor
-
public class YAttributeDescriptor extends YDescriptor
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classYAttributeDescriptor.PersistenceType
-
Field Summary
Fields Modifier and Type Field Description static intENCRYPTED_FLAGstatic intINHERITED_FLAGstatic intINITIAL_FLAGstatic intLOCALIZED_FLAGstatic intOPTIONAL_FLAGstatic intPARTOF_FLAGstatic intPRIMITIVE_FLAGstatic intPRIVATE_FLAGstatic intPROPERTY_FLAGstatic intREAD_FLAGstatic intREMOVE_FLAGstatic intSEARCH_FLAGstatic intTIM_IGNORE_FLAGstatic intWRITE_FLAG
-
Constructor Summary
Constructors Constructor Description YAttributeDescriptor(YNamespace container, java.lang.String enclosingTypeCode, java.lang.String qualifier, java.lang.String typeCode)YAttributeDescriptor(java.lang.String enclosingType, YAttributeDescriptor inheritedFrom)
-
Method Summary
-
Methods inherited from class de.hybris.bootstrap.typesystem.YDescriptor
getQualifier, getType, getTypeCode, setModifiers, setUniqueModifier
-
Methods inherited from class de.hybris.bootstrap.typesystem.YTypeSystemElement
addCustomProperties, addCustomProperty, getMetaTypeCode, isAutocreate, isGenerate, setAutocreate, setGenerate, setMetaTypeCode
-
Methods inherited from class de.hybris.bootstrap.typesystem.YNameSpaceElement
getLoaderInfo, getNamespace, getTypeSystem, setLoaderInfo
-
-
-
-
Field Detail
-
READ_FLAG
public static final int READ_FLAG
- See Also:
- Constant Field Values
-
WRITE_FLAG
public static final int WRITE_FLAG
- See Also:
- Constant Field Values
-
REMOVE_FLAG
public static final int REMOVE_FLAG
- See Also:
- Constant Field Values
-
OPTIONAL_FLAG
public static final int OPTIONAL_FLAG
- See Also:
- Constant Field Values
-
SEARCH_FLAG
public static final int SEARCH_FLAG
- See Also:
- Constant Field Values
-
PARTOF_FLAG
public static final int PARTOF_FLAG
- See Also:
- Constant Field Values
-
PRIVATE_FLAG
public static final int PRIVATE_FLAG
- See Also:
- Constant Field Values
-
PROPERTY_FLAG
public static final int PROPERTY_FLAG
- See Also:
- Constant Field Values
-
LOCALIZED_FLAG
public static final int LOCALIZED_FLAG
- See Also:
- Constant Field Values
-
INHERITED_FLAG
public static final int INHERITED_FLAG
- See Also:
- Constant Field Values
-
INITIAL_FLAG
public static final int INITIAL_FLAG
- See Also:
- Constant Field Values
-
TIM_IGNORE_FLAG
public static final int TIM_IGNORE_FLAG
- See Also:
- Constant Field Values
-
ENCRYPTED_FLAG
public static final int ENCRYPTED_FLAG
- See Also:
- Constant Field Values
-
PRIMITIVE_FLAG
public static final int PRIMITIVE_FLAG
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
YAttributeDescriptor
public YAttributeDescriptor(YNamespace container, java.lang.String enclosingTypeCode, java.lang.String qualifier, java.lang.String typeCode)
-
YAttributeDescriptor
public YAttributeDescriptor(java.lang.String enclosingType, YAttributeDescriptor inheritedFrom)
-
-
Method Detail
-
isRedeclaredOneToManyRelationEnd
public boolean isRedeclaredOneToManyRelationEnd()
-
resetCaches
public void resetCaches()
Description copied from class:YNameSpaceElementSince most typesystem elements use lazy references e.g. by codes this method allows to reset all lazy loaded references and data so that they will be calculated anew upon next access.- Overrides:
resetCachesin classYDescriptor
-
redeclare
protected void redeclare(java.lang.String typeCode)
- Overrides:
redeclarein classYDescriptor
-
redeclare
protected void redeclare(java.lang.String typeCode, int modifiers)- Overrides:
redeclarein classYDescriptor
-
getCustomProps
public java.util.Map<java.lang.String,java.lang.String> getCustomProps()
Overwritten to merge all super type properties. UsegetOwnCustomProps()to get just the ones declared at this type.- Overrides:
getCustomPropsin classYTypeSystemElement
-
getOwnCustomProps
public java.util.Map<java.lang.String,java.lang.String> getOwnCustomProps()
-
toString
public java.lang.String toString()
- Overrides:
toStringin classYDescriptor
-
connectToRelationEnd
protected void connectToRelationEnd(YRelationEnd end)
-
getRelationEnd
public YRelationEnd getRelationEnd()
-
getConditionQuery
public java.lang.String getConditionQuery()
-
isRelationEndAttribute
public boolean isRelationEndAttribute()
-
getDefaultMetaTypeCode
protected java.lang.String getDefaultMetaTypeCode()
- Specified by:
getDefaultMetaTypeCodein classYTypeSystemElement
-
getMetaType
public YComposedType getMetaType()
- Overrides:
getMetaTypein classYTypeSystemElement
-
validate
public void validate()
Description copied from class:YNameSpaceElementValidates the element. This should check whether or not lazy references can be resolved or any data is missing.- Overrides:
validatein classYDescriptor
-
isDeclared
public boolean isDeclared()
-
isInherited
public boolean isInherited()
-
getPersistenceQualifier
public java.lang.String getPersistenceQualifier()
-
hasNonGenericPersistenceQualifier
public boolean hasNonGenericPersistenceQualifier()
-
setPersistenceQualifier
public void setPersistenceQualifier(java.lang.String persistenceQualifier)
-
getPersistenceType
public YAttributeDescriptor.PersistenceType getPersistenceType()
-
isPersistable
public boolean isPersistable()
-
getColumnType
public YAtomicType getColumnType()
-
getColumnType
protected YAtomicType getColumnType(YType type)
-
getAttributeDeploymentOrFail
public YAttributeDeployment getAttributeDeploymentOrFail()
-
tryGetAttributeDeployment
public YAttributeDeployment tryGetAttributeDeployment()
-
isRelationAttribute
protected boolean isRelationAttribute()
-
getConfiguredModifiers
public int getConfiguredModifiers()
-
getModifiers
public int getModifiers()
- Overrides:
getModifiersin classYDescriptor
-
isLocalized
public boolean isLocalized()
-
setPersistenceType
public void setPersistenceType(YAttributeDescriptor.PersistenceType persistenceType)
-
getSelectionOfQualifier
public java.lang.String getSelectionOfQualifier()
-
getSelectionOf
public YAttributeDescriptor getSelectionOf()
-
setSelectionOfQualifier
public void setSelectionOfQualifier(java.lang.String selectionOfQualifier)
-
getEnclosingTypeCode
public java.lang.String getEnclosingTypeCode()
-
isRedeclared
public boolean isRedeclared()
-
clearPersistenceInfos
protected void clearPersistenceInfos()
-
setInherited
public void setInherited(boolean isInherited)
-
setRedeclared
public void setRedeclared(boolean isRedeclared)
-
setModelData
public void setModelData(ModelTagListener.ModelData modelData)
-
isGenerateInModel
public boolean isGenerateInModel()
-
getDeclaringAttribute
public YAttributeDescriptor getDeclaringAttribute()
-
getDeclaringType
public YComposedType getDeclaringType()
-
getSuperAttribute
public YAttributeDescriptor getSuperAttribute()
-
getEnclosingType
public YComposedType getEnclosingType()
-
getDefaultValueDefinition
public java.lang.String getDefaultValueDefinition()
-
setDefaultValueDefinition
public void setDefaultValueDefinition(java.lang.String defaultValueDefinition)
-
getDescription
public java.lang.String getDescription()
-
setDescription
public void setDescription(java.lang.String description)
-
getDbColumnDefinitions
public java.util.Map<java.lang.String,java.lang.String> getDbColumnDefinitions()
-
addDbColumnDefinitions
public void addDbColumnDefinitions(java.util.Map<java.lang.String,java.lang.String> dbColumnDefinitions)
-
getRealColumnName
public java.lang.String getRealColumnName()
- Returns:
- the configuredColumnName
-
setRealColumnName
public void setRealColumnName(java.lang.String configuredColumnName)
- Parameters:
configuredColumnName- the configuredColumnName to set
-
isOptional
public boolean isOptional()
-
isSearchable
public boolean isSearchable()
-
isPartOf
public boolean isPartOf()
-
isWritable
public boolean isWritable()
-
isInitial
public boolean isInitial()
-
isReadable
public boolean isReadable()
-
isPrivate
public boolean isPrivate()
-
isProperty
public boolean isProperty()
-
isEncrypted
public boolean isEncrypted()
-
isPrimitive
public boolean isPrimitive()
-
isBooleanAttribute
public boolean isBooleanAttribute()
-
getSetters
public java.util.List<ModelTagListener.ModelDataMethod> getSetters()
-
getGetters
public java.util.List<ModelTagListener.ModelDataMethod> getGetters()
-
setAttributeHandler
public void setAttributeHandler(java.lang.String attributeHandler)
-
getAttributeHandlerIncludingSuperTypes
public java.lang.String getAttributeHandlerIncludingSuperTypes()
-
getConfiguredAttributeHandler
public java.lang.String getConfiguredAttributeHandler()
-
isUniqueModifier
public boolean isUniqueModifier()
- Overrides:
isUniqueModifierin classYDescriptor
-
setConfiguredPersistenceType
public void setConfiguredPersistenceType(YAttributeDescriptor.PersistenceType configuredPersistenceType)
-
getDynamicAttributeHandler
public java.lang.String getDynamicAttributeHandler()
-
getColumnName
public java.lang.String getColumnName(DatabaseSettings databaseSettings)
-
hasFixedColumnName
public boolean hasFixedColumnName()
-
-