Fix warnings on MSVC 2008 64 Bit (#470)
[geos.git] / src / simplify / TaggedLineSegment.cpp
blob8ad7b8c6f1a3bb440fbb552b12bc86f74848b193
1 /**********************************************************************
2 * $Id$
4 * GEOS - Geometry Engine Open Source
5 * http://geos.refractions.net
7 * Copyright (C) 2006 Refractions Research Inc.
9 * This is free software; you can redistribute and/or modify it under
10 * the terms of the GNU Lesser General Licence as published
11 * by the Free Software Foundation.
12 * See the COPYING file for more information.
14 **********************************************************************
16 * Last port: simplify/TaggedLineSegment.java rev. 1.1 (JTS-1.7.1)
18 **********************************************************************/
20 #include <geos/simplify/TaggedLineSegment.h>
22 #include <cassert>
24 #ifndef GEOS_DEBUG
25 #define GEOS_DEBUG 0
26 #endif
28 #ifdef GEOS_DEBUG
29 #include <iostream>
30 #endif
32 namespace geos {
33 namespace simplify { // geos::simplify
35 TaggedLineSegment::TaggedLineSegment(const geom::Coordinate& p0,
36 const geom::Coordinate& p1,
37 const geom::Geometry* nParent,
38 unsigned int nIndex)
40 LineSegment(p0, p1),
41 parent(nParent),
42 index(nIndex)
46 TaggedLineSegment::TaggedLineSegment(const geom::Coordinate& p0,
47 const geom::Coordinate& p1)
49 LineSegment(p0, p1),
50 parent(NULL),
51 index(0)
55 TaggedLineSegment::TaggedLineSegment(const TaggedLineSegment& ls)
57 LineSegment(ls),
58 parent(ls.parent),
59 index(ls.index)
63 const geom::Geometry*
64 TaggedLineSegment::getParent() const
66 return parent;
69 unsigned int
70 TaggedLineSegment::getIndex() const
72 return index;
75 } // namespace geos::simplify
76 } // namespace geos
78 /**********************************************************************
79 * $Log$
80 * Revision 1.2 2006/04/12 17:19:57 strk
81 * Ported TaggedLineStringSimplifier class, made LineSegment class
82 * polymorphic to fix derivation of TaggedLineSegment
84 * Revision 1.1 2006/04/12 14:22:12 strk
85 * Initial implementation of TaggedLineSegment and TaggedLineString classes
87 **********************************************************************/