Class JoinQuery
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic <T extends org.locationtech.jts.geom.Geometry>
org.apache.spark.api.java.JavaPairRDD<org.locationtech.jts.geom.Geometry,T> distanceJoin(SpatialRDD<T> spatialRDD, CircleRDD queryRDD, JoinQuery.JoinParams joinParams) Note: INTERNAL FUNCTION.static <T extends org.locationtech.jts.geom.Geometry>
org.apache.spark.api.java.JavaPairRDD<org.locationtech.jts.geom.Geometry,List<T>> DistanceJoinQuery(SpatialRDD<T> spatialRDD, CircleRDD queryRDD, boolean useIndex, boolean considerBoundaryIntersection) Deprecated.static <T extends org.locationtech.jts.geom.Geometry>
org.apache.spark.api.java.JavaPairRDD<org.locationtech.jts.geom.Geometry,List<T>> DistanceJoinQuery(SpatialRDD<T> spatialRDD, CircleRDD queryRDD, boolean useIndex, SpatialPredicate spatialPredicate) Inner joins two sets of geometries, where the query windows are circles (aka.static <T extends org.locationtech.jts.geom.Geometry>
org.apache.spark.api.java.JavaPairRDD<org.locationtech.jts.geom.Geometry,List<T>> DistanceJoinQuery(SpatialRDD<T> spatialRDD, CircleRDD queryRDD, JoinQuery.JoinParams joinParams) static <T extends org.locationtech.jts.geom.Geometry>
org.apache.spark.api.java.JavaPairRDD<org.locationtech.jts.geom.Geometry,Long> DistanceJoinQueryCountByKey(SpatialRDD<T> spatialRDD, CircleRDD queryRDD, boolean useIndex, boolean considerBoundaryIntersection) Deprecated.static <T extends org.locationtech.jts.geom.Geometry>
org.apache.spark.api.java.JavaPairRDD<org.locationtech.jts.geom.Geometry,Long> DistanceJoinQueryCountByKey(SpatialRDD<T> spatialRDD, CircleRDD queryRDD, boolean useIndex, SpatialPredicate spatialPredicate) static <T extends org.locationtech.jts.geom.Geometry>
org.apache.spark.api.java.JavaPairRDD<org.locationtech.jts.geom.Geometry,Long> DistanceJoinQueryCountByKey(SpatialRDD<T> spatialRDD, CircleRDD queryRDD, JoinQuery.JoinParams joinParams) static <T extends org.locationtech.jts.geom.Geometry>
org.apache.spark.api.java.JavaPairRDD<org.locationtech.jts.geom.Geometry,T> DistanceJoinQueryFlat(SpatialRDD<T> spatialRDD, CircleRDD queryRDD, boolean useIndex, boolean considerBoundaryIntersection) Deprecated.static <T extends org.locationtech.jts.geom.Geometry>
org.apache.spark.api.java.JavaPairRDD<org.locationtech.jts.geom.Geometry,T> DistanceJoinQueryFlat(SpatialRDD<T> spatialRDD, CircleRDD queryRDD, boolean useIndex, SpatialPredicate spatialPredicate) Inner joins two sets of geometries, where the query windows are circles (aka.static <T extends org.locationtech.jts.geom.Geometry>
org.apache.spark.api.java.JavaPairRDD<org.locationtech.jts.geom.Geometry,T> DistanceJoinQueryFlat(SpatialRDD<T> spatialRDD, CircleRDD queryRDD, JoinQuery.JoinParams joinParams) static <U extends org.locationtech.jts.geom.Geometry,T extends org.locationtech.jts.geom.Geometry>
org.apache.spark.api.java.JavaPairRDD<U,T> knnJoin(SpatialRDD<U> queryRDD, SpatialRDD<T> objectRDD, JoinQuery.JoinParams joinParams, boolean includeTies, boolean broadcastJoin) static <U extends org.locationtech.jts.geom.Geometry,T extends org.locationtech.jts.geom.Geometry>
org.apache.spark.api.java.JavaPairRDD<U,List<T>> KNNJoinQuery(SpatialRDD<T> objectRDD, SpatialRDD<U> queryRDD, IndexType indexType, int k, DistanceMetric distanceMetric) Joins two sets of geometries on specified distance metric and finds the k nearest neighbors.static <U extends org.locationtech.jts.geom.Geometry,T extends org.locationtech.jts.geom.Geometry>
org.apache.spark.api.java.JavaPairRDD<U,T> spatialJoin(SpatialRDD<U> leftRDD, SpatialRDD<T> rightRDD, JoinQuery.JoinParams joinParams) Note: INTERNAL FUNCTION.static <U extends org.locationtech.jts.geom.Geometry,T extends org.locationtech.jts.geom.Geometry>
org.apache.spark.api.java.JavaPairRDD<U,List<T>> SpatialJoinQuery(SpatialRDD<T> spatialRDD, SpatialRDD<U> queryRDD, boolean useIndex, boolean considerBoundaryIntersection) Deprecated.static <U extends org.locationtech.jts.geom.Geometry,T extends org.locationtech.jts.geom.Geometry>
org.apache.spark.api.java.JavaPairRDD<U,List<T>> SpatialJoinQuery(SpatialRDD<T> spatialRDD, SpatialRDD<U> queryRDD, boolean useIndex, SpatialPredicate spatialPredicate) Inner joins two sets of geometries on specified spatial predicate.static <U extends org.locationtech.jts.geom.Geometry,T extends org.locationtech.jts.geom.Geometry>
org.apache.spark.api.java.JavaPairRDD<U,List<T>> SpatialJoinQuery(SpatialRDD<T> spatialRDD, SpatialRDD<U> queryRDD, JoinQuery.JoinParams joinParams) static <U extends org.locationtech.jts.geom.Geometry,T extends org.locationtech.jts.geom.Geometry>
org.apache.spark.api.java.JavaPairRDD<U,Long> SpatialJoinQueryCountByKey(SpatialRDD<T> spatialRDD, SpatialRDD<U> queryRDD, boolean useIndex, boolean considerBoundaryIntersection) Deprecated.static <U extends org.locationtech.jts.geom.Geometry,T extends org.locationtech.jts.geom.Geometry>
org.apache.spark.api.java.JavaPairRDD<U,Long> SpatialJoinQueryCountByKey(SpatialRDD<T> spatialRDD, SpatialRDD<U> queryRDD, boolean useIndex, SpatialPredicate spatialPredicate) static <U extends org.locationtech.jts.geom.Geometry,T extends org.locationtech.jts.geom.Geometry>
org.apache.spark.api.java.JavaPairRDD<U,Long> SpatialJoinQueryCountByKey(SpatialRDD<T> spatialRDD, SpatialRDD<U> queryRDD, JoinQuery.JoinParams joinParams) static <U extends org.locationtech.jts.geom.Geometry,T extends org.locationtech.jts.geom.Geometry>
org.apache.spark.api.java.JavaPairRDD<U,T> SpatialJoinQueryFlat(SpatialRDD<T> spatialRDD, SpatialRDD<U> queryRDD, boolean useIndex, boolean considerBoundaryIntersection) Deprecated.static <U extends org.locationtech.jts.geom.Geometry,T extends org.locationtech.jts.geom.Geometry>
org.apache.spark.api.java.JavaPairRDD<U,T> SpatialJoinQueryFlat(SpatialRDD<T> spatialRDD, SpatialRDD<U> queryRDD, boolean useIndex, SpatialPredicate spatialPredicate) Inner joins two sets of geometries on specified spatial predicate.static <U extends org.locationtech.jts.geom.Geometry,T extends org.locationtech.jts.geom.Geometry>
org.apache.spark.api.java.JavaPairRDD<U,T> SpatialJoinQueryFlat(SpatialRDD<T> spatialRDD, SpatialRDD<U> queryRDD, JoinQuery.JoinParams joinParams)
-
Constructor Details
-
JoinQuery
public JoinQuery()
-
-
Method Details
-
SpatialJoinQuery
public static <U extends org.locationtech.jts.geom.Geometry,T extends org.locationtech.jts.geom.Geometry> org.apache.spark.api.java.JavaPairRDD<U,List<T>> SpatialJoinQuery(SpatialRDD<T> spatialRDD, SpatialRDD<U> queryRDD, boolean useIndex, SpatialPredicate spatialPredicate) throws Exception Inner joins two sets of geometries on specified spatial predicate.spatialPredicateis the spatial predicate in join conditionspatialRDD <spatialPredicate> queryRDDIf
useIndexis false, the join uses nested loop algorithm to identify matching geometries.If
useIndexis true, the join scans query windows and uses an index of geometries built prior to invoking the join to lookup matches.Duplicate geometries present in the input queryWindowRDD, regardless of their non-spatial attributes, will not be reflected in the join results. Duplicate geometries present in the input spatialRDD, regardless of their non-spatial attributes, will be reflected in the join results.
- Type Parameters:
U- Type of the geometries in queryWindowRDD setT- Type of the geometries in spatialRDD set- Parameters:
spatialRDD- Set of geometriesqueryRDD- Set of geometries which serve as query windowsuseIndex- Boolean indicating whether the join should use the index fromspatialRDD.indexedRDDspatialPredicate- Spatial predicate in join conditionspatialRDD <spatialPredicate> queryRDD- Returns:
- RDD of pairs where each pair contains a geometry and a set of matching geometries
- Throws:
Exception- the exception
-
SpatialJoinQuery
@Deprecated public static <U extends org.locationtech.jts.geom.Geometry,T extends org.locationtech.jts.geom.Geometry> org.apache.spark.api.java.JavaPairRDD<U,List<T>> SpatialJoinQuery(SpatialRDD<T> spatialRDD, SpatialRDD<U> queryRDD, boolean useIndex, boolean considerBoundaryIntersection) throws Exception Deprecated.Inner joins two sets of geometries on 'covers' or 'intersects' relationship.If
considerBoundaryIntersectionistrue, returns pairs of geometries which intersect. Otherwise, returns pairs of geometries where first geometry covers second geometry.If
useIndexis false, the join uses nested loop algorithm to identify matching geometries.If
useIndexis true, the join scans query windows and uses an index of geometries built prior to invoking the join to lookup matches.Duplicate geometries present in the input queryWindowRDD, regardless of their non-spatial attributes, will not be reflected in the join results. Duplicate geometries present in the input spatialRDD, regardless of their non-spatial attributes, will be reflected in the join results.
- Type Parameters:
U- Type of the geometries in queryWindowRDD setT- Type of the geometries in spatialRDD set- Parameters:
spatialRDD- Set of geometriesqueryRDD- Set of geometries which serve as query windowsuseIndex- Boolean indicating whether the join should use the index fromspatialRDD.indexedRDDconsiderBoundaryIntersection- Join relationship type: 'intersects' if true, 'covers' otherwise- Returns:
- RDD of pairs where each pair contains a geometry and a set of matching geometries
- Throws:
Exception- the exception
-
SpatialJoinQuery
public static <U extends org.locationtech.jts.geom.Geometry,T extends org.locationtech.jts.geom.Geometry> org.apache.spark.api.java.JavaPairRDD<U,List<T>> SpatialJoinQuery(SpatialRDD<T> spatialRDD, SpatialRDD<U> queryRDD, JoinQuery.JoinParams joinParams) throws Exception - Throws:
Exception
-
SpatialJoinQueryFlat
public static <U extends org.locationtech.jts.geom.Geometry,T extends org.locationtech.jts.geom.Geometry> org.apache.spark.api.java.JavaPairRDD<U,T> SpatialJoinQueryFlat(SpatialRDD<T> spatialRDD, SpatialRDD<U> queryRDD, boolean useIndex, SpatialPredicate spatialPredicate) throws Exception Inner joins two sets of geometries on specified spatial predicate. Results are put in a flat pair format.spatialPredicateis the spatial predicate in join conditionspatialRDD <spatialPredicate> queryRDD.If
useIndexis false, the join uses nested loop algorithm to identify matching geometries.If
useIndexis true, the join scans query windows and uses an index of geometries built prior to invoking the join to lookup matches.Duplicates present in the input RDDs will be reflected in the join results.
- Type Parameters:
U- Type of the geometries in queryWindowRDD setT- Type of the geometries in spatialRDD set- Parameters:
spatialRDD- Set of geometriesqueryRDD- Set of geometries which serve as query windowsuseIndex- Boolean indicating whether the join should use the index fromspatialRDD.indexedRDDspatialPredicate- Spatial predicate in join conditionspatialRDD <spatialPredicate> queryRDD- Returns:
- RDD of pairs of matching geometries
- Throws:
Exception- the exception
-
SpatialJoinQueryFlat
@Deprecated public static <U extends org.locationtech.jts.geom.Geometry,T extends org.locationtech.jts.geom.Geometry> org.apache.spark.api.java.JavaPairRDD<U,T> SpatialJoinQueryFlat(SpatialRDD<T> spatialRDD, SpatialRDD<U> queryRDD, boolean useIndex, boolean considerBoundaryIntersection) throws Exception Deprecated.Inner joins two sets of geometries on 'covers' or 'intersects' relationship. Results are put in a flat pair format.If
considerBoundaryIntersectionistrue, returns pairs of geometries which intersect. Otherwise, returns pairs of geometries where first geometry covers second geometry.If
useIndexis false, the join uses nested loop algorithm to identify matching geometries.If
useIndexis true, the join scans query windows and uses an index of geometries built prior to invoking the join to lookup matches.Duplicates present in the input RDDs will be reflected in the join results.
- Type Parameters:
U- Type of the geometries in queryWindowRDD setT- Type of the geometries in spatialRDD set- Parameters:
spatialRDD- Set of geometriesqueryRDD- Set of geometries which serve as query windowsuseIndex- Boolean indicating whether the join should use the index fromspatialRDD.indexedRDDconsiderBoundaryIntersection- Join relationship type: 'intersects' if true, 'covers' otherwise- Returns:
- RDD of pairs of matching geometries
- Throws:
Exception- the exception
-
SpatialJoinQueryFlat
public static <U extends org.locationtech.jts.geom.Geometry,T extends org.locationtech.jts.geom.Geometry> org.apache.spark.api.java.JavaPairRDD<U,T> SpatialJoinQueryFlat(SpatialRDD<T> spatialRDD, SpatialRDD<U> queryRDD, JoinQuery.JoinParams joinParams) throws Exception - Throws:
Exception
-
SpatialJoinQueryCountByKey
public static <U extends org.locationtech.jts.geom.Geometry,T extends org.locationtech.jts.geom.Geometry> org.apache.spark.api.java.JavaPairRDD<U,Long> SpatialJoinQueryCountByKey(SpatialRDD<T> spatialRDD, SpatialRDD<U> queryRDD, boolean useIndex, SpatialPredicate spatialPredicate) throws Exception SpatialJoinQueryFlat(SpatialRDD, SpatialRDD, boolean, SpatialPredicate)count by key.Duplicate geometries present in the input queryWindowRDD RDD, regardless of their non-spatial attributes, will not be reflected in the join results. Duplicate geometries present in the input spatialRDD RDD, regardless of their non-spatial attributes, will be reflected in the join results.
- Type Parameters:
U- Type of the geometries in queryWindowRDD setT- Type of the geometries in spatialRDD set- Parameters:
spatialRDD- Set of geometriesqueryRDD- Set of geometries which serve as query windowsuseIndex- Boolean indicating whether the join should use the index fromspatialRDD.indexedRDDspatialPredicate- Spatial predicate in join conditionspatialRDD <spatialPredicate> queryRDD- Returns:
- the result of
SpatialJoinQueryFlat(SpatialRDD, SpatialRDD, boolean, SpatialPredicate), but in this pair RDD, each pair contains a geometry and the count of matching geometries - Throws:
Exception- the exception
-
SpatialJoinQueryCountByKey
@Deprecated public static <U extends org.locationtech.jts.geom.Geometry,T extends org.locationtech.jts.geom.Geometry> org.apache.spark.api.java.JavaPairRDD<U,Long> SpatialJoinQueryCountByKey(SpatialRDD<T> spatialRDD, SpatialRDD<U> queryRDD, boolean useIndex, boolean considerBoundaryIntersection) throws Exception Deprecated.SpatialJoinQueryFlat(SpatialRDD, SpatialRDD, boolean, boolean)count by key.Duplicate geometries present in the input queryWindowRDD RDD, regardless of their non-spatial attributes, will not be reflected in the join results. Duplicate geometries present in the input spatialRDD RDD, regardless of their non-spatial attributes, will be reflected in the join results.
- Type Parameters:
U- Type of the geometries in queryWindowRDD setT- Type of the geometries in spatialRDD set- Parameters:
spatialRDD- Set of geometriesqueryRDD- Set of geometries which serve as query windowsuseIndex- Boolean indicating whether the join should use the index fromspatialRDD.indexedRDDconsiderBoundaryIntersection- Join relationship type: 'intersects' if true, 'covers' otherwise- Returns:
- the result of
SpatialJoinQueryFlat(SpatialRDD, SpatialRDD, boolean, boolean), but in this pair RDD, each pair contains a geometry and the count of matching geometries - Throws:
Exception- the exception
-
SpatialJoinQueryCountByKey
public static <U extends org.locationtech.jts.geom.Geometry,T extends org.locationtech.jts.geom.Geometry> org.apache.spark.api.java.JavaPairRDD<U,Long> SpatialJoinQueryCountByKey(SpatialRDD<T> spatialRDD, SpatialRDD<U> queryRDD, JoinQuery.JoinParams joinParams) throws Exception - Throws:
Exception
-
KNNJoinQuery
public static <U extends org.locationtech.jts.geom.Geometry,T extends org.locationtech.jts.geom.Geometry> org.apache.spark.api.java.JavaPairRDD<U,List<T>> KNNJoinQuery(SpatialRDD<T> objectRDD, SpatialRDD<U> queryRDD, IndexType indexType, int k, DistanceMetric distanceMetric) throws Exception Joins two sets of geometries on specified distance metric and finds the k nearest neighbors.Duplicate geometries present in the input queryWindowRDD, regardless of their non-spatial attributes, will not be reflected in the join results. Duplicate geometries present in the input objectRDD, regardless of their non-spatial attributes, will be reflected in the join results.
- Type Parameters:
U- Type of the geometries in queryWindowRDD setT- Type of the geometries in objectRDD set- Parameters:
objectRDD-objectRDDis the set of geometries (neighbors) to be queriedqueryRDD-queryRDDis the set of geometries which serve as query geometries (center points)indexType-indexTypeis the index type to use for the joink-kis the number of nearest neighbors to finddistanceMetric-distanceMetricis the distance metric to use- Returns:
- RDD of pairs where each pair contains a geometry and a set of matching geometries
- Throws:
Exception- the exception
-
DistanceJoinQueryFlat
public static <T extends org.locationtech.jts.geom.Geometry> org.apache.spark.api.java.JavaPairRDD<org.locationtech.jts.geom.Geometry,T> DistanceJoinQueryFlat(SpatialRDD<T> spatialRDD, CircleRDD queryRDD, boolean useIndex, SpatialPredicate spatialPredicate) throws Exception Inner joins two sets of geometries, where the query windows are circles (aka. distance join). Results are put in a flat pair format.spatialPredicateis the spatial predicate in join conditionspatialRDD <spatialPredicate> queryRDD.If
useIndexis false, the join uses nested loop algorithm to identify matching circle/geometry.If
useIndexis true, the join scans circles and uses an index of geometries built prior to invoking the join to lookup matches.Duplicates present in the input RDDs will be reflected in the join results.
- Type Parameters:
T- Type of the geometries in spatialRDD set- Parameters:
spatialRDD- Set of geometriesqueryRDD- Set of geometriesuseIndex- Boolean indicating whether the join should use the index fromspatialRDD.indexedRDDspatialPredicate- Spatial predicate in join conditionspatialRDD <spatialPredicate> queryRDD, should be one ofINTERSECTSandCOVERED_BY- Returns:
- RDD of pairs of matching geometries
- Throws:
Exception- the exception
-
DistanceJoinQueryFlat
@Deprecated public static <T extends org.locationtech.jts.geom.Geometry> org.apache.spark.api.java.JavaPairRDD<org.locationtech.jts.geom.Geometry,T> DistanceJoinQueryFlat(SpatialRDD<T> spatialRDD, CircleRDD queryRDD, boolean useIndex, boolean considerBoundaryIntersection) throws Exception Deprecated.Inner joins two sets of geometries on 'coveredBy' relationship (aka. distance join). Results are put in a flat pair format.If
considerBoundaryIntersectionistrue, returns pairs of circle/geometry which intersect. Otherwise, returns pairs of geometries where first circle covers second geometry.If
useIndexis false, the join uses nested loop algorithm to identify matching circle/geometry.If
useIndexis true, the join scans circles and uses an index of geometries built prior to invoking the join to lookup matches.Duplicates present in the input RDDs will be reflected in the join results.
- Type Parameters:
T- Type of the geometries in spatialRDD set- Parameters:
spatialRDD- Set of geometriesqueryRDD- Set of geometriesuseIndex- Boolean indicating whether the join should use the index fromspatialRDD.indexedRDDconsiderBoundaryIntersection- consider boundary intersection- Returns:
- RDD of pairs of matching geometries
- Throws:
Exception- the exception
-
DistanceJoinQueryFlat
public static <T extends org.locationtech.jts.geom.Geometry> org.apache.spark.api.java.JavaPairRDD<org.locationtech.jts.geom.Geometry,T> DistanceJoinQueryFlat(SpatialRDD<T> spatialRDD, CircleRDD queryRDD, JoinQuery.JoinParams joinParams) throws Exception - Throws:
Exception
-
DistanceJoinQuery
public static <T extends org.locationtech.jts.geom.Geometry> org.apache.spark.api.java.JavaPairRDD<org.locationtech.jts.geom.Geometry,List<T>> DistanceJoinQuery(SpatialRDD<T> spatialRDD, CircleRDD queryRDD, boolean useIndex, SpatialPredicate spatialPredicate) throws Exception Inner joins two sets of geometries, where the query windows are circles (aka. distance join). The query window objects are converted to circle objects. The radius is the given distance. Eventually, the original window objects are recovered and outputted.spatialPredicateis the spatial predicate in join conditionspatialRDD <spatialPredicate> queryRDD.If
useIndexis false, the join uses nested loop algorithm to identify matching circle/geometry.If
useIndexis true, the join scans circles and uses an index of geometries built prior to invoking the join to lookup matches.Duplicate geometries present in the input CircleRDD, regardless of their non-spatial attributes, will not be reflected in the join results. Duplicate geometries present in the input spatialRDD, regardless of their non-spatial attributes, will be reflected in the join results.
- Type Parameters:
T- Type of the geometries in spatialRDD set- Parameters:
spatialRDD- Set of geometriesqueryRDD- Set of geometriesuseIndex- Boolean indicating whether the join should use the index fromspatialRDD.indexedRDDspatialPredicate- Spatial predicate in join conditionspatialRDD <spatialPredicate> queryRDD, should be one ofINTERSECTSandCOVERED_BY- Returns:
- RDD of pairs where each pair contains a geometry and a set of matching geometries
- Throws:
Exception- the exception
-
DistanceJoinQuery
@Deprecated public static <T extends org.locationtech.jts.geom.Geometry> org.apache.spark.api.java.JavaPairRDD<org.locationtech.jts.geom.Geometry,List<T>> DistanceJoinQuery(SpatialRDD<T> spatialRDD, CircleRDD queryRDD, boolean useIndex, boolean considerBoundaryIntersection) throws Exception Deprecated.Inner joins two sets of geometries on 'coveredBy' relationship (aka. distance join). The query window objects are converted to circle objects. The radius is the given distance. Eventually, the original window objects are recovered and outputted.If
considerBoundaryIntersectionistrue, returns pairs of circle/geometry which intersect. Otherwise, returns pairs of geometries where first circle covers second geometry.If
useIndexis false, the join uses nested loop algorithm to identify matching circle/geometry.If
useIndexis true, the join scans circles and uses an index of geometries built prior to invoking the join to lookup matches.Duplicate geometries present in the input CircleRDD, regardless of their non-spatial attributes, will not be reflected in the join results. Duplicate geometries present in the input spatialRDD, regardless of their non-spatial attributes, will be reflected in the join results.
- Type Parameters:
T- Type of the geometries in spatialRDD set- Parameters:
spatialRDD- Set of geometriesqueryRDD- Set of geometriesuseIndex- Boolean indicating whether the join should use the index fromspatialRDD.indexedRDDconsiderBoundaryIntersection- consider boundary intersection- Returns:
- RDD of pairs where each pair contains a geometry and a set of matching geometries
- Throws:
Exception- the exception
-
DistanceJoinQuery
public static <T extends org.locationtech.jts.geom.Geometry> org.apache.spark.api.java.JavaPairRDD<org.locationtech.jts.geom.Geometry,List<T>> DistanceJoinQuery(SpatialRDD<T> spatialRDD, CircleRDD queryRDD, JoinQuery.JoinParams joinParams) throws Exception - Throws:
Exception
-
DistanceJoinQueryCountByKey
public static <T extends org.locationtech.jts.geom.Geometry> org.apache.spark.api.java.JavaPairRDD<org.locationtech.jts.geom.Geometry,Long> DistanceJoinQueryCountByKey(SpatialRDD<T> spatialRDD, CircleRDD queryRDD, boolean useIndex, SpatialPredicate spatialPredicate) throws Exception DistanceJoinQueryFlat(SpatialRDD, CircleRDD, boolean, boolean)count by key.Duplicate geometries present in the input CircleRDD, regardless of their non-spatial attributes, will not be reflected in the join results. Duplicate geometries present in the input spatialRDD, regardless of their non-spatial attributes, will be reflected in the join results.
- Type Parameters:
T- Type of the geometries in spatialRDD set- Parameters:
spatialRDD- Set of geometriesqueryRDD- Set of geometriesuseIndex- Boolean indicating whether the join should use the index fromspatialRDD.indexedRDDspatialPredicate- Spatial predicate in join conditionspatialRDD <spatialPredicate> queryRDD, should be one ofINTERSECTSandCOVERED_BY- Returns:
- the result of
DistanceJoinQueryFlat(SpatialRDD, CircleRDD, boolean, boolean), but in this pair RDD, each pair contains a geometry and the count of matching geometries - Throws:
Exception- the exception
-
DistanceJoinQueryCountByKey
@Deprecated public static <T extends org.locationtech.jts.geom.Geometry> org.apache.spark.api.java.JavaPairRDD<org.locationtech.jts.geom.Geometry,Long> DistanceJoinQueryCountByKey(SpatialRDD<T> spatialRDD, CircleRDD queryRDD, boolean useIndex, boolean considerBoundaryIntersection) throws Exception Deprecated.DistanceJoinQueryFlat(SpatialRDD, CircleRDD, boolean, boolean)count by key.Duplicate geometries present in the input CircleRDD, regardless of their non-spatial attributes, will not be reflected in the join results. Duplicate geometries present in the input spatialRDD, regardless of their non-spatial attributes, will be reflected in the join results.
- Type Parameters:
T- Type of the geometries in spatialRDD set- Parameters:
spatialRDD- Set of geometriesqueryRDD- Set of geometriesuseIndex- Boolean indicating whether the join should use the index fromspatialRDD.indexedRDDconsiderBoundaryIntersection- consider boundary intersection- Returns:
- the result of
DistanceJoinQueryFlat(SpatialRDD, CircleRDD, boolean, boolean), but in this pair RDD, each pair contains a geometry and the count of matching geometries - Throws:
Exception- the exception
-
DistanceJoinQueryCountByKey
public static <T extends org.locationtech.jts.geom.Geometry> org.apache.spark.api.java.JavaPairRDD<org.locationtech.jts.geom.Geometry,Long> DistanceJoinQueryCountByKey(SpatialRDD<T> spatialRDD, CircleRDD queryRDD, JoinQuery.JoinParams joinParams) throws Exception - Throws:
Exception
-
distanceJoin
public static <T extends org.locationtech.jts.geom.Geometry> org.apache.spark.api.java.JavaPairRDD<org.locationtech.jts.geom.Geometry,T> distanceJoin(SpatialRDD<T> spatialRDD, CircleRDD queryRDD, JoinQuery.JoinParams joinParams) throws Exception Note: INTERNAL FUNCTION. API COMPATIBILITY IS NOT GUARANTEED. DO NOT USE IF YOU DON'T KNOW WHAT IT IS.- Throws:
Exception
-
spatialJoin
public static <U extends org.locationtech.jts.geom.Geometry,T extends org.locationtech.jts.geom.Geometry> org.apache.spark.api.java.JavaPairRDD<U,T> spatialJoin(SpatialRDD<U> leftRDD, SpatialRDD<T> rightRDD, JoinQuery.JoinParams joinParams) throws Exception Note: INTERNAL FUNCTION. API COMPATIBILITY IS NOT GUARANTEED. DO NOT USE IF YOU DON'T KNOW WHAT IT IS.- Throws:
Exception
-
knnJoin
public static <U extends org.locationtech.jts.geom.Geometry,T extends org.locationtech.jts.geom.Geometry> org.apache.spark.api.java.JavaPairRDD<U,T> knnJoin(SpatialRDD<U> queryRDD, SpatialRDD<T> objectRDD, JoinQuery.JoinParams joinParams, boolean includeTies, boolean broadcastJoin) throws Exception - Type Parameters:
U- Type of the geometries in queryRDD setT- Type of the geometries in objectRDD set- Parameters:
queryRDD-queryRDDis the set of geometries which serve as query geometries (center points)objectRDD-objectRDDis the set of geometries (neighbors) to be queriedjoinParams-joinParamsis the parameters for the joinincludeTies-includeTiesis a boolean indicating whether to include ties- Returns:
- RDD of pairs where each pair contains a geometry and a set of matching geometries
- Throws:
Exception
-