[][src]Struct lettre::message::SinglePart

pub struct SinglePart { /* fields omitted */ }

Single part

Example

use lettre::message::{SinglePart, header};

let part = SinglePart::builder()
     .header(header::ContentType("text/plain; charset=utf8".parse().unwrap()))
     .header(header::ContentTransferEncoding::Binary)
     .body("Текст письма в уникоде");

Implementations

impl SinglePart[src]

pub fn builder() -> SinglePartBuilder[src]

Creates a default builder for singlepart

pub fn seven_bit() -> SinglePartBuilder[src]

Creates a singlepart builder with 7bit encoding

Shortcut for SinglePart::builder().header(ContentTransferEncoding::SevenBit).

pub fn quoted_printable() -> SinglePartBuilder[src]

Creates a singlepart builder with quoted-printable encoding

Shortcut for SinglePart::builder().header(ContentTransferEncoding::QuotedPrintable).

pub fn base64() -> SinglePartBuilder[src]

Creates a singlepart builder with base64 encoding

Shortcut for SinglePart::builder().header(ContentTransferEncoding::Base64).

pub fn eight_bit() -> SinglePartBuilder[src]

Creates a singlepart builder with 8-bit encoding

Shortcut for SinglePart::builder().header(ContentTransferEncoding::EightBit).

pub fn binary() -> SinglePartBuilder[src]

Creates a singlepart builder with binary encoding

Shortcut for SinglePart::builder().header(ContentTransferEncoding::Binary).

pub fn headers(&self) -> &Headers[src]

Get the headers from singlepart

pub fn body_ref(&self) -> &[u8][src]

Read the body from singlepart

pub fn formatted(&self) -> Vec<u8>[src]

Get message content formatted for SMTP

Trait Implementations

impl Clone for SinglePart[src]

impl Debug for SinglePart[src]

impl EmailFormat for SinglePart[src]

Auto Trait Implementations

Blanket Implementations

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

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

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

impl<T> From<T> for T[src]

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

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

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

type Error = Infallible

The type returned in the event of a conversion error.

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

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

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,