APIdia Launch Partner
Top Description Fields Constructors Methods
javax.swing.event

public Class TableColumnModelEvent

extends EventObject
Class Inheritance
Annotations
@SuppressWarnings:serial
Imports
java.util.EventObject, javax.swing.table.*

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 JavaBeans has been added to the java.beans package. Please see java.beans.XMLEncoder.

Author
Alan Chung
See Also
TableColumnModelListener

Field Summary

Modifier and TypeField and Description
protected int
fromIndex

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

protected int
toIndex

The index of the column to where it was moved or added

Inherited from java.util.EventObject:
source

Constructor Summary

AccessConstructor and Description
public
TableColumnModelEvent(TableColumnModel
the TableColumnModel that originated the event
source
,
int
an int specifying the index from where the column was moved or removed
from
,
int
an int specifying the index to where the column was moved or added
to
)

Constructs a TableColumnModelEvent object.

Method Summary

Modifier and TypeMethod and Description
public int

Returns:

int value for index from which the column was moved or removed
getFromIndex
()

Returns the fromIndex.

public int

Returns:

int value of column's new index
getToIndex
()

Returns the toIndex.

Inherited from java.util.EventObject:
getSourcetoString

Field Detail

fromIndexback to summary
protected int fromIndex

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

toIndexback to summary
protected int toIndex

The index of the column to where it was moved or added

Constructor Detail

TableColumnModelEventback to summary
public TableColumnModelEvent(TableColumnModel source, int from, int to)

Constructs a TableColumnModelEvent object.

Parameters
source:TableColumnModel

the TableColumnModel that originated the event

from:int

an int specifying the index from where the column was moved or removed

to:int

an int specifying the index to where the column was moved or added

See Also
getFromIndex, getToIndex

Method Detail

getFromIndexback to summary
public int getFromIndex()

Returns the fromIndex. Valid for removed or moved events

Returns:int

int value for index from which the column was moved or removed

getToIndexback to summary
public int getToIndex()

Returns the toIndex. Valid for add and moved events

Returns:int

int value of column's new index