public interface TransactionResult extends Iterable<Object>
MULTI
transaction result. TransactionResult
contains whether the transaction was rolled
back (i.e. conditional transaction using WATCH
) and the List
of transaction responses.Modifier and Type | Method and Description |
---|---|
<T> T |
get(int index)
Returns the element at the specified position in this
TransactionResult . |
boolean |
isEmpty()
Returns true if this
TransactionResult contains no elements. |
int |
size()
Returns the number of elements in this collection.
|
Stream<Object> |
stream()
Returns a sequential
Stream with this TransactionResult as its source. |
boolean |
wasDiscarded() |
default boolean |
wasRolledBack()
Deprecated.
use renamed method
wasDiscarded() as Redis has no notion of rollback. |
forEach, iterator, spliterator
boolean wasDiscarded()
@Deprecated default boolean wasRolledBack()
wasDiscarded()
as Redis has no notion of rollback.int size()
TransactionResult
contains more than
Integer.MAX_VALUE
elements, returns Integer.MAX_VALUE
.boolean isEmpty()
TransactionResult
contains no elements.TransactionResult
contains no elements<T> T get(int index)
TransactionResult
.T
- inferred typeindex
- index of the element to returnTransactionResult
IndexOutOfBoundsException
- if the index is out of range (index < 0 || index >= size())Stream<Object> stream()
Stream
with this TransactionResult
as its source.Stream
over the elements in this TransactionResult
Copyright © 2019 lettuce.io. All rights reserved.