GEOS
3.6.2
|
00001 /********************************************************************** 00002 * 00003 * GEOS - Geometry Engine Open Source 00004 * http://geos.osgeo.org 00005 * 00006 * Copyright (C) 2005-2006 Refractions Research Inc. 00007 * Copyright (C) 2001-2002 Vivid Solutions 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: geomgraph/index/MonotoneChain.java rev. 1.3 (JTS-1.7) 00017 * 00018 **********************************************************************/ 00019 00020 #ifndef GEOS_GEOMGRAPH_INDEX_MONOTONECHAIN_H 00021 #define GEOS_GEOMGRAPH_INDEX_MONOTONECHAIN_H 00022 00023 00024 #include <geos/export.h> 00025 #include <geos/geomgraph/index/SweepLineEventObj.h> // for inheritance 00026 #include <geos/geomgraph/index/MonotoneChainEdge.h> // for inline 00027 00028 // Forward declarations 00029 namespace geos { 00030 namespace geomgraph { 00031 namespace index { 00032 class SegmentIntersector; 00033 } 00034 } 00035 } 00036 00037 namespace geos { 00038 namespace geomgraph { // geos::geomgraph 00039 namespace index { // geos::geomgraph::index 00040 00044 class GEOS_DLL MonotoneChain: public SweepLineEventOBJ { 00045 private: 00046 MonotoneChainEdge *mce; 00047 int chainIndex; 00048 00049 public: 00050 00051 MonotoneChain(MonotoneChainEdge *newMce, int newChainIndex): 00052 mce(newMce), 00053 chainIndex(newChainIndex) 00054 {} 00055 00056 ~MonotoneChain() {} 00057 00058 void computeIntersections(MonotoneChain *mc,SegmentIntersector *si) { 00059 mce->computeIntersectsForChain(chainIndex,*(mc->mce),mc->chainIndex,*si); 00060 } 00061 }; 00062 00063 00064 00065 00066 } // namespace geos.geomgraph.index 00067 } // namespace geos.geomgraph 00068 } // namespace geos 00069 00070 #endif 00071