ilog.ds
Class RowEvent

java.lang.Object
  |
  +--java.util.EventObject
        |
        +--ilog.ds.AbstractDSEvent
              |
              +--ilog.ds.RowEvent
All Implemented Interfaces:
Serializable

public class RowEvent
extends AbstractDSEvent

Event class used for all row and cell events happening on a TableDataSource object.

See Also:
IlTableDataSource, Serialized Form

Field Summary
protected  IlTableCellInfo[] _cellInfos
           
protected  int _index
           
protected  Object _row
           
static int AT_END
           
 
Fields inherited from class ilog.ds.AbstractDSEvent
_properties, _type, ADD, REMOVE, UPDATE
 
Fields inherited from class java.util.EventObject
source
 
Constructor Summary
protected RowEvent(Object source, int type, int index, Object row, Map properties, IlTableCellInfo[] cellInfos)
           
  RowEvent(Object source, Object row)
          Constructor used to generate an event when a row is deleted from a table data source.
  RowEvent(Object source, Object row, Map properties, IlTableCellInfo[] cellInfos)
          Constructor used to generate an event when a row is updated in a table data source.
  RowEvent(Object source, Object row, Map properties, IlTableCellInfo[] cellInfos, int index)
          Constructor used to generate an event when a row is added in a table data source.
 
Method Summary
 IlTableCellInfo[] getCellInfos()
           
 int getIndex()
          Gets the index where the row should be inserted.
 Object getRow()
          Gets the row (to be used only as a key)
 int getType()
          Gets the type of event.
 
Methods inherited from class ilog.ds.AbstractDSEvent
getProperties
 
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
 

Field Detail

AT_END

public static final int AT_END

_index

protected int _index

_row

protected Object _row

_cellInfos

protected IlTableCellInfo[] _cellInfos
Constructor Detail

RowEvent

protected RowEvent(Object source,
                   int type,
                   int index,
                   Object row,
                   Map properties,
                   IlTableCellInfo[] cellInfos)

RowEvent

public RowEvent(Object source,
                Object row,
                Map properties,
                IlTableCellInfo[] cellInfos,
                int index)
Constructor used to generate an event when a row is added in a table data source.
Parameters:
source - The sender of the event (the TableDataSource)
row -  
cellInfos -  
index - The position where the row should be inserted. The value AT_END means insertion after last row.
See Also:
IlTableDataSource

RowEvent

public RowEvent(Object source,
                Object row)
Constructor used to generate an event when a row is deleted from a table data source.
Parameters:
source - The sender of the event (the TableDataSource)
row - The row in the TableDataSource
See Also:
IlTableDataSource

RowEvent

public RowEvent(Object source,
                Object row,
                Map properties,
                IlTableCellInfo[] cellInfos)
Constructor used to generate an event when a row is updated in a table data source.
Parameters:
source - The sender of the event (the TableDataSource)
row -  
properties -  
cellInfos -  
See Also:
IlTableDataSource
Method Detail

getType

public int getType()
Gets the type of event.
Overrides:
getType in class AbstractDSEvent
Returns:
a type that can be ADD, REMOVE, or UPDATE.

getRow

public Object getRow()
Gets the row (to be used only as a key)
Returns:
the subject of this event

getCellInfos

public IlTableCellInfo[] getCellInfos()
Returns:
a TableCellInfo array. Used for the events of type ADD and UPDATE. This array only contains updated cells (property or value) of the row in an UPDATE event. and contains all cells of the new row in an ADD event.
See Also:
IlTableCellInfo

getIndex

public int getIndex()
Gets the index where the row should be inserted. The value AT_END means insertion after last row.
Returns:
the index of the row in a ROW_ADD event.