interface EdgeGraph.NonEmpty<N>
A non-empty type-invariant immutable edge (undirected) graph.
Extends: Streamable.NonEmpty<T>, EdgeGraph<N>
Type parameters
| Name | Description |
|---|---|
| N | the node type |
Methods
stream
Returns a non-empty Stream containing all graph elements of this collection as single tuples for isolated nodes and 2-valued tuples of nodes for connections. See the Graph documentation and the EdgeGraph API documentation
streamStream containing all graph elements of this collection as single tuples for isolated nodes and 2-valued tuples of nodes for connections. See the Graph documentation and the EdgeGraph API documentationDefinition
stream(): Stream.NonEmpty<GraphElement<N>>;
example
EdgeGraphHashed.of([1], [2, 3]).stream().toArray() // => [[1], [2, 3]]