GEOS
3.3.1
|
00001 /********************************************************************** 00002 * $Id: MCIndexPointSnapper.h 3240 2011-02-23 14:37:39Z 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 r320 (JTS-1.12) 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 public: 00052 00053 00054 MCIndexPointSnapper(index::SpatialIndex& nIndex) 00055 : 00056 index(nIndex) 00057 {} 00058 00071 bool snap(HotPixel& hotPixel, SegmentString* parentEdge, 00072 unsigned int vertexIndex); 00073 00074 bool snap(HotPixel& hotPixel) { 00075 return snap(hotPixel, 0, 0); 00076 } 00077 00078 00079 private: 00080 00081 index::SpatialIndex& index; 00082 00083 // Declare type as noncopyable 00084 MCIndexPointSnapper(const MCIndexPointSnapper& other); 00085 MCIndexPointSnapper& operator=(const MCIndexPointSnapper& rhs); 00086 }; 00087 00088 00089 } // namespace geos::noding::snapround 00090 } // namespace geos::noding 00091 } // namespace geos 00092 00093 //#ifdef GEOS_INLINE 00094 //# include "geos/noding/snapround/MCIndexPointSnapper.inl" 00095 //#endif 00096 00097 #endif // GEOS_NODING_SNAPROUND_MCINDEXPOINTSNAPPER_H 00098 00099 /********************************************************************** 00100 * $Log$ 00101 * Revision 1.3 2006/03/24 09:52:41 strk 00102 * USE_INLINE => GEOS_INLINE 00103 * 00104 * Revision 1.2 2006/03/22 18:12:31 strk 00105 * indexChain.h header split. 00106 * 00107 * Revision 1.1 2006/03/14 12:55:56 strk 00108 * Headers split: geomgraphindex.h, nodingSnapround.h 00109 * 00110 **********************************************************************/ 00111