All edges at this node - commonly denoted as E(v).
All edges at this node - commonly denoted as E(v).
all edges with at least one end connecting to this node.
Finds a node (not necessarily directly) connected with this node
for which the predicate pred
holds taking optional filters and visitors into account.
Finds a node (not necessarily directly) connected with this node
for which the predicate pred
holds taking optional filters and visitors into account..
For directed or mixed graphs the node to be found is weekly connected with this node.
Node/edge visitor functions allow arbitrary user-defined computation
during the traversal.
This node itself does not count as a match. This is also true if it has a hook.
If several connected nodes exist with pred
the algorithm selects the first
of them it founds.
The predicate which must hold true for the resulting node.
Predicate to filter the nodes to be visited during traversal.
The default value is anyNode
, that is no filtering.
A return of true
signals that the traversal is to be canceled.
Predicate to filter the edges to be visited during traversal.
The default value is anyEdge
meaning that no filtering takes place.
Function to be called on visiting a node for the first time
during a traversal. It can mutate the node or carry out any other side effect.
The default value is the empty function noNodeAction
. Alternatively, an instance of ExtendedNodeVisitor
may be passed to obtain additional state information such as the current
depth. The concrete type of the last argument, the informer
depends on the underlying implementation so you need to match against it. Concerning this method please match against
scalax.collection.GraphTraversalImpl.DfsInformer.
Function to be called on visiting an edge.
It can mutate the node or carry out any other side effect.
The default value is the empty function noEdgeAction
.
If a NodeOrdering
or EdgeOrdering
different from noOrdering
is supplied
neighbor nodes will be sorted during the traversal. Thus it is guaranteed that
the smaller an element's ranking the sooner it will be processed. In case of
EdgeOrdering
it is guaranteed that the smaller an edge's ranking the sooner
its relevant end(s) will be processed.
A node with the predicate pred
or None if either
a) there is no node with pred
or
b) there exists no connection to such a node at all
c) there exists a connection to such a node but due to
user filtering or canceling the traversal this connection had to be disregarded.
Finds a cycle starting the search at this node taking optional filters and visitors into account.
Finds a cycle starting the search at this node taking optional filters and visitors into account., if any.
The resulting cycle may start at any node connected with this
node.
Predicate to filter the nodes to be visited during traversal.
The default value is anyNode
, that is no filtering.
A return of true
signals that the traversal is to be canceled.
Predicate to filter the edges to be visited during traversal.
The default value is anyEdge
meaning that no filtering takes place.
A positive value limits the number of layers for BFS respectively
the number of consecutive child visits before siblings are visited for DFS.
0
- the default - indicates that the traversal should have
an unlimited depth meaning that it will be continued either until
it's canceled by nodeVisitor
or until all nodes have been visited.
Function to be called on visiting a node for the first time
during a traversal. It can mutate the node or carry out any other side effect.
The default value is the empty function noNodeAction
. Alternatively, an instance of ExtendedNodeVisitor
may be passed to obtain additional state information such as the current
depth. The concrete type of the last argument, the informer
depends on the underlying implementation so you need to match against it. Concerning this method please match against
scalax.collection.GraphTraversalImpl.WgbInformer.
Function to be called on visiting an edge.
It can mutate the node or carry out any other side effect.
The default value is the empty function noEdgeAction
.
If a NodeOrdering
or EdgeOrdering
different from noOrdering
is supplied
neighbor nodes will be sorted during the traversal. Thus it is guaranteed that
the smaller an element's ranking the sooner it will be processed. In case of
EdgeOrdering
it is guaranteed that the smaller an edge's ranking the sooner
its relevant end(s) will be processed.
A cycle or None if either
a) there exists no cycle in the component this
node belongs to or
b) there exists a cycle in the component but due to the given
filtering conditions or a Cancel
return by a visitor this cycle
had to be disregarded.
Finds a predecessor of this node for which the predicate pred
holds taking optional filters and visitors into account.
Finds a predecessor of this node for which the predicate pred
holds taking optional filters and visitors into account..
Node/edge visitor functions allow arbitrary user-defined computation
during the traversal.
This node itself does not count as a match. This is also true if it has a hook. If several predecessors exist the algorithm selects the first of them found.
The predicate which must hold true for the resulting node.
Predicate to filter the nodes to be visited during traversal.
The default value is anyNode
, that is no filtering.
A return of true
signals that the traversal is to be canceled.
Predicate to filter the edges to be visited during traversal.
The default value is anyEdge
meaning that no filtering takes place.
Function to be called on visiting a node for the first time
during a traversal. It can mutate the node or carry out any other side effect.
The default value is the empty function noNodeAction
. Alternatively, an instance of ExtendedNodeVisitor
may be passed to obtain additional state information such as the current
depth. The concrete type of the last argument, the informer
depends on the underlying implementation so you need to match against it. Concerning this method please match against
scalax.collection.GraphTraversalImpl.DfsInformer.
Function to be called on visiting an edge.
It can mutate the node or carry out any other side effect.
The default value is the empty function noEdgeAction
.
If a NodeOrdering
or EdgeOrdering
different from noOrdering
is supplied
neighbor nodes will be sorted during the traversal. Thus it is guaranteed that
the smaller an element's ranking the sooner it will be processed. In case of
EdgeOrdering
it is guaranteed that the smaller an edge's ranking the sooner
its relevant end(s) will be processed.
A node with the predicate pred
or None if either
a) there is no node with pred
or
b) there exists no path from such a node to this node at all or
c) there exists a path from such a node to this node but due to
user filtering or canceling the traversal this path had to be disregarded.
Finds a successor of this node for which the predicate pred
holds taking optional filters and visitors into account.
Finds a successor of this node for which the predicate pred
holds taking optional filters and visitors into account..
Node/edge visitor functions allow arbitrary user-defined computation
during the traversal.
This node itself does not count as a match. This is also true if it has a hook. If several successors exist the algorithm selects the first of them it founds.
The predicate which must hold true for the resulting node.
Predicate to filter the nodes to be visited during traversal.
The default value is anyNode
, that is no filtering.
A return of true
signals that the traversal is to be canceled.
Predicate to filter the edges to be visited during traversal.
The default value is anyEdge
meaning that no filtering takes place.
Function to be called on visiting a node for the first time
during a traversal. It can mutate the node or carry out any other side effect.
The default value is the empty function noNodeAction
. Alternatively, an instance of ExtendedNodeVisitor
may be passed to obtain additional state information such as the current
depth. The concrete type of the last argument, the informer
depends on the underlying implementation so you need to match against it. Concerning this method please match against
scalax.collection.GraphTraversalImpl.DfsInformer.
Function to be called on visiting an edge.
It can mutate the node or carry out any other side effect.
The default value is the empty function noEdgeAction
.
If a NodeOrdering
or EdgeOrdering
different from noOrdering
is supplied
neighbor nodes will be sorted during the traversal. Thus it is guaranteed that
the smaller an element's ranking the sooner it will be processed. In case of
EdgeOrdering
it is guaranteed that the smaller an edge's ranking the sooner
its relevant end(s) will be processed.
A node with the predicate pred
or None if either
a) there is no node with pred
or
b) there exists no path to such a node at all
c) there exists a path to such a node but due to
user filtering or canceling the traversal this path had to be disregarded.
Finds a path from this node to a successor of this node for which the predicate
pred
holds taking optional filters and visitors into account.
Finds a path from this node to a successor of this node for which the predicate
pred
holds taking optional filters and visitors into account..
This node itself does not count as a match. This is also true if it has a hook. If several successors exist the algorithm selects any first matching node.
The predicate which must hold true for the successor.
Predicate to filter the nodes to be visited during traversal.
The default value is anyNode
, that is no filtering.
A return of true
signals that the traversal is to be canceled.
Predicate to filter the edges to be visited during traversal.
The default value is anyEdge
meaning that no filtering takes place.
Function to be called on visiting a node for the first time
during a traversal. It can mutate the node or carry out any other side effect.
The default value is the empty function noNodeAction
. Alternatively, an instance of ExtendedNodeVisitor
may be passed to obtain additional state information such as the current
depth. The concrete type of the last argument, the informer
depends on the underlying implementation so you need to match against it. Concerning this method please match against
scalax.collection.GraphTraversalImpl.DfsInformer.
Function to be called on visiting an edge.
It can mutate the node or carry out any other side effect.
The default value is the empty function noEdgeAction
.
If a NodeOrdering
or EdgeOrdering
different from noOrdering
is supplied
neighbor nodes will be sorted during the traversal. Thus it is guaranteed that
the smaller an element's ranking the sooner it will be processed. In case of
EdgeOrdering
it is guaranteed that the smaller an edge's ranking the sooner
its relevant end(s) will be processed.
A path to a node with the predicate pred
or None if either
a) there is no node with pred
or
b) there exists no path to such a node at all
c) there exists a path to such a node but due to the given filter
conditions this path had to be disregarded.
Finds the shortest path from this node to potentialSuccessor
.
Finds the shortest path from this node to potentialSuccessor
.
The calculation is based on the weight of the edges on the path. As a default, edges have a weight of 1 what can be overridden by custom edges.
The node the shortest path is to be found to.
Predicate to filter the nodes to be visited during traversal.
The default value is anyNode
, that is no filtering.
A return of true
signals that the traversal is to be canceled.
Predicate to filter the edges to be visited during traversal.
The default value is anyEdge
meaning that no filtering takes place.
Function to be called on visiting a node for the first time
during a traversal. It can mutate the node or carry out any other side effect.
The default value is the empty function noNodeAction
. Alternatively, an instance of ExtendedNodeVisitor
may be passed to obtain additional state information such as the current
depth. The concrete type of the last argument, the informer
depends on the underlying implementation so you need to match against it. Concerning this method please match against
scalax.collection.GraphTraversalImpl.DijkstraInformer.
Function to be called on visiting an edge.
It can mutate the node or carry out any other side effect.
The default value is the empty function noEdgeAction
.
If a NodeOrdering
or EdgeOrdering
different from noOrdering
is supplied
neighbor nodes will be sorted during the traversal. Thus it is guaranteed that
the smaller an element's ranking the sooner it will be processed. In case of
EdgeOrdering
it is guaranteed that the smaller an edge's ranking the sooner
its relevant end(s) will be processed.
The shortest path to potentialSuccessor
or None if either
a) there exists no path to potentialSuccessor
or
b) there exists a path to potentialSuccessor
but due to the given
filtering conditions this path had to be disregarded.
Traverses this graph starting at this (root) node for side-effects allowing
Traverses this graph starting at this (root) node for side-effects allowing
a) to filter nodes and/or edges, b) to carry out any side effect at visited nodes and/or edges and c) to cancel the traversal at any node.
Determines which connected nodes the traversal has to follow.
The default value is Successors
.
Predicate to filter the nodes to be visited during traversal.
The default value is anyNode
, that is no filtering.
A return of true
signals that the traversal is to be canceled. Alternatively, an instance of ExtendedNodeVisitor
may be passed to obtain additional state information such as the current
depth. The concrete type of the last argument, the informer
depends on the underlying implementation so you need to match against it. Concerning this method please match against
scalax.collection.GraphTraversalImpl.DfsInformer or
scalax.collection.GraphTraversalImpl.BfsInformer depending on the
breadthFirst
argument.
Predicate to filter the edges to be visited during traversal.
The default value is anyEdge
meaning that no filtering takes place.
If true
the traversal is based on a breath first
(BFS, layer-for-layer) search, otherwise on a depth first search (DFS).
The default value is BFS.
A positive value limits the number of layers for BFS respectively
the number of consecutive child visits before siblings are visited for DFS.
0
- the default - indicates that the traversal should have
an unlimited depth meaning that it will be continued either until
it's canceled by nodeVisitor
or until all nodes have been visited.
If a NodeOrdering
or EdgeOrdering
different from noOrdering
is supplied
neighbor nodes will be sorted during the traversal. Thus it is guaranteed that
the smaller an element's ranking the sooner it will be processed. In case of
EdgeOrdering
it is guaranteed that the smaller an edge's ranking the sooner
its relevant end(s) will be processed.
Function to be called on visiting a node for the first time
during a traversal. It can mutate the node or carry out any other side effect.
The default value is the empty function noNodeAction
.
Function to be called on visiting an edge.
It can mutate the node or carry out any other side effect.
The default value is the empty function noEdgeAction
.
The outer node as supplied by the user at instantiation time or by adding nodes this graph.
The outer node as supplied by the user at instantiation time or by adding nodes this graph.
Reference to the user-supplied outer node.
Synonym for incomingFrom
.
Synonym for incomingFrom
.
Synonym for incoming
.
Synonym for incoming
.
Synonym for findIncomingFrom
.
Synonym for findIncomingFrom
.
Synonym for diPredecessors
.
Synonym for diPredecessors
.
The Graph
instance this
node is contained in.
The degree of this node.
The degree of this node.
the number of edges that connect to this node. An edge that connects to this node at more than one ends (loop) is counted as much times as it is connected to this node.
All direct predecessors of this node, also called predecessor set or open in-neighborhood: source nodes of directed incident edges and / or adjacent nodes of undirected incident edges excluding this node.
All direct predecessors of this node, also called predecessor set or open in-neighborhood: source nodes of directed incident edges and / or adjacent nodes of undirected incident edges excluding this node.
set of all direct predecessors of this node.
All direct successors of this node, also called successor set or open out-neighborhood: target nodes of directed incident edges and / or adjacent nodes of undirected incident edges excluding this node.
All direct successors of this node, also called successor set or open out-neighborhood: target nodes of directed incident edges and / or adjacent nodes of undirected incident edges excluding this node.
set of all direct successors of this node.
Same as findCycle(...)
with default arguments.
Same as findCycle(...)
with default arguments.
An edge at from
having this node as a successor.
An edge at from
having this node as a successor.
The node being at an edge which has this node as a successor.
An edges at from
having this node as a successor.
If from
equals this node a hook may be returned.
If from
is not an adjacent node None
is returned.
An outgoing edge connecting this node with to
.
An outgoing edge connecting this node with to
.
The node which is the end point of an edge starting at this node.
One of possibly several edges connecting this node with to
.
If to
equals this node a hook may be returned.
If to
is not an adjacent node None
is returned.
Checks whether this node has only hooks or no edges at all.
Checks whether this node has only hooks or no edges at all.
true if this node has only hooks or it does not participate in any edge
Checks whether potentialPredecessor
is a predecessor of this node taking optional filters and visitors into account.
Checks whether potentialPredecessor
is a predecessor of this node taking optional filters and visitors into account..
Node/edge visitor functions allow arbitrary user-defined computation
during the traversal.
Same as isSuccessorOf
.
The node which is potentially a predecessor of this node.
Predicate to filter the nodes to be visited during traversal.
The default value is anyNode
, that is no filtering.
A return of true
signals that the traversal is to be canceled.
Predicate to filter the edges to be visited during traversal.
The default value is anyEdge
meaning that no filtering takes place.
Function to be called on visiting a node for the first time
during a traversal. It can mutate the node or carry out any other side effect.
The default value is the empty function noNodeAction
. Alternatively, an instance of ExtendedNodeVisitor
may be passed to obtain additional state information such as the current
depth. The concrete type of the last argument, the informer
depends on the underlying implementation so you need to match against it. Concerning this method please match against
scalax.collection.GraphTraversalImpl.DfsInformer.
Function to be called on visiting an edge.
It can mutate the node or carry out any other side effect.
The default value is the empty function noEdgeAction
.
If a NodeOrdering
or EdgeOrdering
different from noOrdering
is supplied
neighbor nodes will be sorted during the traversal. Thus it is guaranteed that
the smaller an element's ranking the sooner it will be processed. In case of
EdgeOrdering
it is guaranteed that the smaller an edge's ranking the sooner
its relevant end(s) will be processed.
true
if a path exists from potentialPredecessor
to this node and
it had not to be excluded due to user filtering or canceling the traversal.
Checks whether potentialSuccessor
is a successor of this node taking optional filters and visitors into account.
Checks whether potentialSuccessor
is a successor of this node taking optional filters and visitors into account..
Node/edge visitor functions allow arbitrary user-defined computation
during the traversal.
Same as isPredecessorOf
.
The node which is potentially a successor of this node.
Predicate to filter the nodes to be visited during traversal.
The default value is anyNode
, that is no filtering.
A return of true
signals that the traversal is to be canceled.
Predicate to filter the edges to be visited during traversal.
The default value is anyEdge
meaning that no filtering takes place.
Function to be called on visiting a node for the first time
during a traversal. It can mutate the node or carry out any other side effect.
The default value is the empty function noNodeAction
. Alternatively, an instance of ExtendedNodeVisitor
may be passed to obtain additional state information such as the current
depth. The concrete type of the last argument, the informer
depends on the underlying implementation so you need to match against it. Concerning this method please match against
scalax.collection.GraphTraversalImpl.DfsInformer.
Function to be called on visiting an edge.
It can mutate the node or carry out any other side effect.
The default value is the empty function noEdgeAction
.
If a NodeOrdering
or EdgeOrdering
different from noOrdering
is supplied
neighbor nodes will be sorted during the traversal. Thus it is guaranteed that
the smaller an element's ranking the sooner it will be processed. In case of
EdgeOrdering
it is guaranteed that the smaller an edge's ranking the sooner
its relevant end(s) will be processed.
true
if a path exists from this node to potentialSuccessor
and
it had not to be excluded due to user filtering or canceling the traversal.
The incoming degree of this node.
The incoming degree of this node.
the number of edges that come in to this node including undirected edges. Every loop on this node is counted twice.
Synonym for diPredecessors
.
Synonym for diPredecessors
.
Incoming edges of this node.
Incoming edges of this node.
set of all edges incoming to of this including undirected edges.
All incoming edges connecting from
with this node.
All incoming edges connecting from
with this node.
The node with zero, one or more edges having this node as a direct successor.
All edges at from
having this node as a direct successor.
If from
equals this node all hooks are returned.
If from
is not an adjacent node an empty set is returned.
Checks whether potentialConnected
is a node (not necessarily directly)
connected with this node taking optional filters and visitors into account.
Checks whether potentialConnected
is a node (not necessarily directly)
connected with this node taking optional filters and visitors into account..
For directed or mixed graphs it is satisfactory that potentialConnected
is
weekly connected with this node.
Node/edge visitor functions allow arbitrary user-defined computation
during the traversal.
The node which is potentially connected with this node.
Predicate to filter the nodes to be visited during traversal.
The default value is anyNode
, that is no filtering.
A return of true
signals that the traversal is to be canceled.
Predicate to filter the edges to be visited during traversal.
The default value is anyEdge
meaning that no filtering takes place.
Function to be called on visiting a node for the first time
during a traversal. It can mutate the node or carry out any other side effect.
The default value is the empty function noNodeAction
.
Alternatively, an instance of ExtendedNodeVisitor
may be passed to obtain additional state information such as the current
depth. The concrete type of the last argument, the informer
depends on the underlying implementation so you need to match against it. Concerning this method please match against
scalax.collection.GraphTraversalImpl.DfsInformer.
Function to be called on visiting an edge.
It can mutate the node or carry out any other side effect.
The default value is the empty function noEdgeAction
.
If a NodeOrdering
or EdgeOrdering
different from noOrdering
is supplied
neighbor nodes will be sorted during the traversal. Thus it is guaranteed that
the smaller an element's ranking the sooner it will be processed. In case of
EdgeOrdering
it is guaranteed that the smaller an edge's ranking the sooner
its relevant end(s) will be processed.
true
if a path exists from this node to potentialConnected
and
it had not to be excluded due to user filtering or canceling the traversal.
Whether that
is an adjacent (direct successor) to this node.
Whether that
is an adjacent (direct successor) to this node.
The node to check for adjacency.
true
if that
is adjacent to this node.
Whether that
is independent of this node meaning that
there exists no edge connecting this node with that
.
Whether that
is independent of this node meaning that
there exists no edge connecting this node with that
.
The node to check for independency.
true
if that
node is independent of this node.
Returns whether this node's degree equals to 0.
Returns whether this node's degree equals to 0.
Returns whether this node's degree equals to 1.
Returns whether this node's degree equals to 1.
Same as hasSuccessor
.
Same as hasSuccessor
.
Same as hasPredecessor
.
Same as hasPredecessor
.
All adjacent nodes (direct successors and predecessors) of this node, also called open neighborhood excluding this node.
All adjacent nodes (direct successors and predecessors) of this node, also called open neighborhood excluding this node.
set of all neighbors.
The outgoing degree of this node.
The outgoing degree of this node.
the number of edges that go out from this node including undirected edges. Every loop on this node is counted twice.
Synonym for diSuccessors
.
Synonym for diSuccessors
.
All edges outgoing from this node.
All edges outgoing from this node.
set of all edges outgoing from this node including undirected edges and hooks.
All outgoing edges connecting this node with to
.
All outgoing edges connecting this node with to
.
The node which is the end point of zero, one or more edges starting at this node.
All edges connecting this node with to
.
If to
equals this node all hooks are returned.
If to
is not an adjacent an empty set is returned.
Finds a path from this node to potentialSuccessor
taking optional filters and visitors into account.
Finds a path from this node to potentialSuccessor
taking optional filters and visitors into account..
The node a path is to be found to.
Predicate to filter the nodes to be visited during traversal.
The default value is anyNode
, that is no filtering.
A return of true
signals that the traversal is to be canceled.
Predicate to filter the edges to be visited during traversal.
The default value is anyEdge
meaning that no filtering takes place.
Function to be called on visiting a node for the first time
during a traversal. It can mutate the node or carry out any other side effect.
The default value is the empty function noNodeAction
. Alternatively, an instance of ExtendedNodeVisitor
may be passed to obtain additional state information such as the current
depth. The concrete type of the last argument, the informer
depends on the underlying implementation so you need to match against it. Concerning this method please match against
scalax.collection.GraphTraversalImpl.DfsInformer.
Function to be called on visiting an edge.
It can mutate the node or carry out any other side effect.
The default value is the empty function noEdgeAction
.
If a NodeOrdering
or EdgeOrdering
different from noOrdering
is supplied
neighbor nodes will be sorted during the traversal. Thus it is guaranteed that
the smaller an element's ranking the sooner it will be processed. In case of
EdgeOrdering
it is guaranteed that the smaller an edge's ranking the sooner
its relevant end(s) will be processed.
A path to potentialSuccessor
or None if either
a) there is no node with pred
or
b) there exists no path to such a node at all
c) there exists a path to such a node but due to the given filter
conditions this path had to be disregarded.
Finds a path from this node to potentialSuccessor
.
Finds a path from this node to potentialSuccessor
.
The node a path is to be found to.
A path to potentialSuccessor
or None if either
a) there is no node with pred
or
b) there exists no path to such a node at all
Traverses this graph starting at this node for side-effects using dfs and applying 'down' and 'up' node visitors to allow computations in a stack-wise manner:
Traverses this graph starting at this node for side-effects using dfs and applying 'down' and 'up' node visitors to allow computations in a stack-wise manner:
val root = "A" val g = Graph(root~>"B1", root~>"B2") val result = ListBuffer.empty[String] (g get root).traverseDownUp()( nodeDown = (n: g.NodeT) => { result. += (if (n == root) "{" else "(") result. += (n.value) Continue }, nodeUp = (n: g.NodeT) => result. += (if (n == root) "}" else ")") ) ("" /: result)(_+_) // yields "{A(B1)(B2)}"
Determines which connected nodes the traversal has to follow.
The default value is Successors
.
Predicate to filter the nodes to be visited during traversal.
The default value is anyNode
, that is no filtering.
A return of true
signals that the traversal is to be canceled.
Predicate to filter the edges to be visited during traversal.
The default value is anyEdge
meaning that no filtering takes place.
Function to be called on visiting an edge.
It can mutate the node or carry out any other side effect.
The default value is the empty function noEdgeAction
.
A positive value limits the number of layers for BFS respectively
the number of consecutive child visits before siblings are visited for DFS.
0
- the default - indicates that the traversal should have
an unlimited depth meaning that it will be continued either until
it's canceled by nodeVisitor
or until all nodes have been visited.
If a NodeOrdering
or EdgeOrdering
different from noOrdering
is supplied
neighbor nodes will be sorted during the traversal. Thus it is guaranteed that
the smaller an element's ranking the sooner it will be processed. In case of
EdgeOrdering
it is guaranteed that the smaller an edge's ranking the sooner
its relevant end(s) will be processed.
Function to be called on visiting a node for the first time
during a traversal. It can mutate the node or carry out any other side effect.
The default value is the empty function noNodeAction
. Alternatively, an instance of ExtendedNodeVisitor
may be passed to obtain additional state information such as the current
depth. The concrete type of the last argument, the informer
depends on the underlying implementation so you need to match against it. Concerning this method please match against
scalax.collection.GraphTraversalImpl.DfsInformer.
Function to be called on reaching an already visited node
when moving up in the imaginary tree of a depth first search. Paired with
nodeVisitor
(the 'down-visitor'), this 'up-visitor' enables a stack-wise view of
the traversed nodes.
The default value is the empty function noNodeUpAction
. Alternatively, an instance of ExtendedNodeVisitor
may be passed to obtain additional state information such as the current
depth. The concrete type of the last argument, the informer
depends on the underlying implementation so you need to match against it. Concerning this method please match against
scalax.collection.GraphTraversalImpl.DfsInformer.
Shortcut for calling 'traverse' with a non-default edgeVisitor
but the default nodeVisitor
allowing a foreach
-like call syntax:
Shortcut for calling 'traverse' with a non-default edgeVisitor
but the default nodeVisitor
allowing a foreach
-like call syntax:
rootNode traverseEdges() { print( if(_.directed) "d" else "u" ) Continue }
Shortcut for calling traverse
with a non-default nodeVisitor
and
the default edgeVisitor
allowing a foreach
-like call syntax:
Shortcut for calling traverse
with a non-default nodeVisitor
and
the default edgeVisitor
allowing a foreach
-like call syntax:
rootNode traverseNodes() {
print("d" + _.degree)
Continue
}
Synonym for edges
.
Synonym for edges
.
Synonym for outgoingTo
.
Synonym for outgoingTo
.
Synonym for outgoing
.
Synonym for outgoing
.
Synonym for outgoingTo
.
Synonym for outgoingTo
.
Synonym for diSuccessors
.
Synonym for diSuccessors
.
Synonym for neighbors
.
Synonym for neighbors
.