00001 /********************************************************************** 00002 * $Id: MCIndexPointSnapper.h 2556 2009-06-06 22:22:28Z strk $ 00003 * 00004 * GEOS - Geometry Engine Open Source 00005 * http://geos.refractions.net 00006 * 00007 * Copyright (C) 2006 Refractions Research Inc. 00008 * 00009 * This is free software; you can redistribute and/or modify it under 00010 * the terms of the GNU Lesser General Public Licence as published 00011 * by the Free Software Foundation. 00012 * See the COPYING file for more information. 00013 * 00014 ********************************************************************** 00015 * 00016 * Last port: noding/snapround/MCIndexPointSnapper.java rev. 1.4 (JTS-1.9) 00017 * 00018 **********************************************************************/ 00019 00020 #ifndef GEOS_NODING_SNAPROUND_MCINDEXPOINTSNAPPER_H 00021 #define GEOS_NODING_SNAPROUND_MCINDEXPOINTSNAPPER_H 00022 00023 #include <geos/export.h> 00024 00025 #include <geos/inline.h> 00026 00027 // Forward declarations 00028 namespace geos { 00029 namespace index { 00030 class SpatialIndex; 00031 } 00032 namespace noding { 00033 class SegmentString; 00034 namespace snapround { 00035 class HotPixel; 00036 } 00037 } 00038 } 00039 00040 namespace geos { 00041 namespace noding { // geos::noding 00042 namespace snapround { // geos::noding::snapround 00043 00049 class GEOS_DLL MCIndexPointSnapper { 00050 00051 private: 00052 00053 index::SpatialIndex& index; 00054 00055 public: 00056 00057 00058 MCIndexPointSnapper(index::SpatialIndex& nIndex) 00059 : 00060 index(nIndex) 00061 {} 00062 00063 00076 bool snap(HotPixel& hotPixel, SegmentString* parentEdge, 00077 unsigned int vertexIndex); 00078 00079 bool snap(HotPixel& hotPixel) { 00080 return snap(hotPixel, 0, 0); 00081 } 00082 00083 }; 00084 00085 00086 } // namespace geos::noding::snapround 00087 } // namespace geos::noding 00088 } // namespace geos 00089 00090 //#ifdef GEOS_INLINE 00091 //# include "geos/noding/snapround/MCIndexPointSnapper.inl" 00092 //#endif 00093 00094 #endif // GEOS_NODING_SNAPROUND_MCINDEXPOINTSNAPPER_H 00095 00096 /********************************************************************** 00097 * $Log$ 00098 * Revision 1.3 2006/03/24 09:52:41 strk 00099 * USE_INLINE => GEOS_INLINE 00100 * 00101 * Revision 1.2 2006/03/22 18:12:31 strk 00102 * indexChain.h header split. 00103 * 00104 * Revision 1.1 2006/03/14 12:55:56 strk 00105 * Headers split: geomgraphindex.h, nodingSnapround.h 00106 * 00107 **********************************************************************/ 00108
1.4.4