@OpenApiAll public class HierarchicDiagramLayouter extends AbstractDiagramLayouter
Modifier and Type | Class and Description |
---|---|
(package private) class |
HierarchicDiagramLayouter.PEXComparator
Comparator for sorting presentation elements by their x position.
|
Constructor and Description |
---|
HierarchicDiagramLayouter()
Construct HierarchicDiagramLayouter
|
HierarchicDiagramLayouter(java.lang.String optionId)
Construct HierarchicDiagramLayouter
|
Modifier and Type | Method and Description |
---|---|
protected void |
afterLayout(AbstractDiagramLayouterOptionsGroup options,
DiagramPresentationElement dpe,
UMLGraph graph,
com.nomagic.magicdraw.commands.MacroCommand mc) |
protected y.layout.ComponentLayouter |
createComponentLayouter(UMLGraph graph,
y.layout.Layouter coreLayouter,
HierarchicLayouterOptionsGroup opt)
Creates a component layouter if possible.
|
protected void |
fixOnFrameElements(UMLGraph graph,
DiagramPresentationElement dpe,
HierarchicLayouterOptionsGroup o)
Fixes, moves, sorts overlapping shapes on diagram frame.
|
java.util.Collection<com.nomagic.magicdraw.uml.symbols.layout.PathRerouteCollector> |
getPathRerouteCollectors() |
protected y.layout.hierarchic.IncrementalHierarchicLayouter |
initDefaultHierarchicSettings(HierarchicLayouterOptionsGroup opt,
UMLGraph graph)
Initializes hierarchic layouter settings: - Enables backlooping - Sets group compaction
enabled - Aligns groups in center - Sets routing style to orthogonal - Adds group node insets
- Enables label layout - Sets the node sequence within layer.
|
protected boolean |
layout(AbstractDiagramLayouterOptionsGroup opt,
DiagramPresentationElement dpe,
UMLGraph graph)
Layouts a diagram
|
protected void |
preProcessing(AbstractDiagramLayouterOptionsGroup options,
DiagramPresentationElement dpe,
com.nomagic.magicdraw.commands.MacroCommand mc) |
void |
registerPathRerouteCollector(com.nomagic.magicdraw.uml.symbols.layout.PathRerouteCollector collector) |
protected void |
resizeOnEdgeElements(UMLGraph graph,
AbstractDiagramLayouterOptionsGroup options)
Resizes elements on edge to the minimal size.
|
protected void |
routeNonRoutedPaths(UMLGraph graph,
DiagramPresentationElement dpe,
AbstractDiagramLayouterOptionsGroup options,
com.nomagic.magicdraw.commands.MacroCommand mc,
java.util.Collection<com.nomagic.magicdraw.uml.symbols.layout.PathRerouteCollector> rerouteCollectors) |
protected y.layout.Layouter |
wrapToAccordingGroupLayouter(UMLGraph graph,
y.layout.hierarchic.IncrementalHierarchicLayouter layouter,
HierarchicLayouterOptionsGroup opt) |
createGraph, createGraph, getSelected, isSubgraphLayout, isTypeSupported, setSubgraphLayout
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
canLayout, drawLayoutResults, getOptionsID
public HierarchicDiagramLayouter()
public HierarchicDiagramLayouter(java.lang.String optionId)
optionId
- hierarchic diagram layouter options idprotected y.layout.hierarchic.IncrementalHierarchicLayouter initDefaultHierarchicSettings(HierarchicLayouterOptionsGroup opt, UMLGraph graph)
opt
- optionsgraph
- current graph that should be layoutedprotected y.layout.Layouter wrapToAccordingGroupLayouter(UMLGraph graph, y.layout.hierarchic.IncrementalHierarchicLayouter layouter, HierarchicLayouterOptionsGroup opt)
@CheckForNull protected y.layout.ComponentLayouter createComponentLayouter(UMLGraph graph, y.layout.Layouter coreLayouter, HierarchicLayouterOptionsGroup opt)
graph
- layouted graphcoreLayouter
- the core layouter for component layouteropt
- hierarchic optionsprotected boolean layout(AbstractDiagramLayouterOptionsGroup opt, DiagramPresentationElement dpe, UMLGraph graph)
AbstractDiagramLayouter
layout
in class AbstractDiagramLayouter
opt
- layouter optionsdpe
- diagram to layoutgraph
- a constructed graph from the diagramprotected void resizeOnEdgeElements(UMLGraph graph, AbstractDiagramLayouterOptionsGroup options)
graph
- layouted graphoptions
- options that may be regarded while adjustingprotected void preProcessing(AbstractDiagramLayouterOptionsGroup options, DiagramPresentationElement dpe, @CheckForNull com.nomagic.magicdraw.commands.MacroCommand mc)
preProcessing
in class AbstractDiagramLayouter
protected void afterLayout(AbstractDiagramLayouterOptionsGroup options, DiagramPresentationElement dpe, UMLGraph graph, com.nomagic.magicdraw.commands.MacroCommand mc)
afterLayout
in class AbstractDiagramLayouter
protected void routeNonRoutedPaths(UMLGraph graph, DiagramPresentationElement dpe, @CheckForNull AbstractDiagramLayouterOptionsGroup options, com.nomagic.magicdraw.commands.MacroCommand mc, java.util.Collection<com.nomagic.magicdraw.uml.symbols.layout.PathRerouteCollector> rerouteCollectors)
protected void fixOnFrameElements(UMLGraph graph, DiagramPresentationElement dpe, HierarchicLayouterOptionsGroup o)
graph
- the graph that is layouteddpe
- diagramo
- options grouppublic final void registerPathRerouteCollector(com.nomagic.magicdraw.uml.symbols.layout.PathRerouteCollector collector)
public java.util.Collection<com.nomagic.magicdraw.uml.symbols.layout.PathRerouteCollector> getPathRerouteCollectors()