Public Member Functions | |
MixListTableModel () | |
MixListTableModel (Element a_mixList) | |
int | getColumnCount () |
int | getRowCount () |
Class<?> | getColumnClass (int columnIndex) |
String | getColumnName (int columnIndex) |
Object | getValueAt (int rowIndex, int columnIndex) |
void | setValueAt (Object value, int rowIndex, int columnIndex) |
boolean | isCellEditable (int row, int col) |
Object[] | getRow (int rowIndex) |
void | addRow (Object a_mix[]) |
void | addRow (Element a_mix) |
void | removeRow (Object a_mle) |
void | removeRow (int rowIndex) |
void | moveRow (int src, int dest) |
Node | toXmlElement (Document a_doc) |
Package Attributes | |
Vector< Object[]> | mixList = new Vector<Object[]>() |
Private Member Functions | |
String | getElementData (Element a_parent, String a_elementName) |
Private Attributes | |
final String | columnName [] |
mixconfig.panels.CascadePanel.MixListTableModel.MixListTableModel | ( | ) |
Constructs a new empty instance of MixListTableModel
mixconfig.panels.CascadePanel.MixListTableModel.MixListTableModel | ( | Element | a_mixList | ) |
Constructs a new instance of MixListTableModel
.
a_mixList | The list of mixes to be contained in the table model as an XML/DOM element |
References mixconfig.panels.CascadePanel.MixListTableModel.addRow(), and mixconfig.panels.CascadePanel.MixListTableModel.getElementData().
int mixconfig.panels.CascadePanel.MixListTableModel.getColumnCount | ( | ) |
int mixconfig.panels.CascadePanel.MixListTableModel.getRowCount | ( | ) |
Class<?> mixconfig.panels.CascadePanel.MixListTableModel.getColumnClass | ( | int | columnIndex | ) |
String mixconfig.panels.CascadePanel.MixListTableModel.getColumnName | ( | int | columnIndex | ) |
Object mixconfig.panels.CascadePanel.MixListTableModel.getValueAt | ( | int | rowIndex, | |
int | columnIndex | |||
) |
void mixconfig.panels.CascadePanel.MixListTableModel.setValueAt | ( | Object | value, | |
int | rowIndex, | |||
int | columnIndex | |||
) |
boolean mixconfig.panels.CascadePanel.MixListTableModel.isCellEditable | ( | int | row, | |
int | col | |||
) |
Object [] mixconfig.panels.CascadePanel.MixListTableModel.getRow | ( | int | rowIndex | ) |
Gets the entry at the specified index
rowIndex | The index of the row to be returned |
Object
References mixconfig.panels.CascadePanel.MixListTableModel.mixList.
Referenced by mixconfig.panels.CascadePanel.moveMix().
void mixconfig.panels.CascadePanel.MixListTableModel.addRow | ( | Object | a_mix[] | ) |
Adds an entry to the table model. The array representing the entry must have 5 fields: Mix ID, mix name, location (City), type (FirstMix, MiddleMix, LastMix), and desired cascade length (a String
reprentation of an int value, or null
).
a_mix | An array of Object holding the mix data. |
References mixconfig.panels.CascadePanel.MixListTableModel.getRowCount(), mixconfig.panels.CascadePanel.MixListTableModel.getValueAt(), mixconfig.panels.CascadePanel.m_availableMixTable, mixconfig.panels.CascadePanel.m_configuredMixTable, and mixconfig.panels.CascadePanel.MixListTableModel.mixList.
Referenced by mixconfig.panels.CascadePanel.MixListTableModel.addRow(), mixconfig.panels.CascadePanel.MixListTableModel.MixListTableModel(), and mixconfig.panels.CascadePanel.moveMix().
void mixconfig.panels.CascadePanel.MixListTableModel.addRow | ( | Element | a_mix | ) |
Adds an entry to the table model. The Element
representing the entry must have one attribute named "id" containing the mix ID, and one or more of the following child nodes:
a_mix | The DOM element containing the mix data |
References mixconfig.panels.CascadePanel.MixListTableModel.addRow(), mixconfig.panels.CascadePanel.MixListTableModel.getColumnCount(), and mixconfig.panels.CascadePanel.MixListTableModel.getElementData().
void mixconfig.panels.CascadePanel.MixListTableModel.removeRow | ( | Object | a_mle | ) |
Removes the specified object from the list of entries.
a_mle | An array of Object representing a mix list entry |
References mixconfig.panels.CascadePanel.MixListTableModel.mixList.
Referenced by mixconfig.panels.CascadePanel.moveMix().
void mixconfig.panels.CascadePanel.MixListTableModel.removeRow | ( | int | rowIndex | ) |
Removes the object at the specified index from the list of entries.
rowIndex | The index of the entry to be removed |
References mixconfig.panels.CascadePanel.MixListTableModel.mixList.
void mixconfig.panels.CascadePanel.MixListTableModel.moveRow | ( | int | src, | |
int | dest | |||
) |
Moves a row from one index to another. The other rows are shifted accordingly.
src | The index of the row to be moved | |
dest | The destination index |
References mixconfig.panels.CascadePanel.m_configuredMixTable, and mixconfig.panels.CascadePanel.MixListTableModel.mixList.
Node mixconfig.panels.CascadePanel.MixListTableModel.toXmlElement | ( | Document | a_doc | ) |
Converts the data in this model to a XML/DOM structure.
a_doc | The document for which the resulting element will be created |
DocumentFragment
object containing the mix list entries as elements (<Mix id="...">...</Mix>
) References mixconfig.panels.MixConfigPanel.getConfiguration(), mixconfig.MixConfiguration.getValue(), and mixconfig.panels.CascadePanel.MixListTableModel.mixList.
String mixconfig.panels.CascadePanel.MixListTableModel.getElementData | ( | Element | a_parent, | |
String | a_elementName | |||
) | [private] |
Searches the specified element for a child node with the specified name, and returns the first text node under that element (if found; null
otherwise).
a_parent | The parent element to be searched | |
a_elementName | The name of the child element whose text node is to be returned |
String
, or null
if there is no such node Referenced by mixconfig.panels.CascadePanel.MixListTableModel.addRow(), and mixconfig.panels.CascadePanel.MixListTableModel.MixListTableModel().
final String mixconfig.panels.CascadePanel.MixListTableModel.columnName[] [private] |
Initial value:
{"Mix ID", "Mix name", "Location", "Type"}
Referenced by mixconfig.panels.CascadePanel.MixListTableModel.getColumnName().
Vector<Object[]> mixconfig.panels.CascadePanel.MixListTableModel.mixList = new Vector<Object[]>() [package] |
The list of mix entries
Referenced by mixconfig.panels.CascadePanel.MixListTableModel.addRow(), mixconfig.panels.CascadePanel.MixListTableModel.getRow(), mixconfig.panels.CascadePanel.MixListTableModel.getRowCount(), mixconfig.panels.CascadePanel.MixListTableModel.getValueAt(), mixconfig.panels.CascadePanel.MixListTableModel.moveRow(), mixconfig.panels.CascadePanel.MixListTableModel.removeRow(), mixconfig.panels.CascadePanel.MixListTableModel.setValueAt(), and mixconfig.panels.CascadePanel.MixListTableModel.toXmlElement().