GEOS 3.6.2
InteriorPointLine.h
1/**********************************************************************
2 *
3 * GEOS - Geometry Engine Open Source
4 * http://geos.osgeo.org
5 *
6 * Copyright (C) 2005-2006 Refractions Research Inc.
7 * Copyright (C) 2001-2002 Vivid Solutions 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.
12 * See the COPYING file for more information.
13 *
14 **********************************************************************
15 *
16 * Last port: algorithm/InteriorPointLine.java r317 (JTS-1.12)
17 *
18 **********************************************************************/
19
20#ifndef GEOS_ALGORITHM_INTERIORPOINTLINE_H
21#define GEOS_ALGORITHM_INTERIORPOINTLINE_H
22
23#include <geos/export.h>
24#include <geos/geom/Coordinate.h>
25
26// Forward declarations
27namespace geos {
28 namespace geom {
29 class Geometry;
31 }
32}
33
34
35namespace geos {
36namespace algorithm { // geos::algorithm
37
48class GEOS_DLL InteriorPointLine {
49public:
50
51 InteriorPointLine(const geom::Geometry *g);
52
53 ~InteriorPointLine();
54
55 //Coordinate* getInteriorPoint() const;
56
57 bool getInteriorPoint(geom::Coordinate& ret) const;
58
59private:
60
61 bool hasInterior;
62
63 geom::Coordinate centroid;
64
65 double minDistance;
66
67 geom::Coordinate interiorPoint;
68
69 void addInterior(const geom::Geometry *geom);
70
71 void addInterior(const geom::CoordinateSequence *pts);
72
73 void addEndpoints(const geom::Geometry *geom);
74
75 void addEndpoints(const geom::CoordinateSequence *pts);
76
77 void add(const geom::Coordinate& point);
78
79};
80
81} // namespace geos::algorithm
82} // namespace geos
83
84#endif // GEOS_ALGORITHM_INTERIORPOINTLINE_H
85
The internal representation of a list of coordinates inside a Geometry.
Definition CoordinateSequence.h:59
Coordinate is the lightweight class used to store coordinates.
Definition Coordinate.h:60
Basic implementation of Geometry, constructed and destructed by GeometryFactory.
Definition Geometry.h:167
Contains classes and interfaces implementing fundamental computational geometry algorithms.
Definition Angle.h:33
Contains the Geometry interface hierarchy and supporting classes.
Definition IndexedNestedRingTester.h:26
Basic namespace for all GEOS functionalities.
Definition IndexedNestedRingTester.h:25