Class CfnPushTemplate.AndroidPushNotificationTemplateProperty.Builder
java.lang.Object
software.amazon.awscdk.services.pinpoint.CfnPushTemplate.AndroidPushNotificationTemplateProperty.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<CfnPushTemplate.AndroidPushNotificationTemplateProperty>
- Enclosing interface:
CfnPushTemplate.AndroidPushNotificationTemplateProperty
@Stability(Stable)
public static final class CfnPushTemplate.AndroidPushNotificationTemplateProperty.Builder
extends Object
implements software.amazon.jsii.Builder<CfnPushTemplate.AndroidPushNotificationTemplateProperty>
A builder for
CfnPushTemplate.AndroidPushNotificationTemplateProperty
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionSets the value ofCfnPushTemplate.AndroidPushNotificationTemplateProperty.getAction()
Sets the value ofCfnPushTemplate.AndroidPushNotificationTemplateProperty.getBody()
build()
Builds the configured instance.imageIconUrl
(String imageIconUrl) Sets the value ofCfnPushTemplate.AndroidPushNotificationTemplateProperty.getImageUrl()
smallImageIconUrl
(String smallImageIconUrl) Sets the value ofCfnPushTemplate.AndroidPushNotificationTemplateProperty.getSound()
Sets the value ofCfnPushTemplate.AndroidPushNotificationTemplateProperty.getTitle()
Sets the value ofCfnPushTemplate.AndroidPushNotificationTemplateProperty.getUrl()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
action
@Stability(Stable) public CfnPushTemplate.AndroidPushNotificationTemplateProperty.Builder action(String action) Sets the value ofCfnPushTemplate.AndroidPushNotificationTemplateProperty.getAction()
- Parameters:
action
- The action to occur if a recipient taps a push notification that's based on the message template. Valid values are:OPEN_APP
– Your app opens or it becomes the foreground app if it was sent to the background. This is the default action.DEEP_LINK
– Your app opens and displays a designated user interface in the app. This action uses the deep-linking features of the Android platform.URL
– The default mobile browser on the recipient's device opens and loads the web page at a URL that you specify.
- Returns:
this
-
body
@Stability(Stable) public CfnPushTemplate.AndroidPushNotificationTemplateProperty.Builder body(String body) Sets the value ofCfnPushTemplate.AndroidPushNotificationTemplateProperty.getBody()
- Parameters:
body
- The message body to use in a push notification that's based on the message template.- Returns:
this
-
imageIconUrl
@Stability(Stable) public CfnPushTemplate.AndroidPushNotificationTemplateProperty.Builder imageIconUrl(String imageIconUrl) - Parameters:
imageIconUrl
- The URL of the large icon image to display in the content view of a push notification that's based on the message template.- Returns:
this
-
imageUrl
@Stability(Stable) public CfnPushTemplate.AndroidPushNotificationTemplateProperty.Builder imageUrl(String imageUrl) Sets the value ofCfnPushTemplate.AndroidPushNotificationTemplateProperty.getImageUrl()
- Parameters:
imageUrl
- The URL of an image to display in a push notification that's based on the message template.- Returns:
this
-
smallImageIconUrl
@Stability(Stable) public CfnPushTemplate.AndroidPushNotificationTemplateProperty.Builder smallImageIconUrl(String smallImageIconUrl) - Parameters:
smallImageIconUrl
- The URL of the small icon image to display in the status bar and the content view of a push notification that's based on the message template.- Returns:
this
-
sound
@Stability(Stable) public CfnPushTemplate.AndroidPushNotificationTemplateProperty.Builder sound(String sound) Sets the value ofCfnPushTemplate.AndroidPushNotificationTemplateProperty.getSound()
- Parameters:
sound
- The sound to play when a recipient receives a push notification that's based on the message template. You can use the default stream or specify the file name of a sound resource that's bundled in your app. On an Android platform, the sound file must reside in/res/raw/
.- Returns:
this
-
title
@Stability(Stable) public CfnPushTemplate.AndroidPushNotificationTemplateProperty.Builder title(String title) Sets the value ofCfnPushTemplate.AndroidPushNotificationTemplateProperty.getTitle()
- Parameters:
title
- The title to use in a push notification that's based on the message template. This title appears above the notification message on a recipient's device.- Returns:
this
-
url
@Stability(Stable) public CfnPushTemplate.AndroidPushNotificationTemplateProperty.Builder url(String url) Sets the value ofCfnPushTemplate.AndroidPushNotificationTemplateProperty.getUrl()
- Parameters:
url
- The URL to open in a recipient's default mobile browser, if a recipient taps a push notification that's based on the message template and the value of theAction
property isURL
.- Returns:
this
-
build
Builds the configured instance.- Specified by:
build
in interfacesoftware.amazon.jsii.Builder<CfnPushTemplate.AndroidPushNotificationTemplateProperty>
- Returns:
- a new instance of
CfnPushTemplate.AndroidPushNotificationTemplateProperty
- Throws:
NullPointerException
- if any required attribute was not provided
-