Class AsynchronousHandlerInvocation

java.lang.Object
net.engio.mbassy.subscription.AbstractSubscriptionContextAware
net.engio.mbassy.dispatch.AsynchronousHandlerInvocation
All Implemented Interfaces:
IHandlerInvocation, ISubscriptionContextAware

public class AsynchronousHandlerInvocation extends AbstractSubscriptionContextAware implements IHandlerInvocation
This invocation will schedule the wrapped (decorated) invocation to be executed asynchronously
  • Field Details

  • Constructor Details

    • AsynchronousHandlerInvocation

      public AsynchronousHandlerInvocation(IHandlerInvocation delegate)
  • Method Details

    • invoke

      public void invoke(Object listener, Object message, MessagePublication publication)
      Invoke the message delivery logic of this handler
      Specified by:
      invoke in interface IHandlerInvocation
      Parameters:
      listener - The listener that will receive the message. This can be a reference to a method object from the java reflection api or any other wrapper that can be used to invoke the handler
      message - The message to be delivered to the handler. This can be any object compatible with the object type that the handler consumes