public class ActivityIDEvent extends ActivityPropertyEvent
ActivityIDEvent is fired by an IlvActivity both
before and after its id is modified. Immediately before its id is modified,
an IlvActivity fires an aboutToChange
ActivityIDEvent in all listeners registered with the Gantt data
model.
Listeners can modify or constrain the proposed id by invoking
setNewID().
Alternatively, a listener can veto the proposed change by invoking
veto().
After its id is modified, an IlvActivity will fire a
changed ActivityIDEvent in all listeners registered
with the Gantt data model. Listeners can access the old and new values of the
activity's id, but cannot modify them via the event mechanism.
source| Constructor and Description |
|---|
ActivityIDEvent(IlvActivity activity,
String oldID,
String newID,
boolean aboutToChangeEvent)
Constructs a new
ActivityIDEvent generated
by the specified activity and with the specified old and new
id values. |
| Modifier and Type | Method and Description |
|---|---|
String |
getNewID()
Returns the activity's new id.
|
String |
getOldID()
Returns the activity's old id.
|
void |
setNewID(String id)
Sets the activity's proposed new id.
|
getActivitygetNewValue, getOldValue, isAboutToChangeEvent, isChangedEvent, isVetoed, setNewValue, vetogetSource, toStringpublic ActivityIDEvent(IlvActivity activity, String oldID, String newID, boolean aboutToChangeEvent)
ActivityIDEvent generated
by the specified activity and with the specified old and new
id values.activity - the activity where the event originatedoldID - the activity's previous idnewID - the activity's new idaboutToChangeEvent - true if this is an
activityIDAboutToChange event or false if this
is an activityIDChanged event.public String getOldID()
activityIDAboutToChange event, then this will be the
same as the activity's current id since the change has not actually
occurred yet. If this is a activityIDChanged event, this
will be the activity's id prior to the current modification being
reported.String representing the activity's old id.public String getNewID()
activityIDAboutToChange event, then this is will be
the activity's proposed value. If this is a activityIDChanged
event, this will be the activity's new id which is being reported.String representing the activity's new id.public void setNewID(String id)
activityIDAboutToChange event. By using this method, a
listener can constrain changes to the activity's id.id - the activity's id© Copyright 2024 Rogue Wave Software, Inc., a Perforce company.. All Rights Reserved.