Interface BoundGeoOperations<K,M>
- All Superinterfaces:
BoundKeyOperations<K>
GeoOperations bound to a certain key.- Since:
- 1.8
- Author:
- Ninad Divadkar, Christoph Strobl, Mark Paluch
-
Method Summary
Modifier and TypeMethodDescriptionadd(@NonNull Iterable<@NonNull RedisGeoCommands.GeoLocation<M>> locations) AddRedisGeoCommands.GeoLocations to keyAddPointwith given member name to key.add(@NonNull RedisGeoCommands.GeoLocation<M> location) AddRedisGeoCommands.GeoLocationto key.Get theDistancebetween member1 and member2.RedisOperations<K, ?> Get Geohash representation of the position for one or more members.Get thePointrepresentation of positions for one or more members.Get the members within the circle defined by the members coordinates and given radius.Get the members within the circle defined by the members coordinates and given radius applyingMetric.radius(@NonNull M member, @NonNull Distance distance, @NonNull RedisGeoCommands.GeoRadiusCommandArgs args) Get the members within the circle defined by the members coordinates and given radius applyingMetricandRedisGeoCommands.GeoRadiusCommandArgs.Get the members within the boundaries of a givenCircle.radius(@NonNull Circle within, @NonNull RedisGeoCommands.GeoRadiusCommandArgs args) Get the members within the boundaries of a givenCircleapplyingRedisGeoCommands.GeoRadiusCommandArgs.Remove the members.default GeoResults<RedisGeoCommands.GeoLocation<M>> Get the members within the boundaries of a givenCircle.default GeoResults<RedisGeoCommands.GeoLocation<M>> search(@NonNull GeoReference<M> reference, @NonNull Distance radius) Get the members usingGeoReferenceas center of the query within the boundaries of a givenradius.default GeoResults<RedisGeoCommands.GeoLocation<M>> search(@NonNull GeoReference<M> reference, @NonNull Distance radius, @NonNull RedisGeoCommands.GeoSearchCommandArgs args) Get the members usingGeoReferenceas center of the query within the boundaries of a givenradiusapplyingRedisGeoCommands.GeoRadiusCommandArgs.default GeoResults<RedisGeoCommands.GeoLocation<M>> search(@NonNull GeoReference<M> reference, @NonNull BoundingBox boundingBox) Get the members usingGeoReferenceas center of the query within the boundaries of a given bounding box.default GeoResults<RedisGeoCommands.GeoLocation<M>> search(@NonNull GeoReference<M> reference, @NonNull BoundingBox boundingBox, @NonNull RedisGeoCommands.GeoSearchCommandArgs args) Get the members usingGeoReferenceas center of the query within the boundaries of a given bounding box applyingRedisGeoCommands.GeoRadiusCommandArgs.search(@NonNull GeoReference<M> reference, @NonNull GeoShape geoPredicate, @NonNull RedisGeoCommands.GeoSearchCommandArgs args) Get the members usingGeoReferenceas center of the query within the boundaries of a givenpredicateapplyingRedisGeoCommands.GeoRadiusCommandArgs.default LongsearchAndStore(@NonNull K destKey, @NonNull Circle within) Get the members within the boundaries of a givenCircleand store results atdestKey.default LongsearchAndStore(@NonNull K destKey, @NonNull GeoReference<M> reference, @NonNull Distance radius) Get the members usingGeoReferenceas center of the query within the boundaries of a givenradiusand store results atdestKey.default LongsearchAndStore(@NonNull K destKey, @NonNull GeoReference<M> reference, @NonNull Distance radius, @NonNull RedisGeoCommands.GeoSearchStoreCommandArgs args) Get the members usingGeoReferenceas center of the query within the boundaries of a givenradiusapplyingRedisGeoCommands.GeoRadiusCommandArgsand store results atdestKey.default LongsearchAndStore(@NonNull K destKey, @NonNull GeoReference<M> reference, @NonNull BoundingBox boundingBox) Get the members usingGeoReferenceas center of the query within the boundaries of a given bounding box and store results atdestKey.default LongsearchAndStore(@NonNull K destKey, @NonNull GeoReference<M> reference, @NonNull BoundingBox boundingBox, RedisGeoCommands.GeoSearchStoreCommandArgs args) Get the members usingGeoReferenceas center of the query within the boundaries of a given bounding box applyingRedisGeoCommands.GeoRadiusCommandArgsand store results atdestKey.searchAndStore(@NonNull K destKey, @NonNull GeoReference<M> reference, @NonNull GeoShape geoPredicate, @NonNull RedisGeoCommands.GeoSearchStoreCommandArgs args) Get the members usingGeoReferenceas center of the query within the boundaries of a givenpredicateapplyingRedisGeoCommands.GeoRadiusCommandArgsand store results atdestKey.
-
Method Details
-
add
-
add
AddRedisGeoCommands.GeoLocationto key.- Parameters:
location- must not be null.- Returns:
- Number of elements added. null when used in pipeline / transaction.
- Since:
- 2.0
- See Also:
-
add
-
add
AddRedisGeoCommands.GeoLocations to key- Parameters:
locations- must not be null.- Returns:
- Number of elements added. null when used in pipeline / transaction.
- Since:
- 2.0
- See Also:
-
distance
-
distance
-
hash
-
position
-
radius
Get the members within the boundaries of a givenCircle.- Parameters:
within- must not be null.- Returns:
- never null unless used in pipeline / transaction.
- Since:
- 2.0
- See Also:
-
radius
GeoResults<RedisGeoCommands.GeoLocation<M>> radius(@NonNull Circle within, @NonNull RedisGeoCommands.GeoRadiusCommandArgs args) Get the members within the boundaries of a givenCircleapplyingRedisGeoCommands.GeoRadiusCommandArgs.- Parameters:
within- must not be null.args- must not be null.- Returns:
- never null unless used in pipeline / transaction.
- Since:
- 2.0
- See Also:
-
radius
Get the members within the circle defined by the members coordinates and given radius.- Parameters:
member- must not be null.radius-- Returns:
- never null unless used in pipeline / transaction.
- Since:
- 2.0
- See Also:
-
radius
Get the members within the circle defined by the members coordinates and given radius applyingMetric.- Parameters:
member- must not be null.distance- must not be null.- Returns:
- never null unless used in pipeline / transaction.
- Since:
- 2.0
- See Also:
-
radius
GeoResults<RedisGeoCommands.GeoLocation<M>> radius(@NonNull M member, @NonNull Distance distance, @NonNull RedisGeoCommands.GeoRadiusCommandArgs args) Get the members within the circle defined by the members coordinates and given radius applyingMetricandRedisGeoCommands.GeoRadiusCommandArgs.- Parameters:
member- must not be null.distance- must not be null.args- must not be null.- Returns:
- never null unless used in pipeline / transaction.
- Since:
- 2.0
- See Also:
-
remove
-
search
Get the members within the boundaries of a givenCircle.- Parameters:
within- must not be null.- Returns:
- never null unless used in pipeline / transaction.
- Since:
- 2.6
- See Also:
-
search
default GeoResults<RedisGeoCommands.GeoLocation<M>> search(@NonNull GeoReference<M> reference, @NonNull Distance radius) Get the members usingGeoReferenceas center of the query within the boundaries of a givenradius.- Parameters:
reference- must not be null.radius- must not be null.- Returns:
- never null unless used in pipeline / transaction.
- Since:
- 2.6
- See Also:
-
search
default GeoResults<RedisGeoCommands.GeoLocation<M>> search(@NonNull GeoReference<M> reference, @NonNull Distance radius, @NonNull RedisGeoCommands.GeoSearchCommandArgs args) Get the members usingGeoReferenceas center of the query within the boundaries of a givenradiusapplyingRedisGeoCommands.GeoRadiusCommandArgs.- Parameters:
reference- must not be null.radius- must not be null.args- must not be null.- Returns:
- never null unless used in pipeline / transaction.
- Since:
- 2.6
- See Also:
-
search
default GeoResults<RedisGeoCommands.GeoLocation<M>> search(@NonNull GeoReference<M> reference, @NonNull BoundingBox boundingBox) Get the members usingGeoReferenceas center of the query within the boundaries of a given bounding box.- Parameters:
reference- must not be null.boundingBox- must not be null.- Returns:
- never null unless used in pipeline / transaction.
- Since:
- 2.6
- See Also:
-
search
default GeoResults<RedisGeoCommands.GeoLocation<M>> search(@NonNull GeoReference<M> reference, @NonNull BoundingBox boundingBox, @NonNull RedisGeoCommands.GeoSearchCommandArgs args) Get the members usingGeoReferenceas center of the query within the boundaries of a given bounding box applyingRedisGeoCommands.GeoRadiusCommandArgs.- Parameters:
reference- must not be null.boundingBox- must not be null.args- must not be null.- Returns:
- never null unless used in pipeline / transaction.
- Since:
- 2.6
- See Also:
-
search
GeoResults<RedisGeoCommands.GeoLocation<M>> search(@NonNull GeoReference<M> reference, @NonNull GeoShape geoPredicate, @NonNull RedisGeoCommands.GeoSearchCommandArgs args) Get the members usingGeoReferenceas center of the query within the boundaries of a givenpredicateapplyingRedisGeoCommands.GeoRadiusCommandArgs.- Parameters:
reference- must not be null.geoPredicate- must not be null.args- must not be null.- Returns:
- never null unless used in pipeline / transaction.
- Since:
- 2.6
- See Also:
-
searchAndStore
-
searchAndStore
default Long searchAndStore(@NonNull K destKey, @NonNull GeoReference<M> reference, @NonNull Distance radius) Get the members usingGeoReferenceas center of the query within the boundaries of a givenradiusand store results atdestKey.- Parameters:
reference- must not be null.radius- must not be null.- Returns:
- never null unless used in pipeline / transaction.
- Since:
- 2.6
- See Also:
-
searchAndStore
default Long searchAndStore(@NonNull K destKey, @NonNull GeoReference<M> reference, @NonNull Distance radius, @NonNull RedisGeoCommands.GeoSearchStoreCommandArgs args) Get the members usingGeoReferenceas center of the query within the boundaries of a givenradiusapplyingRedisGeoCommands.GeoRadiusCommandArgsand store results atdestKey.- Parameters:
reference- must not be null.radius- must not be null.args- must not be null.- Returns:
- never null unless used in pipeline / transaction.
- Since:
- 2.6
- See Also:
-
searchAndStore
default Long searchAndStore(@NonNull K destKey, @NonNull GeoReference<M> reference, @NonNull BoundingBox boundingBox) Get the members usingGeoReferenceas center of the query within the boundaries of a given bounding box and store results atdestKey.- Parameters:
reference- must not be null.boundingBox- must not be null.- Returns:
- never null unless used in pipeline / transaction.
- Since:
- 2.6
- See Also:
-
searchAndStore
default Long searchAndStore(@NonNull K destKey, @NonNull GeoReference<M> reference, @NonNull BoundingBox boundingBox, RedisGeoCommands.GeoSearchStoreCommandArgs args) Get the members usingGeoReferenceas center of the query within the boundaries of a given bounding box applyingRedisGeoCommands.GeoRadiusCommandArgsand store results atdestKey.- Parameters:
reference- must not be null.boundingBox- must not be null.args- must not be null.- Returns:
- never null unless used in pipeline / transaction.
- Since:
- 2.6
- See Also:
-
searchAndStore
Long searchAndStore(@NonNull K destKey, @NonNull GeoReference<M> reference, @NonNull GeoShape geoPredicate, @NonNull RedisGeoCommands.GeoSearchStoreCommandArgs args) Get the members usingGeoReferenceas center of the query within the boundaries of a givenpredicateapplyingRedisGeoCommands.GeoRadiusCommandArgsand store results atdestKey.- Parameters:
reference- must not be null.geoPredicate- must not be null.args- must not be null.- Returns:
- never null unless used in pipeline / transaction.
- Since:
- 2.6
- See Also:
-
getOperations
RedisOperations<K,?> getOperations()- Specified by:
getOperationsin interfaceBoundKeyOperations<K>- Returns:
- the underlying
RedisOperationsused to execute commands. - Since:
- 4.0
-