|
Search this API | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object y.layout.hierarchic.incremental.BusDescriptor
public class BusDescriptor
A BusDescriptor
defines settings for edges routed on a common bus and forming a bus substructure
for IncrementalHierarchicLayouter
.
Edges mapped to the same BusDescriptor
instance, adjacent to a common root node and having the same
edge direction form a bus.
The mapping is retrieved from a DataProvider
registered with the input graph with
key IncrementalHierarchicLayouter.BUS_DESCRIPTOR_DPKEY
.
A graph that contains a bus consisting of 15 edges and using default descriptor settings (bus edges are highlighted)
IncrementalHierarchicLayouter.BUS_DESCRIPTOR_DPKEY
Field Summary | |
---|---|
static java.lang.Object |
PLACE_BEFORE_BUS_DPKEY
A DataProvider key for assigning nodes to a specific side of the common bus
If no DataProvider is specified with this key, the nodes will be placed in an alternating way. |
static java.lang.Object |
ROOT_OFFSET_DPKEY
A DataProvider key for assigning nodes to specific layers relative to the root node of the bus
An offset value i specified for a bus node is interpreted relative to the root node as follows,
assuming that the root node is in layer x . |
Constructor Summary | |
---|---|
BusDescriptor()
|
Method Summary | |
---|---|
int |
getMaximumNodesAfterBus()
Returns the maximum number of nodes in a layer that are placed after the common bus segment. |
int |
getMaximumNodesBeforeBus()
Returns the maximum number of nodes in a layer that are placed before the common bus segment. |
void |
setMaximumNodesAfterBus(int maximumNodesAfterBus)
Specifies the maximum number of nodes in a layer that are placed after the common bus segment. |
void |
setMaximumNodesBeforeBus(int maximumNodesBeforeBus)
Specifies the maximum number of nodes in a layer that are placed before the common bus segment. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final java.lang.Object ROOT_OFFSET_DPKEY
DataProvider
key for assigning nodes to specific layers relative to the root node of the bus
An offset value i
specified for a bus node is interpreted relative to the root node as follows,
assuming that the root node is in layer x
.
x + i
x - i
2
, 10
, 15
are
normalized to 1
, 2
, 3
).number of nodes before the bus
and
number of nodes after the bus
might be violated if the layer indices
provided here are such that e.g., a layer contains too many nodes to fulfill the node count constraints.public static final java.lang.Object PLACE_BEFORE_BUS_DPKEY
DataProvider
key for assigning nodes to a specific side of the common bus
If no DataProvider
is specified with this key, the nodes will be placed in an alternating way.
sequence constraints
between the bus nodes.Constructor Detail |
---|
public BusDescriptor()
Method Detail |
---|
public int getMaximumNodesBeforeBus()
This setting allows to individually specify how the bus nodes should be distributed before/after the
common bus segment with respect to sequence of each layer.
By default, both the getMaximumNodesBeforeBus()
and the getMaximumNodesAfterBus()
are
0
which means that the nodes are equally distributed and the common bus segment is placed in the
middle. The actual number of nodes before and after the bus is determined automatically in that case.
PLACE_BEFORE_BUS_DPKEY
, but the value
of this property is set to 0
, then the maximum will be exceeded as necessary. The
maximum can also be exceeded if there are too many fixed bus nodes in the same layer (when running in
incremental mode
)
or when bus layers are user-specified via ROOT_OFFSET_DPKEY
.setMaximumNodesBeforeBus(int)
public void setMaximumNodesBeforeBus(int maximumNodesBeforeBus)
This setting allows to individually specify how the bus nodes should be distributed before/after the
common bus segment with respect to sequence of each layer.
By default, both the getMaximumNodesBeforeBus()
and the getMaximumNodesAfterBus()
are
0
which means that the nodes are equally distributed and the common bus segment is placed in the
middle. The actual number of nodes before and after the bus is determined automatically in that case.
PLACE_BEFORE_BUS_DPKEY
, but the value
of this property is set to 0
, then the maximum will be exceeded as necessary. The
maximum can also be exceeded if there are too many fixed bus nodes in the same layer (when running in
incremental mode
)
or when bus layers are user-specified via ROOT_OFFSET_DPKEY
.0
. If the maximum number of nodes after the bus is 0
too, then the number of
nodes is unrestricted, otherwise all nodes are placed after the bus.maximumNodesBeforeBus
- the maximum number of nodes that are allowed to be placed before the bus segment
java.lang.IllegalArgumentException
- if the given node count is negativeExample result with equally distributed bus: both, before and after node count are 0 | Example result where before bus node count is 1 and after bus node count is 2 |
public int getMaximumNodesAfterBus()
This setting allows to individually specify how the bus nodes should be distributed before/after the
common bus segment with respect to the sequence of each layer.
By default, both the getMaximumNodesBeforeBus()
and the getMaximumNodesAfterBus()
are
0
which means that the nodes are equally distributed and the common bus segment is placed in the
middle. The actual number of nodes before and after the bus is determined automatically in that case.
PLACE_BEFORE_BUS_DPKEY
, but the value
of this property is set to 0
, then the maximum will be exceeded as necessary. The
maximum can also be exceeded if there are too many fixed bus nodes in the same layer (when running in
incremental mode
)
or when bus layers are user-specified via ROOT_OFFSET_DPKEY
.setMaximumNodesAfterBus(int)
public void setMaximumNodesAfterBus(int maximumNodesAfterBus)
This setting allows to individually specify how the bus nodes should be distributed before/after the
common bus segment with respect to sequence of each layer.
By default, both the getMaximumNodesBeforeBus()
and the getMaximumNodesAfterBus()
are
0
which means that the nodes are equally distributed and the common bus segment is placed in the
middle. The actual number of nodes before and after the bus is determined automatically in that case.
PLACE_BEFORE_BUS_DPKEY
, but the value
of this property is set to 0
, then the maximum will be exceeded as necessary. The
maximum can also be exceeded if there are too many fixed bus nodes in the same layer (when running in
incremental mode
)
or when bus layers are user-specified via ROOT_OFFSET_DPKEY
.0
. If the maximum number of nodes before the bus is 0
too, then the number of
nodes is unrestricted, otherwise all nodes are placed before the bus.maximumNodesAfterBus
- the maximum number of nodes that are allowed to be placed after the bus segment
java.lang.IllegalArgumentException
- if the given node count is negativeExample result with equally distributed bus: both, before and after node count are 0 | Example result where before bus node count is 1 and after bus node count is 2 |
|
© Copyright 2000-2022, yWorks GmbH. All rights reserved. |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |