Ir a la consola

MulticastMessage.Builder

public static class MulticastMessage.Builder extends Object

Public Method Summary

MulticastMessage.Builder
addAllTokens(Collection<String> tokens)
Adds a collection of tokens to which the message should be sent.
MulticastMessage.Builder
addToken(String token)
Adds a token to which the message should be sent.
MulticastMessage
build()
Creates a new MulticastMessage instance from the parameters set on this builder.
MulticastMessage.Builder
putAllData(Map<String, String> map)
Adds all the key-value pairs in the given map to the message as data fields.
MulticastMessage.Builder
putData(String key, String value)
Adds the given key-value pair to the message as a data field.
MulticastMessage.Builder
setAndroidConfig(AndroidConfig androidConfig)
Sets the Android-specific information to be included in the message.
MulticastMessage.Builder
setApnsConfig(ApnsConfig apnsConfig)
Sets the information specific to APNS (Apple Push Notification Service).
MulticastMessage.Builder
setNotification(Notification notification)
Sets the notification information to be included in the message.
MulticastMessage.Builder
setWebpushConfig(WebpushConfig webpushConfig)
Sets the Webpush-specific information to be included in the message.

Inherited Method Summary

Public Methods

public MulticastMessage.Builder addAllTokens (Collection<String> tokens)

Adds a collection of tokens to which the message should be sent. Up to 100 tokens can be specified on a single instance of MulticastMessage.

Parameters
tokens Collection of Firebase device registration tokens.
Returns
  • This builder.

public MulticastMessage.Builder addToken (String token)

Adds a token to which the message should be sent. Up to 100 tokens can be specified on a single instance of MulticastMessage.

Parameters
token A non-null, non-empty Firebase device registration token.
Returns
  • This builder.

public MulticastMessage build ()

Creates a new MulticastMessage instance from the parameters set on this builder.

Returns