GEOS 3.10.1
MonotoneChainOverlapAction.h
1/**********************************************************************
2 *
3 * GEOS - Geometry Engine Open Source
4 * http://geos.osgeo.org
5 *
6 * Copyright (C) 2001-2002 Vivid Solutions Inc.
7 *
8 * This is free software; you can redistribute and/or modify it under
9 * the terms of the GNU Lesser General Public Licence as published
10 * by the Free Software Foundation.
11 * See the COPYING file for more information.
12 *
13 **********************************************************************
14 *
15 * Last port: index/chain/MonotoneChainOverlapAction.java rev. 1.6 (JTS-1.10)
16 *
17 **********************************************************************/
18
19#ifndef GEOS_IDX_CHAIN_MONOTONECHAINOVERLAPACTION_H
20#define GEOS_IDX_CHAIN_MONOTONECHAINOVERLAPACTION_H
21
22#include <geos/export.h>
23#include <geos/geom/LineSegment.h>
24
25
26// Forward declarations
27namespace geos {
28namespace index {
29namespace chain {
30class MonotoneChain;
31}
32}
33}
34
35namespace geos {
36namespace index { // geos::index
37namespace chain { // geos::index::chain
38
44
45protected:
46
47 geom::LineSegment overlapSeg1;
48
49 geom::LineSegment overlapSeg2;
50
51public:
52
54
55 virtual
57
68 virtual void overlap(const MonotoneChain& mc1, std::size_t start1,
69 const MonotoneChain& mc2, std::size_t start2);
70
78 virtual void
79 overlap(const geom::LineSegment& /*seg1*/,
80 const geom::LineSegment& /*seg2*/) {}
81
82};
83
84} // namespace geos::index::chain
85} // namespace geos::index
86} // namespace geos
87
88#endif // GEOS_IDX_CHAIN_MONOTONECHAINOVERLAPACTION_H
89
Definition: LineSegment.h:59
The action for the internal iterator for performing overlap queries on a MonotoneChain.
Definition: MonotoneChainOverlapAction.h:43
virtual void overlap(const MonotoneChain &mc1, std::size_t start1, const MonotoneChain &mc2, std::size_t start2)
This function can be overridden if the original chains are needed.
virtual void overlap(const geom::LineSegment &, const geom::LineSegment &)
This is a convenience function which can be overridden to obtain the actual line segments which overl...
Definition: MonotoneChainOverlapAction.h:79
Monotone Chains are a way of partitioning the segments of a linestring to allow for fast searching of...
Definition: index/chain/MonotoneChain.h:86
Basic namespace for all GEOS functionalities.
Definition: geos.h:40