Class RosterGroupTableModel
- java.lang.Object
-
- javax.swing.table.AbstractTableModel
-
- jmri.jmrit.roster.swing.rostergroup.RosterGroupTableModel
-
- All Implemented Interfaces:
java.io.Serializable
,javax.swing.table.TableModel
public class RosterGroupTableModel extends javax.swing.table.AbstractTableModel
Table data model for display of Rosters entries to a specific Roster Group.Any desired ordering, etc, is handled outside this class.
The initial implementation doesn't automatically update when roster entries change, it only allows the setting of a roster entry, to a roster group. Based Upon RosterTableModel
- Since:
- 2.7.5
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description (package private) static int
ADDTOGROUPCOL
(package private) java.lang.String
group
(package private) static int
IDCOL
(package private) static int
MFGCOL
(package private) static int
NUMCOL
(package private) static int
OWNERCOL
(package private) static int
ROADNAMECOL
(package private) static int
ROADNUMBERCOL
-
Constructor Summary
Constructors Constructor Description RosterGroupTableModel()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
configureTable(javax.swing.JTable table)
void
dispose()
java.lang.Class<?>
getColumnClass(int col)
int
getColumnCount()
java.lang.String
getColumnName(int col)
void
getGroupEnabled(RosterEntry re)
int
getPreferredWidth(int col)
int
getRowCount()
java.lang.Object
getValueAt(int row, int col)
Provides the empty String if attribute doesn't exist.boolean
isCellEditable(int row, int col)
This implementation can't edit the values yetvoid
setGroup(java.lang.String grp)
void
setValueAt(java.lang.Object value, int row, int col)
-
Methods inherited from class javax.swing.table.AbstractTableModel
addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getListeners, getTableModelListeners, removeTableModelListener
-
-
-
-
Field Detail
-
IDCOL
static final int IDCOL
- See Also:
- Constant Field Values
-
ROADNUMBERCOL
static final int ROADNUMBERCOL
- See Also:
- Constant Field Values
-
ROADNAMECOL
static final int ROADNAMECOL
- See Also:
- Constant Field Values
-
MFGCOL
static final int MFGCOL
- See Also:
- Constant Field Values
-
OWNERCOL
static final int OWNERCOL
- See Also:
- Constant Field Values
-
ADDTOGROUPCOL
static final int ADDTOGROUPCOL
- See Also:
- Constant Field Values
-
group
java.lang.String group
-
NUMCOL
static final int NUMCOL
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
RosterGroupTableModel
public RosterGroupTableModel()
-
-
Method Detail
-
getRowCount
public int getRowCount()
-
getColumnCount
public int getColumnCount()
-
getColumnName
public java.lang.String getColumnName(int col)
- Specified by:
getColumnName
in interfacejavax.swing.table.TableModel
- Overrides:
getColumnName
in classjavax.swing.table.AbstractTableModel
-
getPreferredWidth
public int getPreferredWidth(int col)
-
getColumnClass
public java.lang.Class<?> getColumnClass(int col)
- Specified by:
getColumnClass
in interfacejavax.swing.table.TableModel
- Overrides:
getColumnClass
in classjavax.swing.table.AbstractTableModel
-
isCellEditable
public boolean isCellEditable(int row, int col)
This implementation can't edit the values yet- Specified by:
isCellEditable
in interfacejavax.swing.table.TableModel
- Overrides:
isCellEditable
in classjavax.swing.table.AbstractTableModel
-
getValueAt
public java.lang.Object getValueAt(int row, int col)
Provides the empty String if attribute doesn't exist.
-
configureTable
public void configureTable(javax.swing.JTable table)
-
dispose
public void dispose()
-
setValueAt
public void setValueAt(java.lang.Object value, int row, int col)
- Specified by:
setValueAt
in interfacejavax.swing.table.TableModel
- Overrides:
setValueAt
in classjavax.swing.table.AbstractTableModel
-
setGroup
public void setGroup(java.lang.String grp)
-
getGroupEnabled
public void getGroupEnabled(RosterEntry re)
-
-