Interface TableColumnConfiguration<S,T>

Type Parameters:
S - type of the objects contained within the table's or treetable's items list
T - type of the content in all cells in this column
All Known Implementing Classes:
DefaultTableColumnConfiguration

public interface TableColumnConfiguration<S,T>
Configuration for a table or treetable column.
Author:
harald
  • Method Details

    • getTableConfiguration

      TableConfiguration<S> getTableConfiguration()
      Gets the table configuration.
      Returns:
      the table configuration
    • getName

      String getName()
      Gets the column name.
      This is usually the binding path.
      The name is also used as a key to the table preferences.
      Returns:
      the name of the column
    • getDisplayedName

      String getDisplayedName()
      Gets the column name displayed in the column header.
      Returns:
      the display name of the column
    • setDisplayedName

      void setDisplayedName(String displayName)
      Sets the column name displayed in the column header.
      Parameters:
      displayName - the display name of the column
    • getType

      Class<T> getType()
      Determines the class for a given column.
      Returns:
      the column class
    • setType

      void setType(Class<T> type)
      Sets the column type.
      Parameters:
      type - the type
    • setGenericType

      void setGenericType(Type genericType)
      Sets the generic type.
      Parameters:
      genericType - the generic type
    • getGenericType

      Type getGenericType()
      Gets the generic type.
      Returns:
      the generic type
    • getCellType

      TableCellType<T> getCellType()
      Gets the specific table cell type.
      Returns:
      the cell type, null to determine from column type
      See Also:
    • setCellType

      void setCellType(TableCellType<T> cellType)
      Sets the specific table cell type.
      Parameters:
      cellType - the cell type, null to determine from column type
    • getPattern

      String getPattern()
      Defines the format for numeric or date/time-types.
      If null is returned a default format will be used according to the column class.
      Returns:
      the format pattern or null if default
    • setPattern

      void setPattern(String pattern)
      Sets the formatting string.
      Parameters:
      pattern - the format pattern
    • getNumberFormat

      DecimalFormat getNumberFormat()
      Gets the number format.
      Returns:
      the number format, null if default
    • getDateTimeFormatter

      DateTimeFormatter getDateTimeFormatter()
      Gets the date or time formatter.
      Returns:
      the formatter, null if default
    • getAlignment

      javafx.geometry.Pos getAlignment()
      Defines the alignment of the column.
      Returns:
      the alignment or null if default
    • setAlignment

      void setAlignment(javafx.geometry.Pos alignment)
      Sets the alignment within the cell.
      Parameters:
      alignment - the alignment
    • isBlankZero

      Boolean isBlankZero()
      Defines the "blankzero" attribute of the column.
      Returns:
      true if blank zeros, false if not, null if use default from editor
    • setBlankZero

      void setBlankZero(Boolean blankZero)
      Sets whether to blank out numeric zero values.
      Parameters:
      blankZero - true if blank zeros, false if not, null if use default from editor
    • setUnsigned

      void setUnsigned(Boolean unsigned)
      Sets whether a numeric field is unsigned or signed.
      Parameters:
      unsigned - true if unsigned, null if use default from editor
    • isUnsigned

      Boolean isUnsigned()
      Returns whether a numeric field is unsigned or signed.
      Returns:
      true if unsigned, null if use default from editor
    • setValidChars

      void setValidChars(String validChars)
      Sets allowed characters.
      Parameters:
      validChars - the valid characters, null to use default from editor
    • getValidChars

      String getValidChars()
      Gets allowed characters.
      Returns:
      the valid characters, null to use default from editor
    • setInvalidChars

      void setInvalidChars(String invalidChars)
      Sets invalid characters.
      Parameters:
      invalidChars - the invalid characters, null to use default from editor
    • getInvalidChars

      String getInvalidChars()
      Gets invalid characters.
      Returns:
      the invalid characters, null to use default from editor
    • isAutoSelect

      Boolean isAutoSelect()
      Gets the autoselect flag.
      Returns:
      true if autoselect, false if not, null if use default from editor
    • setAutoSelect

      void setAutoSelect(Boolean autoSelect)
      Sets the autoselect feature.
      Parameters:
      autoSelect - true if autoselect, false if not, null if use default from editor
    • getMaxColumns

      Integer getMaxColumns()
      Gets the maximum columns for text cell editors.
      Returns:
      the max columns, null if not defined
    • setMaxColumns

      void setMaxColumns(Integer maxColumns)
      Sets the max columns.
      Parameters:
      maxColumns - the max columns, null if not defined
    • getScale

      Integer getScale()
      Gets the scale for fractional numeric cell editors.
      Returns:
      the scale, null if not defined
    • setScale

      void setScale(Integer scale)
      Sets the numeric scale.
      Parameters:
      scale - the scale, null if not defined
    • getCaseConversion

      Boolean getCaseConversion()
      Gets the case conversion.
      Returns:
      true = convert to uppercase, false = lowercase, null = no conversion (default)
    • setCaseConversion

      void setCaseConversion(Boolean caseConversion)
      Sets the case conversion.
      Parameters:
      caseConversion - true = convert to uppercase, false = lowercase, null = no conversion (default)
    • isSummable

      boolean isSummable()
      Determines whether the column is summable.
      Returns:
      true if column is summable
    • setSummable

      void setSummable(Boolean summable)
      Sets whether the column is summable.
      Parameters:
      summable - Boolean.TRUE if summable, Boolean.FALSE if not, NULL if numeric type
    • getSummable

      Boolean getSummable()
      Returns whether the column is summable.
      Returns:
      Boolean.TRUE if summable, Boolean.FALSE if not, NULL if numeric type
    • getEditable

      Boolean getEditable()
      Returns whether the column is editable.
      Returns:
      Boolean.TRUE if editable, Boolean.FALSE if not, NULL if depends on table configuration
    • setEditable

      void setEditable(Boolean editable)
      Sets whether the column is editable.
      Parameters:
      editable - Boolean.TRUE if editable, Boolean.FALSE if not, NULL if depends on table configuration
    • isEditable

      boolean isEditable()
      Returns whether column is editable.
      Returns:
      true if editable, the default is false
    • getEditor

      FxComponent getEditor()
      Gets the editor component.
      Returns:
      the editor, null to use default from TableCellType.getEditor()
    • setEditor

      void setEditor(FxComponent editor)
      Sets the editor component.
      Parameters:
      editor - the editor, null to use default from TableCellType.getEditor()
    • getBinding

      FxTableBinding<S,T> getBinding()
      Gets the binding for this column.
      Returns:
      the binding, null if none
    • setBinding

      void setBinding(FxTableBinding<S,T> binding)
      Sets the binding.
      Parameters:
      binding - the binding
    • getTableColumn

      javafx.scene.control.TableColumn<S,T> getTableColumn()
      Gets or creates the table column.
      Used if configuration applies to a TableView.
      Returns:
      the table column, never null
    • getTreeTableColumn

      javafx.scene.control.TreeTableColumn<S,T> getTreeTableColumn()
      Gets or creates the tree table column.
      Used if configuration applies to a TreeTableView.
      Returns:
      the tree table column, never null