GEOS 3.11.1
SegmentExtractingNoder.h
1/**********************************************************************
2 *
3 * GEOS - Geometry Engine Open Source
4 * http://geos.osgeo.org
5 *
6 * Copyright (C) 2021 Paul Ramsey <pramsey@cleverelephant.ca>
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#pragma once
16
17#include <geos/export.h>
18
19#include <geos/geom/Coordinate.h>
20#include <geos/geom/Envelope.h>
21#include <geos/noding/Noder.h>
22#include <geos/noding/snap/SnappingPointIndex.h>
23
24
25// Forward declarations
26namespace geos {
27namespace geom {
28class Envelope;
29class PrecisionModel;
30}
31namespace noding {
32class SegmentString;
33}
34}
35
36namespace geos {
37namespace noding { // geos::noding
38
52class GEOS_DLL SegmentExtractingNoder : public Noder {
53
54private:
55
56 std::vector<SegmentString*>* segList;
57
58 void extractSegments(
59 const std::vector<SegmentString*>& inputSegs,
60 std::vector<SegmentString*>& outputSegs);
61
62 void extractSegments(
63 const SegmentString* ss,
64 std::vector<SegmentString*>& outputSegs);
65
66
67public:
68
73 : segList(nullptr)
74 {};
75
76 void computeNodes(std::vector<SegmentString*>* segStrings) override;
77
82 std::vector<SegmentString*>* getNodedSubstrings() const override;
83
84
85};
86
87
88} // namespace geos::noding
89} // namespace geos
Computes all intersections between segments in a set of SegmentString.
Definition: Noder.h:46
Definition: SegmentExtractingNoder.h:52
void computeNodes(std::vector< SegmentString * > *segStrings) override
Computes the noding for a collection of SegmentStrings.
std::vector< SegmentString * > * getNodedSubstrings() const override
SegmentExtractingNoder()
Definition: SegmentExtractingNoder.h:72
An interface for classes which represent a sequence of contiguous line segments.
Definition: SegmentString.h:45
Basic namespace for all GEOS functionalities.
Definition: geos.h:39