show

open fun show(@NonNull context: Context, @NonNull message: BatchMessage)

Asynchronously show the BatchMessage. It will be displayed in a dedicated activity (MessagingActivity).

Note that if this method will work even if Batch is in do not disturb mode.

The given context should be an Activity instance to enable support for the banner format, as it has to be attached to an activity. If you want to tweak how the SDK displays a banner, you can implement Batch.Messaging.DisplayHintProvider in your activity.

Parameters

context

Your activity's context, Can't be null.

message

Message to show. Can't be null.