public class SpatialCommonIndexedBinningStrategy extends SpatialBinningStrategy<CommonIndexedPersistenceEncoding>
SpatialBinningStrategycomplexGeometryBinning, geometryFieldName, precision, type| Constructor and Description |
|---|
SpatialCommonIndexedBinningStrategy()
Create a binning strategy using a small number of bins.
|
SpatialCommonIndexedBinningStrategy(SpatialBinningType type,
int precision,
boolean useCentroidOnly) |
SpatialCommonIndexedBinningStrategy(SpatialBinningType type,
int precision,
boolean useCentroidOnly,
String geometryFieldName) |
| Modifier and Type | Method and Description |
|---|---|
void |
fromBinary(byte[] bytes) |
org.locationtech.jts.geom.Geometry |
getGeometry(DataTypeAdapter<CommonIndexedPersistenceEncoding> adapter,
CommonIndexedPersistenceEncoding entry)
Extract the geometry from the entry.
|
byte[] |
toBinary() |
getBins, getPrecisionclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetWeightpublic SpatialCommonIndexedBinningStrategy()
public SpatialCommonIndexedBinningStrategy(SpatialBinningType type, int precision, boolean useCentroidOnly)
public SpatialCommonIndexedBinningStrategy(SpatialBinningType type, int precision, boolean useCentroidOnly, String geometryFieldName)
type - S2, H3, or GeoHashprecision - the resolution/length of the hashuseCentroidOnly - desired behavior for complex geometry such as lines and polygons whether
to just aggregate one hash value based on the centroid or to apply the aggregation to
all overlapping centroidsgeometryFieldName - The field name of the geometry used in a given
CommonIndexedPersistenceEncoding entry. For more documentation on this behavior, see
new
GeohashBinningStrategy(int).public org.locationtech.jts.geom.Geometry getGeometry(DataTypeAdapter<CommonIndexedPersistenceEncoding> adapter, CommonIndexedPersistenceEncoding entry)
SpatialBinningStrategyentry - The entry that will be binned using this strategy.public byte[] toBinary()
toBinary in interface PersistabletoBinary in class SpatialBinningStrategy<CommonIndexedPersistenceEncoding>public void fromBinary(byte[] bytes)
fromBinary in interface PersistablefromBinary in class SpatialBinningStrategy<CommonIndexedPersistenceEncoding>Copyright © 2013–2021. All rights reserved.