public class SplitDockTreeFactory extends Object implements SplitTreeFactory<SplitDockTree.Key>
SplitTreeFactory that writes into a SplitDockTree and
so fills up an empty SplitDockTree until it is a full, valid
tree.| Constructor and Description |
|---|
SplitDockTreeFactory(SplitDockTree<Dockable> tree)
Creates a new factory.
|
| Modifier and Type | Method and Description |
|---|---|
SplitDockTree.Key |
horizontal(SplitDockTree.Key left,
SplitDockTree.Key right,
double divider,
long id,
Path[] placeholders,
PlaceholderMap placeholderMap,
boolean visible)
Informs about a node that is divided vertically.
|
SplitDockTree.Key |
leaf(Dockable dockable,
long id,
Path[] placeholders,
PlaceholderMap placeholderMap)
Informs about a leaf of the tree.
|
SplitDockTree.Key |
placeholder(long id,
Path[] placeholders,
PlaceholderMap placeholderMap)
Informs about a set of placeholder in the tree.
|
SplitDockTree.Key |
root(SplitDockTree.Key root,
long id)
Informs about the node that is the root.
|
SplitDockTree.Key |
vertical(SplitDockTree.Key top,
SplitDockTree.Key bottom,
double divider,
long id,
Path[] placeholders,
PlaceholderMap placeholderMap,
boolean visible)
Informs about a node that is divided vertically.
|
public SplitDockTreeFactory(SplitDockTree<Dockable> tree)
tree - the tree into which this factory will write.public SplitDockTree.Key horizontal(SplitDockTree.Key left, SplitDockTree.Key right, double divider, long id, Path[] placeholders, PlaceholderMap placeholderMap, boolean visible)
SplitTreeFactoryhorizontal in interface SplitTreeFactory<SplitDockTree.Key>left - the left child of the node, might be nullright - the right child of the node, might be nulldivider - the size of the left node, a value between 0 and 1.id - the unique identifier of this node or -1placeholders - the placeholders associated with this node, can be emptyplaceholderMap - placeholder information of a child DockStationvisible - whether this node is visible to the user or not. A node is only visible to the user
if at least one of its children is visiblenullpublic SplitDockTree.Key vertical(SplitDockTree.Key top, SplitDockTree.Key bottom, double divider, long id, Path[] placeholders, PlaceholderMap placeholderMap, boolean visible)
SplitTreeFactoryvertical in interface SplitTreeFactory<SplitDockTree.Key>top - the top child of the node, might be nullbottom - the bottom child of the node, might be nulldivider - the size of the top node, a value between 0 and 1.id - the unique identifier of this node or -1placeholders - the placeholders associated with this node, can be emptyplaceholderMap - placeholder information of a child DockStationvisible - whether this node is visible to the user or not. A node is only visible to the user
if at least one of its children is visiblenullpublic SplitDockTree.Key leaf(Dockable dockable, long id, Path[] placeholders, PlaceholderMap placeholderMap)
SplitTreeFactoryleaf in interface SplitTreeFactory<SplitDockTree.Key>dockable - the element in the leafid - the unique identifier of this node or -1placeholders - the placeholders associated with this node, can be emptyplaceholderMap - placeholder information of a child DockStationnullpublic SplitDockTree.Key placeholder(long id, Path[] placeholders, PlaceholderMap placeholderMap)
SplitTreeFactoryplaceholder in interface SplitTreeFactory<SplitDockTree.Key>id - the unique id of this placeholderplaceholders - the placeholdersplaceholderMap - placeholder information of a child DockStationnullpublic SplitDockTree.Key root(SplitDockTree.Key root, long id)
SplitTreeFactoryroot in interface SplitTreeFactory<SplitDockTree.Key>root - the root of the tree, might be nullid - the unique identifier of this node or -1nullCopyright © 2017 Docking Frames. All rights reserved.