-
public final class CustomUpdateContent.Builder
-
-
Field Summary
Fields Modifier and Type Field Description private CustomUpdateLocalizedTextctaprivate Stringdata
-
Constructor Summary
Constructors Constructor Description CustomUpdateContent.Builder(GamingContext contextToken, CustomUpdateLocalizedText text, Bitmap image)Creates a CustomUpdateContent Builder CustomUpdateContent.Builder(GamingContext contextToken, CustomUpdateLocalizedText text, CustomUpdateMedia media)Creates a CustomUpdateContent Builder
-
Method Summary
Modifier and Type Method Description final CustomUpdateLocalizedTextgetCta()final UnitsetCta(CustomUpdateLocalizedText cta)final StringgetData()final UnitsetData(String data)final CustomUpdateContent.BuildersetCta(CustomUpdateLocalizedText cta)Sets the CTA (Call to Action) text in the update messageIf none is provided then a localized version of 'play' will be used. final CustomUpdateContent.BuildersetData(String data)Sets a Data that will be sent back to the game when a user clicks on the message. final CustomUpdateContentbuild()Returns a CustomUpdateContent with the values defined in this builder. -
-
Constructor Detail
-
CustomUpdateContent.Builder
CustomUpdateContent.Builder(GamingContext contextToken, CustomUpdateLocalizedText text, Bitmap image)
Creates a CustomUpdateContent Builder- Parameters:
contextToken- GamingContext A valid GamingContext to send the update to.text- The text that will be included in the updateimage- An image that will be included in the update
-
CustomUpdateContent.Builder
CustomUpdateContent.Builder(GamingContext contextToken, CustomUpdateLocalizedText text, CustomUpdateMedia media)
Creates a CustomUpdateContent Builder- Parameters:
contextToken- GamingContext A valid GamingContext to send the update to.text- The text that will be included in the updatemedia- A gif or video that will be included in the update
-
-
Method Detail
-
getCta
final CustomUpdateLocalizedText getCta()
-
setCta
final Unit setCta(CustomUpdateLocalizedText cta)
-
setCta
final CustomUpdateContent.Builder setCta(CustomUpdateLocalizedText cta)
Sets the CTA (Call to Action) text in the update message
If none is provided then a localized version of 'play' will be used.
- Parameters:
cta- The Custom CTA to use.
-
setData
final CustomUpdateContent.Builder setData(String data)
Sets a Data that will be sent back to the game when a user clicks on the message. When the game is launched from a Custom Update message the data here will be forwarded as a Payload. Please use the GamingPayload class to retrieve it.
- Parameters:
data- A String that will be sent back to the game.
-
build
final CustomUpdateContent build()
Returns a CustomUpdateContent with the values defined in this builder.
-
-
-
-