Class KDBTreePartitioner
- java.lang.Object
-
- org.apache.spark.Partitioner
-
- org.apache.sedona.core.spatialPartitioning.SpatialPartitioner
-
- org.apache.sedona.core.spatialPartitioning.KDBTreePartitioner
-
- All Implemented Interfaces:
Serializable
,scala.Serializable
public class KDBTreePartitioner extends SpatialPartitioner
- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class org.apache.sedona.core.spatialPartitioning.SpatialPartitioner
grids, gridType
-
-
Constructor Summary
Constructors Constructor Description KDBTreePartitioner(KDB tree)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description DedupParams
getDedupParams()
int
numPartitions()
Iterator<scala.Tuple2<Integer,org.locationtech.jts.geom.Geometry>>
placeObject(org.locationtech.jts.geom.Geometry spatialObject)
Given a geometry, returns a list of partitions it overlaps.-
Methods inherited from class org.apache.sedona.core.spatialPartitioning.SpatialPartitioner
getGrids, getGridType, getPartition
-
-
-
-
Constructor Detail
-
KDBTreePartitioner
public KDBTreePartitioner(KDB tree)
-
-
Method Detail
-
numPartitions
public int numPartitions()
- Specified by:
numPartitions
in classorg.apache.spark.Partitioner
-
placeObject
public Iterator<scala.Tuple2<Integer,org.locationtech.jts.geom.Geometry>> placeObject(org.locationtech.jts.geom.Geometry spatialObject) throws Exception
Description copied from class:SpatialPartitioner
Given a geometry, returns a list of partitions it overlaps.For points, returns exactly one partition as long as grid type is non-overlapping. For other geometry types or for overlapping grid types, may return multiple partitions.
- Specified by:
placeObject
in classSpatialPartitioner
- Throws:
Exception
-
getDedupParams
@Nullable public DedupParams getDedupParams()
- Specified by:
getDedupParams
in classSpatialPartitioner
-
-