An undirected graph where each node is tied to a Point
.
A UndirectedPointGraph can be used for most general purpose graph needs.
- Inheritance
- Object
- Graph
- UndirectedPointGraph
Constructors
- UndirectedPointGraph()
-
Default constructor. Use .addAdjacency to populate this Graph.
- UndirectedPointGraph.fromAdjacencyList(List<List<PointNode>> adjacencyList)
-
Conveinience constructor, that calls .addAdjacency for each element of
adjacencyList
.
Properties
- adjacencyList → List<List<PointNode>>
-
Return a ListList<PointNode>> where each element is an
PointNode
pair representing an edge of this graph.read-only - allNodes → List<PointNode>
-
read-only
- hashCode → int
-
Get a hash code for this object.…
read-only, inherited - runtimeType → Type
-
A representation of the runtime type of the object.
read-only, inherited
Operators
-
operator ==(
other) → bool -
The equality operator.…
inherited
Methods
-
addAdjacency(
PointNode node1, PointNode node2) → void -
Add an edge to this graph connecting
node1
andnode2
. -
containsNode(
PointNode node) → bool -
Returns whether or not the [Node] [node] is a member of this
Graph
. -
distance(
PointNode n1, PointNode n2) → double -
Returns the distance between
n1
andn2
.… -
getNeighbors(
PointNode node, {bool onlyWalkable: true}) → List<PointNode> -
Returns every PointNode that is adjacent to
node
. -
heuristic(
PointNode n1, PointNode n2) → double -
Returns the heuristic distance estimate between
n1
andn2
. -
noSuchMethod(
Invocation invocation) → dynamic -
noSuchMethod
is invoked when users invoke a non-existent method on an object. The name of the method and the arguments of the invocation are passed tonoSuchMethod
in anInvocation
. IfnoSuchMethod
returns a value, that value becomes the result of the original invocation.…inherited -
toString(
) → String -
Returns a string representation of this object.
inherited