Packagecom.yworks.yfiles.layout.labeling
Classpublic class GreedyMISLabeling
InheritanceGreedyMISLabeling Inheritance MISLabelingAlgorithm Inheritance AbstractLabelingAlgorithm Inheritance AbstractLayoutStage Inheritance YObject Inheritance Object

This class places the labels of a graph using a greedy strategy. This is the fastest label placing algorithm provided.



Public Properties
 PropertyDefined By
 InheritedapplyPostprocessing : Boolean
Getter: Returns true if the postprocessing step is applied.
AbstractLabelingAlgorithm
 InheritedautoFlippingEnabled : Boolean
Determines whether or not edge labels associated with a "free" label model (see for example y.view.SmartEdgeLabelModel) should be automatically flipped if they would be upside-down.
AbstractLabelingAlgorithm
 InheritedboxesToNodesInternal : Map
[read-only]
MISLabelingAlgorithm
 InheritedconflictGraphInternal : Graph
[read-only]
MISLabelingAlgorithm
 InheritedcoreLayouter : Layouter
Specifies the core layouter.
AbstractLayoutStage
 InheritedcustomProfitModelRatio : Number
Getter: Returns the custom profit model ratio.
MISLabelingAlgorithm
 InheritededgeGroupOverlapAllowed : Boolean
Getter: Returns whether edge labels may overlap with edges belonging to the same edge group.
AbstractLabelingAlgorithm
 Inheritedgraph : LayoutGraph
MISLabelingAlgorithm
 InheritedmoveInternalNodeLabels : Boolean
Specifies true if the labeling algorithm is allowed to move internal node labels.
AbstractLabelingAlgorithm
 InheritednodesToIDInternal : NodeMap
[read-only]
MISLabelingAlgorithm
 InheritedoptimizationStrategy : int
Specifies the optimization strategy of the labeling algorithm.
MISLabelingAlgorithm
 InheritedplaceEdgeLabels : Boolean
Specifies whether labels assigned to edges in a graph should be placed or ignored.
AbstractLabelingAlgorithm
 InheritedplaceNodeLabels : Boolean
Specifies whether labels assigned to nodes in a graph should be placed or ignored.
AbstractLabelingAlgorithm
 InheritedprofitModel : ProfitModel
Sets the profit model that is used to rank the available positions for each label.
AbstractLabelingAlgorithm
 Inheritedrects : YList
[read-only] Returns the set of all generated candidate rectangles.
AbstractLabelingAlgorithm
 InheritedremoveEdgeOverlaps : Boolean
Specifies how label candidates which overlap with edges are handled.
AbstractLabelingAlgorithm
 InheritedremoveNodeOverlaps : Boolean
Specifies how label candidates which overlap with nodes are handled.
AbstractLabelingAlgorithm
 InheritedselectedLabelsDpKey : Object
Getter: Returns the labeling selection DataProvider key.
AbstractLabelingAlgorithm
 InheritedstoreRects : Boolean
Specifies whether the candidate rectangles should be stored to be retrieved.
AbstractLabelingAlgorithm
 InheriteduseAlternativeSideHandling : Boolean
Getter: Returns true if the preference on which side of an edge a corresponding label should be placed is interpreted by human perception instead of always following the edge from source to target.
AbstractLabelingAlgorithm
Protected Properties
 PropertyDefined By
 InheritedboxesToNodes : Map
MISLabelingAlgorithm
 InheritedconflictGraph : Graph
the conflict graph
MISLabelingAlgorithm
 InheritednodesToBoxes : NodeMap
holds for each node in the conflictGraph the corresponding LabelCandidate
MISLabelingAlgorithm
 InheritednodesToID : NodeMap
holds for each node in the conflictGraph the corresponding integer index of the Label[]
MISLabelingAlgorithm
Public Methods
 MethodDefined By
  
GreedyMISLabeling(init:Boolean = true)
GreedyMISLabeling
 Inherited
canLayout(graph:LayoutGraph):Boolean
[override] Returns true.
AbstractLabelingAlgorithm
 Inherited
doLayout(graph:LayoutGraph):void
[override] Place the labels in the graph.
AbstractLabelingAlgorithm
 Inherited
equals(o:Object):Boolean
YObject
  
getClass():Class
[override]
GreedyMISLabeling
 Inherited
Returns the profit model that is used to rank the available positions for each label.
AbstractLabelingAlgorithm
 Inherited
hashCode():int
YObject
 Inherited
Place the labels in the graph.
AbstractLabelingAlgorithm
 Inherited
labelSome(gl:LayoutGraph, key:Object):void
Place a subset of the labels.
AbstractLabelingAlgorithm
 Inherited
labelSome2(gl:LayoutGraph, nodeLabels:YList, edgeLabels:YList):void
Place some labels in the graph.
AbstractLabelingAlgorithm
  
[static]
GreedyMISLabeling
Protected Methods
 MethodDefined By
 Inherited
Creates a node map which assigns to each node the profit.
MISLabelingAlgorithm
 Inherited
canLayoutCore(graph:LayoutGraph):Boolean
Queries the core layouter whether or not the given graph can be laid out.
AbstractLayoutStage
 Inherited
checkGroupNodeSize(layout:GraphLayout, node:Object):void
This method throws an com.yworks.bridge.util.IllegalArgumentException if the width/height of the given group node object is zero.
AbstractLabelingAlgorithm
 Inherited
checkNodeSize(layout:GraphLayout, node:Object):void
This method throws an com.yworks.bridge.util.IllegalArgumentException if the width/height of the given node object is zero.
AbstractLabelingAlgorithm
 Inherited
Creates one edge between two nodes if the corresponding label candidates are intersecting.
MISLabelingAlgorithm
 Inherited
Invokes the layout routine of the core layouter.
AbstractLayoutStage
 Inherited
Calculates the overlapping factor between a label candidate and an edge segment.
MISLabelingAlgorithm
 Inherited
Calculates the overlapping factor between a label candidate and a node halo.
MISLabelingAlgorithm
 Inherited
Calculates the overlapping factor between two label candidates.
MISLabelingAlgorithm
 Inherited
Calculates the overlapping factor between a label candidate and a node.
MISLabelingAlgorithm
 Inherited
AbstractLabelingAlgorithm
 Inherited
AbstractLayoutStage
 Inherited
AbstractLayoutStage
  
GreedyMISLabeling
 Inherited
MISLabelingAlgorithm
Public Constants
 ConstantDefined By
 InheritedLABEL_MODEL_DPKEY : Object = y.layout.labeling.AbstractLabelingAlgorithm.LABEL_MODEL_DPKEY
[static] com.yworks.yfiles.base.DataProvider key to specify for each com.yworks.yfiles.layout.EdgeLabelLayout s and each com.yworks.yfiles.layout.NodeLabelLayout a replacement com.yworks.yfiles.layout.EdgeLabelModel or com.yworks.yfiles.layout.NodeLabelModel, respectively, that is used by the labeling algorithm instead of the original label model.
AbstractLabelingAlgorithm
 InheritedOPTIMIZATION_BALANCED : int = 0
[static] Use a balanced optimization strategy.
MISLabelingAlgorithm
 InheritedOPTIMIZATION_EDGE_OVERLAP : int = 3
[static] Use an optimization strategy that especially reduces overlaps between labels and edges.
MISLabelingAlgorithm
 InheritedOPTIMIZATION_LABEL_OVERLAP : int = 2
[static] Use an optimization strategy that especially reduces overlaps between labels.
MISLabelingAlgorithm
 InheritedOPTIMIZATION_NODE_OVERLAP : int = 1
[static] Use an optimization strategy that especially reduces overlaps between labels and nodes as well as labels and node halos.
MISLabelingAlgorithm
 InheritedOPTIMIZATION_NONE : int = 4
[static] Use no optimization strategy.
MISLabelingAlgorithm
Constructor Detail
GreedyMISLabeling()Constructor
public function GreedyMISLabeling(init:Boolean = true)



Parameters
init:Boolean (default = true)
Method Detail
getClass()method
override public function getClass():Class

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

newGreedyMISLabeling()method 
public static function newGreedyMISLabeling():GreedyMISLabeling

Returns
GreedyMISLabeling