#[non_exhaustive]pub enum ChatCreateInput<'a> {
Direct {
client_id: Option<&'a str>,
contact_id: &'a Id,
},
Group {
client_id: Option<&'a str>,
name: &'a str,
member_ids: &'a [Id],
description: Option<&'a str>,
avatar_blob_id: Option<&'a Id>,
message_expiry_seconds: Option<u64>,
},
Channel {
client_id: Option<&'a str>,
space_id: &'a Id,
name: &'a str,
description: Option<&'a str>,
},
}Expand description
Input parameters for Chat/set create.
Discriminates the three Chat creation kinds from the spec. Each variant
carries the fields required for that kind plus an optional client_id;
when None, a ULID is generated automatically.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Direct
Create a direct (one-to-one) chat.
Fields
Group
Create a group chat.
Fields
Channel
Create a channel chat inside a Space.
Trait Implementations§
Auto Trait Implementations§
impl<'a> Freeze for ChatCreateInput<'a>
impl<'a> RefUnwindSafe for ChatCreateInput<'a>
impl<'a> Send for ChatCreateInput<'a>
impl<'a> Sync for ChatCreateInput<'a>
impl<'a> Unpin for ChatCreateInput<'a>
impl<'a> UnsafeUnpin for ChatCreateInput<'a>
impl<'a> UnwindSafe for ChatCreateInput<'a>
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