public interface ArrayPipelineBinaryCommands
| Modifier and Type | Method and Description |
|---|---|
Response<java.lang.Long> |
arcount(byte[] key)
ARCOUNT Command Returns the number of
non-empty elements in an array.
|
Response<java.lang.Long> |
ardel(byte[] key,
long... indices)
ARDEL Command Deletes elements at the
specified indices in an array.
|
Response<java.lang.Long> |
ardel(byte[] key,
long index)
ARDEL Command Deletes the element at a
single index in an array.
|
Response<java.lang.Long> |
ardelrange(byte[] key,
long start,
long end)
ARDELRANGE Command Convenience
single-range overload of
ardelrange(byte[], LongRange...). |
Response<java.lang.Long> |
ardelrange(byte[] key,
LongRange... ranges)
ARDELRANGE Command Deletes elements
in one or more inclusive
LongRange ranges of indices. |
Response<byte[]> |
arget(byte[] key,
long index)
ARGET Command Returns the value stored at
a single index in an array.
|
Response<java.util.List<byte[]>> |
argetrange(byte[] key,
long start,
long end)
ARGETRANGE Command Returns the values
at a contiguous range of indices.
|
Response<java.util.List<java.lang.Long>> |
argrep(byte[] key,
ArgrepParams params)
ARGREP Command Searches array elements
within an inclusive index range (carried by
ArgrepParams) using one or more textual
predicates and returns the matching indices. |
Response<java.util.List<KeyValue<java.lang.Long,byte[]>>> |
argrepWithValues(byte[] key,
ArgrepParams params)
ARGREP Command Searches array elements
within an inclusive index range (carried by
ArgrepParams) and returns the matching
index/value pairs. |
Response<ArrayInfo> |
arinfo(byte[] key)
ARINFO Command Returns metadata
describing an array.
|
Response<ArrayFullInfo> |
arinfoFull(byte[] key)
ARINFO Command Returns the
FULL
variant of the array metadata. |
Response<java.lang.Long> |
arinsert(byte[] key,
byte[]... values)
ARINSERT Command Inserts one or more
values at consecutive indices beginning at the current insert cursor position.
|
Response<java.lang.Long> |
arinsert(byte[] key,
byte[] value)
ARINSERT Command Convenience
single-value overload of
arinsert(byte[], byte[]...). |
Response<java.util.List<byte[]>> |
arlastitems(byte[] key,
long count)
ARLASTITEMS Command Returns the most
recently inserted elements in oldest-first order.
|
Response<java.util.List<byte[]>> |
arlastitems(byte[] key,
long count,
boolean rev)
ARLASTITEMS Command Returns the most
recently inserted elements.
|
Response<java.lang.Long> |
arlen(byte[] key)
ARLEN Command Returns the length of an
array (max index + 1).
|
Response<java.util.List<byte[]>> |
armget(byte[] key,
long... indices)
ARMGET Command Returns the values at
multiple indices.
|
Response<java.lang.Long> |
armset(byte[] key,
java.util.Map<java.lang.Long,byte[]> indexValueMap)
ARMSET Command Sets multiple index-value
pairs.
|
Response<java.lang.Long> |
arnext(byte[] key)
ARNEXT Command Returns the next index
that
ARINSERT would use. |
Response<byte[]> |
aropAggregate(byte[] key,
long start,
long end,
ArrayAggregate op)
AROP Command Applies a numeric aggregate
over the non-empty elements in the inclusive
[start, end] range. |
Response<java.lang.Long> |
aropBitwise(byte[] key,
long start,
long end,
ArrayBitwise op)
AROP Command Applies a bitwise operation
over the non-empty elements in the inclusive
[start, end] range. |
Response<java.lang.Long> |
aropCount(byte[] key,
long start,
long end)
AROP Command Counts the number of non-empty
elements in the inclusive
[start, end] range using the USED subcommand. |
Response<java.lang.Long> |
aropCount(byte[] key,
long start,
long end,
byte[] match)
AROP Command Counts elements in the
inclusive
[start, end] range whose value equals match using the MATCH
subcommand. |
Response<java.lang.Long> |
arring(byte[] key,
long size,
byte[]... values)
ARRING Command Inserts one or more values
into an array as a fixed-size ring buffer.
|
Response<java.lang.Long> |
arring(byte[] key,
long size,
byte[] value)
ARRING Command Convenience single-value
overload of
arring(byte[], long, byte[]...). |
Response<java.util.List<KeyValue<java.lang.Long,byte[]>>> |
arscan(byte[] key,
long start,
long end)
ARSCAN Command Iterates existing elements
in an inclusive index range and returns the index/value pairs.
|
Response<java.util.List<KeyValue<java.lang.Long,byte[]>>> |
arscan(byte[] key,
long start,
long end,
long limit)
ARSCAN Command Iterates existing elements
in an inclusive index range with a cap on the number of pairs returned.
|
Response<java.lang.Long> |
arseek(byte[] key,
long index)
ARSEEK Command Sets the insert cursor of
an array to a specific index.
|
Response<java.lang.Long> |
arset(byte[] key,
long index,
byte[]... values)
ARSET Command Sets one or more contiguous
values starting at
index. |
Response<java.lang.Long> |
arset(byte[] key,
long index,
byte[] value)
ARSET Command Convenience single-value
overload of
arset(byte[], long, byte[]...). |
@Experimental Response<java.lang.Long> arcount(byte[] key)
Time complexity: O(1)
Wire: ARCOUNT key
key - the name of the key that holds the arrayResponse that resolves to the number of non-empty elements, or 0 if
key does not exist@Experimental Response<java.lang.Long> ardel(byte[] key, long index)
Time complexity: O(1)
Wire: ARDEL key index
key - the name of the key that holds the arrayindex - the zero-based index to deleteResponse that resolves to 1 if an element was deleted, 0
otherwise@Experimental Response<java.lang.Long> ardel(byte[] key, long... indices)
Time complexity: O(N) where N is the number of indices supplied.
Wire: ARDEL key index1 [index2 ...]
key - the name of the key that holds the arrayindices - one or more zero-based indices to deleteResponse that resolves to the number of elements actually deleted@Experimental Response<java.lang.Long> ardelrange(byte[] key, LongRange... ranges)
LongRange ranges of indices.
Time complexity: O(M + N) where M is the number of ranges and N the total number of elements they cover.
Wire: ARDELRANGE key r1.start r1.end [r2.start r2.end ...]
key - the name of the key that holds the arrayranges - one or more inclusive index rangesResponse that resolves to the number of elements deleted@Experimental Response<java.lang.Long> ardelrange(byte[] key, long start, long end)
ardelrange(byte[], LongRange...).
Wire: ARDELRANGE key start end
key - the name of the key that holds the arraystart - zero-based start index (inclusive)end - zero-based end index (inclusive)Response that resolves to the number of elements deleted@Experimental Response<byte[]> arget(byte[] key, long index)
Time complexity: O(1)
Wire: ARGET key index
key - the name of the key that holds the arrayindex - the zero-based index of the element to retrieveResponse that resolves to the value at the given index, or null if
the key or index does not exist@Experimental Response<java.util.List<byte[]>> argetrange(byte[] key, long start, long end)
Time complexity: O(N) where N is the number of elements in the range.
Wire: ARGETRANGE key start end
key - the name of the key that holds the arraystart - zero-based start index of the rangeend - zero-based end index of the range (inclusive)Response that resolves to the list of values in traversal order; empty slots
appear as null entries@Experimental Response<java.util.List<java.lang.Long>> argrep(byte[] key, ArgrepParams params)
ArgrepParams) using one or more textual
predicates and returns the matching indices.
Time complexity: O(N) where N is the number of elements scanned.
Wire: ARGREP key start end <params>
key - the name of the key that holds the arrayparams - the search range, predicates and options to applyResponse that resolves to the matching indices in traversal order@Experimental Response<java.util.List<KeyValue<java.lang.Long,byte[]>>> argrepWithValues(byte[] key, ArgrepParams params)
ArgrepParams) and returns the matching
index/value pairs.
Time complexity: O(N) where N is the number of elements scanned.
Wire: ARGREP key start end <params> WITHVALUES
key - the name of the key that holds the arrayparams - the search range, predicates and options to applyResponse that resolves to the matching index/value pairs@Experimental Response<ArrayInfo> arinfo(byte[] key)
@Experimental Response<ArrayFullInfo> arinfoFull(byte[] key)
FULL
variant of the array metadata.
Time complexity: O(S) where S is the number of slices.
Wire: ARINFO key FULL
key - the name of the key that holds the arrayResponse that resolves to a typed ArrayFullInfo, or null if
the key does not exist@Experimental Response<java.lang.Long> arinsert(byte[] key, byte[]... values)
Time complexity: O(N) where N is the number of values inserted.
Wire: ARINSERT key value1 [value2 ...]
key - the name of the key that holds the arrayvalues - one or more values to insertResponse that resolves to the last index at which a value was inserted@Experimental Response<java.lang.Long> arinsert(byte[] key, byte[] value)
arinsert(byte[], byte[]...).
Wire: ARINSERT key value
key - the name of the key that holds the arrayvalue - the value to insertResponse that resolves to the index at which the value was inserted@Experimental Response<java.util.List<byte[]>> arlastitems(byte[] key, long count)
Time complexity: O(N) where N is the number of returned elements.
Wire: ARLASTITEMS key count
key - the name of the key that holds the arraycount - the maximum number of elements to returnResponse that resolves to the list of last-inserted values@Experimental Response<java.util.List<byte[]>> arlastitems(byte[] key, long count, boolean rev)
rev is true, elements are returned in reverse
chronological order.
Time complexity: O(N) where N is the number of returned elements.
Wire: ARLASTITEMS key count [REV]
key - the name of the key that holds the arraycount - the maximum number of elements to returnrev - whether to request the REV variantResponse that resolves to the list of last-inserted values@Experimental Response<java.lang.Long> arlen(byte[] key)
key - the name of the key that holds the arrayResponse that resolves to the array length, or 0 if the key does not
exist@Experimental Response<java.util.List<byte[]>> armget(byte[] key, long... indices)
Time complexity: O(N) where N is the number of requested indices.
Wire: ARMGET key index1 [index2 ...]
key - the name of the key that holds the arrayindices - one or more zero-based indices to retrieveResponse that resolves to the list of values aligned with indices;
missing slots appear as null@Experimental Response<java.lang.Long> armset(byte[] key, java.util.Map<java.lang.Long,byte[]> indexValueMap)
Time complexity: O(N) where N is the number of pairs.
Wire: ARMSET key index1 value1 [index2 value2 ...]
key - the name of the key that holds the arrayindexValueMap - the index-to-value pairs to writeResponse that resolves to the number of slots that were previously empty@Experimental Response<java.lang.Long> arnext(byte[] key)
ARINSERT would use.
Time complexity: O(1)
Wire: ARNEXT key
key - the name of the key that holds the arrayResponse that resolves to 0L for missing keys, the next insert index
when one is available, or null when the cursor is exhausted@Experimental Response<java.lang.Long> aropBitwise(byte[] key, long start, long end, ArrayBitwise op)
[start, end] range.
Time complexity: O(N) where N is the number of elements scanned.
Wire: AROP key start end AND|OR|XOR
key - the name of the key that holds the arraystart - zero-based start index (inclusive)end - zero-based end index (inclusive)op - the bitwise operator to applyResponse that resolves to the operation's numeric result@Experimental Response<byte[]> aropAggregate(byte[] key, long start, long end, ArrayAggregate op)
[start, end] range.
Time complexity: O(N) where N is the number of elements scanned.
Wire: AROP key start end SUM|MIN|MAX
key - the name of the key that holds the arraystart - zero-based start index (inclusive)end - zero-based end index (inclusive)op - the aggregate operator to applyResponse that resolves to the aggregate value as raw bytes, or null
when the range is empty@Experimental Response<java.lang.Long> aropCount(byte[] key, long start, long end)
[start, end] range using the USED subcommand.
Time complexity: O(N) where N is the number of elements scanned.
Wire: AROP key start end USED
key - the name of the key that holds the arraystart - zero-based start index (inclusive)end - zero-based end index (inclusive)Response that resolves to the count of non-empty elements@Experimental Response<java.lang.Long> aropCount(byte[] key, long start, long end, byte[] match)
[start, end] range whose value equals match using the MATCH
subcommand.
Time complexity: O(N) where N is the number of elements scanned.
Wire: AROP key start end MATCH match
key - the name of the key that holds the arraystart - zero-based start index (inclusive)end - zero-based end index (inclusive)match - the value to matchResponse that resolves to the count of matching elements@Experimental Response<java.lang.Long> arring(byte[] key, long size, byte[]... values)
Time complexity: O(N) where N is the number of values inserted.
Wire: ARRING key size value1 [value2 ...]
key - the name of the key that holds the arraysize - the ring buffer window sizevalues - one or more values to insertResponse that resolves to the last index at which a value was inserted@Experimental Response<java.lang.Long> arring(byte[] key, long size, byte[] value)
arring(byte[], long, byte[]...).
Wire: ARRING key size value
key - the name of the key that holds the arraysize - the ring buffer window sizevalue - the value to insertResponse that resolves to the index at which the value was inserted@Experimental Response<java.util.List<KeyValue<java.lang.Long,byte[]>>> arscan(byte[] key, long start, long end)
Time complexity: O(N) where N is the number of populated elements.
Wire: ARSCAN key start end
key - the name of the key that holds the arraystart - zero-based start index; when start > end the iteration is reversedend - zero-based end index (inclusive)Response that resolves to the populated (index, value) pairs@Experimental Response<java.util.List<KeyValue<java.lang.Long,byte[]>>> arscan(byte[] key, long start, long end, long limit)
Time complexity: O(N) where N is the number of populated elements returned.
Wire: ARSCAN key start end LIMIT limit
key - the name of the key that holds the arraystart - zero-based start index; when start > end the iteration is reversedend - zero-based end index (inclusive)limit - cap on the number of returned populated elementsResponse that resolves to the populated (index, value) pairs@Experimental Response<java.lang.Long> arseek(byte[] key, long index)
Time complexity: O(1)
Wire: ARSEEK key index
key - the name of the key that holds the arrayindex - the zero-based index to set as the new insert cursorResponse that resolves to 1 if the cursor was set, 0 if the
key does not exist@Experimental Response<java.lang.Long> arset(byte[] key, long index, byte[]... values)
index.
Time complexity: O(N) where N is the number of values written.
Wire: ARSET key index value1 [value2 ...]
key - the name of the key that holds the arrayindex - zero-based starting indexvalues - one or more values to write at consecutive indicesResponse that resolves to the number of slots that were previously empty@Experimental Response<java.lang.Long> arset(byte[] key, long index, byte[] value)
arset(byte[], long, byte[]...).
Wire: ARSET key index value
key - the name of the key that holds the arrayindex - zero-based index at which to store the valuevalue - the value to writeResponse that resolves to the number of slots that were previously emptyCopyright © 2026. All rights reserved.