DATATYPE - Main object value type.public class JPAExecutionResult<DATATYPE>
extends com.phloc.commons.state.impl.SuccessWithValue<DATATYPE>
| Constructor and Description |
|---|
JPAExecutionResult(com.phloc.commons.state.ISuccessIndicator aSuccessIndicator,
DATATYPE aObj,
Throwable aThrowable) |
| Modifier and Type | Method and Description |
|---|---|
static <T> JPAExecutionResult<T> |
createFailure(Throwable t) |
static <T> JPAExecutionResult<T> |
createSuccess(T aObj) |
boolean |
equals(Object o) |
DATATYPE |
getOrThrow() |
Throwable |
getThrowable() |
int |
hashCode() |
boolean |
hasThrowable() |
String |
toString() |
@Nullable public Throwable getThrowable()
null.hasThrowable()public boolean hasThrowable()
true if an exception is present, false if
not.getThrowable()@Nullable public DATATYPE getOrThrow() throws Throwable
Throwable - if a Throwable is presentSuccessWithValue.get(),
hasThrowable(),
getThrowable()public boolean equals(Object o)
equals in class com.phloc.commons.state.impl.SuccessWithValue<DATATYPE>public int hashCode()
hashCode in class com.phloc.commons.state.impl.SuccessWithValue<DATATYPE>public String toString()
toString in class com.phloc.commons.state.impl.SuccessWithValue<DATATYPE>@Nonnull public static <T> JPAExecutionResult<T> createSuccess(@Nonnull T aObj)
@Nonnull public static <T> JPAExecutionResult<T> createFailure(@Nullable Throwable t)
Copyright © 2006–2015 phloc systems. All rights reserved.