public abstract class

NotificationMessage

extends Object
implements Parcelable
java.lang.Object
   ↳ com.salesforce.marketingcloud.notifications.NotificationMessage

Summary

Nested Classes
enum NotificationMessage.Sound  
enum NotificationMessage.Trigger  
enum NotificationMessage.Type  
[Expand]
Inherited Constants
From interface android.os.Parcelable
Public Constructors
NotificationMessage()
Public Methods
abstract String alert()
The alert text that is used as the ticker text and content text of the notification.
abstract String custom()
abstract Map<String, String> customKeys()
abstract String id()
The message id.
abstract String mediaAltText()
abstract String mediaUrl()
abstract int notificationId()
abstract Map<String, String> payload()
The original message payload sent via push.
abstract Region region()
For notifications triggered by Geofence/Beacon messaging this field will be populated with the region information used for tracking the associated event.
abstract String regionId()
The id for the associated region.
abstract NotificationMessage.Sound sound()
Sound set by the marketer.
abstract String soundName()
The sound name provided in the message.
abstract String subTitle()
This value can be sent in the message payload, but there is no defined way of displaying a sub title in a notification.
abstract String title()
The title to be used for the notification.
abstract NotificationMessage.Trigger trigger()
Trigger of the message.
abstract NotificationMessage.Type type()
Message type.
abstract String url()
The url set for the notification from the marketer.
[Expand]
Inherited Methods
From class java.lang.Object
From interface android.os.Parcelable

Public Constructors

public NotificationMessage ()

Public Methods

public abstract String alert ()

The alert text that is used as the ticker text and content text of the notification.

public abstract String custom ()

public abstract Map<String, String> customKeys ()

public abstract String id ()

The message id.

public abstract String mediaAltText ()

public abstract String mediaUrl ()

public abstract int notificationId ()

public abstract Map<String, String> payload ()

The original message payload sent via push. Will only be populated when trigger() == Trigger.PUSH.

public abstract Region region ()

For notifications triggered by Geofence/Beacon messaging this field will be populated with the region information used for tracking the associated event.

Returns
  • region

public abstract String regionId ()

The id for the associated region. Will be null for PUSH messages.

public abstract NotificationMessage.Sound sound ()

Sound set by the marketer.

public abstract String soundName ()

The sound name provided in the message. This will be null unless sound() equals CUSTOM.

public abstract String subTitle ()

This value can be sent in the message payload, but there is no defined way of displaying a sub title in a notification. The value is parsed in this object, but will not be added to the notification by the SDK.

public abstract String title ()

The title to be used for the notification. If a title is provided in the message payload it will be used, otherwise the message will be displayed without a title.

public abstract NotificationMessage.Trigger trigger ()

Trigger of the message.

public abstract NotificationMessage.Type type ()

Message type.

public abstract String url ()

The url set for the notification from the marketer. Note: This might not be a valid http url