pub struct TypeDef {
pub name: String,
pub kind: TypeKind,
pub title: String,
pub description: Option<String>,
pub schema: Value,
pub roles: Option<Vec<Role>>,
pub instructions: Option<String>,
pub status: Option<TypeStatus>,
pub rate_hint: Option<u32>,
pub max_payload_hint: Option<u64>,
pub extra: Option<BTreeMap<String, Value>>,
}Expand description
A room-scoped declaration of a custom event type. The field set is closed.
Fields§
§name: String§kind: TypeKind§title: String§description: Option<String>§schema: ValueJSON Schema for the event payload, following the type schema profile.
roles: Option<Vec<Role>>§instructions: Option<String>§status: Option<TypeStatus>§rate_hint: Option<u32>§max_payload_hint: Option<u64>§extra: Option<BTreeMap<String, Value>>None when absent; an explicit {} is kept so a signed declaration
re-serializes to the bytes that were signed.
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for TypeDef
impl<'de> Deserialize<'de> for TypeDef
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 StructuralPartialEq for TypeDef
Auto Trait Implementations§
impl Freeze for TypeDef
impl RefUnwindSafe for TypeDef
impl Send for TypeDef
impl Sync for TypeDef
impl Unpin for TypeDef
impl UnsafeUnpin for TypeDef
impl UnwindSafe for TypeDef
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