GEOS  3.9.0dev
PointExtracter.h
1 /**********************************************************************
2  *
3  * GEOS - Geometry Engine Open Source
4  * http://geos.osgeo.org
5  *
6  * Copyright (C) 2001-2002 Vivid Solutions Inc.
7  * Copyright (C) 2006 Refractions Research Inc.
8  *
9  * This is free software; you can redistribute and/or modify it under
10  * the terms of the GNU Lesser General Public Licence as published
11  * by the Free Software Foundation.
13  *
14  **********************************************************************/
15
16 #ifndef GEOS_GEOM_UTIL_POINTEXTRACTER_H
17 #define GEOS_GEOM_UTIL_POINTEXTRACTER_H
18
19 #include <geos/export.h>
20 #include <geos/geom/GeometryFilter.h>
21 #include <geos/geom/Point.h>
22 #include <vector>
23
24 namespace geos {
25 namespace geom { // geos.geom
26 namespace util { // geos.geom.util
27
31 class GEOS_DLL PointExtracter: public GeometryFilter {
32
33 public:
40  static void getPoints(const Geometry& geom, Point::ConstVect& ret);
41
47
48  void filter_rw(Geometry* geom) override;
49
50  void filter_ro(const Geometry* geom) override;
51
52 private:
53
54  Point::ConstVect& comps;
55
56  // Declare type as noncopyable
57  PointExtracter(const PointExtracter& other) = delete;
58  PointExtracter& operator=(const PointExtracter& rhs) = delete;
59 };
60
61 } // namespace geos.geom.util
62 } // namespace geos.geom
63 } // namespace geos
64
65 #endif
Geometry classes support the concept of applying a Geometry filter to the Geometry.
Definition: GeometryFilter.h:47
std::vector< const Point * > ConstVect
A vector of const Point pointers.
Definition: Point.h:73
Basic implementation of Geometry, constructed and destructed by GeometryFactory.
Definition: Geometry.h:188
Basic namespace for all GEOS functionalities.
Definition: IndexedNestedRingTester.h:26
Definition: PointExtracter.h:31