Edge
An edge connects two vertices.
Extends
Methods
getCost()
getCost():
number
Gets the cost for this edge. Defaults to 1.
Returns
number
Edge cost.
getFullId()
getFullId():
string
Alias for the getId method.
Returns
string
Overrides
Base.getFullId
getId()
getId():
string
Gets the id for this Edge.
Returns
string
Edge id.
isDirected()
isDirected():
boolean
Gets whether or not the Edge is directed.
Returns
boolean
True if the Edge is directed (unidirectional), false otherwise.
Properties
cost
cost:
number
Edge cost
source
source:
Vertex
Source of the Edge.
target
target:
Vertex
Target of the Edge.
type
type:
string
Object's type.