public class TreeSetModelEvent extends EventObject
IlvTreeSetModel
.TreeSetModelListener
,
Serialized FormModifier and Type | Class and Description |
---|---|
static class |
TreeSetModelEvent.Type
This class defines the event types of the outer event class.
|
source
Constructor and Description |
---|
TreeSetModelEvent(IlvTreeSetModel source,
TreeSetModelEvent.Type type)
Creates an event.
|
TreeSetModelEvent(IlvTreeSetModel source,
TreeSetModelEvent.Type type,
int column,
boolean oldValue,
boolean newValue)
Creates an event.
|
TreeSetModelEvent(IlvTreeSetModel source,
TreeSetModelEvent.Type type,
int column,
IlvDataColumnInfo columnInfo)
Creates an event.
|
TreeSetModelEvent(IlvTreeSetModel source,
TreeSetModelEvent.Type type,
int column,
Object oldValue,
Object newValue)
Creates an event.
|
TreeSetModelEvent(IlvTreeSetModel source,
TreeSetModelEvent.Type type,
Object object,
TreePath objectPath,
boolean recursive,
int column)
Creates an event.
|
TreeSetModelEvent(IlvTreeSetModel source,
TreeSetModelEvent.Type type,
Object parent,
TreePath parentPath,
Object[] objects)
Creates an event.
|
Modifier and Type | Method and Description |
---|---|
int |
getColumn()
Returns the index of the affected column, or -1 for all columns.
|
IlvDataColumnInfo |
getColumnInfo()
Returns the meta information of the affected column, or
null
for all columns. |
IlvTreeSetModel |
getModel()
Returns the model from which this event comes.
|
Object |
getNewValue()
Returns the new value inside the
IlvDataColumnInfo . |
Object |
getObject()
Returns the affected object.
|
TreePath |
getObjectPath()
Returns the path from the root to the affected object.
|
Object[] |
getObjects()
Returns the roots of the affected subtrees.
|
Object |
getOldValue()
Returns the old value inside the
IlvDataColumnInfo . |
Object |
getParent()
Returns the parent object of the roots of the affected subtrees, or
null for a root change. |
TreePath |
getParentPath()
Returns the path from the root to the parent object of the roots of the
affected subtrees, or
null for a root change. |
TreeSetModelEvent.Type |
getType()
Returns the event type.
|
boolean |
isRecursive()
Returns
true if the entire subtree is affected, not just a single object. |
String |
toString()
Returns a
String representation of this event. |
getSource
public TreeSetModelEvent(IlvTreeSetModel source, TreeSetModelEvent.Type type)
You are not meant to use this constructor. SERIES_BEGIN
and SERIES_END
are automatically generated by the class
IlvAbstractTreeSetModel
.
source
- The model.type
- One of SERIES_BEGIN
, SERIES_END
.public TreeSetModelEvent(IlvTreeSetModel source, TreeSetModelEvent.Type type, Object object, TreePath objectPath, boolean recursive, int column)
source
- The model.type
- One of DATA_CHANGED
, BEFORE_DATA_CHANGE
.object
- The object whose attributes have changed.objectPath
- The path from the root to the object.recursive
- true
if the attributes of the entire subtree have
changed, false
for a change affecting only the single
object.column
- Column that changed, or -1 for all columns.public TreeSetModelEvent(IlvTreeSetModel source, TreeSetModelEvent.Type type, Object parent, TreePath parentPath, Object[] objects)
source
- The model.type
- One of OBJECTS_ADDED
, OBJECTS_REMOVED
,
BEFORE_OBJECTS_REMOVED
, DURING_OBJECTS_REMOVED
.parent
- The parent object of the set of objects that were changed,
added or removed, or null
for a root change.parentPath
- The path from the root to the parent object, or
null
for a root change.objects
- The set of objects that was added or removed
(together with their entire subtrees).public TreeSetModelEvent(IlvTreeSetModel source, TreeSetModelEvent.Type type, int column, IlvDataColumnInfo columnInfo)
source
- The model.type
- One of COLUMN_ADDED
, COLUMN_REMOVED
,
BEFORE_COLUMN_REMOVED
.column
- The column that was added or removed (index after adding
or before removing).columnInfo
- The IlvDataColumnInfo
of the column that was
added or removed.public TreeSetModelEvent(IlvTreeSetModel source, TreeSetModelEvent.Type type, int column, Object oldValue, Object newValue)
source
- The model.type
- One of EMPTY_VALUE_CHANGED
,
ENUM_VALUES_CHANGED
,
MIN_VALUE_CHANGED
,
MAX_VALUE_CHANGED
.column
- The affected column.oldValue
- The old value.newValue
- The new Value.public TreeSetModelEvent(IlvTreeSetModel source, TreeSetModelEvent.Type type, int column, boolean oldValue, boolean newValue)
source
- The model.type
- One of ENUMERATED_CHANGED
.column
- The affected column.oldValue
- The old value.newValue
- The new Value.public IlvTreeSetModel getModel()
public TreeSetModelEvent.Type getType()
public Object getObject()
DATA_CHANGED
,
BEFORE_DATA_CHANGE
.public TreePath getObjectPath()
DATA_CHANGED
,
BEFORE_DATA_CHANGE
.public boolean isRecursive()
true
if the entire subtree is affected, not just a single object.
Assumes the event type is one of DATA_CHANGED
,
BEFORE_DATA_CHANGE
.public Object getParent()
null
for a root change.
Assumes the event type is one of OBJECTS_ADDED
,
OBJECTS_REMOVED
, BEFORE_OBJECTS_REMOVED
,
DURING_OBJECTS_REMOVED
.public TreePath getParentPath()
null
for a root change.
Assumes the event type is one of OBJECTS_ADDED
,
OBJECTS_REMOVED
, BEFORE_OBJECTS_REMOVED
,
DURING_OBJECTS_REMOVED
.public Object[] getObjects()
OBJECTS_ADDED
,
OBJECTS_REMOVED
, BEFORE_OBJECTS_REMOVED
,
DURING_OBJECTS_REMOVED
.public int getColumn()
DATA_CHANGED
,
BEFORE_DATA_CHANGE
,
COLUMN_ADDED
, COLUMN_REMOVED
,
BEFORE_COLUMN_REMOVED
,
EMPTY_VALUE_CHANGED
, ENUMERATED_CHANGED
,
ENUM_VALUES_CHANGED
, MIN_VALUE_CHANGED
,
MAX_VALUE_CHANGED
.public IlvDataColumnInfo getColumnInfo()
null
for all columns.
Assumes the event type is one of DATA_CHANGED
,
BEFORE_DATA_CHANGE
,
COLUMN_ADDED
, COLUMN_REMOVED
,
BEFORE_COLUMN_REMOVED
,
EMPTY_VALUE_CHANGED
, ENUMERATED_CHANGED
,
ENUM_VALUES_CHANGED
, MIN_VALUE_CHANGED
,
MAX_VALUE_CHANGED
.public Object getOldValue()
IlvDataColumnInfo
.
Assumes the event type is one of EMPTY_VALUE_CHANGED
,
ENUMERATED_CHANGED
, ENUM_VALUES_CHANGED
,
MIN_VALUE_CHANGED
, MAX_VALUE_CHANGED
.public Object getNewValue()
IlvDataColumnInfo
.
Assumes the event type is one of EMPTY_VALUE_CHANGED
,
ENUMERATED_CHANGED
, ENUM_VALUES_CHANGED
,
MIN_VALUE_CHANGED
, MAX_VALUE_CHANGED
.public String toString()
String
representation of this event.toString
in class EventObject
© Copyright 2024 Rogue Wave Software, Inc., a Perforce company.. All Rights Reserved.