K - key typeV - value typepublic interface RStream<K,V> extends RStreamAsync<K,V>, RExpirable
Requires Redis 5.0.0 and higher.
| Modifier and Type | Method and Description |
|---|---|
StreamId |
add(K key,
V value)
Appends a new entry and returns generated Stream ID
|
StreamId |
add(K key,
V value,
int trimLen,
boolean trimStrict)
Appends a new entry and returns generated Stream ID.
|
void |
add(StreamId id,
K key,
V value)
Appends a new entry by specified Stream ID
|
void |
add(StreamId id,
K key,
V value,
int trimLen,
boolean trimStrict)
Appends a new entry by specified Stream ID.
|
StreamId |
addAll(Map<K,V> entries)
Appends new entries and returns generated Stream ID
|
StreamId |
addAll(Map<K,V> entries,
int trimLen,
boolean trimStrict)
Appends new entries and returns generated Stream ID.
|
void |
addAll(StreamId id,
Map<K,V> entries)
Appends new entries by specified Stream ID
|
void |
addAll(StreamId id,
Map<K,V> entries,
int trimLen,
boolean trimStrict)
Appends new entries by specified Stream ID.
|
Map<StreamId,Map<K,V>> |
range(int count,
StreamId startId,
StreamId endId)
Read stream data in range by specified start Stream ID (included) and end Stream ID (included).
|
Map<StreamId,Map<K,V>> |
range(StreamId startId,
StreamId endId)
Read stream data in range by specified start Stream ID (included) and end Stream ID (included).
|
Map<StreamId,Map<K,V>> |
rangeReversed(int count,
StreamId startId,
StreamId endId)
Read stream data in reverse order in range by specified start Stream ID (included) and end Stream ID (included).
|
Map<StreamId,Map<K,V>> |
rangeReversed(StreamId startId,
StreamId endId)
Read stream data in reverse order in range by specified start Stream ID (included) and end Stream ID (included).
|
Map<String,Map<StreamId,Map<K,V>>> |
read(Collection<String> keys,
StreamId... ids)
Read stream data by specified collection of keys including this stream and Stream ID per key.
|
Map<String,Map<StreamId,Map<K,V>>> |
read(int count,
Collection<String> keys,
StreamId... ids)
Read stream data by specified collection of keys including this stream and Stream ID per key.
|
Map<String,Map<StreamId,Map<K,V>>> |
read(int count,
long timeout,
TimeUnit unit,
Collection<String> keys,
StreamId... ids)
Read stream data by specified collection of keys including this stream and Stream ID per key.
|
Map<StreamId,Map<K,V>> |
read(int count,
long timeout,
TimeUnit unit,
StreamId... ids)
Read stream data by specified collection of Stream IDs.
|
Map<StreamId,Map<K,V>> |
read(int count,
StreamId... ids)
Read stream data by specified collection of Stream IDs.
|
Map<String,Map<StreamId,Map<K,V>>> |
read(long timeout,
TimeUnit unit,
Collection<String> keys,
StreamId... ids)
Read stream data by specified collection of keys including this stream and Stream ID per key.
|
Map<StreamId,Map<K,V>> |
read(long timeout,
TimeUnit unit,
StreamId... ids)
Read stream data by specified collection of Stream IDs.
|
Map<StreamId,Map<K,V>> |
read(StreamId... ids)
Read stream data by specified collection of Stream IDs.
|
long |
size()
Returns number of entries in stream
|
addAllAsync, addAllAsync, addAllAsync, addAllAsync, addAsync, addAsync, addAsync, addAsync, rangeAsync, rangeAsync, rangeReversedAsync, rangeReversedAsync, readAsync, readAsync, readAsync, readAsync, readAsync, readAsync, readAsync, readAsync, sizeAsyncclearExpire, expire, expireAt, expireAt, remainTimeToLivecopy, delete, getCodec, getName, isExists, migrate, move, rename, renamenx, touch, unlinkclearExpireAsync, expireAsync, expireAtAsync, expireAtAsync, remainTimeToLiveAsynccopyAsync, deleteAsync, isExistsAsync, migrateAsync, moveAsync, renameAsync, renamenxAsync, touchAsync, unlinkAsynclong size()
StreamId add(K key, V value)
key - - key of entryvalue - - value of entryvoid add(StreamId id, K key, V value)
id - - Stream IDkey - - key of entryvalue - - value of entryStreamId add(K key, V value, int trimLen, boolean trimStrict)
trimLen size.
If trimStrict is false then trims to few tens of entries more than specified length to trim.key - - key of entryvalue - - value of entrytrimLen - - length to trimtrimStrict - - if false then trims to few tens of entries more than specified length to trimvoid add(StreamId id, K key, V value, int trimLen, boolean trimStrict)
trimLen size.
If trimStrict is false then trims to few tens of entries more than specified length to trim.id - - Stream IDkey - - key of entryvalue - - value of entrytrimLen - - length to trimtrimStrict - - if false then trims to few tens of entries more than specified length to trimStreamId addAll(Map<K,V> entries)
entries - - entries to addvoid addAll(StreamId id, Map<K,V> entries)
id - - Stream IDentries - - entries to addStreamId addAll(Map<K,V> entries, int trimLen, boolean trimStrict)
trimLen size.
If trimStrict is false then trims to few tens of entries more than specified length to trim.entries - - entries to addtrimLen - - length to trimtrimStrict - - if false then trims to few tens of entries more than specified length to trimvoid addAll(StreamId id, Map<K,V> entries, int trimLen, boolean trimStrict)
trimLen size.
If trimStrict is false then trims to few tens of entries more than specified length to trim.id - - Stream IDentries - - entries to addtrimLen - - length to trimtrimStrict - - if false then trims to few tens of entries more than specified length to trimMap<StreamId,Map<K,V>> read(StreamId... ids)
ids - - collection of Stream IDsMap<StreamId,Map<K,V>> read(int count, StreamId... ids)
count - - stream data size limitids - - collection of Stream IDsMap<StreamId,Map<K,V>> read(long timeout, TimeUnit unit, StreamId... ids)
timeout interval.timeout - - time interval to wait for stream data availabilityunit - - time interval unitids - - collection of Stream IDsMap<StreamId,Map<K,V>> read(int count, long timeout, TimeUnit unit, StreamId... ids)
timeout interval.count - - stream data size limittimeout - - time interval to wait for stream data availabilityunit - - time interval unitids - - collection of Stream IDsMap<String,Map<StreamId,Map<K,V>>> read(Collection<String> keys, StreamId... ids)
keys - - collection of keysids - - collection of Stream IDsMap<String,Map<StreamId,Map<K,V>>> read(int count, Collection<String> keys, StreamId... ids)
count - - stream data size limitkeys - - collection of keysids - - collection of Stream IDsMap<String,Map<StreamId,Map<K,V>>> read(long timeout, TimeUnit unit, Collection<String> keys, StreamId... ids)
timeout interval.timeout - - time interval to wait for stream data availabilityunit - - time interval unitkeys - - collection of keysids - - collection of Stream IDsMap<String,Map<StreamId,Map<K,V>>> read(int count, long timeout, TimeUnit unit, Collection<String> keys, StreamId... ids)
timeout interval.count - - stream data size limittimeout - - time interval to wait for stream data availabilityunit - - time interval unitkeys - - collection of keysids - - collection of Stream IDsMap<StreamId,Map<K,V>> range(StreamId startId, StreamId endId)
startId - - start Stream IDendId - - end Stream IDMap<StreamId,Map<K,V>> range(int count, StreamId startId, StreamId endId)
count - - stream data size limitstartId - - start Stream IDendId - - end Stream IDMap<StreamId,Map<K,V>> rangeReversed(StreamId startId, StreamId endId)
startId - - start Stream IDendId - - end Stream IDMap<StreamId,Map<K,V>> rangeReversed(int count, StreamId startId, StreamId endId)
count - - stream data size limitstartId - - start Stream IDendId - - end Stream IDCopyright © 2014–2018 The Redisson Project. All rights reserved.