Module omix.api

Interface Table

All Superinterfaces:
Table
All Known Subinterfaces:
HHeaderTable, HVHeadersTable, VHeaderTable

public interface Table
extends Table
This interface represents a table in the data manager sidebar available for mutation within plug-ins.
Since:
Omix 1.8.5
Author:
Dr. Peter Droste
  • Method Details

    • setValue

      void setValue​(int row, int column, Object value)
      Sets the table content at the given position.
      Parameters:
      row -
      column -
      value -
    • transposed

      Table transposed()
      Description copied from interface: Table
      Returns the transposed table matrix of the current table. The returned table is a new object which does no longer represent the actual table representation in the data manager sidebar, i.e. Table.getSelection() will always return an empty list.
      Specified by:
      transposed in interface Table
      Returns:
      transposed table
      See Also:
      Table.transposed()
    • toHVHeadersTable

      HVHeadersTable toHVHeadersTable()
      Description copied from interface: Table
      Returns a table with horizontal and vertical header.
      1. If the original table is already a HVHeadersTable, the table itself is returned.
      2. If the table is a plain table the first data row is used as horizontal header and the first column as vertical header, i.e. all original rows r and columns c must now be accessed by decreased indexes [r-1, c-1]. The cell [0,0] of the original table is skipped at all.
      3. If the table is a HHeaderTable the first column is used as vertical header, i.e. all original columns c must now be accessed by a decreased index c-1. The first column label of the original table is skipped at all.
      Except in case 1, the returned table is a new object which does no longer represent the actual table representation in the data manager sidebar, i.e. Table.getSelection() will always return an empty list.
      Specified by:
      toHVHeadersTable in interface Table
      Returns:
      HVHeadersTable
      See Also:
      Table.toHVHeadersTable()
    • toHorizontalHeaderTable

      HHeaderTable toHorizontalHeaderTable()
      Description copied from interface: Table
      Returns a table with a horizontal header.
      1. If the original table is already a HHeaderTable, the table itself is returned.
      2. If the table is a plain table the first data row is used as horizontal header, i.e. all original rows r must now be accessed by a decreased index r-1.
      3. If the table is a VHeaderTable the vertical header is inserted as first data column, i.e. all original columns c must now be accessed by an increased index c+1. The first data row is used as horizontal header, i.e. all original rows r must now be accessed by a decreased index r-1.
      4. If the table is a HVHeadersTable the vertical header is inserted as first data column, i.e. all original columns c must now be accessed by an increased index c+1.
      Except in case 1, the returned table is a new object which does no longer represent the actual table representation in the data manager sidebar, i.e. Table.getSelection() will always return an empty list.
      Specified by:
      toHorizontalHeaderTable in interface Table
      Returns:
      HHeaderTable
      See Also:
      Table.toHorizontalHeaderTable()
    • toVerticalHeaderTable

      VHeaderTable toVerticalHeaderTable()
      Description copied from interface: Table
      Returns a table with a vertical header.
      1. If the original table is already a VHeaderTable, the table itself is returned.
      2. If the table is a plain table the first data column is used as vertical header, i.e. all original columns c must now be accessed by a decreased index c-1.
      3. If the table is a HVHeadersTable the horizontal header is inserted as first data row, i.e. all original rows r must now be accessed by an increased index r+1.
      4. If the table is a HHeaderTable the horizontal header is inserted as first data row, i.e. all original rows r must now be accessed by an increased index r+1. The first data column is used as vertical header, i.e. all original columns c must now be accessed by a decreased index c-1.
      Except in case 1, the returned table is a new object which does no longer represent the actual table representation in the data manager sidebar, i.e. Table.getSelection() will always return an empty list.
      Specified by:
      toVerticalHeaderTable in interface Table
      Returns:
      HHeaderTable
      See Also:
      Table.toVerticalHeaderTable()
    • toPlainTable

      Table toPlainTable()
      Description copied from interface: Table
      Returns a table without headers.
      1. If the original table is already plain, the table itself is returned.
      2. If the table is a HHeaderTable the horizontal header is inserted as first data row, i.e. all original rows r must now be accessed by an increased index r+1.
      3. If the table is a VHeaderTable the vertical header is inserted as first data column, i.e. all original columns c must now be accessed by an increased index c+1.
      4. If the table is a HVHeadersTable, additionally, the vertically header is inserted as first data column, i.e. all original columns c must now be accessed by an increased index c+1.
      Except in case 1, the returned table is a new object which does no longer represent the actual table representation in the data manager sidebar, i.e. Table.getSelection() will always return an empty list.
      Specified by:
      toPlainTable in interface Table
      Returns:
      plain table
      See Also:
      Table.toPlainTable()
    • canGet

      boolean canGet()
      Can the Table.getValue(int, int) method be used?
      Returns:
      can get
    • canSet

      boolean canSet()
      Can the setValue(int, int, Object) method be used?
      Returns:
      can set
    • isModified

      boolean isModified()
      Has the table been modified?
      Returns:
      modified
    • getOriginalDataMatrix

      <T extends DataMatrixInterface> T getOriginalDataMatrix​(Class<T> dataMatrixInterface)
      Returns the original DataMatrixInterface instance behind this table if the given class matches to the data matrixes type, otherwise null.
      Parameters:
      dataMatrixInterface - type of the data matrix instance.
      Returns:
      instance of DataMatrixInterface
      Since:
      Omix 1.9.0
    • setSelection

      void setSelection​(List<Table.SelectedContent> selection)
      Set the selection of the table. This method does not set the current selection in the table editor widget!
      Parameters:
      selection - list of selection elements
    • addDataMatrixChangeListener

      void addDataMatrixChangeListener​(DataMatrixChangeListener listener)
      Parameters:
      listener -
      Since:
      Omix 1.8.6
    • removeDataMatrixChangeListener

      void removeDataMatrixChangeListener​(DataMatrixChangeListener listener)
      Parameters:
      listener -
      Since:
      Omix 1.8.6