public class ResourcesInsertedEvent extends IlvHierarchyNodeChildEvent<IlvResource> implements ResourceEvent
ResourcesInsertedEvent
is used to notify listeners when
children have been inserted into a common parent resource in the
tree of resources managed by an IlvGanttModel
.
The child resources must be siblings and direct descendents (not
grandchildren) of the specified parent resource. A listener can obtain the
parent resource by calling getResource()
.ResourceHierarchyListener
,
IlvGanttModel
,
Serialized Formsource
Constructor and Description |
---|
ResourcesInsertedEvent(IlvGanttModel model,
IlvResource parent,
int[] childIndices)
Constructs a new
ResourcesInsertedEvent generated by the
specified data model that can be used to notify listeners
when child resources have been inserted into a common parent. |
ResourcesInsertedEvent(IlvGanttModel model,
IlvResource parent,
List<? extends IlvResource> children)
Constructs a new
ResourcesInsertedEvent generated by the
specified data model that can be used to notify listeners
when child resources have been inserted into a common parent. |
Modifier and Type | Method and Description |
---|---|
IlvResource |
getResource()
Returns the resource that identifies the portion of the tree hierarchy
that has been modified.
|
getChildIndices, getChildNodes, getChildren, getGanttModel, getParent
getSource, toString
public ResourcesInsertedEvent(IlvGanttModel model, IlvResource parent, int[] childIndices)
ResourcesInsertedEvent
generated by the
specified data model that can be used to notify listeners
when child resources have been inserted into a common parent.
Note:
This constructor cannot be used to notify listeners when the root resource
of the data model has been inserted.model
- The data model where the event originated.parent
- The parent resource that has had children inserted.childIndices
- An int
array that specifies the index
values of the inserted resources. The indices represent the final
state of the resource tree, after the inserts have occurred. The indices
do not have to be pre-sorted.public ResourcesInsertedEvent(IlvGanttModel model, IlvResource parent, List<? extends IlvResource> children)
ResourcesInsertedEvent
generated by the
specified data model that can be used to notify listeners
when child resources have been inserted into a common parent.model
- The data model where the event originated.parent
- The parent resource that has had children inserted. If the
insertion being reported is the data model's root resource,
parent
should be null
and children
should be a single element list containing the root resource.children
- The list of child IlvResource
's that have
been inserted. The resources do not have to be presorted.public IlvResource getResource()
null
.getResource
in interface ResourceEvent
IlvResource
top of the modified tree hierarchy.© Copyright Rogue Wave Software, Inc. 1997, 2018. All Rights Reserved.