public abstract class JedisConverters extends Converters
Modifier and Type | Field and Description |
---|---|
static byte[] |
MINUS_BYTES |
static byte[] |
NEGATIVE_INFINITY_BYTES |
static byte[] |
PLUS_BYTES |
static byte[] |
POSITIVE_INFINITY_BYTES |
Constructor and Description |
---|
JedisConverters() |
Modifier and Type | Method and Description |
---|---|
static byte[] |
boundaryToBytesForZRange(RedisZSetCommands.Range.Boundary boundary,
byte[] defaultValue)
Converts a given
RedisZSetCommands.Range.Boundary to its binary representation suitable for ZRANGEBY* commands, despite
ZRANGEBYLEX. |
static byte[] |
boundaryToBytesForZRangeByLex(RedisZSetCommands.Range.Boundary boundary,
byte[] defaultValue)
Converts a given
RedisZSetCommands.Range.Boundary to its binary representation suitable for ZRANGEBYLEX command. |
static ListConverter<byte[],String> |
bytesListToStringListConverter()
Deprecated.
since 2.5
|
static Converter<Exception,DataAccessException> |
exceptionConverter() |
static ListConverter<redis.clients.jedis.GeoCoordinate,org.springframework.data.geo.Point> |
geoCoordinateToPointConverter()
Deprecated.
since 2.5
|
static Converter<List<redis.clients.jedis.GeoRadiusResponse>,org.springframework.data.geo.GeoResults<RedisGeoCommands.GeoLocation<byte[]>>> |
geoRadiusResponseToGeoResultsConverter(org.springframework.data.geo.Metric metric)
|
static ListConverter<byte[],Long> |
getBytesListToLongListConverter()
Deprecated.
since 2.5
|
static ListConverter<String,byte[]> |
stringListToByteList() |
static MapConverter<String,byte[]> |
stringMapToByteMap()
Deprecated.
since 2.5
|
static SetConverter<String,byte[]> |
stringSetToByteSet()
Deprecated.
since 2.5
|
static Converter<String,byte[]> |
stringToBytes() |
static byte[][] |
toBitfieldCommandArguments(BitFieldSubCommands source)
Convert given
BitFieldSubCommands into argument array. |
static redis.clients.jedis.BitOP |
toBitOp(RedisStringCommands.BitOperation bitOp) |
static byte[][] |
toByteArrays(Map<byte[],byte[]> source) |
static byte[] |
toBytes(Double source) |
static byte[] |
toBytes(Integer source) |
static byte[] |
toBytes(Long source) |
static byte[] |
toBytes(String source) |
static DataAccessException |
toDataAccessException(Exception ex)
Deprecated.
since 2.5
|
static ValueEncoding |
toEncoding(byte[] source)
Convert the given
source value to the corresponding ValueEncoding . |
static redis.clients.jedis.GeoCoordinate |
toGeoCoordinate(org.springframework.data.geo.Point source)
Convert
Point into GeoCoordinate . |
static redis.clients.jedis.params.GeoRadiusParam |
toGeoRadiusParam(RedisGeoCommands.GeoRadiusCommandArgs source)
Convert
RedisGeoCommands.GeoRadiusCommandArgs into GeoRadiusParam . |
static redis.clients.jedis.GeoUnit |
toGeoUnit(org.springframework.data.geo.Metric metric)
Convert
Metric into GeoUnit . |
static List<RedisClientInfo> |
toListOfRedisClientInformation(String source) |
static List<RedisServer> |
toListOfRedisServer(List<Map<String,String>> source) |
static redis.clients.jedis.ListPosition |
toListPosition(RedisListCommands.Position source) |
static Long |
toLong(byte[] source) |
static RedisClusterNode |
toNode(Object source) |
static redis.clients.jedis.ScanParams |
toScanParams(ScanOptions options)
Convert
ScanOptions to Jedis ScanParams . |
static redis.clients.jedis.params.SetParams |
toSetCommandExPxArgument(Expiration expiration)
Converts a given
Expiration to the according SET command argument. |
static redis.clients.jedis.params.SetParams |
toSetCommandExPxArgument(Expiration expiration,
redis.clients.jedis.params.SetParams params)
Converts a given
Expiration to the according SET command argument. |
static redis.clients.jedis.params.SetParams |
toSetCommandNxXxArgument(RedisStringCommands.SetOption option)
Converts a given
RedisStringCommands.SetOption to the according SET command argument. |
static redis.clients.jedis.params.SetParams |
toSetCommandNxXxArgument(RedisStringCommands.SetOption option,
redis.clients.jedis.params.SetParams params)
Converts a given
RedisStringCommands.SetOption to the according SET command argument. |
static redis.clients.jedis.SortingParams |
toSortingParams(SortParameters params) |
static String |
toString(byte[] source) |
static String[] |
toStrings(byte[][] source) |
static List<String> |
toStrings(List<byte[]> source) |
static RedisZSetCommands.Tuple |
toTuple(redis.clients.jedis.Tuple source) |
static Map<byte[],Double> |
toTupleMap(Set<RedisZSetCommands.Tuple> tuples)
|
static Set<RedisZSetCommands.Tuple> |
toTupleSet(Set<redis.clients.jedis.Tuple> source)
Deprecated.
since 2.5
|
static SetConverter<redis.clients.jedis.Tuple,RedisZSetCommands.Tuple> |
tupleSetToTupleSet()
Deprecated.
since 2.5
|
static ListConverter<redis.clients.jedis.Tuple,RedisZSetCommands.Tuple> |
tuplesToTuples()
|
deserializingGeoResultsConverter, distanceConverterForMetric, entryOf, identityConverter, listToPropertiesConverter, longToBoolean, mapToPropertiesConverter, millisecondsToTimeUnit, millisecondsToTimeUnit, parse, parse, secondsToDuration, secondsToTimeUnit, secondsToTimeUnit, stringToBoolean, stringToBooleanConverter, stringToDataType, stringToProps, toBit, toBoolean, toClusterNode, toDataType, toObjects, toProperties, toProperties, toProperties, toSetOfRedisClusterNodes, toSetOfRedisClusterNodes, toTimeMillis, toTimeMillis
public static final byte[] PLUS_BYTES
public static final byte[] MINUS_BYTES
public static final byte[] POSITIVE_INFINITY_BYTES
public static final byte[] NEGATIVE_INFINITY_BYTES
public static ListConverter<redis.clients.jedis.Tuple,RedisZSetCommands.Tuple> tuplesToTuples()
public static ListConverter<String,byte[]> stringListToByteList()
@Deprecated public static SetConverter<String,byte[]> stringSetToByteSet()
@Deprecated public static MapConverter<String,byte[]> stringMapToByteMap()
@Deprecated public static SetConverter<redis.clients.jedis.Tuple,RedisZSetCommands.Tuple> tupleSetToTupleSet()
public static Converter<Exception,DataAccessException> exceptionConverter()
public static String[] toStrings(byte[][] source)
@Deprecated public static Set<RedisZSetCommands.Tuple> toTupleSet(Set<redis.clients.jedis.Tuple> source)
public static RedisZSetCommands.Tuple toTuple(redis.clients.jedis.Tuple source)
public static Map<byte[],Double> toTupleMap(Set<RedisZSetCommands.Tuple> tuples)
tuples
- must not be null.public static byte[] toBytes(Integer source)
public static byte[] toBytes(Long source)
public static byte[] toBytes(Double source)
source
- public static Long toLong(byte[] source)
public static ValueEncoding toEncoding(byte[] source)
source
value to the corresponding ValueEncoding
.source
- can be null.ValueEncoding
for given source
. Never null.public static RedisClusterNode toNode(Object source)
source
- public static List<RedisClientInfo> toListOfRedisClientInformation(String source)
source
- public static List<RedisServer> toListOfRedisServer(List<Map<String,String>> source)
source
- @Deprecated public static DataAccessException toDataAccessException(Exception ex)
public static redis.clients.jedis.ListPosition toListPosition(RedisListCommands.Position source)
public static byte[][] toByteArrays(Map<byte[],byte[]> source)
@Nullable public static redis.clients.jedis.SortingParams toSortingParams(@Nullable SortParameters params)
public static redis.clients.jedis.BitOP toBitOp(RedisStringCommands.BitOperation bitOp)
public static byte[] boundaryToBytesForZRange(@Nullable RedisZSetCommands.Range.Boundary boundary, byte[] defaultValue)
RedisZSetCommands.Range.Boundary
to its binary representation suitable for ZRANGEBY* commands, despite
ZRANGEBYLEX.boundary
- defaultValue
- public static byte[] boundaryToBytesForZRangeByLex(@Nullable RedisZSetCommands.Range.Boundary boundary, byte[] defaultValue)
RedisZSetCommands.Range.Boundary
to its binary representation suitable for ZRANGEBYLEX command.boundary
- public static redis.clients.jedis.params.SetParams toSetCommandExPxArgument(Expiration expiration)
Expiration
to the according SET
command argument.
expiration
- must not be null.public static redis.clients.jedis.params.SetParams toSetCommandExPxArgument(Expiration expiration, redis.clients.jedis.params.SetParams params)
Expiration
to the according SET
command argument.
expiration
- must not be null.params
- public static redis.clients.jedis.params.SetParams toSetCommandNxXxArgument(RedisStringCommands.SetOption option)
option
- must not be null.public static redis.clients.jedis.params.SetParams toSetCommandNxXxArgument(RedisStringCommands.SetOption option, redis.clients.jedis.params.SetParams params)
option
- must not be null.params
- public static redis.clients.jedis.ScanParams toScanParams(ScanOptions options)
ScanOptions
to Jedis ScanParams
.options
- public static List<String> toStrings(List<byte[]> source)
source
- @Deprecated public static ListConverter<byte[],String> bytesListToStringListConverter()
@Deprecated public static ListConverter<byte[],Long> getBytesListToLongListConverter()
public static ListConverter<redis.clients.jedis.GeoCoordinate,org.springframework.data.geo.Point> geoCoordinateToPointConverter()
public static redis.clients.jedis.GeoCoordinate toGeoCoordinate(org.springframework.data.geo.Point source)
Point
into GeoCoordinate
.source
- public static Converter<List<redis.clients.jedis.GeoRadiusResponse>,org.springframework.data.geo.GeoResults<RedisGeoCommands.GeoLocation<byte[]>>> geoRadiusResponseToGeoResultsConverter(org.springframework.data.geo.Metric metric)
metric
- public static redis.clients.jedis.GeoUnit toGeoUnit(org.springframework.data.geo.Metric metric)
Metric
into GeoUnit
.metric
- public static redis.clients.jedis.params.GeoRadiusParam toGeoRadiusParam(RedisGeoCommands.GeoRadiusCommandArgs source)
RedisGeoCommands.GeoRadiusCommandArgs
into GeoRadiusParam
.source
- public static byte[][] toBitfieldCommandArguments(BitFieldSubCommands source)
BitFieldSubCommands
into argument array.source
- Copyright © 2011–2023 Pivotal Software, Inc.. All rights reserved.