pub struct Message {
pub name: Option<String>,
pub data: Option<HashMap<String, String>>,
pub notification: Option<Notification>,
pub android: Option<AndroidConfig>,
pub webpush: Option<WebpushConfig>,
pub apns: Option<ApnsConfig>,
pub fcm_options: Option<FcmOptions>,
pub token: Option<String>,
pub topic: Option<String>,
pub condition: Option<String>,
}Expand description
Represents a message to be sent via FCM.
Fields§
§name: Option<String>Output Only. The identifier of the message sent.
data: Option<HashMap<String, String>>Arbitrary key/value payload.
notification: Option<Notification>Basic notification template to use across all platforms.
android: Option<AndroidConfig>Android specific options for messages sent through FCM connection server.
webpush: Option<WebpushConfig>Webpush protocol options.
apns: Option<ApnsConfig>Apple Push Notification Service specific options.
fcm_options: Option<FcmOptions>Template for FCM options across all platforms.
token: Option<String>Registration token to send a message to.
topic: Option<String>Topic name to send a message to, e.g. “weather”. Note: “/topics/” prefix should not be provided.
condition: Option<String>Condition to send a message to, e.g. “‘foo’ in topics && ‘bar’ in topics”.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Message
impl<'de> Deserialize<'de> for Message
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for Message
impl RefUnwindSafe for Message
impl Send for Message
impl Sync for Message
impl Unpin for Message
impl UnwindSafe for Message
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more