Package | com.yworks.yfiles.layout.planar |
Class | public class PlanarityTest |
Inheritance | PlanarityTest YObject Object |
See also
Property | Defined By | ||
---|---|---|---|
nonEmbeddedEdges : EdgeList [read-only]
Returns a list of edges that were not added to the embedding in a run of embedPlanarSubgraph()
| PlanarityTest |
Method | Defined By | ||
---|---|---|---|
PlanarityTest(init:Boolean = true)
Creates an instance of PlanarityAlgorithm. | PlanarityTest | ||
embed(planar:PlanarInformation):Boolean
Creates an embedding of a given graph if it is planar. | PlanarityTest | ||
embedPlanarSubgraph(planar:PlanarInformation):Boolean
Runs a planarity test and constructs a valid embedding of the graph. | PlanarityTest | ||
equals(o:Object):Boolean | YObject | ||
getClass():Class [override] | PlanarityTest | ||
hashCode():int | YObject | ||
Determines if the a given graph is planar. | PlanarityTest | ||
[static]
Creates an instance of PlanarityAlgorithm. | PlanarityTest |
Method | Defined By | ||
---|---|---|---|
initPlanarityTest():void
Initializes this object. | PlanarityTest |
nonEmbeddedEdges | property |
nonEmbeddedEdges:EdgeList
[read-only] Returns a list of edges that were not added to the embedding in a run of embedPlanarSubgraph()
public function get nonEmbeddedEdges():EdgeList
See also
PlanarityTest | () | Constructor |
public function PlanarityTest(init:Boolean = true)
Creates an instance of PlanarityAlgorithm. The DFS-tree used for the algorithm is constructed using the given order of nodes and edges in the graph.
Parametersinit: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.
|
embed | () | method |
public function embed(planar:PlanarInformation):Boolean
Creates an embedding of a given graph if it is planar. The result will be saved in the instance of com.yworks.yfiles.layout.planar.PlanarInformation which is
Parameters
planar:PlanarInformation — The PlanarInformation containing the graph to embed.
|
Boolean — true , if the embedding process was successful.
|
See also
embedPlanarSubgraph | () | method |
public function embedPlanarSubgraph(planar:PlanarInformation):Boolean
Runs a planarity test and constructs a valid embedding of the graph. If the graph is non-planar, some edges are hidden in order to make it planar. A list of hidden edges can be accessed via nonEmbeddedEdges.
Parameters
planar:PlanarInformation — The Graph to test, saved in a PlanarInformation data structure.
|
Boolean — true , if the graph is planar.
|
See also
getClass | () | method |
override public function getClass():Class
ReturnsClass |
initPlanarityTest | () | method |
protected final function initPlanarityTest():void
Initializes this object. See the documentation of the corresponding factory method newPlanarityTest()
for details.
See also
isPlanar | () | method |
public function isPlanar(graph:Graph):Boolean
Determines if the a given graph is planar. Runtime of this test is O(N) where N is the number of nodes.
Parameters
graph:Graph — The graph to test
|
Boolean — true , if the graph is planar
|
newPlanarityTest | () | method |
public static function newPlanarityTest():PlanarityTest
Creates an instance of PlanarityAlgorithm. The DFS-tree used for the algorithm is constructed using the given order of nodes and edges in the graph.
ReturnsPlanarityTest |