26#ifndef __TERRALIB_GEOMETRY_INTERNAL_GEOMETRY_H
27#define __TERRALIB_GEOMETRY_INTERNAL_GEOMETRY_H
30#include "../common/BaseVisitable.h"
31#include "../common/Enums.h"
32#include "../datatype/AbstractData.h"
33#include "../NoExceptDefinition.h"
171 virtual const std::
string& getGeometryType() const
_NOEXCEPT_OP(true)= 0;
381 void getWkb(
char* wkb,
te::common::MachineByteOrder byteOrder) const
_NOEXCEPT_OP(false);
695 virtual
Geometry* locateAlong(const
double& mValue) const
_NOEXCEPT_OP(false) {
return locateBetween(mValue, mValue); }
789 int quadrantSegments,
905 static
GeomType getGeomTypeId(const std::
string& gtype);
916 static std::
string getGeomTypeString(const
int& gId);
925 static
bool isGeomType(const std::
string& stype);
932 static
void loadGeomTypeId();
946 int getTypeCode() const;
953 std::
string toString()
const {
return asText(); }
#define TE_DEFINE_VISITABLE
The root of all hierarchies that can be visited.
A base class for values that can be retrieved from the data access module.
An Envelope defines a 2D rectangular region.
GeometryPtr(te::gm::Geometry *geometry=nullptr)
GeometryPtr(GeometryPtr &&rhs)
GeometrySharedPtr(te::gm::Geometry *geometry=nullptr)
Geometry is the root class of the geometries hierarchy, it follows OGC and ISO standards.
virtual Geometry * buffer(const double &distance) const _NOEXCEPT_OP(false)
This method calculates the buffer of a geometry.
virtual double distance(const Geometry *const rhs) const _NOEXCEPT_OP(false)
It returns the shortest distance between any two points in the two geometry objects.
virtual Geometry * buffer(const double &distance, int quadrantSegments, BufferCapStyle endCapStyle) const _NOEXCEPT_OP(false)
This method calculates the buffer of a geometry.
static std::map< std::string, GeomType > sm_geomTypeMap
A set of geometry type names (in UPPER CASE).
virtual Geometry * convexHull() const _NOEXCEPT_OP(false)
This method calculates the Convex Hull of a geometry.
virtual Geometry * locateBetween(const double &mStart, const double &mEnd) const _NOEXCEPT_OP(false)
It returns a derived geometry collection value according to the range of coordinate values inclusivel...
virtual void setSRID(int srid) _NOEXCEPT_OP(true)=0
It sets the Spatial Reference System ID of the geometry and all its parts if it is a GeometryCollecti...
virtual const std::string get2DGeometryType() const _NOEXCEPT_OP(true)
It returns the name of 2D geometry subclass.
virtual Geometry * buffer(const double &distance, int quadrantSegments) const _NOEXCEPT_OP(false)
This method calculates the buffer of a geometry.
Geometry * getEnvelope() const _NOEXCEPT_OP(true)
It returns the minimum bounding rectangle (MBR) for the geometry.
Geometry(GeomType t, int srid=0, Envelope *mbr=0) _NOEXCEPT_OP(true)
It initializes the Geometry with the specified spatial reference system id and envelope.
int m_srid
The Spatial Reference System code associated to the Geometry.
virtual void transform(const int &srid) _NOEXCEPT_OP(false)
It converts the coordinate values of the geometry to the new spatial reference system.
GeomType m_gType
Internal geometry type.
virtual void convert(te::srs::Converter *converter) _NOEXCEPT_OP(false)=0
It converts the coordinate values of the geometry to the new spatial reference system.
Envelope * m_mbr
The geometry minimum bounding rectangle.
A Converter is responsible for the conversion of coordinates between different Coordinate Systems (CS...
GeomType
Each enumerated type is compatible with a Well-known Binary (WKB) type code.
Dimensionality
From Wikipedia: "in mathematics, the dimension of an object is an intrinsic property,...
BufferCapStyle
Buffer end cap style.
A visitor interface for the SymbologyEncoding hierarchy.
An utility struct for representing 2D coordinates.
#define TEGEOMEXPORT
You can use this macro in order to export/import classes and functions from this module.
Enumerations of XML module.