graphi.types.undirected module¶
-
class
graphi.types.undirected.Undirected(*source, **kwargs)¶ Bases:
graphi.abc.GraphWrapper to make
Graphinstances undirectedSee also
The
undirectable()decorator forGraphclasses.-
clear()¶ Remove all elements from this graph
-
edges()¶ Return a new view of the graph’s edges
Returns: view of the graph’s edges Return type: UndirectedEdgeView
-
undirected¶
-
update(other)¶ Update the graph with the nodes, edges and values from
other, overwriting existing elements.Parameters: other ( GraphorItemView) – graph or items from which to pull elements
-
values()¶ Return a new view of the values of the graph’s edges
Returns: view of the values of the graph’s edges Return type: UndirectedValueView
-
-
class
graphi.types.undirected.UndirectedEdge(start, stop, step=None)¶ Bases:
graphi.edge.EdgeAn undirected edge as a pair of nodes
For any nodes
aandb, theUndirectedEdgesa:bandb:aare equivalent. As a result, which of the two isstartorstopis arbitrary but well-defined.
-
class
graphi.types.undirected.UndirectedEdgeView(graph)¶ Bases:
graphi.abc.EdgeViewView on the undirected edges in a graph
-
class
graphi.types.undirected.UndirectedValueView(graph)¶ Bases:
graphi.abc.ValueViewView on the values of undirected edges in a graph