Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

com.paradoxpoint.libitina.monument
Class MonumentTableModel  view MonumentTableModel download MonumentTableModel.java

java.lang.Object
  extended byjavax.swing.table.AbstractTableModel
      extended bycom.paradoxpoint.libitina.monument.MonumentTableModel
All Implemented Interfaces:
java.util.EventListener, javax.swing.event.ListDataListener, MonumentListener, java.io.Serializable, javax.swing.table.TableModel

public final class MonumentTableModel
extends javax.swing.table.AbstractTableModel
implements MonumentListener


Field Summary
private  java.lang.String[] columnNames
           
private  Monument data
           
private static int EDITABLE
           
private static int HEIGHT
           
private static int MIRRORED
           
private static int NAME
           
private static int ROTATION
           
private static int SOURCE
           
private static int VISIBLE
           
private static int WIDTH
           
private static int X
           
private static int Y
           
 
Fields inherited from class javax.swing.table.AbstractTableModel
listenerList
 
Constructor Summary
MonumentTableModel()
          Creates a new instance of MonumentTableModel
MonumentTableModel(Monument monument)
           
MonumentTableModel(PositionBiasMode monumentMode)
           
 
Method Summary
 void contentsChanged(javax.swing.event.ListDataEvent e)
          Notifies the listener that the contents of the list have changed in some way.
 java.lang.Class getColumnClass(int columnIndex)
          Returns the Class for all Object instances in the specified column.
 int getColumnCount()
          Returns the number of columns in the model.
 java.lang.String getColumnName(int column)
          Returns the name of the specified column.
 Monument getMonument()
           
 int getRowCount()
          Returns the number of rows in the model.
 java.lang.Object getValueAt(int rowIndex, int columnIndex)
          Returns the value (Object) at a particular cell in the table.
 void intervalAdded(javax.swing.event.ListDataEvent e)
          Notifies the listener that one or more items have been added to the list.
 void intervalRemoved(javax.swing.event.ListDataEvent e)
          Notifies the listener that one or more items have been removed from the list.
 boolean isCellEditable(int rowIndex, int columnIndex)
          Returns true if the specified cell is editable, and false if it is not.
 void setValueAt(java.lang.Object aValue, int rowIndex, int columnIndex)
          Sets the value of the given cell.
 
Methods inherited from class javax.swing.table.AbstractTableModel
addTableModelListener, findColumn, fireTableCellUpdated, fireTableChanged, fireTableDataChanged, fireTableRowsDeleted, fireTableRowsInserted, fireTableRowsUpdated, fireTableStructureChanged, getListeners, getTableModelListeners, removeTableModelListener
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

data

private Monument data

VISIBLE

private static final int VISIBLE
See Also:
Constant Field Values

EDITABLE

private static final int EDITABLE
See Also:
Constant Field Values

NAME

private static final int NAME
See Also:
Constant Field Values

WIDTH

private static final int WIDTH
See Also:
Constant Field Values

HEIGHT

private static final int HEIGHT
See Also:
Constant Field Values

X

private static final int X
See Also:
Constant Field Values

Y

private static final int Y
See Also:
Constant Field Values

ROTATION

private static final int ROTATION
See Also:
Constant Field Values

MIRRORED

private static final int MIRRORED
See Also:
Constant Field Values

SOURCE

private static final int SOURCE
See Also:
Constant Field Values

columnNames

private java.lang.String[] columnNames
Constructor Detail

MonumentTableModel

public MonumentTableModel(Monument monument)

MonumentTableModel

public MonumentTableModel(PositionBiasMode monumentMode)

MonumentTableModel

public MonumentTableModel()
Creates a new instance of MonumentTableModel

Method Detail

getColumnClass

public java.lang.Class getColumnClass(int columnIndex)
Description copied from class: javax.swing.table.AbstractTableModel
Returns the Class for all Object instances in the specified column.

Specified by:
getColumnClass in interface javax.swing.table.TableModel

getColumnCount

public int getColumnCount()
Description copied from interface: javax.swing.table.TableModel
Returns the number of columns in the model.

Specified by:
getColumnCount in interface javax.swing.table.TableModel

getColumnName

public java.lang.String getColumnName(int column)
Description copied from class: javax.swing.table.AbstractTableModel
Returns the name of the specified column. This method generates default names in a sequence (starting with column 0): A, B, C, ..., Z, AA, AB, AC, ..., AZ, BA, BB, BC, and so on. Subclasses may override this method to allow column names to be specified on some other basis.

Specified by:
getColumnName in interface javax.swing.table.TableModel

contentsChanged

public void contentsChanged(javax.swing.event.ListDataEvent e)
Description copied from interface: javax.swing.event.ListDataListener
Notifies the listener that the contents of the list have changed in some way. This method will be called if the change cannot be notified via the ListDataListener.intervalAdded(ListDataEvent)>ListDataListener.intervalAdded(ListDataEvent) 55 or the ListDataListener.intervalRemoved(ListDataEvent)>ListDataListener.intervalRemoved(ListDataEvent) 55 methods.

Specified by:
contentsChanged in interface javax.swing.event.ListDataListener

getMonument

public Monument getMonument()

getRowCount

public int getRowCount()
Description copied from interface: javax.swing.table.TableModel
Returns the number of rows in the model.

Specified by:
getRowCount in interface javax.swing.table.TableModel

getValueAt

public java.lang.Object getValueAt(int rowIndex,
                                   int columnIndex)
Description copied from interface: javax.swing.table.TableModel
Returns the value (Object) at a particular cell in the table.

Specified by:
getValueAt in interface javax.swing.table.TableModel

intervalAdded

public void intervalAdded(javax.swing.event.ListDataEvent e)
Description copied from interface: javax.swing.event.ListDataListener
Notifies the listener that one or more items have been added to the list. The event argument can supply the indices for the range of items added.

Specified by:
intervalAdded in interface javax.swing.event.ListDataListener

intervalRemoved

public void intervalRemoved(javax.swing.event.ListDataEvent e)
Description copied from interface: javax.swing.event.ListDataListener
Notifies the listener that one or more items have been removed from the list. The event argument can supply the indices for the range of items removed.

Specified by:
intervalRemoved in interface javax.swing.event.ListDataListener

isCellEditable

public boolean isCellEditable(int rowIndex,
                              int columnIndex)
Description copied from class: javax.swing.table.AbstractTableModel
Returns true if the specified cell is editable, and false if it is not. This implementation returns false for all arguments, subclasses should override the method if necessary.

Specified by:
isCellEditable in interface javax.swing.table.TableModel

setValueAt

public void setValueAt(java.lang.Object aValue,
                       int rowIndex,
                       int columnIndex)
Description copied from class: javax.swing.table.AbstractTableModel
Sets the value of the given cell. This implementation ignores all arguments and does nothing, subclasses should override the method if necessary.

Specified by:
setValueAt in interface javax.swing.table.TableModel