Interface ReturnResolver<S extends Source,T>

Type Parameters:
S - the source type
T - the type of value to return
All Known Implementing Classes:
BaseReturnResolver

public interface ReturnResolver<S extends Source,T>
An interface that represents a way to handle a returned value from a method that does is NOT void. (doesn't return void). This is useful when you want your annotated command methods to return values and those values should be handled in a certain way when returned (after the method's invocation).
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns the type of the return value.
    void
    handle(ExecutionContext<S> context, MethodElement method, T value)
    Handles the return value of a command.
  • Method Details

    • handle

      void handle(ExecutionContext<S> context, MethodElement method, T value)
      Handles the return value of a command.
      Parameters:
      context - The execution context of the command.
      method - The method element of the command.
      value - The return value of the command.
    • getType

      Type getType()
      Returns the type of the return value.
      Returns:
      The type of the return value.