GEOS  3.9.1dev
ShortCircuitedGeometryVisitor.h
Go to the documentation of this file.
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.
12  * See the COPYING file for more information.
13  *
14  **********************************************************************/
15 
16 #ifndef GEOS_GEOM_UTIL_SHORTCIRCUITEDGEOMETRYVISITOR_H
17 #define GEOS_GEOM_UTIL_SHORTCIRCUITEDGEOMETRYVISITOR_H
18 
19 #include <geos/export.h>
20 
21 // Forward declarations
22 namespace geos {
23 namespace geom {
24 class Geometry;
25 }
26 }
27 
28 
29 namespace geos {
30 namespace geom { // geos.geom
31 namespace util { // geos.geom.util
32 
40 
41 private:
42 
43  bool done;
44 
45 protected:
46 
47  virtual void visit(const Geometry& element) = 0;
48  virtual bool isDone() = 0;
49 
50 public:
51 
53  :
54  done(false)
55  {}
56 
57  void applyTo(const Geometry& geom);
58 
59  virtual
61 
62 };
63 
64 } // namespace geos.geom.util
65 } // namespace geos.geom
66 } // namespace geos
67 
68 #endif
#define GEOS_DLL
Definition: export.h:28
A visitor to Geometry elements which can be short-circuited by a given condition. ...
Basic implementation of Geometry, constructed and destructed by GeometryFactory.
Definition: Geometry.h:188
Basic namespace for all GEOS functionalities.