00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021 #ifndef GEOS_GEOMGRAPH_EDGENODINGVALIDATOR_H
00022 #define GEOS_GEOMGRAPH_EDGENODINGVALIDATOR_H
00023
00024 #include <geos/export.h>
00025 #include <vector>
00026
00027 #include <geos/noding/FastNodingValidator.h>
00028
00029 #include <geos/inline.h>
00030
00031 #ifdef _MSC_VER
00032 #pragma warning(push)
00033 #pragma warning(disable: 4251) // warning C4251: needs to have dll-interface to be used by clients of class
00034 #endif
00035
00036
00037 namespace geos {
00038 namespace geom {
00039 class CoordinateSequence;
00040 }
00041 namespace noding {
00042 class SegmentString;
00043 }
00044 namespace geomgraph {
00045 class Edge;
00046 }
00047 }
00048
00049 namespace geos {
00050 namespace geomgraph {
00051
00057 class GEOS_DLL EdgeNodingValidator {
00058
00059 private:
00060 std::vector<noding::SegmentString*>& toSegmentStrings(std::vector<Edge*>& edges);
00061
00062
00063
00064
00065
00066 std::vector<noding::SegmentString*> segStr;
00067
00068
00069
00070
00071
00072 std::vector<geom::CoordinateSequence*> newCoordSeq;
00073
00074 noding::FastNodingValidator nv;
00075
00076 public:
00077
00089 static void checkValid(std::vector<Edge*>& edges)
00090 {
00091 EdgeNodingValidator validator(edges);
00092 validator.checkValid();
00093 }
00094
00095 EdgeNodingValidator(std::vector<Edge*>& edges)
00096 :
00097 segStr(),
00098 newCoordSeq(),
00099 nv(toSegmentStrings(edges))
00100 {}
00101
00102 ~EdgeNodingValidator();
00103
00104 void checkValid() { nv.checkValid(); }
00105 };
00106
00107
00108 }
00109 }
00110
00111 #ifdef _MSC_VER
00112 #pragma warning(pop)
00113 #endif
00114
00115
00116
00117
00118
00119 #endif // ifndef GEOS_GEOMGRAPH_EDGENODINGVALIDATOR_H