Package com.logicaldoc.core.metadata
Class Attribute
java.lang.Object
com.logicaldoc.core.metadata.Attribute
- All Implemented Interfaces:
- Serializable,- Comparable<Attribute>
This class defines the value of an attribute associated to an extensible
 object. For each value, is possible to define the type and if it is mandatory
 or not.
- Since:
- 4.5.1
- Author:
- Matteo Caruso - LogicalDOC
- See Also:
- 
Field SummaryFieldsModifier and TypeFieldDescriptionstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final int
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionintbooleanGets the value as it should be displayed to the userintintgetLabel()intWhether an attribute value is mandatory or not.intgetName()intThis is the position of the attribute into the attributes listintgetSetId()intgetType()getValue()Gets the attribute value.inthashCode()booleanvoidsetBooleanValue(Boolean booleanValue) voidsetDateValue(Date dateValue) voidsetDependsOn(String dependsOn) voidsetDoubleValue(Double doubleValue) voidsetEditor(int editor) voidsetHidden(int hidden) voidsetInitialization(String initialization) voidsetIntValue(Long intValue) voidvoidsetMandatory(int mandatory) voidsetMultiple(int multiple) voidvoidvoidsetPosition(int position) voidsetReadonly(int readonly) voidvoidsetStringValue(String stringValue) voidsetStringValues(String stringValues) voidsetType(int type) voidsetValidation(String validation) voidSets the attribute value.
- 
Field Details- 
TYPE_STRINGpublic static final int TYPE_STRING- See Also:
 
- 
TYPE_INTpublic static final int TYPE_INT- See Also:
 
- 
TYPE_DOUBLEpublic static final int TYPE_DOUBLE- See Also:
 
- 
TYPE_DATEpublic static final int TYPE_DATE- See Also:
 
- 
TYPE_USERpublic static final int TYPE_USER- See Also:
 
- 
TYPE_BOOLEANpublic static final int TYPE_BOOLEAN- See Also:
 
- 
TYPE_FOLDERpublic static final int TYPE_FOLDER- See Also:
 
- 
TYPE_DOCUMENTpublic static final int TYPE_DOCUMENT- See Also:
 
- 
TYPE_SECTIONpublic static final int TYPE_SECTION- See Also:
 
- 
EDITOR_DEFAULTpublic static final int EDITOR_DEFAULT- See Also:
 
- 
EDITOR_LISTBOXpublic static final int EDITOR_LISTBOX- See Also:
 
 
- 
- 
Constructor Details- 
Attributepublic Attribute()
- 
Attribute
 
- 
- 
Method Details- 
getStringValue
- 
setStringValue
- 
getIntValue
- 
setIntValue
- 
getDoubleValue
- 
setDoubleValue
- 
getDateValue
- 
setDateValue
- 
getBooleanValue
- 
setBooleanValue
- 
getTypepublic int getType()
- 
setTypepublic void setType(int type) 
- 
isSectionpublic boolean isSection()
- 
getValueGets the attribute value. It can be as String, Long, Double or Date.- Returns:
- The attribute value as Object.
 
- 
getDisplayValueGets the value as it should be displayed to the user- Returns:
- The attribute value to display
 
- 
setValueSets the attribute value. It can be as String, Long, Double or Date.- Parameters:
- value- The attribute value.
 
- 
getMandatorypublic int getMandatory()Whether an attribute value is mandatory or not.- Returns:
- If 0, the attribute value is not mandatory; if 1, the attribute value is mandatory.
 
- 
setMandatorypublic void setMandatory(int mandatory) 
- 
getPositionpublic int getPosition()This is the position of the attribute into the attributes list- Returns:
- the attribute's position
 
- 
setPositionpublic void setPosition(int position) 
- 
compareTo- Specified by:
- compareToin interface- Comparable<Attribute>
 
- 
hashCodepublic int hashCode()
- 
equals
- 
getLabel
- 
setLabel
- 
getEditorpublic int getEditor()
- 
setEditorpublic void setEditor(int editor) 
- 
getHiddenpublic int getHidden()
- 
setHiddenpublic void setHidden(int hidden) 
- 
getSetId
- 
setSetId
- 
getMultiplepublic int getMultiple()
- 
setMultiplepublic void setMultiple(int multiple) 
- 
getParent
- 
setParent
- 
getName
- 
setName
- 
getStringValues
- 
setStringValues
- 
getDependsOn
- 
setDependsOn
- 
getReadonlypublic int getReadonly()
- 
setReadonlypublic void setReadonly(int readonly) 
- 
getValidation
- 
setValidation
- 
getInitialization
- 
setInitialization
 
-