Enum pb_async::PushData [−][src]
pub enum PushData<'a> {
Note {
title: &'a str,
body: &'a str,
},
Link {
title: &'a str,
body: &'a str,
url: &'a str,
},
File {
body: &'a str,
file_name: &'a str,
file_type: &'a str,
file_url: &'a str,
},
}Data which can be pushed.
Used in Client::push.
Variants
NoteNote push.
Fields of Note
title: &'a str | The note's title. |
body: &'a str | The note's message. |
LinkLink push.
Fields of Link
title: &'a str | The link's title. |
body: &'a str | A message associated with the link. |
url: &'a str | The url to open. |
FileFile push. Needs to be uploaded first with Client::upload_request.
Fields of File
body: &'a str | A message to go with the file. |
file_name: &'a str | The name of the file. |
file_type: &'a str | The MIME type of the file. |
file_url: &'a str | The url for the file. See [UploadRequestResponse.file_url]. |
Trait Implementations
impl<'a> Copy for PushData<'a>[src]
impl<'a> Copy for PushData<'a>impl<'a> Clone for PushData<'a>[src]
impl<'a> Clone for PushData<'a>fn clone(&self) -> PushData<'a>[src]
fn clone(&self) -> PushData<'a>Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)1.0.0[src]
fn clone_from(&mut self, source: &Self)1.0.0
[src]Performs copy-assignment from source. Read more
impl<'a> Debug for PushData<'a>[src]
impl<'a> Debug for PushData<'a>