16#ifndef GEOS_PLANARGRAPH_NODE_H
17#define GEOS_PLANARGRAPH_NODE_H
19#include <geos/export.h>
21#include <geos/planargraph/GraphComponent.h>
22#include <geos/planargraph/DirectedEdgeStar.h>
23#include <geos/geom/Coordinate.h>
45class GEOS_DLL
Node:
public GraphComponent {
56 friend std::ostream& operator << (std::ostream& os,
const Node&);
115 return deStar->getDegree();
124 return deStar->getIndex(edge);
Coordinate is the lightweight class used to store coordinates.
Definition Coordinate.h:60
A sorted collection of DirectedEdge which leave a Node in a PlanarGraph.
Definition planargraph/DirectedEdgeStar.h:43
Represents a directed edge in a PlanarGraph.
Definition planargraph/DirectedEdge.h:46
Represents an undirected edge of a PlanarGraph.
Definition planargraph/Edge.h:54
A node in a PlanarGraph is a location where 0 or more Edge meet.
Definition planargraph/Node.h:45
static std::vector< Edge * > * getEdgesBetween(Node *node0, Node *node1)
Returns all Edges that connect the two nodes (which are assumed to be different).
geom::Coordinate & getCoordinate()
Returns the location of this Node.
Definition planargraph/Node.h:93
Node(geom::Coordinate &newPt, DirectedEdgeStar *newDeStar)
Constructs a Node with the given location and collection of outgoing DirectedEdges....
Definition planargraph/Node.h:84
size_t getDegree() const
Returns the number of edges around this Node.
Definition planargraph/Node.h:114
DirectedEdgeStar * getOutEdges()
Returns the collection of DirectedEdges that leave this Node.
Definition planargraph/Node.h:108
void addOutEdge(DirectedEdge *de)
Adds an outgoing DirectedEdge to this Node.
Definition planargraph/Node.h:100
DirectedEdgeStar * deStar
The collection of DirectedEdges that leave this Node.
Definition planargraph/Node.h:52
geom::Coordinate pt
The location of this Node.
Definition planargraph/Node.h:49
int getIndex(Edge *edge)
Returns the zero-based index of the given Edge, after sorting in ascending order by angle with the po...
Definition planargraph/Node.h:123
Node(const geom::Coordinate &newPt)
Constructs a Node with the given location.
Definition planargraph/Node.h:69
Contains classes to implement a planar graph data structure.
Definition LineMergeDirectedEdge.h:32
std::ostream & operator<<(std::ostream &, const DirectedEdge &)
Output operator.
Basic namespace for all GEOS functionalities.
Definition IndexedNestedRingTester.h:25