Interface IXItemPropertiesData

    • Method Detail

      • getClassName

        String getClassName()
        Returns:
        the className of an item XTextField, XPage etc.
      • isOfType

        default boolean isOfType​(Class<? extends IXItemBasic> className)
        Checks whether this item is of the given class. This is a convenience method that compares the class name of this item with the simple name of the given class.
        Parameters:
        className - The class to compare this item to.
        Returns:
        True if this item is an instance of the given element type, false otherwise.
      • get

        XPropertyValue get​(XPropertyEnum xPropertyEnum)
        Parameters:
        xPropertyEnum - - get a property by XPropertyEnum
        Returns:
        - a new XProperty if not exist
      • get

        XPropertyValue get​(String property)
        Parameters:
        property - - get a property by name
        Returns:
        - a new XProperty if not exist
      • contains

        boolean contains​(String property)
        Parameters:
        property - the name of the property
        Returns:
        true if property exist
      • contains

        boolean contains​(XPropertyEnum xPropertyEnum)
        Parameters:
        xPropertyEnum - the enum of the property
        Returns:
        true if property exist
      • getId

        String getId()
        Returns:
        the string value for the property id
      • getName

        String getName()
        Returns:
        The name of this item.
      • getAlias

        String getAlias()
        Returns:
        The alias of this item.
      • getResolvedAlias

        String getResolvedAlias()
        Returns:
        The effective alias of this item, either the alias when not empty, or the name otherwise.
      • getAttributes

        com.alibaba.fastjson.JSONArray getAttributes()
        Gets a list of custom HTML attributes that should be added to the form element. See XPropertyEnum.attributes.
        Returns:
        A list of custom HTML attributes.
      • getAttributesEntries

        default Iterable<Map.Entry<String,​String>> getAttributesEntries()
        Gets an iterable over the name and values of all custom attributes that should be added to the form element. See XPropertyEnum.attributes. When an attribute exists, but has no or an empty value, the returned list contains an entry with the empty string as a value.
        Returns:
        An iterable with name value pairs of all custom attributes, the key is the attribute name, the value is the attribute value.
      • getAttributeValue

        default String getAttributeValue​(String name)
        Gets the value of a custom attribute that should be added to the form element. See XPropertyEnum.attributes. Returns null when no such attribute was configured. Returns the empty string when an attribute with no value was configured.
        Parameters:
        name - Name of the attribute to get.
        Returns:
        Value of the attribute.
      • put

        default void put​(String property,
                         XPropertyValue value)
        Sets 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.
        Parameters:
        property - The name of the property to set.
        value - The new value of the property. Null will remove the property.
      • setAttributeValue

        default String setAttributeValue​(String name,
                                         String value)
        sets the value of a custom attribute that should be added to the form element. See XPropertyEnum.attributes. Passing null as the value is equivalent to calling removeAttribute(String).
        Parameters:
        name - Name of the attribute to set.
        value - New value of the attribute. null will remove the attribute.
        Returns:
        The old value of the attribute, same as if you had called getAttributeValue(String) beforehand.
      • removeAttribute

        default String removeAttribute​(String name)
        Removes a custom HTML attribute with the given name, irrespective of its value. See XPropertyEnum.attributes.
        Parameters:
        name - Name of the attribute to remove.
        Returns:
        The old value of the attribute, same as if you had called getAttributeValue(String) beforehand.
      • hasAttribute

        default boolean hasAttribute​(String name)
        Checks whether a custom HTML attribute with the given name exists, irrespective of its value. See XPropertyEnum.attributes. This method can be used e.g. for boolean attributes like "required", "readonly", or "multiple".
        Parameters:
        name - Name of the attribute to check.
        Returns:
        Whether an attribute with the given name exists.
      • isUploadMultiple

        default boolean isUploadMultiple()
        Checks whether an upload allows multiple files for a single upload element.
        Returns:
        Whether the "multiple" attribute is set.
      • getParentId

        String getParentId()
        Returns:
        id of parent element
      • getOptions

        com.alibaba.fastjson.JSONArray getOptions()
        Returns:
        JSONArray of property Option
      • getRequiredgroup

        String getRequiredgroup()
      • getDatatype

        String getDatatype()
      • getMinvalue

        String getMinvalue()
      • getMaxvalue

        String getMaxvalue()
      • getMaxfilesize

        String getMaxfilesize()
      • getFileextension

        String getFileextension()
      • getEquals

        String getEquals()
      • getRequiredif

        String getRequiredif()
      • getReadonlyif

        String getReadonlyif()
      • getHiddenif

        String getHiddenif()
      • getRequiredifcomp

        String getRequiredifcomp()
      • getRequiredifvalue

        String getRequiredifvalue()
      • getReadonlyifcomp

        String getReadonlyifcomp()
      • getReadonlyifvalue

        String getReadonlyifvalue()
      • getHiddenifcomp

        String getHiddenifcomp()
      • getHiddenifclear

        String getHiddenifclear()
      • getReadonlyifclear

        String getReadonlyifclear()
      • getHiddenifvalue

        String getHiddenifvalue()
      • getRequired

        boolean getRequired()
        Returns:
        true required equals 1
      • isStatusdependent

        boolean isStatusdependent()
        Returns:
        the statusdependent
      • isUsergrouppendent

        boolean isUsergrouppendent()
        Returns:
        the usergrouppendent
      • isRepeated

        default boolean isRepeated()
        Checks whether this item is itself repeated, see also XPropertyEnum.dynamic. Note: This method only checks if the item is repeated, not whether it is inside a container that is repeated.
        Returns:
        True if this item is repeated, false otherwise.
      • isReadonlyStatusdependent

        boolean isReadonlyStatusdependent()
        Returns:
        the readonly statusdependent
      • isReadonlyUsergrouppendant

        boolean isReadonlyUsergrouppendant()
        Returns:
        the readonly usergrouppendant