SFCGAL 1.4.0
|
A PreparedGeometry is a shell around a SFCGAL::Geometry. More...
#include <PreparedGeometry.h>
Public Member Functions | |
PreparedGeometry () | |
Default constructor. More... | |
PreparedGeometry (std::unique_ptr< Geometry > &&geometry, srid_t srid=0) | |
Constructor. More... | |
PreparedGeometry (Geometry *geometry, srid_t srid=0) | |
Constructor. More... | |
virtual | ~PreparedGeometry () |
const Geometry & | geometry () const |
Geometry accessors. More... | |
Geometry & | geometry () |
void | resetGeometry (Geometry *geom) |
Geometry setter. More... | |
const srid_t & | SRID () const |
SRID read only accessor. More... | |
srid_t & | SRID () |
SRID accessor. More... | |
const Envelope & | envelope () const |
Envelope accessor (using cache) More... | |
void | invalidateCache () |
Resets the cache. More... | |
std::string | asEWKT (const int &numDecimals=- 1) const |
Convert to an extended WKT (with SRID) More... | |
template<class Archive > | |
void | save (Archive &ar, const unsigned int) const |
Serializer. More... | |
template<class Archive > | |
void | load (Archive &ar, const unsigned int) |
template<class Archive > | |
void | serialize (Archive &ar, const unsigned int version) |
Protected Attributes | |
std::unique_ptr< Geometry > | _geometry |
srid_t | _srid |
boost::optional< Envelope > | _envelope |
A PreparedGeometry is a shell around a SFCGAL::Geometry.
It is used to store annex data, like SRID or cached computations
It is noncopyable since it stores a std::unique_ptr<SFCGAL::Geometry>
SFCGAL::PreparedGeometry::PreparedGeometry | ( | ) |
Default constructor.
SFCGAL::PreparedGeometry::PreparedGeometry | ( | std::unique_ptr< Geometry > && | geometry, |
srid_t | srid = 0 |
||
) |
Constructor.
geometry | pointer to the underlying SFCGAL::Geometry. Takes ownership |
Constructor.
geometry | pointer to the underlying SFCGAL::Geometry. Takes ownership |
|
virtual |
std::string SFCGAL::PreparedGeometry::asEWKT | ( | const int & | numDecimals = - 1 | ) | const |
Convert to an extended WKT (with SRID)
numDecimals | number of decimals, -1 for keeping the exact rational representation, if possible |
Geometry & SFCGAL::PreparedGeometry::geometry | ( | ) |
void SFCGAL::PreparedGeometry::invalidateCache | ( | ) |
Resets the cache.
|
inline |
|
inline |
Serializer.
|
inline |
|
inline |
SRID accessor.
|
inline |
SRID read only accessor.
|
mutableprotected |
|
protected |
|
protected |