GEOS 3.16.0dev
PolygonRingTouch.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 * Copyright (C) 2021 Martin Davis
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.
12 * See the COPYING file for more information.
13 *
14 **********************************************************************/
15
16#pragma once
17
18#include <geos/export.h>
19#include <geos/geom/Coordinate.h>
20
21
22// Forward declarations
23namespace geos {
24namespace operation {
25namespace valid {
26class PolygonRing;
27}
28}
29}
30
31namespace geos { // geos.
32namespace operation { // geos.operation
33namespace valid { // geos.operation.valid
34
35class GEOS_DLL PolygonRingTouch {
36 using CoordinateXY = geos::geom::CoordinateXY;
37
38private:
39
40 PolygonRing* ring;
41 CoordinateXY touchPt;
42
43
44public:
45
46 PolygonRingTouch(PolygonRing* p_ring, const CoordinateXY& p_pt)
47 : ring(p_ring)
48 , touchPt(p_pt)
49 {};
50
51 const CoordinateXY* getCoordinate() const;
52
53 PolygonRing* getRing() const;
54
55 bool isAtLocation(const CoordinateXY& pt) const;
56
57};
58
59} // namespace geos.operation.valid
60} // namespace geos.operation
61} // namespace geos
62
Basic namespace for all GEOS functionalities.
Definition geos.h:38