Class DataSourceProperty


  • public class DataSourceProperty
    extends Object
    A representation of the DatasourceField which can be read from the DataSourceField table or created on the basis of an existing Property from the in-memory model. DataSourceProperties are passed into the data source template to generate the data source representation. This class provides static factory methods for different ways of creating it.
    Author:
    mtaal
    • Constructor Detail

      • DataSourceProperty

        public DataSourceProperty()
    • Method Detail

      • createFromProperty

        public static DataSourceProperty createFromProperty​(Property property)
        Create a DataSourceProperty using a model property.
        Parameters:
        property - the property to use to initialize the data source property
        Returns:
        a new DataSourceProperty instance
      • createFromDataSourceField

        public static DataSourceProperty createFromDataSourceField​(DatasourceField dsField)
        Create a DataSourceProperty using a DatasourceField to initialize it.
        Parameters:
        dsField - the data source field used to initialize the new data source property
        Returns:
        a new DataSourceProperty instance
      • getAllowedValues

        public static Set<String> getAllowedValues​(Reference reference)
        Gets a Set of allowed values for a List reference
        Parameters:
        reference - List reference
      • getType

        public String getType()
      • getName

        public String getName()
      • setName

        public void setName​(String name)
      • isId

        public boolean isId()
      • setId

        public void setId​(boolean id)
      • isMandatory

        public boolean isMandatory()
      • setMandatory

        public void setMandatory​(boolean mandatory)
      • isAuditInfo

        public boolean isAuditInfo()
      • setAuditInfo

        public void setAuditInfo​(boolean auditInfo)
      • isUpdatable

        public boolean isUpdatable()
      • setUpdatable

        public void setUpdatable​(boolean updatable)
      • isBoolean

        public boolean isBoolean()
      • setBoolean

        public void setBoolean​(boolean isBoolean)
      • getAllowedValues

        public Set<String> getAllowedValues()
      • setAllowedValues

        public void setAllowedValues​(Set<String> allowedValues)
      • isPrimitive

        public boolean isPrimitive()
      • setPrimitive

        public void setPrimitive​(boolean primitive)
      • getFieldLength

        public int getFieldLength()
      • setFieldLength

        public void setFieldLength​(int fieldLength)
      • getPrimitiveObjectType

        public Class<?> getPrimitiveObjectType()
      • setPrimitiveObjectType

        public void setPrimitiveObjectType​(Class<?> primitiveObjectType)
      • getTargetEntity

        public Entity getTargetEntity()
      • setTargetEntity

        public void setTargetEntity​(Entity targetEntity)
      • isNumericType

        public boolean isNumericType()
      • setNumericType

        public void setNumericType​(boolean numericType)
      • setUIDefinition

        public void setUIDefinition​(UIDefinition uiDefinition)
      • isAdditional

        public boolean isAdditional()
      • setAdditional

        public void setAdditional​(boolean additional)