Class TransactionResultImpl
- java.lang.Object
-
- io.quarkus.redis.runtime.datasource.TransactionResultImpl
-
- All Implemented Interfaces:
TransactionResult,Iterable<Object>
public class TransactionResultImpl extends Object implements TransactionResult
-
-
Field Summary
Fields Modifier and Type Field Description static TransactionResultDISCARDED
-
Constructor Summary
Constructors Constructor Description TransactionResultImpl(boolean discarded, List<Object> res)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleandiscarded()Checks if the transaction was discarded (rolled back)<T> Tget(int index)Returns the response at the specified position in thisTransactionResult.booleanisEmpty()Returnstrueif thisTransactionResultcontains no responses.Iterator<Object>iterator()intsize()Returns the number of responses.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface java.lang.Iterable
forEach, spliterator
-
-
-
-
Field Detail
-
DISCARDED
public static final TransactionResult DISCARDED
-
-
Method Detail
-
discarded
public boolean discarded()
Description copied from interface:TransactionResultChecks if the transaction was discarded (rolled back)- Specified by:
discardedin interfaceTransactionResult- Returns:
trueif the transaction batch was discarded.
-
size
public int size()
Description copied from interface:TransactionResultReturns the number of responses.- Specified by:
sizein interfaceTransactionResult- Returns:
- the number of responses
-
isEmpty
public boolean isEmpty()
Description copied from interface:TransactionResultReturnstrueif thisTransactionResultcontains no responses.- Specified by:
isEmptyin interfaceTransactionResult- Returns:
trueif thisTransactionResultcontains no responses
-
get
public <T> T get(int index)
Description copied from interface:TransactionResultReturns the response at the specified position in thisTransactionResult. It contains the result of the commands executed at the same position in the transaction.- Specified by:
getin interfaceTransactionResult- Type Parameters:
T- the expected type- Parameters:
index- index of the element to return- Returns:
- the element at the specified position in this
TransactionResult
-
-