Skip to main content

Action

Enum Action 

Source
pub enum Action<'a> {
    Keep {
        flags: &'a [&'a str],
        message_id: usize,
    },
    Discard,
    Reject {
        extended: bool,
        reason: &'a str,
    },
    FileInto {
        folder: &'a str,
        flags: &'a [&'a str],
        mailbox_id: Option<&'a str>,
        special_use: Option<&'a str>,
        create: bool,
        message_id: usize,
    },
    SendMessage {
        source: MessageSource,
        recipient: Recipient<'a>,
        notify: Notify,
        return_of_content: Ret,
        by_time: ByTime<i64>,
        message_id: usize,
    },
    Notify {
        from: Option<&'a str>,
        importance: Importance,
        options: &'a [&'a str],
        message: &'a str,
        method: &'a str,
    },
    SetEnvelope {
        envelope: Envelope,
        value: &'a str,
    },
    CreatedMessage {
        message_id: usize,
        message: Vec<u8>,
    },
}

Variants§

§

Keep

Fields

§flags: &'a [&'a str]
§message_id: usize
§

Discard

§

Reject

Fields

§extended: bool
§reason: &'a str
§

FileInto

Fields

§folder: &'a str
§flags: &'a [&'a str]
§mailbox_id: Option<&'a str>
§special_use: Option<&'a str>
§create: bool
§message_id: usize
§

SendMessage

Fields

§recipient: Recipient<'a>
§notify: Notify
§return_of_content: Ret
§by_time: ByTime<i64>
§message_id: usize
§

Notify

Fields

§from: Option<&'a str>
§importance: Importance
§options: &'a [&'a str]
§message: &'a str
§method: &'a str
§

SetEnvelope

Fields

§envelope: Envelope
§value: &'a str
§

CreatedMessage

Fields

§message_id: usize
§message: Vec<u8>

Trait Implementations§

Source§

impl<'a> Debug for Action<'a>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'a> Eq for Action<'a>

Source§

impl<'a> PartialEq for Action<'a>

Source§

fn eq(&self, other: &Action<'a>) -> bool

Equality operator ==. Read more
1.0.0 (const: unstable) · Source§

fn ne(&self, other: &Rhs) -> bool

Inequality operator !=. Read more
Source§

impl<'a> StructuralPartialEq for Action<'a>

Auto Trait Implementations§

§

impl<'a> Freeze for Action<'a>

§

impl<'a> RefUnwindSafe for Action<'a>

§

impl<'a> Send for Action<'a>

§

impl<'a> Sync for Action<'a>

§

impl<'a> Unpin for Action<'a>

§

impl<'a> UnsafeUnpin for Action<'a>

§

impl<'a> UnwindSafe for Action<'a>

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
where ST: ?Sized, DT: ?Sized,

Source§

impl<Q, K> Equivalent<K> for Q
where Q: Eq + ?Sized, K: Borrow<Q> + ?Sized,

Source§

fn equivalent(&self, key: &K) -> bool

Compare self to key and return true if they are equal.
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

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

Source§

impl<T> Read<Exclusive, BecauseExclusive> for T
where T: ?Sized,

Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = !

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, !>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

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

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.