Interface Batch.Messaging.LifecycleListener2

All Superinterfaces:
Batch.Messaging.LifecycleListener
Enclosing class:
Batch.Messaging

public static interface Batch.Messaging.LifecycleListener2 extends Batch.Messaging.LifecycleListener
Listener interface for messaging events. If you'd like to opt-in to additional lifecycle events, you should implement this methods, as it gives you more control about how and when to display In-App Messages
  • Method Details

    • onBatchInAppMessageReady

      boolean onBatchInAppMessageReady(BatchInAppMessage message)
      Called when an In-App Message is about to be displayed, giving a chance to cancel it and handle it manually.

      This method can be called from any thread.

      Parameters:
      message - The In-App message about to be displayed
      Returns:
      true if you handled the message, false if you want to let Batch continue processing it. Returning true will prevent this message from being automatically displayed: it then becomes your responsibility to do so, if you wish.