Class AnswerException

All Implemented Interfaces:
Serializable, ControlFlowRuntimeException

public class AnswerException extends LightweightError implements ControlFlowRuntimeException
This exception will be thrown when an answer continuation is triggered.
Since:
1.0
See Also:
  • Constructor Details

    • AnswerException

      public AnswerException(ContinuationContext context, Object answer)
      [PRIVATE AND UNSUPPORTED] Instantiates a new answer exception.

      This is used by the instrumented bytecode that provides continuations support, it's not intended for general use.

      Parameters:
      context - the active continuation context
      answer - the answered value
      Since:
      1.0
  • Method Details

    • getContext

      public ContinuationContext getContext()
      Retrieves the context of this answer continuation.
      Returns:
      this answer continuation's context
      Since:
      1.0
    • getAnswer

      public Object getAnswer()
      Retrieves the answered value.
      Returns:
      this answer continuation's answered value; or

      null if no answer was provided

      Since:
      1.0