Options
All
  • Public
  • Public/Protected
  • All
Menu

Internal model of a hierarchical graph. This model stores nodes and edges equivalent to the real graph nodes and edges, but also stores the rank of the cells, the order within the ranks and the new candidate locations of cells. The internal model also reverses edge direction were appropriate , ignores self-loop and groups parallels together under one edge object.

Hierarchy

  • mxSwimlaneModel

Index

Constructors

constructor

Properties

SOURCESCANSTARTRANK

SOURCESCANSTARTRANK: number

Variable: SOURCESCANSTARTRANK

High value to start source layering scan rank value from.

dfsCount

dfsCount: number

Variable: dfsCount

Count of the number of times the ancestor dfs has been used.

edgeMapper

edgeMapper: any

Variable: edgeMapper

Map from graph edges to internal model edges

maxRank

maxRank: number

Variable: maxRank

Stores the largest rank number allocated

parent

parent: mxCell

Variable: parent

The parent cell whose children are being laid out

ranks

ranks: any

Variable: ranks

Mapping from rank number to actual rank

ranksPerGroup

ranksPerGroup: any

Variable: ranksPerGroup

An array of the number of ranks within each swimlane

roots

roots: mxCell[]

Variable: roots

Store of roots of this hierarchy model, these are real graph cells, not internal cells

tightenToSource

tightenToSource: boolean

Variable: tightenToSource

Whether or not to tighten the assigned ranks of vertices up towards the source cells.

vertexMapper

vertexMapper: any

Variable: vertexMapper

Map from graph vertices to internal model nodes.

Methods

createInternalCells

dfs

  • dfs(parent: any, root: any, connectingEdge: any, visitor: any, seen: any, layer: any): void
  • Performs a depth first search on the internal hierarchy model

    Parameters

    • parent: any

      the parent internal node of the current internal node

    • root: any

      the current internal node

    • connectingEdge: any

      the internal edge connecting the internal node and the parent internal node, if any

    • visitor: any

      the visitor pattern to be called for each node

    • seen: any

      a set of all nodes seen by this dfs a set of all of the ancestor node of the current node

    • layer: any

      the layer on the dfs tree ( not the same as the model ranks )

    Returns void

extendedDfs

  • extendedDfs(parent: any, root: any, connectingEdge: any, visitor: any, seen: any, ancestors: any, childHash: any, layer: any): void
  • Performs a depth first search on the internal hierarchy model. This dfs extends the default version by keeping track of cells ancestors, but it should be only used when necessary because of it can be computationally intensive for deep searches.

    Parameters

    • parent: any

      the parent internal node of the current internal node

    • root: any

      the current internal node

    • connectingEdge: any

      the internal edge connecting the internal node and the parent internal node, if any

    • visitor: any

      the visitor pattern to be called for each node

    • seen: any

      a set of all nodes seen by this dfs

    • ancestors: any

      the parent hash code

    • childHash: any

      the new hash code for this node

    • layer: any

      the layer on the dfs tree ( not the same as the model ranks )

    Returns void

fixRanks

  • fixRanks(): void

initialRank

  • initialRank(): void
  • Basic determination of minimum layer ranking by working from from sources or sinks and working through each node in the relevant edge direction. Starting at the sinks is basically a longest path layering algorithm.

    Returns void

maxChainDfs

  • maxChainDfs(parent: mxCell, root: mxCell, connectingEdge: any, seen: any, chainCount: number): void
  • Performs a depth first search on the internal hierarchy model. This dfs extends the default version by keeping track of chains within groups. Any cycles should be removed prior to running, but previously seen cells are ignored.

    Parameters

    • parent: mxCell

      the parent internal node of the current internal node

    • root: mxCell

      the current internal node

    • connectingEdge: any

      the internal edge connecting the internal node and the parent internal node, if any

    • seen: any

      a set of all nodes seen by this dfs

    • chainCount: number

      the number of edges in the chain of vertices going through the current swimlane

    Returns void

visit

  • visit(visitor: any, dfsRoots: any, trackAncestors: any, seenNodes: any): void
  • A depth first search through the internal heirarchy model.

    Parameters

    • visitor: any

      The visitor function pattern to be called for each node.

    • dfsRoots: any
    • trackAncestors: any

      Whether or not the search is to keep track all nodes directly above this one in the search path.

    • seenNodes: any

    Returns void

Generated using TypeDoc