Struct expo_server_sdk::PushMessage[][src]

pub struct PushMessage {
    pub to: PushToken,
    pub data: Option<Value>,
    pub title: Option<String>,
    pub body: Option<String>,
    pub sound: Option<Sound>,
    pub ttl: Option<u32>,
    pub expiration: Option<u32>,
    pub priority: Option<Priority>,
    pub badge: Option<u32>,
}

A PushMessage struct modelled after the one listed here:

Example:

extern crate expo_server_sdk;
use expo_server_sdk::*;
use std::str::FromStr;

let token = PushToken::from_str("ExpoPushToken[my-token]").unwrap();
let mut msg = PushMessage::new(token).body("test notification");

Fields

Methods

impl PushMessage
[src]

Trait Implementations

impl Clone for PushMessage
[src]

Returns a copy of the value. Read more

Performs copy-assignment from source. Read more

Auto Trait Implementations

impl Send for PushMessage

impl Sync for PushMessage