@Description("Returns the inherent dimension of this Geometry object, which must be less than or equal to the coordinate dimension") @ScalarFunction("ST_Dimension") @SqlType(TINYINT) public static long stDimension(@SqlType(GEOMETRY_TYPE_NAME) Slice input) { return deserialize(input).dimension(); }
int dimension = geometry.dimension(); cursorsByDimension[dimension].tick(geometry.getEsriGeometry()); operatorsByDimension[dimension].tock();
@Override protected Object evaluateOGCGeometry(OGCGeometry geometry) throws HyracksDataException { return geometry.dimension(); }
@Override public int dimension() { int maxD = 0; for (int i = 0, n = numGeometries(); i < n; i++) maxD = Math.max(geometryN(i).dimension(), maxD); return maxD; }
@Override public int dimension() { int maxD = 0; for (int i = 0, n = numGeometries(); i < n; i++) maxD = Math.max(geometryN(i).dimension(), maxD); return maxD; }
@Description("Returns the inherent dimension of this Geometry object, which must be less than or equal to the coordinate dimension") @ScalarFunction("ST_Dimension") @SqlType(TINYINT) public static long stDimension(@SqlType(GEOMETRY_TYPE_NAME) Slice input) { return deserialize(input).dimension(); }
@Description("Returns the inherent dimension of this Geometry object, which must be less than or equal to the coordinate dimension") @ScalarFunction("ST_Dimension") @SqlType(TINYINT) public static long stDimension(@SqlType(GEOMETRY_TYPE_NAME) Slice input) { return deserialize(input).dimension(); }
public IntWritable evaluate(BytesWritable geomref) { if (geomref == null || geomref.getLength() == 0) { LogUtils.Log_ArgumentsNull(LOG); return null; } OGCGeometry ogcGeometry = GeometryUtils.geometryFromEsriShape(geomref); if (ogcGeometry == null) { LogUtils.Log_ArgumentsNull(LOG); return null; } resultInt.set(ogcGeometry.dimension()); return resultInt; }
/** * Checks if collection is flattened. * @return True for the flattened collection. A flattened collection contains up to three non-empty geometries: * an OGCMultiPoint, an OGCMultiPolygon, and an OGCMultiLineString. */ public boolean isFlattened() { int n = numGeometries(); if (n > 3) return false; int dimension = -1; for (int i = 0; i < n; ++i) { OGCGeometry g = geometryN(i); if (g.isEmpty()) return false;//no empty allowed String t = g.geometryType(); if (t != OGCMultiPoint.TYPE && t != OGCMultiPolygon.TYPE && t != OGCMultiLineString.TYPE) return false; //check strict order of geometry dimensions int d = g.dimension(); if (d <= dimension) return false; dimension = d; } return true; }
/** * Checks if collection is flattened. * @return True for the flattened collection. A flattened collection contains up to three non-empty geometries: * an OGCMultiPoint, an OGCMultiPolygon, and an OGCMultiLineString. */ public boolean isFlattened() { int n = numGeometries(); if (n > 3) return false; int dimension = -1; for (int i = 0; i < n; ++i) { OGCGeometry g = geometryN(i); if (g.isEmpty()) return false;//no empty allowed String t = g.geometryType(); if (t != OGCMultiPoint.TYPE && t != OGCMultiPolygon.TYPE && t != OGCMultiLineString.TYPE) return false; //check strict order of geometry dimensions int d = g.dimension(); if (d <= dimension) return false; dimension = d; } return true; }
int dimension = geometry.dimension(); cursorsByDimension[dimension].tick(geometry.getEsriGeometry()); operatorsByDimension[dimension].tock();
int dimension = geometry.dimension(); cursorsByDimension[dimension].tick(geometry.getEsriGeometry()); operatorsByDimension[dimension].tock();