Package com.batch.android.core
Class InternalPushData
- java.lang.Object
-
- com.batch.android.core.InternalPushData
-
public class InternalPushData extends java.lang.ObjectClass to easily access the push data
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classInternalPushData.Formatstatic classInternalPushData.Prioritystatic classInternalPushData.ReceiptMode
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringBATCH_BUNDLE_KEYKey this data is contained in when stored in a push bundle
-
Constructor Summary
Constructors Constructor Description InternalPushData(JSONObject batchData)InternalPushData(java.lang.String batchData)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.List<BatchNotificationAction>getActions()java.lang.StringgetChannel()Returns the channel for Android 8.0java.util.List<java.lang.Double>getCustomBigIconAvailableDensity()java.lang.StringgetCustomBigIconURL()java.util.List<java.lang.Double>getCustomBigImageAvailableDensity()java.lang.StringgetCustomBigImageURL()java.util.Map<java.lang.String,java.lang.Object>getExtraParameters()java.lang.StringgetGroup()Get the notification group name.java.lang.StringgetInstallId()java.lang.StringgetJsonPayload()JSONObjectgetLandingMessage()InternalPushData.FormatgetNotificationFormat()Get the notification format A format is like a Messaging message formatJSONObjectgetNotificationFormatArguments()Get the notification format argumentsjava.util.Map<java.lang.String,java.lang.Object>getOpenData()Get the open data as mapInternalPushData.PrioritygetPriority()static InternalPushDatagetPushDataForFirebaseMessage(com.google.firebase.messaging.RemoteMessage message)static InternalPushDatagetPushDataForReceiverBundle(android.os.Bundle extras)static InternalPushDatagetPushDataForReceiverIntent(android.content.Intent intent)java.lang.StringgetPushId()java.util.Map<java.lang.String,java.lang.Object>getReceiptEventData()Get the event data for the display receiptlonggetReceiptMaxDelay()longgetReceiptMinDelay()InternalPushData.ReceiptModegetReceiptMode()java.lang.StringgetScheme()BatchNotificationSourcegetSource()intgetVisibility()Get the notification's visibility.booleanhasCustomBigIcon()booleanhasCustomBigImage()booleanhasLandingMessage()booleanhasScheme()booleanisGroupSummary()Get the notification group name.booleanisLocalCampainsRefresh()booleanisSchemeEmpty()booleanisSilent()booleanshouldUseLegacyBigPictureIconBehaviour()Returns whether the old custom icon fallback behaviour for BigPictureStyle (which changed in 1.14.1) should be used or not.
-
-
-
Field Detail
-
BATCH_BUNDLE_KEY
public static final java.lang.String BATCH_BUNDLE_KEY
Key this data is contained in when stored in a push bundle- See Also:
- Constant Field Values
-
-
Constructor Detail
-
InternalPushData
public InternalPushData(java.lang.String batchData)
-
InternalPushData
public InternalPushData(JSONObject batchData)
-
-
Method Detail
-
getPushDataForReceiverIntent
public static InternalPushData getPushDataForReceiverIntent(@NonNull android.content.Intent intent)
-
getPushDataForReceiverBundle
public static InternalPushData getPushDataForReceiverBundle(@Nullable android.os.Bundle extras)
-
getPushDataForFirebaseMessage
public static InternalPushData getPushDataForFirebaseMessage(@Nullable com.google.firebase.messaging.RemoteMessage message)
-
getJsonPayload
public java.lang.String getJsonPayload()
-
isSilent
public boolean isSilent()
-
isLocalCampainsRefresh
public boolean isLocalCampainsRefresh()
-
hasScheme
public boolean hasScheme()
-
isSchemeEmpty
public boolean isSchemeEmpty()
-
getScheme
public java.lang.String getScheme()
-
getPushId
public java.lang.String getPushId()
-
getInstallId
public java.lang.String getInstallId()
-
hasLandingMessage
public boolean hasLandingMessage()
-
getLandingMessage
public JSONObject getLandingMessage()
-
hasCustomBigIcon
public boolean hasCustomBigIcon()
-
getCustomBigIconURL
public java.lang.String getCustomBigIconURL()
-
getCustomBigIconAvailableDensity
public java.util.List<java.lang.Double> getCustomBigIconAvailableDensity()
-
hasCustomBigImage
public boolean hasCustomBigImage()
-
getCustomBigImageURL
public java.lang.String getCustomBigImageURL()
-
getCustomBigImageAvailableDensity
public java.util.List<java.lang.Double> getCustomBigImageAvailableDensity()
-
getActions
public java.util.List<BatchNotificationAction> getActions()
-
getReceiptMode
public InternalPushData.ReceiptMode getReceiptMode()
-
getReceiptMinDelay
public long getReceiptMinDelay()
-
getReceiptMaxDelay
public long getReceiptMaxDelay()
-
getPriority
public InternalPushData.Priority getPriority()
-
getChannel
public java.lang.String getChannel()
Returns the channel for Android 8.0
-
getSource
public BatchNotificationSource getSource()
-
getGroup
public java.lang.String getGroup()
Get the notification group name. Meant to be used withNotificationCompat.Builder.setGroup(String)- Returns:
- Group name string, null if none
-
isGroupSummary
public boolean isGroupSummary()
Get the notification group name. Meant to be used withNotificationCompat.Builder.setGroupSummary(boolean)- Returns:
- Whether this notification should be a group summary or not
-
getVisibility
public int getVisibility()
Get the notification's visibility.See
NotificationCompat.Builder.setVisibility(int)- Returns:
- The wanted visibility. Default is
Notification.VISIBILITY_PUBLIC
-
getNotificationFormat
public InternalPushData.Format getNotificationFormat()
Get the notification format A format is like a Messaging message format
-
getNotificationFormatArguments
@Nullable public JSONObject getNotificationFormatArguments()
Get the notification format arguments
-
getExtraParameters
public java.util.Map<java.lang.String,java.lang.Object> getExtraParameters()
-
getOpenData
public java.util.Map<java.lang.String,java.lang.Object> getOpenData()
Get the open data as map- Returns:
-
getReceiptEventData
public java.util.Map<java.lang.String,java.lang.Object> getReceiptEventData()
Get the event data for the display receipt- Returns:
-
shouldUseLegacyBigPictureIconBehaviour
public boolean shouldUseLegacyBigPictureIconBehaviour()
Returns whether the old custom icon fallback behaviour for BigPictureStyle (which changed in 1.14.1) should be used or not.Default false
-
-