Class AXItemPropertiesData
java.lang.Object
de.xima.fc.form.common.models.AXItemPropertiesData
- All Implemented Interfaces:
IXItemPropertiesData, Serializable
- Direct Known Subclasses:
XItem, XItemRenderData
Stores all the properties (
XPropertyEnum) of a form item and offers methods to access these properties.- Author:
- XIMA MEDIA GmbH
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected Stringprotected Map<String, XPropertyValue> protected com.alibaba.fastjson.JSONObject -
Constructor Summary
ConstructorsConstructorDescriptionAXItemPropertiesData(Map<String, XPropertyValue> propertyMap) Deprecated.AXItemPropertiesData(Map<String, XPropertyValue> propertyMap, com.alibaba.fastjson.JSONObject version) Deprecated.This is an internal method meant only for sub classes. -
Method Summary
Modifier and TypeMethodDescriptionbooleancontains(XPropertyEnum xPropertyEnum) booleanget(XPropertyEnum xPropertyEnum) getAlias()com.alibaba.fastjson.JSONArrayGets a list of custom HTML attributes that should be added to the form element.getId()getName()com.alibaba.fastjson.JSONArraybooleancom.vdurmont.semver4j.Semvercom.alibaba.fastjson.JSONObjectgetVrule()booleanbooleanbooleanbooleanbooleanvoidput(String property, XPropertyValue xProperty) Sets the given property to the given value.voidset(XPropertyEnum xPropertyEnum, Object value) sets a property by XPropertyEnumvoidsets a property by namevoidsetClassName(String className) Deprecated.Set the class name when creating an instance, don't mutate existing instances.Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface IXItemPropertiesData
getAttributesEntries, getAttributeValue, hasAttribute, isOfType, isRepeated, isUploadMultiple, removeAttribute, setAttributeValue
-
Field Details
-
className
-
propertyMap
-
version
protected com.alibaba.fastjson.JSONObject version
-
-
Constructor Details
-
AXItemPropertiesData
@Deprecated public AXItemPropertiesData(Map<String, XPropertyValue> propertyMap, com.alibaba.fastjson.JSONObject version) Deprecated.This is an internal method meant only for sub classes. This will be changed toprotected.Creates a new item properties wrapper for the given property map.- Parameters:
propertyMap- map of propertiesversion- Version data of the form to which this item belongs.
-
AXItemPropertiesData
Deprecated.Creates a new item properties wrapper for the given property map.- Parameters:
propertyMap- Map of properties
-
-
Method Details
-
getPropertyMap
- Specified by:
getPropertyMapin interfaceIXItemPropertiesData
-
getClassName
- Specified by:
getClassNamein interfaceIXItemPropertiesData- Returns:
- the className of an item XTextField, XPage etc.
-
setClassName
Deprecated.Set the class name when creating an instance, don't mutate existing instances.- Parameters:
className- of the renderer to be for an item XTextField, XPage etc.
-
put
Description copied from interface:IXItemPropertiesDataSets the given property to the given value. If the property does not exist, it is created. If the value is null, the property is removed.- Specified by:
putin interfaceIXItemPropertiesData- Parameters:
property- The name of the property to set.xProperty- The new value of the property. Null will remove the property.
-
get
- Specified by:
getin interfaceIXItemPropertiesData- Parameters:
xPropertyEnum- - get a property by XPropertyEnum- Returns:
- - a new XProperty if not exist
-
get
- Specified by:
getin interfaceIXItemPropertiesData- Parameters:
property- - get a property by name- Returns:
- - a new XProperty if not exist
-
set
sets a property by XPropertyEnum- Parameters:
xPropertyEnum- the enum of the propertyvalue- the value of the property
-
set
-
getVersion
public com.alibaba.fastjson.JSONObject getVersion()- Returns:
- The version object of the form to which this item belongs.
-
getSemver
public com.vdurmont.semver4j.Semver getSemver()- Returns:
- The parsed sem-version of the form to which this item belongs. May not exist for old forms, in which case
0.0.0is returned.
-
contains
- Specified by:
containsin interfaceIXItemPropertiesData- Parameters:
property- the name of the property- Returns:
- true if property exist
-
contains
- Specified by:
containsin interfaceIXItemPropertiesData- Parameters:
xPropertyEnum- the enum of the property- Returns:
- true if property exist
-
getId
- Specified by:
getIdin interfaceIXItemPropertiesData- Returns:
- the string value for the property id
-
getName
- Specified by:
getNamein interfaceIXItemPropertiesData- Returns:
- The
nameof this item.
-
getAlias
- Specified by:
getAliasin interfaceIXItemPropertiesData- Returns:
- The
aliasof this item.
-
getResolvedAlias
- Specified by:
getResolvedAliasin interfaceIXItemPropertiesData- Returns:
- The effective alias of this item, either the alias when not empty, or the name otherwise.
-
getAttributes
public com.alibaba.fastjson.JSONArray getAttributes()Description copied from interface:IXItemPropertiesDataGets a list of custom HTML attributes that should be added to the form element. SeeXPropertyEnum.attributes.- Specified by:
getAttributesin interfaceIXItemPropertiesData- Returns:
- A list of custom HTML attributes.
-
getParentId
- Specified by:
getParentIdin interfaceIXItemPropertiesData- Returns:
- id of parent element
-
getOptions
public com.alibaba.fastjson.JSONArray getOptions()- Specified by:
getOptionsin interfaceIXItemPropertiesData- Returns:
- JSONArray of property Option
-
getRequiredgroup
- Specified by:
getRequiredgroupin interfaceIXItemPropertiesData
-
getDatatype
- Specified by:
getDatatypein interfaceIXItemPropertiesData
-
getMinvalue
- Specified by:
getMinvaluein interfaceIXItemPropertiesData
-
getMaxvalue
- Specified by:
getMaxvaluein interfaceIXItemPropertiesData
-
getVrule
- Specified by:
getVrulein interfaceIXItemPropertiesData
-
getMaxfilesize
- Specified by:
getMaxfilesizein interfaceIXItemPropertiesData
-
getFileextension
- Specified by:
getFileextensionin interfaceIXItemPropertiesData
-
getEquals
- Specified by:
getEqualsin interfaceIXItemPropertiesData
-
getRequiredif
- Specified by:
getRequiredifin interfaceIXItemPropertiesData
-
getReadonlyif
- Specified by:
getReadonlyifin interfaceIXItemPropertiesData
-
getHiddenif
- Specified by:
getHiddenifin interfaceIXItemPropertiesData
-
getRequiredifcomp
- Specified by:
getRequiredifcompin interfaceIXItemPropertiesData
-
getRequiredifvalue
- Specified by:
getRequiredifvaluein interfaceIXItemPropertiesData
-
getReadonlyifcomp
- Specified by:
getReadonlyifcompin interfaceIXItemPropertiesData
-
getReadonlyifvalue
- Specified by:
getReadonlyifvaluein interfaceIXItemPropertiesData
-
getHiddenifcomp
- Specified by:
getHiddenifcompin interfaceIXItemPropertiesData
-
getHiddenifclear
- Specified by:
getHiddenifclearin interfaceIXItemPropertiesData
-
getReadonlyifclear
- Specified by:
getReadonlyifclearin interfaceIXItemPropertiesData
-
getHiddenifvalue
- Specified by:
getHiddenifvaluein interfaceIXItemPropertiesData
-
getRequired
public boolean getRequired()- Specified by:
getRequiredin interfaceIXItemPropertiesData- Returns:
- true required equals 1
-
isValidateOnServerSide
public boolean isValidateOnServerSide()- Specified by:
isValidateOnServerSidein interfaceIXItemPropertiesData- Returns:
trueifXPropertyEnum.servervalidateis set to1.
-
isStatusdependent
public boolean isStatusdependent()- Specified by:
isStatusdependentin interfaceIXItemPropertiesData- Returns:
- the statusdependent
-
isUsergrouppendent
public boolean isUsergrouppendent()- Specified by:
isUsergrouppendentin interfaceIXItemPropertiesData- Returns:
- the usergrouppendent
-
isReadonlyStatusdependent
public boolean isReadonlyStatusdependent()- Specified by:
isReadonlyStatusdependentin interfaceIXItemPropertiesData- Returns:
- the readonly statusdependent
-
isReadonlyUsergrouppendant
public boolean isReadonlyUsergrouppendant()- Specified by:
isReadonlyUsergrouppendantin interfaceIXItemPropertiesData- Returns:
- the readonly usergrouppendant
-
AXItemPropertiesData(Map, JSONObject)