Skip to main content

MsgContentExt

Trait MsgContentExt 

Source
pub trait MsgContentExt {
    // Required methods
    fn text_part(&self) -> Option<&str>;
    fn text_part_mut(&mut self) -> Option<&mut String>;
    fn preview(&self) -> Option<&str>;
    fn preview_mut(&mut self) -> Option<&mut String>;

    // Provided methods
    fn set_text_part(&mut self, new_text: impl Into<String>) { ... }
    fn set_preview(&mut self, new_preview: String) { ... }
}

Required Methods§

Source

fn text_part(&self) -> Option<&str>

Source

fn text_part_mut(&mut self) -> Option<&mut String>

Source

fn preview(&self) -> Option<&str>

Source

fn preview_mut(&mut self) -> Option<&mut String>

Provided Methods§

Source

fn set_text_part(&mut self, new_text: impl Into<String>)

Source

fn set_preview(&mut self, new_preview: String)

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.

Implementors§