K
- Key type.V
- Value type.public interface NodeSelectionStringAsyncCommands<K,V>
Modifier and Type | Method and Description |
---|---|
AsyncExecutions<Long> |
append(K key,
V value)
Append a value to a key.
|
AsyncExecutions<Long> |
bitcount(K key)
Count set bits in a string.
|
AsyncExecutions<Long> |
bitcount(K key,
long start,
long end)
Count set bits in a string.
|
AsyncExecutions<List<Long>> |
bitfield(K key,
BitFieldArgs bitFieldArgs)
Execute
BITFIELD with its subcommands. |
AsyncExecutions<Long> |
bitopAnd(K destination,
K... keys)
Perform bitwise AND between strings.
|
AsyncExecutions<Long> |
bitopNot(K destination,
K source)
Perform bitwise NOT between strings.
|
AsyncExecutions<Long> |
bitopOr(K destination,
K... keys)
Perform bitwise OR between strings.
|
AsyncExecutions<Long> |
bitopXor(K destination,
K... keys)
Perform bitwise XOR between strings.
|
AsyncExecutions<Long> |
bitpos(K key,
boolean state)
Find first bit set or clear in a string.
|
AsyncExecutions<Long> |
bitpos(K key,
boolean state,
long start)
Find first bit set or clear in a string.
|
AsyncExecutions<Long> |
bitpos(K key,
boolean state,
long start,
long end)
Find first bit set or clear in a string.
|
AsyncExecutions<Long> |
decr(K key)
Decrement the integer value of a key by one.
|
AsyncExecutions<Long> |
decrby(K key,
long amount)
Decrement the integer value of a key by the given number.
|
AsyncExecutions<V> |
get(K key)
Get the value of a key.
|
AsyncExecutions<Long> |
getbit(K key,
long offset)
Returns the bit value at offset in the string value stored at key.
|
AsyncExecutions<V> |
getrange(K key,
long start,
long end)
Get a substring of the string stored at a key.
|
AsyncExecutions<V> |
getset(K key,
V value)
Set the string value of a key and return its old value.
|
AsyncExecutions<Long> |
incr(K key)
Increment the integer value of a key by one.
|
AsyncExecutions<Long> |
incrby(K key,
long amount)
Increment the integer value of a key by the given amount.
|
AsyncExecutions<Double> |
incrbyfloat(K key,
double amount)
Increment the float value of a key by the given amount.
|
AsyncExecutions<List<KeyValue<K,V>>> |
mget(K... keys)
Get the values of all the given keys.
|
AsyncExecutions<Long> |
mget(KeyValueStreamingChannel<K,V> channel,
K... keys)
Stream over the values of all the given keys.
|
AsyncExecutions<String> |
mset(Map<K,V> map)
Set multiple keys to multiple values.
|
AsyncExecutions<Boolean> |
msetnx(Map<K,V> map)
Set multiple keys to multiple values, only if none of the keys exist.
|
AsyncExecutions<String> |
psetex(K key,
long milliseconds,
V value)
Set the value and expiration in milliseconds of a key.
|
AsyncExecutions<String> |
set(K key,
V value)
Set the string value of a key.
|
AsyncExecutions<String> |
set(K key,
V value,
SetArgs setArgs)
Set the string value of a key.
|
AsyncExecutions<Long> |
setbit(K key,
long offset,
int value)
Sets or clears the bit at offset in the string value stored at key.
|
AsyncExecutions<String> |
setex(K key,
long seconds,
V value)
Set the value and expiration of a key.
|
AsyncExecutions<Boolean> |
setnx(K key,
V value)
Set the value of a key, only if the key does not exist.
|
AsyncExecutions<Long> |
setrange(K key,
long offset,
V value)
Overwrite part of a string at key starting at the specified offset.
|
AsyncExecutions<Long> |
strlen(K key)
Get the length of the value stored in a key.
|
AsyncExecutions<Long> append(K key, V value)
key
- the keyvalue
- the valueAsyncExecutions<Long> bitcount(K key)
key
- the keyAsyncExecutions<Long> bitcount(K key, long start, long end)
key
- the keystart
- the startend
- the endAsyncExecutions<List<Long>> bitfield(K key, BitFieldArgs bitFieldArgs)
BITFIELD
with its subcommands.key
- the keybitFieldArgs
- the args containing subcommands, must not be null.AsyncExecutions<Long> bitpos(K key, boolean state)
key
- the keystate
- the stateBITPOS key 0
will return 24, since up to bit 23 all the bits are 1.
Basically the function consider the right of the string as padded with zeros if you look for clear bits and
specify no range or the start argument only.AsyncExecutions<Long> bitpos(K key, boolean state, long start)
key
- the keystate
- the bit type: longstart
- the start type: longBITPOS key 0
will return 24, since up to bit 23 all the bits are 1.
Basically the function consider the right of the string as padded with zeros if you look for clear bits and
specify no range or the start argument only.AsyncExecutions<Long> bitpos(K key, boolean state, long start, long end)
key
- the keystate
- the bit type: longstart
- the start type: longend
- the end type: longBITPOS key 0
will return 24, since up to bit 23 all the bits are 1.
Basically the function consider the right of the string as padded with zeros if you look for clear bits and
specify no range or the start argument only.
However this behavior changes if you are looking for clear bits and specify a range with both
start and end. If no clear bit is found in the specified range, the function
returns -1 as the user specified a clear range and there are no 0 bits in that range.AsyncExecutions<Long> bitopAnd(K destination, K... keys)
destination
- result key of the operationkeys
- operation input key namesAsyncExecutions<Long> bitopNot(K destination, K source)
destination
- result key of the operationsource
- operation input key namesAsyncExecutions<Long> bitopOr(K destination, K... keys)
destination
- result key of the operationkeys
- operation input key namesAsyncExecutions<Long> bitopXor(K destination, K... keys)
destination
- result key of the operationkeys
- operation input key namesAsyncExecutions<Long> decr(K key)
key
- the keykey
after the decrementAsyncExecutions<Long> decrby(K key, long amount)
key
- the keyamount
- the decrement type: longkey
after the decrementAsyncExecutions<V> get(K key)
key
- the keykey
, or null when key
does not exist.AsyncExecutions<Long> getbit(K key, long offset)
key
- the keyoffset
- the offset type: longAsyncExecutions<V> getrange(K key, long start, long end)
key
- the keystart
- the start type: longend
- the end type: longAsyncExecutions<V> getset(K key, V value)
key
- the keyvalue
- the valuekey
, or null when key
did not exist.AsyncExecutions<Long> incr(K key)
key
- the keykey
after the incrementAsyncExecutions<Long> incrby(K key, long amount)
key
- the keyamount
- the increment type: longkey
after the incrementAsyncExecutions<Double> incrbyfloat(K key, double amount)
key
- the keyamount
- the increment type: doublekey
after the increment.AsyncExecutions<List<KeyValue<K,V>>> mget(K... keys)
keys
- the keyAsyncExecutions<Long> mget(KeyValueStreamingChannel<K,V> channel, K... keys)
channel
- the channelkeys
- the keysAsyncExecutions<String> mset(Map<K,V> map)
map
- the nullOK
since MSET
can't fail.AsyncExecutions<Boolean> msetnx(Map<K,V> map)
map
- the null1
if the all the keys were set. 0
if no key was set (at least one key already existed).AsyncExecutions<String> set(K key, V value)
key
- the keyvalue
- the valueOK
if SET
was executed correctly.AsyncExecutions<String> set(K key, V value, SetArgs setArgs)
key
- the keyvalue
- the valuesetArgs
- the setArgsOK
if SET
was executed correctly.AsyncExecutions<Long> setbit(K key, long offset, int value)
key
- the keyoffset
- the offset type: longvalue
- the value type: stringAsyncExecutions<String> setex(K key, long seconds, V value)
key
- the keyseconds
- the seconds type: longvalue
- the valueAsyncExecutions<String> psetex(K key, long milliseconds, V value)
key
- the keymilliseconds
- the milliseconds type: longvalue
- the valueAsyncExecutions<Boolean> setnx(K key, V value)
key
- the keyvalue
- the value1
if the key was set 0
if the key was not setAsyncExecutions<Long> setrange(K key, long offset, V value)
key
- the keyoffset
- the offset type: longvalue
- the valueAsyncExecutions<Long> strlen(K key)
key
- the keykey
, or 0
when key
does not exist.Copyright © 2019 lettuce.io. All rights reserved.