OmniSciDB  340b00dbf6
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
com.mapd.parser.extension.ddl.omnisci.OmniSciGeoTypeNameSpec Class Reference
+ Inheritance diagram for com.mapd.parser.extension.ddl.omnisci.OmniSciGeoTypeNameSpec:
+ Collaboration diagram for com.mapd.parser.extension.ddl.omnisci.OmniSciGeoTypeNameSpec:

Public Member Functions

 OmniSciGeoTypeNameSpec (OmniSciGeo geoType, Integer coordinateSystem, boolean isGeography, Pair< OmniSciEncoding, Integer > encodingInfo, SqlParserPos pos)
 
Map< String, Object > toJsonMap (Map< String, Object > map)
 

Private Attributes

OmniSciEncoding encodingType
 
Integer encodingSize
 
OmniSciGeo geoType
 
boolean isGeography
 
Integer coordinateSystem
 

Detailed Description

Definition at line 11 of file OmniSciGeoTypeNameSpec.java.

Constructor & Destructor Documentation

com.mapd.parser.extension.ddl.omnisci.OmniSciGeoTypeNameSpec.OmniSciGeoTypeNameSpec ( OmniSciGeo  geoType,
Integer  coordinateSystem,
boolean  isGeography,
Pair< OmniSciEncoding, Integer >  encodingInfo,
SqlParserPos  pos 
)
inline

Definition at line 18 of file OmniSciGeoTypeNameSpec.java.

References com.mapd.parser.extension.ddl.omnisci.OmniSciGeoTypeNameSpec.coordinateSystem, and com.mapd.parser.extension.ddl.omnisci.OmniSciGeoTypeNameSpec.geoType.

22  {
23  super(SqlTypeName.GEOMETRY, pos);
24  this.geoType = geoType;
25  this.coordinateSystem = coordinateSystem;
26  if (encodingInfo != null) {
27  this.encodingType = encodingInfo.left;
28  this.encodingSize = encodingInfo.right;
29  }
30  }

Member Function Documentation

Map<String, Object> com.mapd.parser.extension.ddl.omnisci.OmniSciGeoTypeNameSpec.toJsonMap ( Map< String, Object >  map)
inline

Definition at line 32 of file OmniSciGeoTypeNameSpec.java.

References com.mapd.parser.extension.ddl.omnisci.OmniSciGeoTypeNameSpec.coordinateSystem, com.mapd.parser.extension.ddl.omnisci.OmniSciGeoTypeNameSpec.encodingSize, com.mapd.parser.extension.ddl.omnisci.OmniSciGeoTypeNameSpec.encodingType, and com.mapd.parser.extension.ddl.omnisci.OmniSciGeoTypeNameSpec.isGeography.

32  {
33  EscapedStringJsonBuilder jsonBuilder = new EscapedStringJsonBuilder();
34  if (isGeography) {
35  jsonBuilder.put(map, "sqltype", "GEOGRAPHY");
36  } else {
37  jsonBuilder.put(map, "sqltype", "GEOMETRY");
38  }
39 
40  if (encodingType != null) {
41  jsonBuilder.put(map, "encodingType", encodingType.name());
42  jsonBuilder.put(map, "encodingSize", encodingSize);
43  }
44 
45  jsonBuilder.put(map, "subtype", geoType.toString());
46  jsonBuilder.put(map, "coordinateSystem", coordinateSystem);
47 
48  return map;
49  }

Member Data Documentation

Integer com.mapd.parser.extension.ddl.omnisci.OmniSciGeoTypeNameSpec.coordinateSystem
private
Integer com.mapd.parser.extension.ddl.omnisci.OmniSciGeoTypeNameSpec.encodingSize
private
OmniSciEncoding com.mapd.parser.extension.ddl.omnisci.OmniSciGeoTypeNameSpec.encodingType
private
OmniSciGeo com.mapd.parser.extension.ddl.omnisci.OmniSciGeoTypeNameSpec.geoType
private
boolean com.mapd.parser.extension.ddl.omnisci.OmniSciGeoTypeNameSpec.isGeography
private

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