1 package com.mapd.parser.extension.ddl.heavydb;
3 import org.apache.calcite.sql.SqlBasicTypeNameSpec;
4 import org.apache.calcite.sql.parser.SqlParserPos;
5 import org.apache.calcite.sql.type.SqlTypeName;
7 import org.apache.calcite.util.Pair;
21 Pair<HeavyDBEncoding, Integer> encodingInfo,
23 super(SqlTypeName.GEOMETRY, pos);
26 if (encodingInfo != null) {
27 this.encodingType = encodingInfo.left;
28 this.encodingSize = encodingInfo.right;
32 public Map<String, Object>
toJsonMap(Map<String, Object> map) {
35 jsonBuilder.put(map,
"sqltype",
"GEOGRAPHY");
37 jsonBuilder.put(map,
"sqltype",
"GEOMETRY");
41 jsonBuilder.put(map,
"encodingType", encodingType.name());
45 jsonBuilder.put(map,
"subtype", geoType.toString());
HeavyDBGeoTypeNameSpec(HeavyDBGeo geoType, Integer coordinateSystem, boolean isGeography, Pair< HeavyDBEncoding, Integer > encodingInfo, SqlParserPos pos)
Map< String, Object > toJsonMap(Map< String, Object > map)
HeavyDBEncoding encodingType