SimpleGeometryPrecisionReducer.h
/**********************************************************************
*
* GEOS - Geometry Engine Open Source
* http://geos.osgeo.org
*
* Copyright (C) 2005-2006 Refractions Research Inc.
*
* This is free software; you can redistribute and/or modify it under
* the terms of the GNU Lesser General Public Licence as published
* by the Free Software Foundation.
* See the COPYING file for more information.
*
**********************************************************************/
#pragma once
#include <geos/export.h>
#include <memory>
// Forward declarations
namespace geos {
namespace geom {
class PrecisionModel;
class Geometry;
}
}
namespace geos {
namespace precision { // geos.precision
class GEOS_DLL SimpleGeometryPrecisionReducer {
private:
const geom::PrecisionModel* newPrecisionModel;
bool removeCollapsed;
//bool changePrecisionModel;
public:
SimpleGeometryPrecisionReducer(const geom::PrecisionModel* pm);
void setRemoveCollapsedComponents(bool nRemoveCollapsed);
/*
* Sets whether the {@link PrecisionModel} of the new reduced Geometry
* will be changed to be the {@link PrecisionModel} supplied to
* specify the reduction. The default is to not change the
* precision model
*
* @param changePrecisionModel if <code>true</code> the precision
* model of the created Geometry will be the
* the precisionModel supplied in the constructor.
*/
//void setChangePrecisionModel(bool nChangePrecisionModel);
const geom::PrecisionModel* getPrecisionModel();
bool getRemoveCollapsed();
std::unique_ptr<geom::Geometry> reduce(const geom::Geometry* geom);
};
} // namespace geos.precision
} // namespace geos
geos::geom::Geometry
Basic implementation of Geometry, constructed and destructed by GeometryFactory.
Definition Geometry.h:196
geos::geom::PrecisionModel
Specifies the precision model of the Coordinate in a Geometry.
Definition PrecisionModel.h:87
geos::precision::SimpleGeometryPrecisionReducer::setRemoveCollapsedComponents
void setRemoveCollapsedComponents(bool nRemoveCollapsed)
geos::geom
Definition Angle.h:26
geos::precision
Provides classes for manipulating the precision model of Geometries.
Definition namespaces.h:300
geos
Basic namespace for all GEOS functionalities.
Definition geos.h:38