Enum mail_core::MailBody

source ·
pub enum MailBody {
    SingleBody {
        body: Resource,
    },
    MultipleBodies {
        bodies: Vec<Mail>,
        hidden_text: SoftAsciiString,
    },
}
Expand description

A type which either represents a single body, or multiple modies.

Note that you could have a mime multipart body just containing a single body and it being semantically important to be this way, so we have to differ between both kinds (instead of just having a Vec of mails)

Variants§

§

SingleBody

Fields

§body: Resource
§

MultipleBodies

Fields

§bodies: Vec<Mail>
§hidden_text: SoftAsciiString

This is part of the standard! But we won’t make it public available for now. Through there is a chance that we need to do so in the future as some mechanisms might misuse this, well unusual think.

Implementations§

Returns true if it’s an multipart body.

Trait Implementations§

Returns a copy of the value. Read more
Performs copy-assignment from source. Read more
Formats the value using the given formatter. Read more

Auto Trait Implementations§

Blanket Implementations§

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The resulting type after obtaining ownership.
Creates owned data from borrowed data, usually by cloning. Read more
Uses borrowed data to replace owned data, usually by cloning. Read more
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.