definition:
|
findNode :: Graph -> NodeID -> Node
findNode graph nid =
let mnode = find ((== nid) . getNodeId) graph
in case mnode of
Nothing -> error ("Invalid NodeID in graph" ++ (show nid))
Just node -> node
|
demand:
|
no demanded arguments
|
deterministic:
|
deterministic operation
|
documentation:
|
-- Get a node by NodeID from a graph
|
failfree:
|
(_, _)
|
indeterministic:
|
referentially transparent operation
|
infix:
|
no fixity defined
|
iotype:
|
{(_,_) |-> _}
|
name:
|
findNode
|
precedence:
|
no precedence defined
|
result-values:
|
_
|
signature:
|
[Node] -> Prelude.Int -> Node
|
solution-complete:
|
operation might suspend on free variables
|
terminating:
|
possibly non-terminating
|
totally-defined:
|
possibly non-reducible on same data term
|