Class ColumnImpl

  • All Implemented Interfaces:
    Column

    public class ColumnImpl
    extends Object
    implements Column
    Representation of a column in a table.
    • Method Detail

      • isNested

        public boolean isNested()
      • setNested

        public void setNested​(boolean nested)
      • getTable

        public Table getTable()
        Description copied from interface: Column
        Accessor for the table for this column.
        Specified by:
        getTable in interface Column
        Returns:
        The table
      • getMemberColumnMapping

        public MemberColumnMapping getMemberColumnMapping()
        Description copied from interface: Column
        Accessor for the mapping (and hence member) that owns this column.
        Specified by:
        getMemberColumnMapping in interface Column
        Returns:
        The associated mapping (or null if this is a surrogate column)
      • getName

        public String getName()
        Description copied from interface: Column
        Accessor for the column name.
        Specified by:
        getName in interface Column
        Returns:
        Name of column
      • isPrimaryKey

        public boolean isPrimaryKey()
        Description copied from interface: Column
        Whether this column is (part of) the primary key
        Specified by:
        isPrimaryKey in interface Column
        Returns:
        Whether part of the PK
      • setPrimaryKey

        public Column setPrimaryKey()
        Description copied from interface: Column
        Mutator to make the column (part of) the primary key.
        Specified by:
        setPrimaryKey in interface Column
        Returns:
        This column
      • setNullable

        public Column setNullable​(boolean flag)
        Description copied from interface: Column
        Mutator for the nullability of the column.
        Specified by:
        setNullable in interface Column
        Parameters:
        flag - Whether this is nullable
        Returns:
        The column with the updated info
      • isNullable

        public boolean isNullable()
        Description copied from interface: Column
        Accessor for whether the column is nullable in the datastore.
        Specified by:
        isNullable in interface Column
        Returns:
        whether the column is nullable
      • setDefaultable

        public Column setDefaultable​(Object defaultValue)
        Description copied from interface: Column
        Mutator for the defaultability of the column.
        Specified by:
        setDefaultable in interface Column
        Parameters:
        defaultValue - The default to use
        Returns:
        The column with the updated info
      • isDefaultable

        public boolean isDefaultable()
        Description copied from interface: Column
        Accessor for whether the column is defaultable.
        Specified by:
        isDefaultable in interface Column
        Returns:
        whether the column is defaultable
      • getDefaultValue

        public Object getDefaultValue()
        Description copied from interface: Column
        Accessor for the default Value
        Specified by:
        getDefaultValue in interface Column
        Returns:
        the default value
      • setUnique

        public Column setUnique​(boolean flag)
        Description copied from interface: Column
        Mutator for the uniqueness of the column.
        Specified by:
        setUnique in interface Column
        Parameters:
        flag - The flag
        Returns:
        The column with the updated info
      • isUnique

        public boolean isUnique()
        Description copied from interface: Column
        Accessor for whether the column is unique.
        Specified by:
        isUnique in interface Column
        Returns:
        whether the column is unique
      • getColumnType

        public ColumnType getColumnType()
        Description copied from interface: Column
        Accessor for the role that this column serves (if known).
        Specified by:
        getColumnType in interface Column
        Returns:
        Role of the column
      • getJdbcType

        public JdbcType getJdbcType()
        Description copied from interface: Column
        Accessor for the JDBC Type used for this column.
        Specified by:
        getJdbcType in interface Column
        Returns:
        The Jdbc type
      • getTypeName

        public String getTypeName()
        Description copied from interface: Column
        Accessor for the native type name in the datastore for this column.
        Specified by:
        getTypeName in interface Column
        Returns:
        The column type name
      • getPosition

        public int getPosition()
        Description copied from interface: Column
        Accessor for the position of this column in the table (if specified).
        Specified by:
        getPosition in interface Column
        Returns:
        The position, or -1 if not specified
      • getColumnMetaData

        public ColumnMetaData getColumnMetaData()
        Description copied from interface: Column
        Accessor for the metadata for this column (if any).
        Specified by:
        getColumnMetaData in interface Column
        Returns:
        Metadata for the column