OmniSciDB  addbbd5075
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
GeoTargetValueSerializer< kPOINT > Struct Template Reference

#include <ResultSetGeoSerialization.h>

Static Public Member Functions

static TargetValue serialize (const SQLTypeInfo &geo_ti, std::array< VarlenDatumPtr, 1 > &vals)

Detailed Description

struct GeoTargetValueSerializer< kPOINT >

Definition at line 127 of file ResultSetGeoSerialization.h.

Member Function Documentation

static TargetValue GeoTargetValueSerializer< kPOINT >::serialize ( const SQLTypeInfo geo_ti,
std::array< VarlenDatumPtr, 1 > &  vals 

Definition at line 128 of file ResultSetGeoSerialization.h.

References anonymous_namespace{ResultSetGeoSerialization.h}::decompress_coords< double >().

129  {
130  // Removing errant NULL check: default ChunkIter accessor may mistake POINT coords
131  // fixlen array for a NULL, plus it is not needed currently - there is no NULL geo
132  // in existing tables, all NULL/empty geo is currently discarded on import.
133  // TODO: add custom ChunkIter accessor able to properly recognize NULL coords
134  // TODO: once NULL geo support is in, resurrect coords NULL check under !notnull
135  // if (!geo_ti.get_notnull() && vals[0]->is_null) {
136  // return GeoTargetValue();
137  // }
138  return GeoPointTargetValue(
139  *decompress_coords<double>(geo_ti, vals[0]->pointer, vals[0]->length));
140  }
std::shared_ptr< std::vector< double > > decompress_coords< double >(const SQLTypeInfo &geo_ti, const int8_t *coords, const size_t coords_sz)

+ Here is the call graph for this function:

The documentation for this struct was generated from the following file: