org.jdesktop.dataset.event
Class RowChangeEvent

java.lang.Object
  extended by java.util.EventObject
      extended by org.jdesktop.dataset.event.RowChangeEvent
All Implemented Interfaces:
java.io.Serializable

public class RowChangeEvent
extends java.util.EventObject

A RowChangeEvent is broadcast by a data table to listeners as rows are changed, on a per-row basis. An EventType enumeration identifies the type of change. A change to a column's value which affects row status results in two events being broadcast, one for the column change and one for the row status change.

Author:
Richard Bair, Patrick Wright
See Also:
Serialized Form

Nested Class Summary
static class RowChangeEvent.EventType
           
 
Field Summary
 
Fields inherited from class java.util.EventObject
source
 
Method Summary
 DataColumn getColumnAffected()
          The column whose value was updated or set to null; will be null if this event is a row status change.
 RowChangeEvent.EventType getEventType()
          The event classification.
 java.lang.Object getPriorColumnValue()
          On a change to a column's value, the column's value before the change.
 DataRow.DataRowStatus getPriorRowStatus()
          On a row status change, the row status before the change.
static RowChangeEvent newCellChangedEvent(DataRow source, DataColumn col, java.lang.Object priorValue, DataRow.DataRowStatus priorStatus)
           
static RowChangeEvent newRowStatusChangeEvent(DataRow source, DataRow.DataRowStatus priorStatus)
           
 
Methods inherited from class java.util.EventObject
getSource, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Method Detail

newRowStatusChangeEvent

public static RowChangeEvent newRowStatusChangeEvent(DataRow source,
                                                     DataRow.DataRowStatus priorStatus)

newCellChangedEvent

public static RowChangeEvent newCellChangedEvent(DataRow source,
                                                 DataColumn col,
                                                 java.lang.Object priorValue,
                                                 DataRow.DataRowStatus priorStatus)

getEventType

public RowChangeEvent.EventType getEventType()
The event classification.


getColumnAffected

public DataColumn getColumnAffected()
The column whose value was updated or set to null; will be null if this event is a row status change.


getPriorColumnValue

public java.lang.Object getPriorColumnValue()
On a change to a column's value, the column's value before the change.


getPriorRowStatus

public DataRow.DataRowStatus getPriorRowStatus()
On a row status change, the row status before the change.



Copyright © 2005 Sun Microsystems All Rights Reserved.