#[non_exhaustive]pub struct SpaceAddRoleInput<'a> {
pub name: &'a str,
pub permissions: &'a [&'a str],
pub position: u64,
pub color: Option<&'a str>,
}Expand description
One role to add in the addRoles patch key of Space/set update
(JMAP Chat §Space/set update / manage_roles permission).
The server assigns the role’s ULID; the request never specifies an id.
Hierarchy enforcement: a member may only add roles whose position is
strictly less than their own highest-position role (server-enforced).
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.name: &'a strHuman-readable role name.
permissions: &'a [&'a str]Permission identifier strings, e.g. "manage_channels".
position: u64Position in the role hierarchy. Lower values sort first.
color: Option<&'a str>Optional CSS-style color string (e.g. "#ff8800"). Pass None to omit.
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl<'a> Freeze for SpaceAddRoleInput<'a>
impl<'a> RefUnwindSafe for SpaceAddRoleInput<'a>
impl<'a> Send for SpaceAddRoleInput<'a>
impl<'a> Sync for SpaceAddRoleInput<'a>
impl<'a> Unpin for SpaceAddRoleInput<'a>
impl<'a> UnsafeUnpin for SpaceAddRoleInput<'a>
impl<'a> UnwindSafe for SpaceAddRoleInput<'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