[][src]Struct sendgrid_rs::message::Message

pub struct Message { /* fields omitted */ }

Message is the wrapper around the entire payload to be sent to SendGrid's API. Use MessageBuilder to properly construct this. The to_json method is available to turn this struct into the request body to send to SendGrid

Methods

impl Message
[src]

pub fn to_json(&self) -> String
[src]

to_json serializes the entire message into JSON. The result of this method call should contain the entire body for the HTTP POST to SendGrid. This method will panic if it is unable to serialize, because it is likely a bug in this crate that is causing it.

Trait Implementations

impl Debug for Message
[src]

impl Serialize for Message
[src]

Auto Trait Implementations

impl Send for Message

impl Sync for Message

Blanket Implementations

impl<T> From for T
[src]

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom for T where
    T: From<U>, 
[src]

type Error = !

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T> Any for T where
    T: 'static + ?Sized
[src]