#[repr(u8)]pub enum Sender {
Member(LeafNodeIndex),
External(SenderExtensionIndex),
NewMemberProposal,
NewMemberCommit,
}Available on 32-bit or 64-bit only.
Expand description
All possible sender types according to the MLS protocol spec.
// draft-ietf-mls-protocol-16
enum {
reserved(0),
member(1),
external(2),
new_member_proposal(3),
new_member_commit(4),
(255)
} SenderType;
// draft-ietf-mls-protocol-16
struct {
SenderType sender_type;
select (Sender.sender_type) {
case member:
uint32 leaf_index;
case external:
uint32 sender_index;
case new_member_commit:
case new_member_proposal:
struct{};
}
} Sender;Variants§
Member(LeafNodeIndex)
The sender is a member of the group
External(SenderExtensionIndex)
The sender is not a member of the group and has an external value instead The index refers to the crate::extensions::ExternalSendersExtension and is 0 indexed
NewMemberProposal
The sender is a new member of the group that joins itself through an External Add proposal
NewMemberCommit
The sender is a new member of the group that joins itself through an External Commit
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Sender
impl<'de> Deserialize<'de> for Sender
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
Source§impl Deserialize for Sender
impl Deserialize for Sender
Source§fn tls_deserialize<R: Read>(bytes: &mut R) -> Result<Self, Error>
fn tls_deserialize<R: Read>(bytes: &mut R) -> Result<Self, Error>
Available on crate feature
std only.This function deserializes the
bytes from the provided a std::io::Read
and returns the populated struct. Read moreSource§impl DeserializeBytes for Sender
impl DeserializeBytes for Sender
Source§impl From<FrankenSender> for Sender
Available on crate features test-utils only.
impl From<FrankenSender> for Sender
Available on crate features
test-utils only.Source§fn from(value: FrankenSender) -> Self
fn from(value: FrankenSender) -> Self
Converts to this type from the input type.
Source§impl From<Sender> for FrankenSender
Available on crate features test-utils only.
impl From<Sender> for FrankenSender
Available on crate features
test-utils only.Source§impl Serialize for &Sender
impl Serialize for &Sender
Source§impl Serialize for Sender
impl Serialize for Sender
impl Eq for Sender
impl StructuralPartialEq for Sender
Auto Trait Implementations§
impl Freeze for Sender
impl RefUnwindSafe for Sender
impl Send for Sender
impl Sync for Sender
impl Unpin for Sender
impl UnwindSafe for Sender
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
§impl<T> Classify for T
impl<T> Classify for T
type Classified = T
fn classify(self) -> T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> Declassify for T
impl<T> Declassify for T
type Declassified = T
fn declassify(self) -> T
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more