pub struct SlackMessageContent {
pub text: Option<String>,
pub blocks: Option<Vec<SlackBlock>>,
pub attachments: Option<Vec<SlackMessageAttachment>>,
}Fields
text: Option<String>blocks: Option<Vec<SlackBlock>>attachments: Option<Vec<SlackMessageAttachment>>Implementations
sourceimpl SlackMessageContent
impl SlackMessageContent
pub fn new() -> Self
pub fn text(&mut self, value: String) -> &mut Self
pub fn reset_text(&mut self) -> &mut Self
pub fn mopt_text(&mut self, value: Option<String>) -> &mut Self
pub fn with_text(self, value: String) -> Self
pub fn without_text(self) -> Self
pub fn opt_text(self, value: Option<String>) -> Self
pub fn blocks(&mut self, value: Vec<SlackBlock>) -> &mut Self
pub fn reset_blocks(&mut self) -> &mut Self
pub fn mopt_blocks(&mut self, value: Option<Vec<SlackBlock>>) -> &mut Self
pub fn with_blocks(self, value: Vec<SlackBlock>) -> Self
pub fn without_blocks(self) -> Self
pub fn opt_blocks(self, value: Option<Vec<SlackBlock>>) -> Self
pub fn attachments(&mut self, value: Vec<SlackMessageAttachment>) -> &mut Self
pub fn reset_attachments(&mut self) -> &mut Self
pub fn mopt_attachments(
&mut self,
value: Option<Vec<SlackMessageAttachment>>
) -> &mut Self
pub fn with_attachments(self, value: Vec<SlackMessageAttachment>) -> Self
pub fn without_attachments(self) -> Self
pub fn opt_attachments(self, value: Option<Vec<SlackMessageAttachment>>) -> Self
Trait Implementations
sourceimpl Clone for SlackMessageContent
impl Clone for SlackMessageContent
sourcefn clone(&self) -> SlackMessageContent
fn clone(&self) -> SlackMessageContent
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read more
sourceimpl Debug for SlackMessageContent
impl Debug for SlackMessageContent
sourceimpl<'de> Deserialize<'de> for SlackMessageContent
impl<'de> Deserialize<'de> for SlackMessageContent
sourcefn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
sourceimpl From<SlackMessageContentInit> for SlackMessageContent
impl From<SlackMessageContentInit> for SlackMessageContent
sourcefn from(value: SlackMessageContentInit) -> Self
fn from(value: SlackMessageContentInit) -> Self
Performs the conversion.
sourceimpl PartialEq<SlackMessageContent> for SlackMessageContent
impl PartialEq<SlackMessageContent> for SlackMessageContent
sourcefn eq(&self, other: &SlackMessageContent) -> bool
fn eq(&self, other: &SlackMessageContent) -> bool
This method tests for self and other values to be equal, and is used
by ==. Read more
sourcefn ne(&self, other: &SlackMessageContent) -> bool
fn ne(&self, other: &SlackMessageContent) -> bool
This method tests for !=.
sourceimpl Serialize for SlackMessageContent
impl Serialize for SlackMessageContent
impl StructuralPartialEq for SlackMessageContent
Auto Trait Implementations
impl RefUnwindSafe for SlackMessageContent
impl Send for SlackMessageContent
impl Sync for SlackMessageContent
impl Unpin for SlackMessageContent
impl UnwindSafe for SlackMessageContent
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcepub fn to_owned(&self) -> T
pub fn to_owned(&self) -> T
Creates owned data from borrowed data, usually by cloning. Read more
sourcepub fn clone_into(&self, target: &mut T)
pub fn clone_into(&self, target: &mut T)
🔬 This is a nightly-only experimental API. (
toowned_clone_into)Uses borrowed data to replace owned data, usually by cloning. Read more