Package ratpack.exec
Interface ExecResult<T>
-
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Modifier and Type Method Description static <T> ExecResult<T>
complete()
Returns a complete exec result.boolean
isComplete()
Is the result that the execution completed without a value being returned.static <T> ExecResult<T>
of(Result<T> result)
Wraps the given result as an exec result.-
Methods inherited from interface ratpack.exec.Result
getThrowable, getValue, getValueOrThrow, isError, isSuccess
-
-
-
-
Method Detail
-
isComplete
boolean isComplete()
Is the result that the execution completed without a value being returned.This can happen if the promise was
routed
instead of being returned to the caller, or if the promise failed and the error was handled “upstream”. In such a case, the code under test handled the promised value. As the promise producing code dealt with the value, the tests will have to examine the side affects of this occurring.- Returns:
- true if the execution the promise was bound to completed before the promised value was provided.
-
of
static <T> ExecResult<T> of(Result<T> result)
Wraps the given result as an exec result.- Type Parameters:
T
- the type of value- Parameters:
result
- the result- Returns:
- the given result as an exec result
- Since:
- 1.2
-
complete
static <T> ExecResult<T> complete()
Returns a complete exec result.- Type Parameters:
T
- the type of value- Returns:
- a complete exec result
- Since:
- 1.2
-
-