pub struct PushPayload {
pub alert: Option<PushAlert>,
pub badge: Option<usize>,
pub sound: Option<PushSound>,
pub thread_id: Option<String>,
pub category: Option<String>,
pub content_available: Option<usize>,
pub mutable_content: Option<usize>,
pub target_content_id: Option<String>,
}Expand description
Payload of a push notification that is sent to a device.
Fields§
§alert: Option<PushAlert>Optional alert that will be presented to the user.
badge: Option<usize>Optional number that will update the badge on the springboard. Set this
to Some(0) to remove an existing badge.
sound: Option<PushSound>Optional sound that will be played when the notification arrives.
thread_id: Option<String>Optional thread id that is used by the OS to group multiple messages that are related to the same “thread” (e.g. conversation or topic).
category: Option<String>Category that matches with one of the categories registered in the app.
content_available: Option<usize>Flag that indicates if content is available (should be either 0 or 1).
mutable_content: Option<usize>Flag that indicates if this payload should be run through the push notification extension of this app to update its content.
target_content_id: Option<String>Content ID that is passed to the app when this notification is opened.
Trait Implementations§
Source§impl Clone for PushPayload
impl Clone for PushPayload
Source§fn clone(&self) -> PushPayload
fn clone(&self) -> PushPayload
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more