|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
T
- the type of the node objectsS
- the type of the timeline objectspublic interface IGanttChartModel<T,S>
A Gantt chart model provides various kinds of information in order to
populate a Gantt chart with data. It is a specialization of a tree table
model (see ITreeTableModel
) where the superclass methods provide the
data for the left-hand side of the chart and the subclass provides the
right-hand side values.
Layer
definitions. Various types of layers are used
on the right-hand side of the Gantt chart. The layer definitions returned by
the model will result in the creation of instances of
TimelineObjectLayer
, which are responsible for rendering the
timeline objectsBinarySearchTimelineObjectIterator
) for a given layer and time span.
When the user scrolls the right-hand side of the Gantt chart only a small
part needs to be repainted. If the user scrolled 10 pixels to the right, the
time span covered by these 10 pixels will be used for a model query.IRelationship
objects for a given timeline
object. The relationships will be visualized via connecting lines between
objects.IGanttChartModelListener
can be attached to the
model. The listeners will be informed in these cases:
AbstractGanttChart.setModel(IGanttChartModel)
,
DualGanttChart.setSecondaryModel(IGanttChartModel)
,
IGanttChartModelListener
,
IGanttChartNode
Method Summary | |
---|---|
void |
addGanttChartModelListener(IGanttChartModelListener l)
Adds a listener to the model. |
java.util.Iterator<S> |
getChildrenTimelineObjects(S parent)
Returns an iterator over the children of the given parent timeline object. |
java.util.Iterator<ILayer> |
getLayers()
Returns an iterator over the layers used by the model. |
java.util.Iterator<IRelationship<S>> |
getRelationships()
Returns all relationships so that they can be visualized by the RelationshipLayer . |
java.util.Iterator<IRelationship<S>> |
getRelationships(S timelineObject)
Returns those relationships that have the given timeline object either as a source or as a target object. |
java.util.Iterator<S> |
getTimelineObjectsIterator(T node,
ILayer layer,
ITimeSpan span)
Returns an Iterator that can be used to iterate over all timeline
objects stored on the given node and layer within the given time span. |
ITimeSpan |
getTimeSpan(S timelineObject)
Returns the time span of the given timeline object. |
boolean |
isParentTimelineObject(S timelineObject)
Determines whether the given timeline object is a parent timeline object. |
void |
removeGanttChartModelListener(IGanttChartModelListener l)
Removes a listener from the model. |
Methods inherited from interface com.dlsc.flexgantt.model.treetable.ITreeTableModel |
---|
addTreeTableModelListener, getColumnValue, getKey, getRowHeaderValue, removeTreeTableModelListener, setColumnValue, setKey, sort |
Methods inherited from interface javax.swing.tree.TreeModel |
---|
addTreeModelListener, getChild, getChildCount, getIndexOfChild, getRoot, isLeaf, removeTreeModelListener, valueForPathChanged |
Method Detail |
---|
java.util.Iterator<ILayer> getLayers()
TimelineObjectLayer
for each layer
model definition.
getTimelineObjectsIterator(Object, ILayer, ITimeSpan)
java.util.Iterator<S> getTimelineObjectsIterator(T node, ILayer layer, ITimeSpan span)
Iterator
that can be used to iterate over all timeline
objects stored on the given node and layer within the given time span.
This method is not allowed to return NULL.
node
- the tree node for which to return an iteratorlayer
- the layer for which to return an iteratorspan
- the time span for which to return an iterator
ITimeSpan getTimeSpan(S timelineObject)
DefaultGanttChartModel
does store the span on the internally used IGanttChartNode
instances.
timelineObject
- the object for which to return the time span
java.util.Iterator<IRelationship<S>> getRelationships()
RelationshipLayer
.
java.util.Iterator<IRelationship<S>> getRelationships(S timelineObject)
RelationshipLayer
wants to
figure out which lines need to be drawn.
timelineObject
- the object for which to return relationships
boolean isParentTimelineObject(S timelineObject)
timelineObject
- the timeline object to check
getChildrenTimelineObjects(Object)
java.util.Iterator<S> getChildrenTimelineObjects(S parent)
parent
- the parent timeline object
void addGanttChartModelListener(IGanttChartModelListener l)
l
- the new listenerremoveGanttChartModelListener(IGanttChartModelListener)
,
GanttChartModelEvent
void removeGanttChartModelListener(IGanttChartModelListener l)
l
- the listener to removeaddGanttChartModelListener(IGanttChartModelListener)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |