Package ratpack.exec

Interface ExecResult<T>

  • Type Parameters:
    T - the type of promised value
    All Superinterfaces:
    Result<T>

    public interface ExecResult<T>
    extends Result<T>
    The result of an execution.
    • 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