#[non_exhaustive]pub enum JoinRuleKind {
Invite,
Knock,
Private,
Restricted,
KnockRestricted,
Public,
}
Expand description
The kind of rule used for users wishing to join this room.
This type can hold an arbitrary string. To build this with a custom value, convert it from a
string with ::from()
/ .into()
. To check for values that are not available as a
documented variant here, use its string representation, obtained through
.as_str()
.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Invite
A user who wishes to join the room must first receive an invite to the room from someone already inside of the room.
Knock
Users can join the room if they are invited, or they can request an invite to the room.
They can be allowed (invited) or denied (kicked/banned) access.
Private
Reserved but not yet implemented by the Matrix specification.
Restricted
Users can join the room if they are invited, or if they meet any of the conditions described in a set of rules.
KnockRestricted
Users can join the room if they are invited, or if they meet any of the conditions described in a set of rules, or they can request an invite to the room.
Public
Anyone can join the room without any prior action.
Implementations§
Trait Implementations§
Source§impl AsRef<str> for JoinRuleKind
impl AsRef<str> for JoinRuleKind
Source§impl Clone for JoinRuleKind
impl Clone for JoinRuleKind
Source§fn clone(&self) -> JoinRuleKind
fn clone(&self) -> JoinRuleKind
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moreSource§impl Debug for JoinRuleKind
impl Debug for JoinRuleKind
Source§impl Default for JoinRuleKind
impl Default for JoinRuleKind
Source§fn default() -> JoinRuleKind
fn default() -> JoinRuleKind
Source§impl<'de> Deserialize<'de> for JoinRuleKind
impl<'de> Deserialize<'de> for JoinRuleKind
Source§fn deserialize<D>(
deserializer: D,
) -> Result<JoinRuleKind, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
fn deserialize<D>(
deserializer: D,
) -> Result<JoinRuleKind, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
Source§impl Display for JoinRuleKind
impl Display for JoinRuleKind
Source§impl From<JoinRuleKind> for JoinRuleSummary
impl From<JoinRuleKind> for JoinRuleSummary
Source§fn from(value: JoinRuleKind) -> JoinRuleSummary
fn from(value: JoinRuleKind) -> JoinRuleSummary
Source§impl<T> From<T> for JoinRuleKind
impl<T> From<T> for JoinRuleKind
Source§fn from(s: T) -> JoinRuleKind
fn from(s: T) -> JoinRuleKind
Source§impl PartialEq for JoinRuleKind
impl PartialEq for JoinRuleKind
Source§impl Serialize for JoinRuleKind
impl Serialize for JoinRuleKind
Source§fn serialize<S>(
&self,
serializer: S,
) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>where
S: Serializer,
fn serialize<S>(
&self,
serializer: S,
) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>where
S: Serializer,
impl Eq for JoinRuleKind
impl StructuralPartialEq for JoinRuleKind
Auto Trait Implementations§
impl Freeze for JoinRuleKind
impl RefUnwindSafe for JoinRuleKind
impl Send for JoinRuleKind
impl Sync for JoinRuleKind
impl Unpin for JoinRuleKind
impl UnwindSafe for JoinRuleKind
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key
and return true
if they are equal.