Packagecom.yworks.yfiles.layout
Classpublic class BufferedLayouter
InheritanceBufferedLayouter Inheritance AbstractLayoutStage Inheritance YObject Inheritance Object

A hull layouter that invokes another layout algorithm on a copy of its input graph.

After the layout process has finished the calculated layout will be either written back to the original graph or will be provided as a separate graph layout information in terms of the original input graph.

This class also provides the possibility to perform arbitrary layout algorithms merely on a graph interface plus associated graph layout. This comes in handy if an application has its own graph and merely provides an graph interface adapter to the yFiles graph layout machinery.



Public Properties
 PropertyDefined By
 InheritedcoreLayouter : Layouter
Specifies the core layouter.
AbstractLayoutStage
Public Methods
 MethodDefined By
  
BufferedLayouter(init:Boolean = true)
Instantiates a new BufferedLayouter.
BufferedLayouter
  
Invokes the core Layouter on a copy of the given graph.
BufferedLayouter
  
Invokes the core Layouter on a copy of the given graph.
BufferedLayouter
  
canLayout(graph:LayoutGraph):Boolean
[override] Whether or not this layouter can layout the given graph.
BufferedLayouter
  
doLayout(layoutGraph:LayoutGraph):void
[override] Invokes the core Layouter on a copy of the given graph.
BufferedLayouter
  
Invokes the core Layouter on a copy of the given graph.
BufferedLayouter
 Inherited
equals(o:Object):Boolean
YObject
  
getClass():Class
[override]
BufferedLayouter
 Inherited
hashCode():int
YObject
  
[static] Instantiates a new BufferedLayouter.
BufferedLayouter
  
[static] Instantiates a new BufferedLayouter that wraps the given core layouter.
BufferedLayouter
Protected Methods
 MethodDefined By
 Inherited
canLayoutCore(graph:LayoutGraph):Boolean
Queries the core layouter whether or not the given graph can be laid out.
AbstractLayoutStage
 Inherited
Invokes the layout routine of the core layouter.
AbstractLayoutStage
 Inherited
AbstractLayoutStage
 Inherited
AbstractLayoutStage
  
Initializes this object.
BufferedLayouter
  
initBufferedLayouter2(coreLayouter:Layouter):void
Initializes this object.
BufferedLayouter
Constructor Detail
BufferedLayouter()Constructor
public function BufferedLayouter(init:Boolean = true)

Instantiates a new BufferedLayouter. No core layouter will be bound this layouter yet.

Parameters
init:Boolean (default = true) — An internally used switch to help handle proper instance initialization in inheritance chains where classes can have multiple constructor-like factory methods. This parameter can safely be ignored/omitted when calling the constructor.
Method Detail
calcLayout()method
public function calcLayout(layoutGraph:LayoutGraph):GraphLayout

Invokes the core Layouter on a copy of the given graph.

Parameters

layoutGraph:LayoutGraph

Returns
GraphLayout — the calculated graph layout for the given graph
calcLayout2()method 
public function calcLayout2(graph:GraphInterface, layout:GraphLayout):GraphLayout

Invokes the core Layouter on a copy of the given graph.

Parameters

graph:GraphInterface
 
layout:GraphLayout

Returns
GraphLayout — the calculated graph layout for the given graph
canLayout()method 
override public function canLayout(graph:LayoutGraph):Boolean

Whether or not this layouter can layout the given graph. The result of this method will be provided by the associated core layouter.

Parameters

graph:LayoutGraph

Returns
Boolean
doLayout()method 
override public function doLayout(layoutGraph:LayoutGraph):void

Invokes the core Layouter on a copy of the given graph. The calculated layout will be written back to the given graph.

Parameters

layoutGraph:LayoutGraph

doLayout2()method 
public function doLayout2(graph:GraphInterface, layout:GraphLayout):void

Invokes the core Layouter on a copy of the given graph. The calculated layout will be written back to the given graph.

Parameters

graph:GraphInterface
 
layout:GraphLayout

getClass()method 
override public function getClass():Class

Returns
Class
initBufferedLayouter1()method 
protected final function initBufferedLayouter1():void

Initializes this object. See the documentation of the corresponding factory method newBufferedLayouter1() for details.

See also

initBufferedLayouter2()method 
protected final function initBufferedLayouter2(coreLayouter:Layouter):void

Initializes this object. See the documentation of the corresponding factory method newBufferedLayouter2() for details.

Parameters

coreLayouter:Layouter

See also

newBufferedLayouter1()method 
public static function newBufferedLayouter1():BufferedLayouter

Instantiates a new BufferedLayouter. No core layouter will be bound this layouter yet.

Returns
BufferedLayouter
newBufferedLayouter2()method 
public static function newBufferedLayouter2(coreLayouter:Layouter):BufferedLayouter

Instantiates a new BufferedLayouter that wraps the given core layouter.

Parameters

coreLayouter:Layouter

Returns
BufferedLayouter