public class SyntaxTableModel extends MidicaTableModel
This class represents the data model of the syntax table in the configuration details view of the info window.
Each row represents either a command category or a syntax command.
Modifier and Type | Field and Description |
---|---|
private static long |
serialVersionUID |
private java.util.ArrayList<SyntaxElement> |
syntaxList |
columnClasses, columnNames, sortableColumns
Constructor and Description |
---|
SyntaxTableModel()
Creates a new instance of the syntax table data model.
|
Modifier and Type | Method and Description |
---|---|
java.util.ArrayList<CategorizedElement> |
getCategorizedRows()
Returns null, if not overridden by a child model class.
|
int |
getRowCount()
Returns the number of rows in the table - same as the sum of syntax commands and categories.
|
java.lang.Object |
getValueAt(int rowIndex,
int colIndex)
Returns the String value to be written into the specified table cell.
|
getCategorizedHashMapRows, getColumnClass, getColumnCount, getColumnName, getHeaderTooltip, isCellEditable, isSortable, setHeaderToolTip
addColumn, addColumn, addColumn, addRow, addRow, convertToVector, convertToVector, getDataVector, insertRow, insertRow, moveRow, newDataAvailable, newRowsAdded, removeRow, rowsRemoved, setColumnCount, setColumnIdentifiers, setColumnIdentifiers, setDataVector, setDataVector, setNumRows, setRowCount, setValueAt
addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getListeners, getTableModelListeners, removeTableModelListener
private static final long serialVersionUID
private java.util.ArrayList<SyntaxElement> syntaxList
public SyntaxTableModel()
Creates a new instance of the syntax table data model. Initializes the table header names according to the currently configured syntax and language.
public int getRowCount()
Returns the number of rows in the table - same as the sum of syntax commands and categories.
getRowCount
in interface javax.swing.table.TableModel
getRowCount
in class MidicaTableModel
public java.lang.Object getValueAt(int rowIndex, int colIndex)
Returns the String value to be written into the specified table cell.
getValueAt
in interface javax.swing.table.TableModel
getValueAt
in class MidicaTableModel
rowIndex
- Queried table row index.colIndex
- Queried table column index.public java.util.ArrayList<CategorizedElement> getCategorizedRows()
MidicaTableModel
Returns null, if not overridden by a child model class. Can be overridden to return the underlying data list, if it contains categorized data. That’s needed for the sorter to be able to hide categories, if the sorting is different from the model’s default sorting.
getCategorizedRows
in class MidicaTableModel