|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjavax.swing.table.AbstractTableModel
faa.tg.departure.client.DepartureTableModel
class DepartureTableModel
This class defines DepartureTableModel which is the model that controls a departure table.
| Field Summary | |
|---|---|
static int |
COL_ACID
|
static int |
COL_DEPT_APT
|
static int |
COL_DEPT_RWY
|
static int |
COL_FLYING_STATUS
|
static int |
COL_NAS_SECTOR
|
static int |
COL_START_TIME
|
static ColumnHeaders[] |
COLUMN_DATA
defines the headers for the table columns |
static java.lang.String |
CVS_VERSION_ID
The CVS Version ID |
private DepartureTableComparator |
dataComparator
|
private java.util.Vector |
rowData
|
(package private) static long |
serialVersionUID
|
private DepartureTable |
table
|
| Fields inherited from class javax.swing.table.AbstractTableModel |
|---|
listenerList |
| Constructor Summary | |
|---|---|
DepartureTableModel(DepartureTable table)
Constructor |
|
| Method Summary | |
|---|---|
void |
addRow(DepartureFlight deptFlight)
adds an aircraft to the table |
int |
findPlace(DepartureRow deptRow)
Deprecated. Please call DepartureTableModel.sort(DepartureTableModel, DepartureTableComparator); |
int |
getColumnCount()
Returns the number of columns in the model Required by AbstractTableModel to define |
java.lang.String |
getColumnName(int column)
Returns the name of the given column number |
int |
getIndex(DepartureRow row)
Returns the index of a given departure row |
DepartureRow |
getRow(Acid acid)
get row by acid |
DepartureRow |
getRow(int row)
returns the departure row at the given index |
int |
getRowCount()
Returns the number of rows in the model Required by AbstractTableModel to define |
java.lang.Object |
getValueAt(int row,
int column)
Returns the value for the cell at column and row, or null if unable to find location [row, column] Required by AbstractTableModel to define |
boolean |
isCellEditable(int nRow,
int nCol)
Returns true if the cell at rowIndex and columnIndex is editable. |
void |
mouseClicked(java.awt.event.MouseEvent me)
Required by MouseListener Interface Invoked when the mouse button has been clicked (pressed and released) on a component. |
void |
mouseEntered(java.awt.event.MouseEvent me)
Required by MouseListener Interface Invoked when the mouse enters a component. |
void |
mouseExited(java.awt.event.MouseEvent me)
Required by MouseListener Interface Invoked when the mouse exits a component. |
void |
mousePressed(java.awt.event.MouseEvent me)
Required by MouseListener Interface Invoked when a mouse button has been pressed on a component. |
void |
mouseReleased(java.awt.event.MouseEvent me)
Required by MouseListener Interface Invoked when a mouse button has been released on a component. |
void |
removeRow(DepartureFlight deptFlight)
removes a given aircraft from the table |
void |
setValueAt(java.lang.Object value,
int row,
int column)
Sets the value for the cell at column and row Had to overwrite so that departure runway could be changed |
static void |
sort(DepartureTableModel model,
DepartureTableComparator dataComparator)
Sort a DepartureTable given the DepartureTableModel, and the DepartureTableComparator to use when sorting Based on Andrey's fpEditor sort |
void |
updateRow(Acid acid,
AirportRwyID aptRwyID)
updates the departure rwy of the table given an acid |
void |
updateRow(Acid acid,
SimulationTime startTime)
update a row in the tables start time given an acid |
void |
updateRow(Acid acid,
java.lang.String flyingStatus)
|
| Methods inherited from class javax.swing.table.AbstractTableModel |
|---|
addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getColumnClass, getListeners, getTableModelListeners, removeTableModelListener |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
static final long serialVersionUID
public static final java.lang.String CVS_VERSION_ID
public static final ColumnHeaders[] COLUMN_DATA
private DepartureTable table
public static final int COL_START_TIME
public static final int COL_ACID
public static final int COL_DEPT_APT
public static final int COL_DEPT_RWY
public static final int COL_NAS_SECTOR
public static final int COL_FLYING_STATUS
private java.util.Vector rowData
private DepartureTableComparator dataComparator
| Constructor Detail |
|---|
public DepartureTableModel(DepartureTable table)
DepartureTable - - the departure table the model is controlling| Method Detail |
|---|
public int getRowCount()
getRowCount in interface javax.swing.table.TableModelpublic int getColumnCount()
getColumnCount in interface javax.swing.table.TableModelpublic java.lang.String getColumnName(int column)
getColumnName in interface javax.swing.table.TableModelgetColumnName in class javax.swing.table.AbstractTableModel
public boolean isCellEditable(int nRow,
int nCol)
isCellEditable in interface javax.swing.table.TableModelisCellEditable in class javax.swing.table.AbstractTableModel
public java.lang.Object getValueAt(int row,
int column)
getValueAt in interface javax.swing.table.TableModel
public void setValueAt(java.lang.Object value,
int row,
int column)
setValueAt in interface javax.swing.table.TableModelsetValueAt in class javax.swing.table.AbstractTableModelpublic DepartureRow getRow(Acid acid)
public void addRow(DepartureFlight deptFlight)
public DepartureRow getRow(int row)
public int getIndex(DepartureRow row)
public void removeRow(DepartureFlight deptFlight)
public void updateRow(Acid acid,
AirportRwyID aptRwyID)
public void updateRow(Acid acid,
java.lang.String flyingStatus)
public void updateRow(Acid acid,
SimulationTime startTime)
public int findPlace(DepartureRow deptRow)
public void mouseClicked(java.awt.event.MouseEvent me)
mouseClicked in interface java.awt.event.MouseListenerme - - the MouseEvent to respond topublic void mouseEntered(java.awt.event.MouseEvent me)
mouseEntered in interface java.awt.event.MouseListenerme - - the MouseEvent to respond topublic void mouseExited(java.awt.event.MouseEvent me)
mouseExited in interface java.awt.event.MouseListenerme - - the MouseEvent to respond topublic void mousePressed(java.awt.event.MouseEvent me)
mousePressed in interface java.awt.event.MouseListenerme - - the MouseEvent to respond topublic void mouseReleased(java.awt.event.MouseEvent me)
mouseReleased in interface java.awt.event.MouseListenerme - - the MouseEvent to respond to
public static void sort(DepartureTableModel model,
DepartureTableComparator dataComparator)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||