K -V -
public class SpatialJavaPairRDD<K,V>
extends <any>
SpatialJavaRDD. This class accepts only SparkRecordInfoProvider instances of type Tuple2<K,V>.| Modifier and Type | Method and Description |
|---|---|
SpatialTransformationContext<<any>> |
createSpatialTransformationContext()
Creates an instance of
SpatialTransformationContext |
SpatialTransformationContext<<any>> |
createSpatialTransformationContext(SpatialOperationConfig spatialOperationConf)
Creates an instance of
SpatialTransformationContext associated to the given SpatialOperationConfig. |
SpatialJavaPairRDD<K,V> |
filter(<any> f, SpatialOperationConfig spatialOpConf)
Returns a new spatial RDD containing only the elements that satisfy both, the filtering lambda function and the spatial operation
|
<R> <any> |
flatMap(<any> f, SpatialOperationConfig spatialOpConf)
Returns a new RDD by first spatially filtering the RDD elements using the spatial operation given by spatialOpConf, a function is applied to all the remaining elements.
|
static <K,V> SpatialJavaPairRDD<K,V> |
fromJavaPairRDD(<any> rdd, SparkRecordInfoProvider<<any>> recordInfoProvider, java.lang.Class<K> keyType, java.lang.Class<V> valType)
Creates a new spatial RDD from an existing JavaPairRDD
|
java.lang.Class<K> |
getKeyType()
Gets the type of the RDD's keys
|
double[] |
getMBR()
Gets the minimum bounding rectangle of the RDD
|
SparkRecordInfoProvider<<any>> |
getRecordInfoProvider()
Gets the RDD's
SparkRecordInfoProvider instance |
java.lang.Class<V> |
getValueType()
Gets the type of the RDD's values
|
java.util.List<<any>> |
nearestNeighbors(<any> f, int k, SpatialOperationConfig spatialOpConf) |
java.util.List<<any>> |
nearestNeighbors(JGeometry qryWindow, int k, double tol)
Returns the k elements which are closest to the given query window
|
public SpatialTransformationContext<<any>> createSpatialTransformationContext()
SpatialTransformationContextSpatialTransformationContextpublic SpatialTransformationContext<<any>> createSpatialTransformationContext(SpatialOperationConfig spatialOperationConf)
SpatialTransformationContext associated to the given SpatialOperationConfig.spatialOperationConf - a spatial operation used to filter recordsSpatialTransformationContextpublic SpatialJavaPairRDD<K,V> filter(<any> f, SpatialOperationConfig spatialOpConf)
f - a filtering lambda functionspatialOpConf - a spatial operation used to filter recordsSpatialJavaRDD
public <R> <any> flatMap(<any> f,
SpatialOperationConfig spatialOpConf)
f - a function to apply to each elementspatialOpConf - a spatial operation used to filter recordspublic static <K,V> SpatialJavaPairRDD<K,V> fromJavaPairRDD(<any> rdd, SparkRecordInfoProvider<<any>> recordInfoProvider, java.lang.Class<K> keyType, java.lang.Class<V> valType)
rdd - the source RDDrecordInfoProvider - an instance of SparkRecordInfoProvider used to extract spatial information from the RDD's keys and valueskeyType - the type of the source RDD keysvalType - the type of the source RDD valuespublic java.lang.Class<K> getKeyType()
public double[] getMBR()
public SparkRecordInfoProvider<<any>> getRecordInfoProvider()
SparkRecordInfoProvider instanceSparkRecordInfoProvider instancepublic java.lang.Class<V> getValueType()
public java.util.List<<any>> nearestNeighbors(<any> f,
int k,
SpatialOperationConfig spatialOpConf)
public java.util.List<<any>> nearestNeighbors(JGeometry qryWindow,
int k,
double tol)
qryWindow - a geometry from where the nearest neighbors will be calculatedk - the number of neighborstol - the tolerance usedCopyright © 2016 Oracle and/or its affiliates. All Rights Reserved.