|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.dlsc.flexgantt.policy.AbstractPolicy com.dlsc.flexgantt.policy.layer.DefaultLabelPolicy
public class DefaultLabelPolicy
The default implmementation of the label policy. For a general description of
this policy please refer to the policy interface ILabelPolicy
.
Constructor Summary | |
---|---|
DefaultLabelPolicy()
|
Method Summary | |
---|---|
java.text.DateFormat |
getDateFormatter()
Returns the date formatter object that gets used by the policy to convert time points (millis) to strings. |
java.lang.String |
getLabel(IRelationship relationship,
IGanttChartModel model)
Returns a label for the given relationship object (usually a summary of the relationship meaning). |
java.lang.String |
getLabel(java.lang.Object node,
java.lang.Object timelineObject,
IGanttChartModel model,
LabelType type)
Returns various types of labels for a given timeline object. |
boolean |
isLabelTypeVisible(java.lang.Object node,
java.lang.Object timelineObject,
IGanttChartModel model,
LabelType type)
Determines whether or not a certain type of label will be shown for the given timeline object or not. |
void |
setDateFormatter(java.text.DateFormat format)
Sets the date formatter object that gets used by the policy to convert time points (millis) to strings. |
Methods inherited from class com.dlsc.flexgantt.policy.AbstractPolicy |
---|
assertClass |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public DefaultLabelPolicy()
Method Detail |
---|
public boolean isLabelTypeVisible(java.lang.Object node, java.lang.Object timelineObject, IGanttChartModel model, LabelType type)
ILabelPolicy
isLabelTypeVisible
in interface ILabelPolicy
node
- the tree node that owns the timeline objecttimelineObject
- the timeline object for which the check gets performedmodel
- the data source that returned the node and timeline objecttype
- the type of the label (name, tooltip, description, etc...)
ILabelPolicy.getLabel(Object, Object, IGanttChartModel, LabelType)
public java.lang.String getLabel(java.lang.Object node, java.lang.Object timelineObject, IGanttChartModel model, LabelType type)
ILabelPolicy
getLabel
in interface ILabelPolicy
node
- the tree node that owns the timeline objecttimelineObject
- the timeline object for which a label gets requestedmodel
- the data source that returned the node and timeline objecttype
- the type of the label (name, tooltip, description, etc...)
ILabelPolicy.isLabelTypeVisible(Object, Object, IGanttChartModel, LabelType)
public java.lang.String getLabel(IRelationship relationship, IGanttChartModel model)
ILabelPolicy
getLabel
in interface ILabelPolicy
relationship
- the relationship for which a label gets requestedmodel
- the data source that returned the relationship object
public java.text.DateFormat getDateFormatter()
public void setDateFormatter(java.text.DateFormat format)
format
- the date formatter object to use
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |