Class LoadDependentRoutingEditor.LoadDependentRoutingStrategyTableModel

java.lang.Object
javax.swing.table.AbstractTableModel
common.editors.LoadDependentRoutingEditor.LoadDependentRoutingStrategyTableModel
All Implemented Interfaces:
Serializable, TableModel
Enclosing class:
LoadDependentRoutingEditor

protected class LoadDependentRoutingEditor.LoadDependentRoutingStrategyTableModel extends AbstractTableModel
See Also:
  • Field Details

    • columnNames

      protected String[] columnNames
    • colClasses

      protected Class<?>[] colClasses
  • Constructor Details

    • LoadDependentRoutingStrategyTableModel

      public LoadDependentRoutingStrategyTableModel()
  • Method Details

    • getRowCount

      public int getRowCount()
      Returns the number of rows in the model. A JTable uses this method to determine how many rows it should display. This method should be quick, as it is called frequently during rendering.
      Returns:
      the number of rows in the model
      See Also:
    • getColumnCount

      public int getColumnCount()
      Returns the number of columns in the model. A JTable uses this method to determine how many columns it should create and display by default.
      Returns:
      the number of columns in the model
      See Also:
    • getColumnName

      public String getColumnName(int columnIndex)
      Specified by:
      getColumnName in interface TableModel
      Overrides:
      getColumnName in class AbstractTableModel
    • getColumnClass

      public Class<?> getColumnClass(int columnIndex)
      Returns class describing data contained in specific column.
      Specified by:
      getColumnClass in interface TableModel
      Overrides:
      getColumnClass in class AbstractTableModel
    • getValueAt

      public Object getValueAt(int rowIndex, int columnIndex)
      Returns the value for the cell at columnIndex and rowIndex.
      Parameters:
      rowIndex - the row whose value is to be queried
      columnIndex - the column whose value is to be queried
      Returns:
      the value Object at the specified cell
    • isCellEditable

      public boolean isCellEditable(int rowIndex, int columnIndex)
      Tells whether data contained in a specific cell(given row and column index) is editable or not. In this case distribution column is not editable, as editing functionality is implemented via edit button
      Specified by:
      isCellEditable in interface TableModel
      Overrides:
      isCellEditable in class AbstractTableModel
    • setValueAt

      public void setValueAt(Object aValue, int rowIndex, int columnIndex)
      Puts edited values to the underlying data structure for model implementation
      Specified by:
      setValueAt in interface TableModel
      Overrides:
      setValueAt in class AbstractTableModel