OmniSciDB  72c90bc290
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
SQLTypeInfoLite Struct Reference

#include <sqltypes_lite.h>

Public Types

enum  SQLTypes {
  UNSPECIFIED = 0, BOOLEAN, TINYINT, SMALLINT,
  INT, BIGINT, FLOAT, DOUBLE,
  POINT, LINESTRING, POLYGON, MULTIPOINT,
  MULTILINESTRING, MULTIPOLYGON, TEXT, ARRAY
}
 
enum  EncodingType { NONE = 0, DICT, GEOINT }
 

Public Member Functions

bool is_geoint () const
 
int32_t get_input_srid () const
 
int32_t get_output_srid () const
 
bool operator== (const SQLTypeInfoLite &other) const
 

Public Attributes

SQLTypes type
 
SQLTypes subtype
 
EncodingType compression
 
int32_t dimension
 
int32_t scale
 
int32_t db_id
 
int32_t dict_id
 

Detailed Description

Definition at line 29 of file sqltypes_lite.h.

Member Enumeration Documentation

Enumerator
NONE 
DICT 
GEOINT 

Definition at line 48 of file sqltypes_lite.h.

48  {
49  NONE = 0,
50  DICT, // used by TEXT and ARRAY of TEXT
51  GEOINT // used by geotypes
52  };

Member Function Documentation

int32_t SQLTypeInfoLite::get_input_srid ( ) const
inline

Definition at line 62 of file sqltypes_lite.h.

References dimension.

Referenced by operator==().

62 { return dimension; }

+ Here is the caller graph for this function:

int32_t SQLTypeInfoLite::get_output_srid ( ) const
inline

Definition at line 63 of file sqltypes_lite.h.

References scale.

Referenced by operator==().

63 { return scale; }

+ Here is the caller graph for this function:

bool SQLTypeInfoLite::is_geoint ( ) const
inline

Definition at line 61 of file sqltypes_lite.h.

References compression, and GEOINT.

Referenced by NestedArrayToGeoTargetValue(), and writeBackCellGeoNestedArray().

61 { return compression == GEOINT; }
EncodingType compression
Definition: sqltypes_lite.h:55

+ Here is the caller graph for this function:

bool SQLTypeInfoLite::operator== ( const SQLTypeInfoLite other) const
inline

Definition at line 65 of file sqltypes_lite.h.

References ARRAY, compression, db_id, DICT, dict_id, get_input_srid(), get_output_srid(), LINESTRING, MULTILINESTRING, MULTIPOINT, MULTIPOLYGON, POINT, POLYGON, subtype, TEXT, and type.

65  {
66  if (type != other.type)
67  return false;
68  if (type == ARRAY) {
69  if (subtype != other.subtype)
70  return false;
71  if (subtype == TEXT) {
72  if (compression != other.compression)
73  return false;
74  if (compression == DICT)
75  return db_id == other.db_id && dict_id == other.dict_id;
76  }
77  } else if (type == TEXT) {
78  if (compression != other.compression)
79  return false;
80  if (compression == DICT)
81  return db_id == other.db_id && dict_id == other.dict_id;
82  } else if (type == POINT || type == LINESTRING || type == POLYGON ||
84  if (compression != other.compression)
85  return false;
86  return get_input_srid() == other.get_input_srid() &&
87  get_output_srid() == other.get_output_srid();
88  }
89  return true;
90  }
SQLTypes subtype
Definition: sqltypes_lite.h:54
int32_t get_output_srid() const
Definition: sqltypes_lite.h:63
EncodingType compression
Definition: sqltypes_lite.h:55
int32_t get_input_srid() const
Definition: sqltypes_lite.h:62

+ Here is the call graph for this function:

Member Data Documentation

EncodingType SQLTypeInfoLite::compression

Definition at line 55 of file sqltypes_lite.h.

Referenced by is_geoint(), operator<<(), operator==(), and SQLTypeInfo::toLite().

int32_t SQLTypeInfoLite::db_id

Definition at line 58 of file sqltypes_lite.h.

Referenced by operator<<(), operator==(), and SQLTypeInfo::toLite().

int32_t SQLTypeInfoLite::dict_id

Definition at line 59 of file sqltypes_lite.h.

Referenced by operator<<(), operator==(), and SQLTypeInfo::toLite().

int32_t SQLTypeInfoLite::dimension

Definition at line 56 of file sqltypes_lite.h.

Referenced by get_input_srid(), operator<<(), and SQLTypeInfo::toLite().

int32_t SQLTypeInfoLite::scale

Definition at line 57 of file sqltypes_lite.h.

Referenced by get_output_srid(), operator<<(), and SQLTypeInfo::toLite().

SQLTypes SQLTypeInfoLite::subtype
SQLTypes SQLTypeInfoLite::type

Definition at line 53 of file sqltypes_lite.h.

Referenced by operator<<(), operator==(), and SQLTypeInfo::toLite().


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