GEOS  3.13.0dev
Public Member Functions | List of all members
geos::operation::linemerge::LineMergeGraph Class Reference

A planar graph of edges that is analyzed to sew the edges together. More...

#include <LineMergeGraph.h>

Inheritance diagram for geos::operation::linemerge::LineMergeGraph:
geos::planargraph::PlanarGraph

Public Member Functions

void addEdge (const geom::LineString *lineString)
 Adds an Edge, DirectedEdges, and Nodes for the given LineString representation of an edge. More...
 
- Public Member Functions inherited from geos::planargraph::PlanarGraph
 PlanarGraph ()
 Constructs a PlanarGraph without any Edges, DirectedEdges, or Nodes.
 
NodefindNode (const geom::Coordinate &pt)
 Returns the Node at the given location, or null if no Node was there.
 
NodeMap::container::iterator nodeIterator ()
 Returns an Iterator over the Nodes in this PlanarGraph.
 
NodeMap::container::iterator nodeBegin ()
 
NodeMap::container::const_iterator nodeBegin () const
 
NodeMap::container::iterator nodeEnd ()
 
NodeMap::container::const_iterator nodeEnd () const
 
void getNodes (std::vector< Node * > &nodes)
 Returns the Nodes in this PlanarGraph. More...
 
std::vector< DirectedEdge * >::iterator dirEdgeIterator ()
 Returns an Iterator over the DirectedEdges in this PlanarGraph, in the order in which they were added. More...
 
std::vector< DirectedEdge * >::iterator dirEdgeBegin ()
 
std::vector< DirectedEdge * >::iterator dirEdgeEnd ()
 
std::vector< Edge * >::iterator edgeIterator ()
 Alias for edgeBegin()
 
std::vector< Edge * >::iterator edgeBegin ()
 Returns an iterator to first Edge in this graph. More...
 
std::vector< Edge * >::iterator edgeEnd ()
 Returns an iterator to one-past last Edge in this graph. More...
 
std::vector< Edge * > * getEdges ()
 
void remove (Edge *edge)
 Removes an Edge and its associated DirectedEdges from their from-Nodes and from this PlanarGraph. More...
 
void remove (DirectedEdge *de)
 Removes DirectedEdge from its from-Node and from this PlanarGraph. More...
 
void remove (Node *node)
 Removes a node from the graph, along with any associated DirectedEdges and Edges.
 
std::vector< Node * > * findNodesOfDegree (std::size_t degree)
 Returns all Nodes with the given number of Edges around it. The return value is a newly allocated vector of existing nodes.
 
void findNodesOfDegree (std::size_t degree, std::vector< Node * > &to)
 Get all Nodes with the given number of Edges around it. More...
 

Additional Inherited Members

- Public Types inherited from geos::planargraph::PlanarGraph
typedef std::vector< Edge * > EdgeContainer
 
typedef EdgeContainer::iterator EdgeIterator
 
- Protected Member Functions inherited from geos::planargraph::PlanarGraph
void add (Node *node)
 Adds a node to the std::map, replacing any that is already at that location. More...
 
void add (Edge *edge)
 Adds the Edge and its DirectedEdges with this PlanarGraph. More...
 
void add (DirectedEdge *dirEdge)
 Adds the Edge to this PlanarGraph. More...
 
- Protected Attributes inherited from geos::planargraph::PlanarGraph
std::vector< Edge * > edges
 
std::vector< DirectedEdge * > dirEdges
 
NodeMap nodeMap
 

Detailed Description

A planar graph of edges that is analyzed to sew the edges together.

The marked flag on planargraph::Edge and planargraph::Node indicates whether they have been logically deleted from the graph.

Member Function Documentation

◆ addEdge()

void geos::operation::linemerge::LineMergeGraph::addEdge ( const geom::LineString lineString)

Adds an Edge, DirectedEdges, and Nodes for the given LineString representation of an edge.

Empty lines or lines with all coordinates equal are not added.

Parameters
lineStringthe linestring to add to the graph

The documentation for this class was generated from the following file: