borland Packages  Class Hierarchy  dx.dataset Package 

DataChangeEvent class

java.lang.Object
   +----java.util.EventObject
           +----com.borland.jb.util.DispatchableEvent
                   +----com.borland.dx.dataset.DataChangeEvent

About the DataChangeEvent class

Variables  Constructors  Properties  Methods  

Implements ExceptionDispatch, Serializable

The DataChangeEvent is the internal event generated when the data in a DataSet is changed. It is passed to DataSet components and listeners of the DataSet. The event ID (see the ID property) indicates the type of data update. Other members provide additional information on the change of the data.

The DataChangeEvent class may be useful for component writers, however, is not recommended for general usage.

The DataChangeListener responds to the DataChangeEvent class.


DataChangeEvent variables

Variables implemented in this class

Variables implemented in java.util.EventObject

DataChangeEvent constructors

DataChangeEvent properties

*Read-only properties **Write-only properties

Properties implemented in this class

Properties implemented in com.borland.jb.util.DispatchableEvent

Properties implemented in java.lang.Object

Properties implemented in java.util.EventObject

DataChangeEvent methods

Methods implemented in this class

Methods implemented in com.borland.jb.util.DispatchableEvent

Methods implemented in java.lang.Object


DataChangeEvent variables

DATA_CHANGED

  public static final int DATA_CHANGED = 5
More than one row of data has changed.

POST_ROW

  public static final int POST_ROW = 6
Notification to listeners that a row is posting. This allows a listener to post unposted field values just before the row is going to be posted.

ROW_ADDED

  public static final int ROW_ADDED = 1
A row was added. Use getRowAffected() to get the new row position.

ROW_CHANGE_POSTED

  public static final int ROW_CHANGE_POSTED = 4
A row was changed and posted. Use getRowAffected() to get the new row position.

ROW_CHANGED

  public static final int ROW_CHANGED = 3
Only a cell changed, row did not post. Use getRowAffected() to get the new row position.

ROW_DELETED

  public static final int ROW_DELETED = 2
A row was deleted. Row member has new row position. Use getRowAffected() to get the new row position.

DataChangeEvent constructors

DataChangeEvent(java.lang.Object, int)

  public DataChangeEvent(Object source, int id)
Constructs a DataChangeEvent object.

DataChangeEvent(java.lang.Object, int, int)

  public DataChangeEvent(Object source, int id, int affectedRow)
Constructs a DataChangeEvent object.

DataChangeEvent properties

ID

 public final int getID()
Read-only property that indicates the type of data change. Return values for this property are constants defined in this class.

rowAffected

 public final int getRowAffected()
Read-only property that returns the row affected by the data change. If the multiRowChange property is false, this property returns the row affected. Otherwise, it returns -1.

DataChangeEvent methods

dispatch(java.util.EventListener)

  public void dispatch(EventListener listener)
This method is used internally by other com.borland classes. You should never use this method directly.

Overrides: com.borland.jb.util.DispatchableEvent.dispatch(java.util.EventListener)

multiRowChange()

  public final boolean multiRowChange()
Specifies whether data in more than one row is affected. Useful for repaint strategies.

toString()

  public String toString()

Returns the concatenation of super.toString and the value of the ID property.

Overrides: com.borland.jb.util.DispatchableEvent.toString()