Class Subscription.Handle

java.lang.Object
net.engio.mbassy.subscription.Subscription.Handle
Enclosing class:
Subscription

public class Subscription.Handle extends Object
A handle exposes specific functionality of a subscription to be used by clients.
  • Constructor Details

    • Handle

      public Handle()
  • Method Details

    • onSubscription

      void onSubscription(Runnable handler)
      Add a runnable that is invoked after a new listener is subscribed to the corresponding subscription. The runnable does not receive any information on the event to prevent clients from untroducing coupling between senders/receivers.
      Parameters:
      handler - The code to be run after each subscription