public Graph < K , VV , EV > getUndirected ( ) { DataSet < Edge < K , EV > > undirectedEdges = edges . flatMap ( new RegularAndReversedEdgesMap <> ( ) ) . name ( "To undirected graph" ) ; return new Graph <> ( vertices , undirectedEdges , this . context ) ; }
This operation adds all inverse - direction edges to the graph .