OmniSciDB
a5dc49c757
|
#include <Types.h>
Public Types | |
enum | GeoType { GeoType::kPOINT, GeoType::kLINESTRING, GeoType::kPOLYGON, GeoType::kMULTIPOLYGON, GeoType::kGEOMETRY, GeoType::kGEOMETRYCOLLECTION, GeoType::kMULTILINESTRING, GeoType::kMULTIPOINT } |
enum | GeoOp { GeoOp::kPROJECTION = 0, GeoOp::kINTERSECTION = 1, GeoOp::kDIFFERENCE = 2, GeoOp::kUNION = 3, GeoOp::kBUFFER = 4, GeoOp::kISVALID = 5, GeoOp::kISEMPTY = 6, GeoOp::kEQUALS = 7, GeoOp::kCONCAVEHULL = 8, GeoOp::kCONVEXHULL = 9 } |
Public Member Functions | |
GeoBase () | |
virtual | ~GeoBase () |
std::string | getWktString () const |
bool | getWkb (std::vector< uint8_t > &) const |
virtual GeoType | getType () const =0 |
const OGRGeometry * | getOGRGeometry () const |
int32_t | getBestPlanarSRID () const |
bool | transform (int32_t srid0, int32_t srid1) |
bool | transform (SQLTypeInfo &ti) |
virtual bool | operator== (const GeoBase &other) const |
bool | isEmpty () const |
std::unique_ptr< GeoBase > | run (GeoOp op, const GeoBase &other) const |
std::unique_ptr< GeoBase > | optimized_run (GeoOp op, const GeoBase &other) const |
std::unique_ptr< GeoBase > | run (GeoOp op, double param) const |
bool | run (GeoOp op) const |
virtual std::unique_ptr< GeoBase > | clone () const =0 |
Static Public Member Functions | |
static std::shared_ptr < OGRCoordinateTransformation > | getTransformation (int32_t srid0, int32_t srid1) |
Protected Member Functions | |
GeoBase (OGRGeometry *geom, const bool owns_geom_obj) | |
Static Protected Member Functions | |
static int | createFromWktString (const std::string &wkt, OGRGeometry **geom) |
static int | createFromWkbView (OGRGeometry **geom, WkbView const) |
Protected Attributes | |
OGRGeometry * | geom_ = nullptr |
bool | owns_geom_obj_ |
Friends | |
class | GeoTypesFactory |
|
strong |
|
strong |
Enumerator | |
---|---|
kPOINT | |
kLINESTRING | |
kPOLYGON | |
kMULTIPOLYGON | |
kGEOMETRY | |
kGEOMETRYCOLLECTION | |
kMULTILINESTRING | |
kMULTIPOINT |
Definition at line 57 of file Types.h.
|
virtual |
|
inlineprotected |
|
pure virtual |
|
staticprotected |
Definition at line 174 of file Types.cpp.
References CHECK, Geospatial::WkbView::ptr_, and Geospatial::WkbView::size_.
Referenced by Geospatial::GeoTypesFactory::createGeoType(), and Geospatial::GeoTypesFactory::createOGRGeometry().
|
staticprotected |
Definition at line 155 of file Types.cpp.
Referenced by Geospatial::GeoTypesFactory::createOGRGeometry(), Geospatial::GeoGeometryCollection::GeoGeometryCollection(), Geospatial::GeoLineString::GeoLineString(), Geospatial::GeoMultiLineString::GeoMultiLineString(), Geospatial::GeoMultiPoint::GeoMultiPoint(), Geospatial::GeoMultiPolygon::GeoMultiPolygon(), Geospatial::GeoPoint::GeoPoint(), and Geospatial::GeoPolygon::GeoPolygon().
int32_t Geospatial::GeoBase::getBestPlanarSRID | ( | ) | const |
Definition at line 227 of file Types.cpp.
References geom_, SRID_LAEA_START, SRID_NORTH_LAMBERT, SRID_NORTH_UTM_START, SRID_SOUTH_LAMBERT, SRID_SOUTH_UTM_START, and SRID_WORLD_MERCATOR.
|
inline |
Definition at line 80 of file Types.h.
References geom_.
Referenced by import_export::anonymous_namespace{QueryExporterGDAL.cpp}::insert_geo_column().
|
static |
Definition at line 308 of file Types.cpp.
References Geospatial::GDAL::init(), SRID_LAEA_END, SRID_LAEA_START, SRID_NORTH_LAMBERT, SRID_NORTH_UTM_END, SRID_NORTH_UTM_START, SRID_SOUTH_LAMBERT, SRID_SOUTH_UTM_END, SRID_SOUTH_UTM_START, SRID_WORLD_MERCATOR, Geospatial::transformation_map_, and Geospatial::transformation_map_mutex_.
Referenced by transform().
|
pure virtual |
Implemented in Geospatial::GeoGeometryCollection, Geospatial::GeoGeometry, Geospatial::GeoMultiPolygon, Geospatial::GeoPolygon, Geospatial::GeoMultiLineString, Geospatial::GeoLineString, Geospatial::GeoMultiPoint, and Geospatial::GeoPoint.
Referenced by anonymous_namespace{RelAlgTranslatorGeo.cpp}::get_ti_from_geo(), and Analyzer::anonymous_namespace{Analyzer.cpp}::get_ti_from_geo().
bool Geospatial::GeoBase::getWkb | ( | std::vector< uint8_t > & | wkb | ) | const |
std::string Geospatial::GeoBase::getWktString | ( | ) | const |
Definition at line 165 of file Types.cpp.
Referenced by GeoWktSerializer< kPOINT >::serialize(), GeoWktSerializer< kMULTIPOINT >::serialize(), GeoWktSerializer< kLINESTRING >::serialize(), GeoWktSerializer< kMULTILINESTRING >::serialize(), GeoWktSerializer< kPOLYGON >::serialize(), GeoWktSerializer< kMULTIPOLYGON >::serialize(), ST_AsText__GeoLineString__cpu_(), ST_AsText__GeoMultiLineString__cpu_(), ST_AsText__GeoMultiPoint__cpu_(), ST_AsText__GeoMultiPolygon__cpu_(), ST_AsText__GeoPoint__cpu_(), and ST_AsText__GeoPolygon__cpu_().
bool Geospatial::GeoBase::isEmpty | ( | ) | const |
Definition at line 197 of file Types.cpp.
References geom_.
Referenced by Geospatial::GeoGeometry::GeoGeometry(), Geospatial::GeoGeometryCollection::GeoGeometryCollection(), and run().
|
virtual |
std::unique_ptr< GeoBase > Geospatial::GeoBase::optimized_run | ( | GeoBase::GeoOp | op, |
const GeoBase & | other | ||
) | const |
Definition at line 440 of file Types.cpp.
References Geospatial::GeoTypesFactory::createGeoType(), geom_, and run_benchmark_import::result.
std::unique_ptr< GeoBase > Geospatial::GeoBase::run | ( | GeoBase::GeoOp | op, |
const GeoBase & | other | ||
) | const |
Definition at line 407 of file Types.cpp.
References Geospatial::GeoTypesFactory::createGeoType(), geom_, kDIFFERENCE, kINTERSECTION, kUNION, and run_benchmark_import::result.
std::unique_ptr< GeoBase > Geospatial::GeoBase::run | ( | GeoBase::GeoOp | op, |
double | param | ||
) | const |
Definition at line 498 of file Types.cpp.
References Geospatial::GeoTypesFactory::createGeoType(), geom_, kBUFFER, and run_benchmark_import::result.
bool Geospatial::GeoBase::run | ( | GeoBase::GeoOp | op | ) | const |
bool Geospatial::GeoBase::transform | ( | int32_t | srid0, |
int32_t | srid1 | ||
) |
Definition at line 384 of file Types.cpp.
References geom_, and getTransformation().
Referenced by transform().
bool Geospatial::GeoBase::transform | ( | SQLTypeInfo & | ti | ) |
Definition at line 393 of file Types.cpp.
References SQLTypeInfo::get_input_srid(), SQLTypeInfo::get_output_srid(), and transform().
|
friend |
|
protected |
Definition at line 102 of file Types.h.
Referenced by Geospatial::GeoPoint::clone(), Geospatial::GeoMultiPoint::clone(), Geospatial::GeoLineString::clone(), Geospatial::GeoMultiLineString::clone(), Geospatial::GeoPolygon::clone(), Geospatial::GeoMultiPolygon::clone(), Geospatial::GeoGeometry::clone(), Geospatial::GeoGeometryCollection::clone(), Geospatial::GeoGeometryCollection::GeoGeometryCollection(), Geospatial::GeoLineString::GeoLineString(), Geospatial::GeoMultiLineString::GeoMultiLineString(), Geospatial::GeoMultiPoint::GeoMultiPoint(), Geospatial::GeoMultiPolygon::GeoMultiPolygon(), Geospatial::GeoPoint::GeoPoint(), Geospatial::GeoPolygon::GeoPolygon(), getBestPlanarSRID(), Geospatial::GeoPoint::getColumns(), Geospatial::GeoMultiPoint::getColumns(), Geospatial::GeoLineString::getColumns(), Geospatial::GeoMultiLineString::getColumns(), Geospatial::GeoPolygon::getColumns(), Geospatial::GeoMultiPolygon::getColumns(), Geospatial::GeoPolygon::getNumInteriorRings(), getOGRGeometry(), getWkb(), getWktString(), isEmpty(), operator==(), optimized_run(), run(), transform(), and ~GeoBase().
|
protected |
Definition at line 103 of file Types.h.
Referenced by ~GeoBase().