pub struct SlackRichTextUser {
pub user_id: SlackUserId,
pub style: Option<SlackRichTextStyle>,
}Fields§
§user_id: SlackUserId§style: Option<SlackRichTextStyle>Implementations§
Source§impl SlackRichTextUser
impl SlackRichTextUser
Sourcepub fn new(user_id: SlackUserId) -> Self
pub fn new(user_id: SlackUserId) -> Self
Creates a new SlackRichTextUser from its required fields. Option fields start as None, and fields with #[default] take their default.
Sourcepub fn user_id(&mut self, value: SlackUserId) -> &mut Self
pub fn user_id(&mut self, value: SlackUserId) -> &mut Self
Sets user_id to value.
Sourcepub fn with_user_id(self, value: SlackUserId) -> Self
pub fn with_user_id(self, value: SlackUserId) -> Self
Returns self with user_id set to value.
Sourcepub fn style(&mut self, value: SlackRichTextStyle) -> &mut Self
pub fn style(&mut self, value: SlackRichTextStyle) -> &mut Self
Sets style to Some(value).
Sourcepub fn reset_style(&mut self) -> &mut Self
pub fn reset_style(&mut self) -> &mut Self
Sets style to None.
Sourcepub fn mopt_style(&mut self, value: Option<SlackRichTextStyle>) -> &mut Self
pub fn mopt_style(&mut self, value: Option<SlackRichTextStyle>) -> &mut Self
Sets style to the given Option.
Sourcepub fn with_style(self, value: SlackRichTextStyle) -> Self
pub fn with_style(self, value: SlackRichTextStyle) -> Self
Returns self with style set to Some(value).
Sourcepub fn without_style(self) -> Self
pub fn without_style(self) -> Self
Returns self with style set to None.
Sourcepub fn opt_style(self, value: Option<SlackRichTextStyle>) -> Self
pub fn opt_style(self, value: Option<SlackRichTextStyle>) -> Self
Returns self with style set to the given Option.
Trait Implementations§
Source§impl Clone for SlackRichTextUser
impl Clone for SlackRichTextUser
Source§impl Debug for SlackRichTextUser
impl Debug for SlackRichTextUser
Source§impl<'de> Deserialize<'de> for SlackRichTextUser
impl<'de> Deserialize<'de> for SlackRichTextUser
Source§fn 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
Source§impl From<SlackRichTextUser> for SlackRichTextInlineElement
impl From<SlackRichTextUser> for SlackRichTextInlineElement
Source§fn from(element: SlackRichTextUser) -> Self
fn from(element: SlackRichTextUser) -> Self
Converts to this type from the input type.
Source§impl From<SlackRichTextUserInit> for SlackRichTextUser
impl From<SlackRichTextUserInit> for SlackRichTextUser
Source§fn from(value: SlackRichTextUserInit) -> Self
fn from(value: SlackRichTextUserInit) -> Self
Converts to this type from the input type.
Source§impl PartialEq for SlackRichTextUser
impl PartialEq for SlackRichTextUser
Source§impl Serialize for SlackRichTextUser
impl Serialize for SlackRichTextUser
impl StructuralPartialEq for SlackRichTextUser
Auto Trait Implementations§
impl Freeze for SlackRichTextUser
impl RefUnwindSafe for SlackRichTextUser
impl Send for SlackRichTextUser
impl Sync for SlackRichTextUser
impl Unpin for SlackRichTextUser
impl UnsafeUnpin for SlackRichTextUser
impl UnwindSafe for SlackRichTextUser
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more