Class: Path

Path(nodes, edges)

new Path(nodes, edges)

Parameters:
Name Type Description
nodes Array.<Node> path's node list.
edges Array.<Edge> path's edge list.
Source:

Members

edgeCount

Returns the amount of edges in the path.
Source:

Edges

Returns the path's edges as list.
Source:

firstNode

Returns the path's first node.
Source:

lastNode

Returns the last node of the path.
Source:

nodeCount

Returns the amount of nodes in th path.
Source:

Nodes

Returns the path's nodes as list.
Source:

Methods

getEdge(index) → {Edge}

Returns an edge in a given index.
Parameters:
Name Type Description
index number (integer)
Source:
Returns:
edge in a given index.
Type
Edge

getNode(index) → {Node}

Returns a node in a given index.
Parameters:
Name Type Description
index number (integer)
Source:
Returns:
node in the given index.
Type
Node

toString() → {string}

Returns the path string representation.
Source:
Returns:
path string representation.
Type
string