javax.swing.event
Class TableColumnModelEvent

java.lang.Object sample code for java.lang.Object definition code for java.lang.Object 
  extended by java.util.EventObject sample code for java.util.EventObject definition code for java.util.EventObject 
      extended by javax.swing.event.TableColumnModelEvent
All Implemented Interfaces:
Serializable sample code for java.io.Serializable definition code for java.io.Serializable

public class TableColumnModelEvent
extends EventObject sample code for java.util.EventObject definition code for java.util.EventObject

TableColumnModelEvent is used to notify listeners that a table column model has changed, such as a column was added, removed, or moved.

Warning: Serialized objects of this class will not be compatible with future Swing releases. The current serialization support is appropriate for short term storage or RMI between applications running the same version of Swing. As of 1.4, support for long term storage of all JavaBeansTM has been added to the java.beans package. Please see XMLEncoder sample code for java.beans.XMLEncoder definition code for java.beans.XMLEncoder .

See Also:
TableColumnModelListener sample code for javax.swing.event.TableColumnModelListener definition code for javax.swing.event.TableColumnModelListener , Serialized Form

Field Summary
protected  int fromIndex sample code for javax.swing.event.TableColumnModelEvent.fromIndex definition code for javax.swing.event.TableColumnModelEvent.fromIndex
          The index of the column from where it was moved or removed
protected  int toIndex sample code for javax.swing.event.TableColumnModelEvent.toIndex definition code for javax.swing.event.TableColumnModelEvent.toIndex
          The index of the column to where it was moved or added from
 
Fields inherited from class java.util.EventObject sample code for java.util.EventObject definition code for java.util.EventObject
source sample code for java.util.EventObject.source definition code for java.util.EventObject.source
 
Constructor Summary
TableColumnModelEvent sample code for javax.swing.event.TableColumnModelEvent.TableColumnModelEvent(javax.swing.table.TableColumnModel, int, int) definition code for javax.swing.event.TableColumnModelEvent.TableColumnModelEvent(javax.swing.table.TableColumnModel, int, int) (TableColumnModel sample code for javax.swing.table.TableColumnModel definition code for javax.swing.table.TableColumnModel  source, int from, int to)
          Constructs a TableColumnModelEvent object.
 
Method Summary
 int getFromIndex sample code for javax.swing.event.TableColumnModelEvent.getFromIndex() definition code for javax.swing.event.TableColumnModelEvent.getFromIndex() ()
          Returns the fromIndex.
 int getToIndex sample code for javax.swing.event.TableColumnModelEvent.getToIndex() definition code for javax.swing.event.TableColumnModelEvent.getToIndex() ()
          Returns the toIndex.
 
Methods inherited from class java.util.EventObject sample code for java.util.EventObject definition code for java.util.EventObject
getSource sample code for java.util.EventObject.getSource() definition code for java.util.EventObject.getSource() , toString sample code for java.util.EventObject.toString() definition code for java.util.EventObject.toString()
 
Methods inherited from class java.lang.Object sample code for java.lang.Object definition code for java.lang.Object
clone sample code for java.lang.Object.clone() definition code for java.lang.Object.clone() , equals sample code for java.lang.Object.equals(java.lang.Object) definition code for java.lang.Object.equals(java.lang.Object) , finalize sample code for java.lang.Object.finalize() definition code for java.lang.Object.finalize() , getClass sample code for java.lang.Object.getClass() definition code for java.lang.Object.getClass() , hashCode sample code for java.lang.Object.hashCode() definition code for java.lang.Object.hashCode() , notify sample code for java.lang.Object.notify() definition code for java.lang.Object.notify() , notifyAll sample code for java.lang.Object.notifyAll() definition code for java.lang.Object.notifyAll() , wait sample code for java.lang.Object.wait() definition code for java.lang.Object.wait() , wait sample code for java.lang.Object.wait(long) definition code for java.lang.Object.wait(long) , wait sample code for java.lang.Object.wait(long, int) definition code for java.lang.Object.wait(long, int)
 

Field Detail

fromIndex sample code for javax.swing.event.TableColumnModelEvent.fromIndex

protected int fromIndex
The index of the column from where it was moved or removed


toIndex sample code for javax.swing.event.TableColumnModelEvent.toIndex

protected int toIndex
The index of the column to where it was moved or added from

Constructor Detail

TableColumnModelEvent sample code for javax.swing.event.TableColumnModelEvent(javax.swing.table.TableColumnModel, int, int) definition code for javax.swing.event.TableColumnModelEvent(javax.swing.table.TableColumnModel, int, int)

public TableColumnModelEvent(TableColumnModel sample code for javax.swing.table.TableColumnModel definition code for javax.swing.table.TableColumnModel  source,
                             int from,
                             int to)
Constructs a TableColumnModelEvent object.

Parameters:
source - the TableColumnModel that originated the event (typically this)
from - an int specifying the first row in a range of affected rows
to - an int specifying the last row in a range of affected rows
Method Detail

getFromIndex sample code for javax.swing.event.TableColumnModelEvent.getFromIndex() definition code for javax.swing.event.TableColumnModelEvent.getFromIndex()

public int getFromIndex()
Returns the fromIndex. Valid for removed or moved events


getToIndex sample code for javax.swing.event.TableColumnModelEvent.getToIndex() definition code for javax.swing.event.TableColumnModelEvent.getToIndex()

public int getToIndex()
Returns the toIndex. Valid for add and moved events