public class ZestProperties
extends java.lang.Object
ZestProperties
class contains a collection of attributes that are
evaluated by Zest.FX and their default values. It does also provide utility
methods to read and write these attributes.Modifier and Type | Field and Description |
---|---|
static java.lang.String |
EDGE_CURVE_CSS_STYLE
This attribute determines the CSS style for an edge.
|
static java.lang.String |
EDGE_LABEL_CSS_STYLE
This attribute determines the CSS style for an edge label.
|
static java.lang.String |
EDGE_ROUTER
This attribute determines the
IFXConnectionRouter used to route
an edge. |
static java.lang.String |
EDGE_SOURCE_DECORATION
This attribute determines the source decoration for an edge.
|
static java.lang.String |
EDGE_STYLE
This attribute determines the dash style for an edge.
|
static java.lang.String |
EDGE_STYLE_DASHDOT
This
EDGE_STYLE will draw the edge alternating dashed and
dotted, i.e. "-.-.-.". |
static java.lang.String |
EDGE_STYLE_DASHDOTDOT
This
EDGE_STYLE will draw the edge alternating dashed and double
dotted, i.e. "-..-..-..". |
static java.lang.String |
EDGE_STYLE_DASHED
This
EDGE_STYLE will draw the edge dashed, i.e. "---". |
static java.lang.String |
EDGE_STYLE_DEFAULT
The default value for the
EDGE_STYLE attribute. |
static java.lang.String |
EDGE_STYLE_DOTTED
This
EDGE_STYLE will draw the edge dotted, i.e. "...". |
static java.lang.String |
EDGE_STYLE_SOLID
This
EDGE_STYLE will draw the edge solid, i.e. "___". |
static java.util.Set<java.lang.String> |
EDGE_STYLE_VALUES
These are the possible
EDGE_STYLE values:
EDGE_STYLE_DASHDOTDOT
EDGE_STYLE_DASHDOT
EDGE_STYLE_DASHED
EDGE_STYLE_DOTTED
EDGE_STYLE_SOLID (default)
|
static java.lang.String |
EDGE_TARGET_DECORATION
This attribute determines the target decoration for an edge.
|
static java.lang.String |
ELEMENT_CSS_CLASS
This attribute determines the CSS class for an element (node/edge).
|
static java.lang.String |
ELEMENT_CSS_ID
This attribute determines the CSS id for an element (node/edge).
|
static java.lang.String |
ELEMENT_LABEL
This attribute determines the label for an element (node/edge).
|
static java.lang.String |
ELEMENT_LAYOUT_IRRELEVANT
This attribute determines if an element (node/edge) is irrelevant for
laying out, i.e. it should be filtered before laying out.
|
static java.lang.Boolean |
ELEMENT_LAYOUT_IRRELEVANT_DEFAULT
The default value for the
ELEMENT_LAYOUT_IRRELEVANT attribute. |
static java.lang.String |
GRAPH_LAYOUT
This attribute determines the
ILayoutAlgorithm used to layout the
graph. |
static java.lang.String |
GRAPH_TYPE
This attribute determines if a graph is directed or undirected.
|
static java.lang.String |
GRAPH_TYPE_DEFAULT
The default value for the
GRAPH_TYPE attribute. |
static java.lang.String |
GRAPH_TYPE_DIRECTED
This
GRAPH_TYPE specifies that the edges of the graph are
directed. |
static java.lang.String |
GRAPH_TYPE_UNDIRECTED
This
GRAPH_TYPE specifies that the edges of the graph are
undirected. |
static java.util.Set<java.lang.String> |
GRAPH_TYPE_VALUES
|
static java.lang.String |
NODE_FISHEYE
This attribute determines the fisheye state for a node.
|
static java.lang.Boolean |
NODE_FISHEYE_DEFAULT
The default value of the
NODE_FISHEYE attribute. |
static java.lang.String |
NODE_ICON
This attribute determines the icon for a node.
|
static java.lang.String |
NODE_LABEL_CSS_STYLE
This attribute determines the CSS style for a node label.
|
static java.lang.String |
NODE_RECT_CSS_STYLE
This attribute determines the CSS style for a node rectangle.
|
static java.lang.String |
NODE_TOOLTIP
This attribute determines the tooltip for a node.
|
Constructor and Description |
---|
ZestProperties() |
Modifier and Type | Method and Description |
---|---|
static java.lang.String |
getCssClass(Edge edge)
Returns the value of the
ELEMENT_CSS_CLASS attribute of the
given Edge . |
static java.lang.String |
getCssClass(Node node)
Returns the value of the
ELEMENT_CSS_CLASS attribute of the
given Node . |
static java.lang.String |
getCssId(Edge edge)
Returns the value of the
ELEMENT_CSS_ID attribute of the given
Edge . |
static java.lang.String |
getCssId(Node node)
Returns the value of the
ELEMENT_CSS_ID attribute of the given
Node . |
static java.lang.String |
getEdgeCurveCssStyle(Edge edge)
Returns the value of the
EDGE_CURVE_CSS_STYLE attribute of the
given Edge . |
static java.lang.String |
getEdgeLabelCssStyle(Edge edge)
Returns the value of the
EDGE_LABEL_CSS_STYLE attribute of the
given Edge . |
static java.lang.Boolean |
getFisheye(Node node,
boolean returnDefaultIfMissing)
Returns the value of the
NODE_FISHEYE attribute of the given
Node . |
static javafx.scene.image.Image |
getIcon(Node node)
|
static java.lang.String |
getLabel(Edge edge)
Returns the value of the
ELEMENT_LABEL attribute of the given
Edge . |
static java.lang.String |
getLabel(Node node)
Returns the value of the
ELEMENT_LABEL attribute of the given
Node . |
static ILayoutAlgorithm |
getLayout(Graph graph)
Returns the value of the
GRAPH_LAYOUT attribute of the given
Graph . |
static java.lang.Boolean |
getLayoutIrrelevant(Edge edge,
boolean returnDefaultIfMissing)
Returns the value of the
ELEMENT_LAYOUT_IRRELEVANT attribute of
the given Edge . |
static java.lang.Boolean |
getLayoutIrrelevant(Node node,
boolean returnDefaultIfMissing)
Returns the value of the
ELEMENT_LAYOUT_IRRELEVANT attribute of
the given Node . |
static java.lang.String |
getNodeLabelCssStyle(Node node)
Returns the value of the
NODE_LABEL_CSS_STYLE attribute of the
given Node . |
static java.lang.String |
getNodeRectCssStyle(Node node)
Returns the value of the
NODE_RECT_CSS_STYLE attribute of the
given Node . |
static IFXConnectionRouter |
getRouter(Edge edge)
Returns the value of the
EDGE_ROUTER attribute of the given
Edge . |
static IFXDecoration |
getSourceDecoration(Edge edge)
Returns the value of the
EDGE_SOURCE_DECORATION attribute of the
given Edge . |
static java.lang.String |
getStyle(Edge edge)
Returns the value of the
EDGE_STYLE attribute of the given
Edge . |
static IFXDecoration |
getTargetDecoration(Edge edge)
Returns the value of the
EDGE_TARGET_DECORATION attribute of the
given Edge . |
static java.lang.String |
getTooltip(Node node)
Returns the value of the
NODE_TOOLTIP attribute of the given
Node . |
static java.lang.String |
getType(Graph graph,
boolean returnDefaultIfMissing)
Returns the value of the
GRAPH_TYPE attribute of the given
Graph . |
static void |
setCssClass(Edge edge,
java.lang.String cssClass)
Sets the value of the
ELEMENT_CSS_CLASS attribute of the given
Edge to the given value. |
static void |
setCssClass(Node node,
java.lang.String cssClass)
Sets the value of the
ELEMENT_CSS_CLASS attribute of the given
Node to the given value. |
static void |
setCssId(Edge edge,
java.lang.String cssId)
Sets the value of the
ELEMENT_CSS_ID attribute of the given
Edge to the given value. |
static void |
setCssId(Node node,
java.lang.String cssId)
Sets the value of the
ELEMENT_CSS_ID attribute of the given
Node to the given value. |
static void |
setEdgeConnCssStyle(Edge edge,
java.lang.String connCssStyle)
Sets the value of the
EDGE_CURVE_CSS_STYLE attribute of the
given Edge to the given value. |
static void |
setEdgeTextCssStyle(Edge edge,
java.lang.String textCssStyle)
Sets the value of the
EDGE_LABEL_CSS_STYLE attribute of the
given Edge to the given value. |
static void |
setFisheye(Node node,
java.lang.Boolean fisheye)
Sets the value of the
NODE_FISHEYE attribute of the given
Node to the given value. |
static void |
setIcon(Node node,
javafx.scene.image.Image icon)
|
static void |
setLabel(Edge edge,
java.lang.String label)
Sets the value of the
ELEMENT_LABEL attribute of the given
Edge to the given value. |
static void |
setLabel(Node node,
java.lang.String label)
Sets the value of the
ELEMENT_LABEL attribute of the given
Node to the given value. |
static void |
setLayout(Graph graph,
ILayoutAlgorithm algorithm)
Sets the value of the
GRAPH_TYPE attribute of the given
Graph to the given value. |
static void |
setLayoutIrrelevant(Edge edge,
java.lang.Boolean layoutIrrelevant)
Sets the value of the
ELEMENT_LAYOUT_IRRELEVANT attribute of the
given Edge to the given value. |
static void |
setLayoutIrrelevant(Node node,
java.lang.Boolean layoutIrrelevant)
Sets the value of the
ELEMENT_LAYOUT_IRRELEVANT attribute of the
given Node to the given value. |
static void |
setNodeRectCssStyle(Node node,
java.lang.String rectCssStyle)
Sets the value of the
NODE_RECT_CSS_STYLE attribute of the given
Node to the given value. |
static void |
setNodeTextCssStyle(Node node,
java.lang.String textCssStyle)
Sets the value of the
NODE_LABEL_CSS_STYLE attribute of the
given Node to the given value. |
static void |
setRouter(Edge edge,
IFXConnectionRouter router)
Sets the value of the
EDGE_ROUTER attribute of the given
Edge to the given value. |
static void |
setSourceDecoration(Edge edge,
IFXDecoration sourceDecoration)
Sets the value of the
EDGE_SOURCE_DECORATION attribute of the
given Edge to the given value. |
static void |
setStyle(Edge edge,
java.lang.String style)
Sets the value of the
EDGE_STYLE attribute of the given
Edge to the given value. |
static void |
setTargetDecoration(Edge edge,
IFXDecoration targetDecoration)
Sets the value of the
EDGE_TARGET_DECORATION attribute of the
given Edge to the given value. |
static void |
setTooltip(Node node,
java.lang.String tooltip)
Sets the value of the
NODE_TOOLTIP attribute of the given
Node to the given value. |
static void |
setType(Graph graph,
java.lang.String type)
Sets the value of the
GRAPH_TYPE attribute of the given
Graph to the given value. |
public static final java.lang.String ELEMENT_LAYOUT_IRRELEVANT
public static final java.lang.Boolean ELEMENT_LAYOUT_IRRELEVANT_DEFAULT
ELEMENT_LAYOUT_IRRELEVANT
attribute.public static final java.lang.String ELEMENT_CSS_CLASS
public static final java.lang.String ELEMENT_CSS_ID
public static final java.lang.String ELEMENT_LABEL
public static final java.lang.String EDGE_CURVE_CSS_STYLE
public static final java.lang.String EDGE_LABEL_CSS_STYLE
public static final java.lang.String NODE_RECT_CSS_STYLE
public static final java.lang.String NODE_LABEL_CSS_STYLE
public static final java.lang.String NODE_ICON
getIcon(Node)
,
setIcon(Node, Image)
,
Constant Field Valuespublic static final java.lang.String NODE_TOOLTIP
public static final java.lang.String NODE_FISHEYE
public static final java.lang.String EDGE_TARGET_DECORATION
public static final java.lang.String EDGE_SOURCE_DECORATION
public static final java.lang.String EDGE_ROUTER
IFXConnectionRouter
used to route
an edge. This attribute does not have a default value.public static final java.lang.String EDGE_STYLE
public static final java.lang.String EDGE_STYLE_DASHED
EDGE_STYLE
will draw the edge dashed, i.e. "---".public static final java.lang.String EDGE_STYLE_DOTTED
EDGE_STYLE
will draw the edge dotted, i.e. "...".public static final java.lang.String EDGE_STYLE_SOLID
EDGE_STYLE
will draw the edge solid, i.e. "___".public static final java.lang.String EDGE_STYLE_DASHDOT
EDGE_STYLE
will draw the edge alternating dashed and
dotted, i.e. "-.-.-.".public static final java.lang.String EDGE_STYLE_DASHDOTDOT
EDGE_STYLE
will draw the edge alternating dashed and double
dotted, i.e. "-..-..-..".public static final java.util.Set<java.lang.String> EDGE_STYLE_VALUES
EDGE_STYLE
values:
public static final java.lang.String EDGE_STYLE_DEFAULT
EDGE_STYLE
attribute.public static final java.lang.String GRAPH_TYPE
public static final java.lang.String GRAPH_TYPE_DIRECTED
GRAPH_TYPE
specifies that the edges of the graph are
directed.public static final java.lang.String GRAPH_TYPE_UNDIRECTED
GRAPH_TYPE
specifies that the edges of the graph are
undirected.public static final java.util.Set<java.lang.String> GRAPH_TYPE_VALUES
GRAPH_TYPE
values:
GRAPH_TYPE_DIRECTED
GRAPH_TYPE_UNDIRECTED
(default)
public static final java.lang.String GRAPH_TYPE_DEFAULT
GRAPH_TYPE
attribute.public static final java.lang.String GRAPH_LAYOUT
ILayoutAlgorithm
used to layout the
graph.public static java.lang.Boolean NODE_FISHEYE_DEFAULT
NODE_FISHEYE
attribute.public static java.lang.String getCssClass(Edge edge)
ELEMENT_CSS_CLASS
attribute of the
given Edge
.public static java.lang.String getCssClass(Node node)
ELEMENT_CSS_CLASS
attribute of the
given Node
.public static java.lang.String getCssId(Edge edge)
ELEMENT_CSS_ID
attribute of the given
Edge
.public static java.lang.String getCssId(Node node)
ELEMENT_CSS_ID
attribute of the given
Node
.public static java.lang.String getEdgeCurveCssStyle(Edge edge)
EDGE_CURVE_CSS_STYLE
attribute of the
given Edge
.public static java.lang.String getEdgeLabelCssStyle(Edge edge)
EDGE_LABEL_CSS_STYLE
attribute of the
given Edge
.public static java.lang.Boolean getFisheye(Node node, boolean returnDefaultIfMissing)
NODE_FISHEYE
attribute of the given
Node
. If the attribute is not set for the given Node
,
either the default attribute value is returned, or null
,
depending on the returnDefaultIfMissing flag.public static javafx.scene.image.Image getIcon(Node node)
public static java.lang.String getLabel(Edge edge)
ELEMENT_LABEL
attribute of the given
Edge
.public static java.lang.String getLabel(Node node)
ELEMENT_LABEL
attribute of the given
Node
.public static ILayoutAlgorithm getLayout(Graph graph)
GRAPH_LAYOUT
attribute of the given
Graph
.public static java.lang.Boolean getLayoutIrrelevant(Edge edge, boolean returnDefaultIfMissing)
ELEMENT_LAYOUT_IRRELEVANT
attribute of
the given Edge
. If the attribute is not set for the given
Edge
, either the default attribute value is returned, or
null
, depending on the returnDefaultIfMissing flag.public static java.lang.Boolean getLayoutIrrelevant(Node node, boolean returnDefaultIfMissing)
ELEMENT_LAYOUT_IRRELEVANT
attribute of
the given Node
. If the attribute is not set for the given
Node
, either the default attribute value is returned, or
null
, depending on the returnDefaultIfMissing flag.public static java.lang.String getNodeLabelCssStyle(Node node)
NODE_LABEL_CSS_STYLE
attribute of the
given Node
.public static java.lang.String getNodeRectCssStyle(Node node)
NODE_RECT_CSS_STYLE
attribute of the
given Node
.public static IFXConnectionRouter getRouter(Edge edge)
EDGE_ROUTER
attribute of the given
Edge
.public static IFXDecoration getSourceDecoration(Edge edge)
EDGE_SOURCE_DECORATION
attribute of the
given Edge
.public static java.lang.String getStyle(Edge edge)
EDGE_STYLE
attribute of the given
Edge
.public static IFXDecoration getTargetDecoration(Edge edge)
EDGE_TARGET_DECORATION
attribute of the
given Edge
.public static java.lang.String getTooltip(Node node)
NODE_TOOLTIP
attribute of the given
Node
.public static java.lang.String getType(Graph graph, boolean returnDefaultIfMissing)
GRAPH_TYPE
attribute of the given
Graph
. If the attribute is not set for the given Graph
,
either the default attribute value is returned, or null
,
depending on the returnDefaultIfMissing flag.public static void setCssClass(Edge edge, java.lang.String cssClass)
ELEMENT_CSS_CLASS
attribute of the given
Edge
to the given value.public static void setCssClass(Node node, java.lang.String cssClass)
ELEMENT_CSS_CLASS
attribute of the given
Node
to the given value.public static void setCssId(Edge edge, java.lang.String cssId)
ELEMENT_CSS_ID
attribute of the given
Edge
to the given value.public static void setCssId(Node node, java.lang.String cssId)
ELEMENT_CSS_ID
attribute of the given
Node
to the given value.public static void setEdgeConnCssStyle(Edge edge, java.lang.String connCssStyle)
EDGE_CURVE_CSS_STYLE
attribute of the
given Edge
to the given value.public static void setEdgeTextCssStyle(Edge edge, java.lang.String textCssStyle)
EDGE_LABEL_CSS_STYLE
attribute of the
given Edge
to the given value.public static void setFisheye(Node node, java.lang.Boolean fisheye)
NODE_FISHEYE
attribute of the given
Node
to the given value.public static void setIcon(Node node, javafx.scene.image.Image icon)
public static void setLabel(Edge edge, java.lang.String label)
ELEMENT_LABEL
attribute of the given
Edge
to the given value.public static void setLabel(Node node, java.lang.String label)
ELEMENT_LABEL
attribute of the given
Node
to the given value.public static void setLayout(Graph graph, ILayoutAlgorithm algorithm)
GRAPH_TYPE
attribute of the given
Graph
to the given value.graph
- The Graph
of which the layout algorithm is changed.algorithm
- The new ILayoutAlgorithm
for the given Graph
.public static void setLayoutIrrelevant(Edge edge, java.lang.Boolean layoutIrrelevant)
ELEMENT_LAYOUT_IRRELEVANT
attribute of the
given Edge
to the given value.public static void setLayoutIrrelevant(Node node, java.lang.Boolean layoutIrrelevant)
ELEMENT_LAYOUT_IRRELEVANT
attribute of the
given Node
to the given value.public static void setNodeRectCssStyle(Node node, java.lang.String rectCssStyle)
NODE_RECT_CSS_STYLE
attribute of the given
Node
to the given value.public static void setNodeTextCssStyle(Node node, java.lang.String textCssStyle)
NODE_LABEL_CSS_STYLE
attribute of the
given Node
to the given value.public static void setRouter(Edge edge, IFXConnectionRouter router)
EDGE_ROUTER
attribute of the given
Edge
to the given value.edge
- The Edge
of which the router is changed.router
- The new IFXConnectionRouter
for the given Edge
.public static void setSourceDecoration(Edge edge, IFXDecoration sourceDecoration)
EDGE_SOURCE_DECORATION
attribute of the
given Edge
to the given value.edge
- The Edge
of which the source decoration is changed.sourceDecoration
- The new source IFXDecoration
for the given
Edge
.public static void setStyle(Edge edge, java.lang.String style)
EDGE_STYLE
attribute of the given
Edge
to the given value.edge
- The Edge
of which the style is changed.style
- The new style for the given Edge
.java.lang.IllegalArgumentException
- when the given style value is not contained within
EDGE_STYLE_VALUES
.public static void setTargetDecoration(Edge edge, IFXDecoration targetDecoration)
EDGE_TARGET_DECORATION
attribute of the
given Edge
to the given value.edge
- The Edge
of which the target decoration is changed.targetDecoration
- The new target IFXDecoration
for the given
Edge
.public static void setTooltip(Node node, java.lang.String tooltip)
NODE_TOOLTIP
attribute of the given
Node
to the given value.public static void setType(Graph graph, java.lang.String type)
GRAPH_TYPE
attribute of the given
Graph
to the given value.graph
- The Graph
of which the type is changed.type
- The new type for the given Graph
.java.lang.IllegalArgumentException
- when the given type value is not contained within
GRAPH_TYPE_VALUES
.Copyright (c) 2014 itemis AG and others. All rights reserved.