Package org.redisson.api
Interface RGeoAsync<V>
-
- Type Parameters:
V
- type of value
- All Superinterfaces:
<V>>
- All Known Subinterfaces:
RGeo<V>
- All Known Implementing Classes:
RedissonGeo
public interface RGeoAsync<V> extends RScoredSortedSetAsync<V>
Geospatial items holder. Asynchronous interface.- Author:
- Nikita Koksharov
-
-
Method Summary
All Methods Instance Methods Abstract Methods Deprecated Methods Modifier and Type Method Description >
addAsync(double longitude, double latitude, V member)
Adds geospatial member.>
addAsync(GeoEntry... entries)
Adds geospatial members.>
addIfExistsAsync(double longitude, double latitude, V member)
Adds geospatial member only if it's already exists.>
addIfExistsAsync(GeoEntry... entries)
Adds geospatial members only if it's already exists.>
distAsync(V firstMember, V secondMember, GeoUnit geoUnit)
Returns distance between members inGeoUnit
units.<>>
hashAsync(V... members)
Returns 11 characters Geohash string mapped by defined member.<V,GeoPosition>>
posAsync(V... members)
Returns geo-position mapped by defined member.<V>>
radiusAsync(double longitude, double latitude, double radius, GeoUnit geoUnit)
Deprecated.<V>>
radiusAsync(double longitude, double latitude, double radius, GeoUnit geoUnit, int count)
Deprecated.<V>>
radiusAsync(double longitude, double latitude, double radius, GeoUnit geoUnit, GeoOrder geoOrder)
Deprecated.<V>>
radiusAsync(double longitude, double latitude, double radius, GeoUnit geoUnit, GeoOrder geoOrder, int count)
Deprecated.<V>>
radiusAsync(V member, double radius, GeoUnit geoUnit)
Deprecated.<V>>
radiusAsync(V member, double radius, GeoUnit geoUnit, int count)
Deprecated.<V>>
radiusAsync(V member, double radius, GeoUnit geoUnit, GeoOrder geoOrder)
Deprecated.<V>>
radiusAsync(V member, double radius, GeoUnit geoUnit, GeoOrder geoOrder, int count)
Deprecated.>
destName, double longitude, double latitude, double radius, GeoUnit geoUnit)
>
destName, double longitude, double latitude, double radius, GeoUnit geoUnit, int count)
>
destName, double longitude, double latitude, double radius, GeoUnit geoUnit, GeoOrder geoOrder, int count)
>
destName, V member, double radius, GeoUnit geoUnit)
>
destName, V member, double radius, GeoUnit geoUnit, int count)
>
destName, V member, double radius, GeoUnit geoUnit, GeoOrder geoOrder, int count)
>
destName, double longitude, double latitude, double radius, GeoUnit geoUnit)
Deprecated.>
destName, double longitude, double latitude, double radius, GeoUnit geoUnit, int count)
Deprecated.>
destName, double longitude, double latitude, double radius, GeoUnit geoUnit, GeoOrder geoOrder, int count)
Deprecated.>
destName, V member, double radius, GeoUnit geoUnit)
Deprecated.>
destName, V member, double radius, GeoUnit geoUnit, int count)
Deprecated.>
destName, V member, double radius, GeoUnit geoUnit, GeoOrder geoOrder, int count)
Deprecated.<>>
radiusWithDistanceAsync(double longitude, double latitude, double radius, GeoUnit geoUnit)
<>>
radiusWithDistanceAsync(double longitude, double latitude, double radius, GeoUnit geoUnit, int count)
<>>
radiusWithDistanceAsync(double longitude, double latitude, double radius, GeoUnit geoUnit, GeoOrder geoOrder)
<>>
radiusWithDistanceAsync(double longitude, double latitude, double radius, GeoUnit geoUnit, GeoOrder geoOrder, int count)
<>>
radiusWithDistanceAsync(V member, double radius, GeoUnit geoUnit)
<>>
radiusWithDistanceAsync(V member, double radius, GeoUnit geoUnit, int count)
<>>
radiusWithDistanceAsync(V member, double radius, GeoUnit geoUnit, GeoOrder geoOrder)
<>>
radiusWithDistanceAsync(V member, double radius, GeoUnit geoUnit, GeoOrder geoOrder, int count)
<V,GeoPosition>>
radiusWithPositionAsync(double longitude, double latitude, double radius, GeoUnit geoUnit)
<V,GeoPosition>>
radiusWithPositionAsync(double longitude, double latitude, double radius, GeoUnit geoUnit, int count)
<V,GeoPosition>>
radiusWithPositionAsync(double longitude, double latitude, double radius, GeoUnit geoUnit, GeoOrder geoOrder)
<V,GeoPosition>>
radiusWithPositionAsync(double longitude, double latitude, double radius, GeoUnit geoUnit, GeoOrder geoOrder, int count)
<V,GeoPosition>>
radiusWithPositionAsync(V member, double radius, GeoUnit geoUnit)
<V,GeoPosition>>
radiusWithPositionAsync(V member, double radius, GeoUnit geoUnit, int count)
<V,GeoPosition>>
radiusWithPositionAsync(V member, double radius, GeoUnit geoUnit, GeoOrder geoOrder)
<V,GeoPosition>>
radiusWithPositionAsync(V member, double radius, GeoUnit geoUnit, GeoOrder geoOrder, int count)
<V>>
searchAsync(GeoSearchArgs args)
Returns the members of a sorted set, which are within the borders of specified search conditions.<>>
searchWithDistanceAsync(GeoSearchArgs args)
Returns the distance mapped by member of a sorted set, which are within the borders of specified search conditions.<V,GeoPosition>>
searchWithPositionAsync(GeoSearchArgs args)
Returns the position mapped by member of a sorted set, which are within the borders of specified search conditions.>
destName, GeoSearchArgs args)
Finds the members of a sorted set, which are within the borders of specified search conditions.>
destName, GeoSearchArgs args)
Finds the members of a sorted set, which are within the borders of specified search conditions.>
tryAddAsync(double longitude, double latitude, V member)
Adds geospatial member only if has not been added before.>
tryAddAsync(GeoEntry... entries)
Adds geospatial members only if has not been added before.-
Methods inherited from interface org.redisson.api.RExpirableAsync
clearExpireAsync, expireAsync, expireAsync, expireAtAsync, expireAtAsync, remainTimeToLiveAsync
-
Methods inherited from interface org.redisson.api.RObjectAsync
addListenerAsync, copyAsync, deleteAsync, dumpAsync, getIdleTimeAsync, isExistsAsync, migrateAsync, moveAsync, removeListenerAsync, renameAsync, renamenxAsync, restoreAndReplaceAsync, restoreAndReplaceAsync, restoreAsync, restoreAsync, sizeInMemoryAsync, touchAsync, unlinkAsync
-
Methods inherited from interface org.redisson.api.RScoredSortedSetAsync
addAllAsync, addAndGetRankAsync, addAndGetRevRankAsync, addAndGetRevRankAsync, addAsync, addIfExistsAsync, addIfGreaterAsync, addIfLessAsync, addScoreAndGetRankAsync, addScoreAndGetRevRankAsync, addScoreAsync, containsAllAsync, containsAsync, countAsync, diffAsync, entryRangeAsync, entryRangeAsync, entryRangeAsync, entryRangeReversedAsync, entryRangeReversedAsync, entryRangeReversedAsync, firstAsync, firstScoreAsync, getScoreAsync, getScoreAsync, intersectionAsync, intersectionAsync, intersectionAsync, intersectionAsync, lastAsync, lastScoreAsync, pollFirstAsync, pollFirstAsync, pollFirstAsync, pollFirstFromAnyAsync, pollLastAsync, pollLastAsync, pollLastAsync, pollLastFromAnyAsync, randomAsync, randomAsync, randomEntriesAsync, rangeToAsync, rangeToAsync, rangeToAsync, rankAsync, readAllAsync, readDiffAsync, readIntersectionAsync, readIntersectionAsync, readIntersectionAsync, readIntersectionAsync, readUnionAsync, readUnionAsync, readUnionAsync, readUnionAsync, removeAllAsync, removeAsync, removeRangeByRankAsync, removeRangeByScoreAsync, retainAllAsync, revRangeToAsync, revRangeToAsync, revRangeToAsync, revRankAsync, revRankAsync, sizeAsync, takeFirstAsync, takeLastAsync, tryAddAsync, unionAsync, unionAsync, unionAsync, unionAsync, valueRangeAsync, valueRangeAsync, valueRangeAsync, valueRangeReversedAsync, valueRangeReversedAsync, valueRangeReversedAsync
-
Methods inherited from interface org.redisson.api.RSortableAsync
readSortAlphaAsync, readSortAlphaAsync, readSortAlphaAsync, readSortAlphaAsync, readSortAlphaAsync, readSortAlphaAsync, readSortAsync, readSortAsync, readSortAsync, readSortAsync, readSortAsync, readSortAsync, sortToAsync, sortToAsync, sortToAsync, sortToAsync, sortToAsync, sortToAsync
-
-
-
-
Method Detail
-
addAsync
> addAsync(double longitude, double latitude, V member)
Adds geospatial member.- Parameters:
longitude
- - longitude of objectlatitude
- - latitude of objectmember
- - object itself- Returns:
- number of elements added to the sorted set, not including elements already existing for which the score was updated
-
addAsync
> addAsync(GeoEntry... entries)
Adds geospatial members.- Parameters:
entries
- - objects- Returns:
- number of elements added to the sorted set, not including elements already existing for which the score was updated
-
addIfExistsAsync
> addIfExistsAsync(double longitude, double latitude, V member)
Adds geospatial member only if it's already exists.Requires Redis 6.2.0 and higher.
- Parameters:
longitude
- - longitude of objectlatitude
- - latitude of objectmember
- - object itself- Returns:
- number of elements added to the sorted set
-
addIfExistsAsync
> addIfExistsAsync(GeoEntry... entries)
Adds geospatial members only if it's already exists.Requires Redis 6.2.0 and higher.
- Parameters:
entries
- - objects- Returns:
- number of elements added to the sorted set
-
tryAddAsync
> tryAddAsync(double longitude, double latitude, V member)
Adds geospatial member only if has not been added before.Requires Redis 6.2.0 and higher.
- Parameters:
longitude
- - longitude of objectlatitude
- - latitude of objectmember
- - object itself- Returns:
- number of elements added to the sorted set
-
tryAddAsync
> tryAddAsync(GeoEntry... entries)
Adds geospatial members only if has not been added before.Requires Redis 6.2.0 and higher.
- Parameters:
entries
- - objects- Returns:
- number of elements added to the sorted set
-
distAsync
> distAsync(V firstMember, V secondMember, GeoUnit geoUnit)
Returns distance between members inGeoUnit
units.- Parameters:
firstMember
- - first objectsecondMember
- - second objectgeoUnit
- - geo unit- Returns:
- distance
-
hashAsync
<>> hashAsync(V... members)
Returns 11 characters Geohash string mapped by defined member.- Parameters:
members
- - objects- Returns:
- hash mapped by object
-
posAsync
<V,GeoPosition>> posAsync(V... members)
Returns geo-position mapped by defined member.- Parameters:
members
- - objects- Returns:
- geo position mapped by object
-
searchAsync
<V>> searchAsync(GeoSearchArgs args)
Returns the members of a sorted set, which are within the borders of specified search conditions.Usage examples:
RFuture objects = geo.searchAsync(GeoSearchArgs.from(15, 37) .radius(200, GeoUnit.KILOMETERS) .order(GeoOrder.ASC) .count(1)));
RFuture objects = geo.searchAsync(GeoSearchArgs.from(15, 37) .radius(200, GeoUnit.KILOMETERS)));
Requires Redis 3.2.10 and higher.
- Parameters:
args
- - search conditions object- Returns:
- list of memebers
-
radiusAsync
<V>> radiusAsync(double longitude, double latitude, double radius, GeoUnit geoUnit)
Deprecated.
-
radiusAsync
<V>> radiusAsync(double longitude, double latitude, double radius, GeoUnit geoUnit, int count)
Deprecated.
-
radiusAsync
<V>> radiusAsync(double longitude, double latitude, double radius, GeoUnit geoUnit, GeoOrder geoOrder)
Deprecated.
-
radiusAsync
<V>> radiusAsync(double longitude, double latitude, double radius, GeoUnit geoUnit, GeoOrder geoOrder, int count)
Deprecated.
-
searchWithDistanceAsync
<>> searchWithDistanceAsync(GeoSearchArgs args)
Returns the distance mapped by member of a sorted set, which are within the borders of specified search conditions.Usage examples:
RFuture objects = geo.searchWithDistanceAsync(GeoSearchArgs.from(15, 37) .radius(200, GeoUnit.KILOMETERS) .order(GeoOrder.ASC) .count(1)));
RFuture objects = geo.searchWithDistanceAsync(GeoSearchArgs.from(15, 37) .radius(200, GeoUnit.KILOMETERS)));
Requires Redis 3.2.10 and higher.
- Parameters:
args
- - search conditions object- Returns:
- distance mapped by object
-
radiusWithDistanceAsync
<>> radiusWithDistanceAsync(double longitude, double latitude, double radius, GeoUnit geoUnit)
-
radiusWithDistanceAsync
<>> radiusWithDistanceAsync(double longitude, double latitude, double radius, GeoUnit geoUnit, int count)
-
radiusWithDistanceAsync
<>> radiusWithDistanceAsync(double longitude, double latitude, double radius, GeoUnit geoUnit, GeoOrder geoOrder)
-
radiusWithDistanceAsync
<>> radiusWithDistanceAsync(double longitude, double latitude, double radius, GeoUnit geoUnit, GeoOrder geoOrder, int count)
-
searchWithPositionAsync
<V,GeoPosition>> searchWithPositionAsync(GeoSearchArgs args)
Returns the position mapped by member of a sorted set, which are within the borders of specified search conditions.Usage examples:
List objects = geo.searchWithPosition(GeoSearchArgs.from(15, 37) .radius(200, GeoUnit.KILOMETERS) .order(GeoOrder.ASC) .count(1)));
List objects = geo.searchWithPosition(GeoSearchArgs.from(15, 37) .radius(200, GeoUnit.KILOMETERS)));
Requires Redis 3.2.10 and higher.
- Parameters:
args
- - search conditions object- Returns:
- position mapped by object
-
radiusWithPositionAsync
<V,GeoPosition>> radiusWithPositionAsync(double longitude, double latitude, double radius, GeoUnit geoUnit)
-
radiusWithPositionAsync
<V,GeoPosition>> radiusWithPositionAsync(double longitude, double latitude, double radius, GeoUnit geoUnit, int count)
-
radiusWithPositionAsync
<V,GeoPosition>> radiusWithPositionAsync(double longitude, double latitude, double radius, GeoUnit geoUnit, GeoOrder geoOrder)
-
radiusWithPositionAsync
<V,GeoPosition>> radiusWithPositionAsync(double longitude, double latitude, double radius, GeoUnit geoUnit, GeoOrder geoOrder, int count)
-
radiusAsync
<V>> radiusAsync(V member, double radius, GeoUnit geoUnit, GeoOrder geoOrder)
Deprecated.
-
radiusAsync
<V>> radiusAsync(V member, double radius, GeoUnit geoUnit, GeoOrder geoOrder, int count)
Deprecated.
-
radiusWithDistanceAsync
<>> radiusWithDistanceAsync(V member, double radius, GeoUnit geoUnit, int count)
-
radiusWithDistanceAsync
<>> radiusWithDistanceAsync(V member, double radius, GeoUnit geoUnit, GeoOrder geoOrder)
-
radiusWithDistanceAsync
<>> radiusWithDistanceAsync(V member, double radius, GeoUnit geoUnit, GeoOrder geoOrder, int count)
-
radiusWithPositionAsync
<V,GeoPosition>> radiusWithPositionAsync(V member, double radius, GeoUnit geoUnit)
-
radiusWithPositionAsync
<V,GeoPosition>> radiusWithPositionAsync(V member, double radius, GeoUnit geoUnit, int count)
-
radiusWithPositionAsync
<V,GeoPosition>> radiusWithPositionAsync(V member, double radius, GeoUnit geoUnit, GeoOrder geoOrder)
-
radiusWithPositionAsync
<V,GeoPosition>> radiusWithPositionAsync(V member, double radius, GeoUnit geoUnit, GeoOrder geoOrder, int count)
-
storeSearchToAsync
> storeSearchToAsync( destName, GeoSearchArgs args)
Finds the members of a sorted set, which are within the borders of specified search conditions.Stores result to
destName
.Usage examples:
long count = geo.storeSearchTo(GeoSearchArgs.from(15, 37) .radius(200, GeoUnit.KILOMETERS) .order(GeoOrder.ASC) .count(1)));
long count = geo.storeSearchTo(GeoSearchArgs.from(15, 37) .radius(200, GeoUnit.KILOMETERS)));
- Parameters:
args
- - search conditions object- Returns:
- length of result
-
radiusStoreToAsync
> radiusStoreToAsync( destName, double longitude, double latitude, double radius, GeoUnit geoUnit)
Deprecated.
-
radiusStoreToAsync
> radiusStoreToAsync( destName, double longitude, double latitude, double radius, GeoUnit geoUnit, int count)
Deprecated.
-
radiusStoreToAsync
> radiusStoreToAsync( destName, double longitude, double latitude, double radius, GeoUnit geoUnit, GeoOrder geoOrder, int count)
Deprecated.
-
radiusStoreToAsync
> radiusStoreToAsync( destName, V member, double radius, GeoUnit geoUnit)
Deprecated.
-
radiusStoreToAsync
> radiusStoreToAsync( destName, V member, double radius, GeoUnit geoUnit, int count)
Deprecated.
-
radiusStoreToAsync
> radiusStoreToAsync( destName, V member, double radius, GeoUnit geoUnit, GeoOrder geoOrder, int count)
Deprecated.
-
storeSortedSearchToAsync
> storeSortedSearchToAsync( destName, GeoSearchArgs args)
Finds the members of a sorted set, which are within the borders of specified search conditions.Stores result to
destName
sorted by distance.Usage examples:
long count = geo.storeSortedSearchTo(GeoSearchArgs.from(15, 37) .radius(200, GeoUnit.KILOMETERS) .order(GeoOrder.ASC) .count(1)));
long count = geo.storeSortedSearchTo(GeoSearchArgs.from(15, 37) .radius(200, GeoUnit.KILOMETERS)));
- Parameters:
args
- - search conditions object- Returns:
- length of result
-
radiusStoreSortedToAsync
> radiusStoreSortedToAsync( destName, double longitude, double latitude, double radius, GeoUnit geoUnit)
-
radiusStoreSortedToAsync
> radiusStoreSortedToAsync( destName, double longitude, double latitude, double radius, GeoUnit geoUnit, int count)
-
radiusStoreSortedToAsync
> radiusStoreSortedToAsync( destName, double longitude, double latitude, double radius, GeoUnit geoUnit, GeoOrder geoOrder, int count)
-
radiusStoreSortedToAsync
> radiusStoreSortedToAsync( destName, V member, double radius, GeoUnit geoUnit)
-
radiusStoreSortedToAsync
> radiusStoreSortedToAsync( destName, V member, double radius, GeoUnit geoUnit, int count)
-
-