|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface ILinePolicy
A policy that can be used to create lines for timeline objects within the row
of a node (nested rows, inner rows). Lines can be useful if the timeline
objects that are placed on a hierarchy node overlap each other. If the total
number of overlapping objects is known then this policy can return a line
count equivalent to that number. To then keep the timeline object separated
the policy needs to return a different line number for each object. Even if a
row uses lines it is still possible to place timeline objects on the row
instead of a line, hence filling the entire height of the row. This is done
by returning -1 for the object's line index. This policy gets used by the
TimelineObjectLayer
when rendering the timeline objects and when
calculating the bounds of these objects.
Method Summary | |
---|---|
int |
getLineCount(java.lang.Object node,
ITreeTableModel model)
Returns the number of (inner) lines shown in the row of a hierarchy node. |
int |
getLineHeight(java.lang.Object node,
ITreeTableModel model,
int lineIndex,
int rowHeight)
Returns the height of a specific (inner) line. |
int |
getLineIndex(java.lang.Object node,
ITreeTableModel model,
java.lang.Object timelineObject)
Returns the index of the line on which the given timeline object shall be placed (the indices start with 0). |
int |
getLineLocation(java.lang.Object node,
ITreeTableModel model,
int lineIndex,
int rowHeight)
Returns the y-coordinate of a specific (inner) line. |
boolean |
isLineVisible(java.lang.Object node,
ITreeTableModel model,
int lineIndex)
Determines whether a specific (inner) line is currently visible or not. |
Method Detail |
---|
int getLineCount(java.lang.Object node, ITreeTableModel model)
node
- the hierarchy node for which to return the total number of
linesmodel
- the tree table model to which the node belongs
int getLineIndex(java.lang.Object node, ITreeTableModel model, java.lang.Object timelineObject)
node
- the hierarchy node for which to return the total number of
linesmodel
- the tree table model to which the node belongstimelineObject
- the timeline object for which to return the line index
int getLineLocation(java.lang.Object node, ITreeTableModel model, int lineIndex, int rowHeight)
node
- the hierarchy node for which to return the total number of
linesmodel
- the tree table model to which the node belongslineIndex
- the index of the line for which to return the y-coordinaterowHeight
- the height of the row to which the line belongs
getLineHeight(Object, ITreeTableModel, int, int)
int getLineHeight(java.lang.Object node, ITreeTableModel model, int lineIndex, int rowHeight)
node
- the hierarchy node for which to return the total number of
linesmodel
- the tree table model to which the node belongslineIndex
- the index of the line for which to return the heightrowHeight
- the height of the row to which the line belongs
boolean isLineVisible(java.lang.Object node, ITreeTableModel model, int lineIndex)
node
- the hierarchy node for which to return the total number of
linesmodel
- the tree table model to which the node belongslineIndex
- the index of the line for which to determine the visibility
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |