Interface ColumnDraft


  • public interface ColumnDraft
    Column draft used by containers to represent future attribute columns.
    Author:
    Mathieu Bastian
    • Method Detail

      • getId

        String getId()
        Gets the column's identifier.

        This identifier is unique across all columns.

        Returns:
        column's id
      • getTitle

        String getTitle()
        Gets the column's title.
        Returns:
        column's title or null if empty
      • setTitle

        void setTitle​(String title)
        Sets the column's title.
        Parameters:
        title - column title
      • getTypeClass

        Class getTypeClass()
        Gets the column's type.
        Returns:
        column's type
      • getResolvedTypeClass

        Class getResolvedTypeClass​(ContainerUnloader container)
        Gets the column's resolved (final) type taking into account the container settings and whether the column is dynamic or not.
        Parameters:
        container - Container
        Returns:
        column's final type
      • getDefaultValue

        Object getDefaultValue()
        Gets the column's default value.
        Returns:
        default value or null if empty
      • setDefaultValue

        void setDefaultValue​(Object value)
        Sets the column's default value.

        The default default value is null.

        Parameters:
        value - default value
      • getResolvedDefaultValue

        Object getResolvedDefaultValue​(ContainerUnloader container)
        Gets the column's resolved (final) default value taking into account the container settings and whether the column is dynamic or not.
        Parameters:
        container - Container
        Returns:
        default value or null if empty
      • isDynamic

        boolean isDynamic()
        Returns true if this column is dynamic.
        Returns:
        true if dynamic, false otherwise
      • setDefaultValueString

        void setDefaultValueString​(String value)
        Sets the column's default value as a string.

        The value will be parsed according to the column's type.

        Parameters:
        value - value to parse and to be set as default