GEOS  3.13.0dev
EdgeEndBundle.h
1 /**********************************************************************
2  *
3  * GEOS - Geometry Engine Open Source
4  * http://geos.osgeo.org
5  *
6  * Copyright (C) 2006 Refractions Research Inc.
7  *
8  * This is free software; you can redistribute and/or modify it under
9  * the terms of the GNU Lesser General Public Licence as published
10  * by the Free Software Foundation.
11  * See the COPYING file for more information.
12  *
13  **********************************************************************
14  *
15  * Last port: operation/relate/EdgeEndBundle.java rev. 1.17 (JTS-1.10)
16  *
17  **********************************************************************/
18 
19 #pragma once
20 
21 #include <geos/export.h>
22 
23 #include <geos/geomgraph/EdgeEnd.h> // for EdgeEndBundle inheritance
24 
25 #include <string>
26 
27 // Forward declarations
28 namespace geos {
29 namespace algorithm {
30 class BoundaryNodeRule;
31 }
32 namespace geom {
33 class IntersectionMatrix;
34 }
35 }
36 
37 
38 namespace geos {
39 namespace operation { // geos::operation
40 namespace relate { // geos::operation::relate
41 
46 class GEOS_DLL EdgeEndBundle: public geomgraph::EdgeEnd {
47 public:
49  ~EdgeEndBundle() override;
50  const std::vector<geomgraph::EdgeEnd*>& getEdgeEnds();
51  void insert(geomgraph::EdgeEnd* e);
52 
53  void computeLabel(const algorithm::BoundaryNodeRule& bnr) override;
54 
61 
62  std::string print() const override;
63 protected:
64  std::vector<geomgraph::EdgeEnd*> edgeEnds;
65 
95  void computeLabelOn(uint8_t geomIndex,
96  const algorithm::BoundaryNodeRule& boundaryNodeRule);
97 
98  void computeLabelSides(uint8_t geomIndex);
99  void computeLabelSide(uint8_t geomIndex, uint32_t side);
100 };
101 
102 } // namespace geos:operation:relate
103 } // namespace geos:operation
104 } // namespace geos
An interface for rules which determine whether node points which are in boundaries of lineal geometry...
Definition: BoundaryNodeRule.h:50
Implementation of Dimensionally Extended Nine-Intersection Model (DE-9IM) matrix.
Definition: IntersectionMatrix.h:51
Models the end of an edge incident on a node.
Definition: EdgeEnd.h:54
A collection of geomgraph::EdgeEnd objects which originate at the same point and have the same direct...
Definition: EdgeEndBundle.h:46
void computeLabelOn(uint8_t geomIndex, const algorithm::BoundaryNodeRule &boundaryNodeRule)
void updateIM(geom::IntersectionMatrix &im)
Update the IM with the contribution for the computed label for the EdgeStubs.
Basic namespace for all GEOS functionalities.
Definition: Angle.h:25