pub enum MessagePartType {
Text,
Code,
Images,
Videos,
Links,
Statuses,
}Expand description
Type discriminant for a MessagePart. The base set is fixed; plugin
vendors extend it via GTS without forking Chat Engine core.
Variants§
Text
Plain text: { text, title? }.
Code
Code block: { language, code }.
Images
One or more image references: { images: [{ image_id, mime_type?, .. }] }.
Videos
One or more video references: { videos: [{ video_id, mime_type?, .. }] }.
Links
Link preview cards: { links: [{ url, title?, .. }] }.
Statuses
Progress/status indicators: { statuses: [{ code, detail? }] }.
Trait Implementations§
Source§impl Clone for MessagePartType
impl Clone for MessagePartType
Source§fn clone(&self) -> MessagePartType
fn clone(&self) -> MessagePartType
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for MessagePartType
Source§impl Debug for MessagePartType
impl Debug for MessagePartType
Source§impl<'de> Deserialize<'de> for MessagePartType
impl<'de> Deserialize<'de> for MessagePartType
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
impl Eq for MessagePartType
Source§impl PartialEq for MessagePartType
impl PartialEq for MessagePartType
Source§impl Serialize for MessagePartType
impl Serialize for MessagePartType
impl StructuralPartialEq for MessagePartType
Auto Trait Implementations§
impl Freeze for MessagePartType
impl RefUnwindSafe for MessagePartType
impl Send for MessagePartType
impl Sync for MessagePartType
impl Unpin for MessagePartType
impl UnsafeUnpin for MessagePartType
impl UnwindSafe for MessagePartType
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