00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017 #ifndef GEOS_GEOM_PREP_PREPAREDLINESTRINGINTERSECTS_H
00018 #define GEOS_GEOM_PREP_PREPAREDLINESTRINGINTERSECTS_H
00019
00020 #include <geos/geom/prep/PreparedLineString.h>
00021 #include <geos/algorithm/PointLocator.h>
00022 #include <geos/geom/util/ComponentCoordinateExtracter.h>
00023 #include <geos/geom/Coordinate.h>
00024 #include <geos/noding/SegmentStringUtil.h>
00025
00026 using namespace geos::algorithm;
00027 using namespace geos::geom::util;
00028
00029 namespace geos {
00030 namespace geom {
00031 namespace prep {
00032
00043 class PreparedLineStringIntersects
00044 {
00045 private:
00046 protected:
00047 PreparedLineString & prepLine;
00048
00049
00058 bool isAnyTestPointInTarget(const geom::Geometry * testGeom) const;
00059
00060
00061
00062
00063
00064
00065
00066
00067
00068
00069
00070
00071
00072
00073
00074
00075
00076
00077
00078
00079 public:
00080
00089 static bool intersects( PreparedLineString & prep, const geom::Geometry * geom )
00090 {
00091 PreparedLineStringIntersects * op = new PreparedLineStringIntersects( prep);
00092 return op->intersects( geom);
00093 }
00094
00098 PreparedLineStringIntersects(PreparedLineString & prep)
00099 : prepLine( prep)
00100 { }
00101
00108 bool intersects(const geom::Geometry * g) const;
00109
00110 };
00111
00112
00113
00114 }
00115 }
00116 }
00117
00118 #endif // GEOS_GEOM_PREP_PREPAREDLINESTRINGINTERSECTS_H
00119
00120
00121
00122