Represents a message that can be sent to multiple devices via Firebase Cloud Messaging (FCM).
Contains payload information as well as the list of device registration tokens and/or
Firebase Installation IDs (FIDs) to which the message should be sent. A single
MulticastMessage may contain up to 500 registration tokens and FIDs combined.
Instances of this class are thread-safe and immutable. Use MulticastMessage.Builder
to create new instances. See sendMulticast(MulticastMessage) for
details on how to send the message to FCM for multicast delivery.
This class and the associated Builder retain the order of tokens and FIDs. Therefore
the order of the responses list obtained by calling getResponses()
on the return value of sendMulticast(MulticastMessage)
corresponds to the order in which targets were added to the
MulticastMessage.Builder. If both tokens and FIDs are provided, tokens are
processed first, followed by FIDs.
Nested Class Summary
| class | MulticastMessage.Builder | ||
Public Method Summary
| static MulticastMessage.Builder |
builder()
Creates a new
MulticastMessage.Builder. |
Inherited Method Summary
Public Methods
public static MulticastMessage.Builder builder ()
Creates a new MulticastMessage.Builder.
Returns
- A
MulticastMessage.Builderinstance.