#[non_exhaustive]pub struct KeyPackage {
    pub version: ProtocolVersion,
    pub cipher_suite: CipherSuite,
    pub hpke_init_key: HpkePublicKey,
    pub extensions: ExtensionList,
    pub signature: Vec<u8>,
    /* private fields */
}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.version: ProtocolVersion§cipher_suite: CipherSuite§hpke_init_key: HpkePublicKey§extensions: ExtensionList§signature: Vec<u8>Implementations§
Source§impl KeyPackage
 
impl KeyPackage
pub fn grease<P: CipherSuiteProvider>(&mut self, cs: &P) -> Result<(), MlsError>
pub fn ungreased_extensions(&self) -> ExtensionList
Source§impl KeyPackage
 
impl KeyPackage
pub fn signing_identity(&self) -> &SigningIdentity
pub fn to_reference<CP: CipherSuiteProvider>( &self, cipher_suite_provider: &CP, ) -> Result<KeyPackageRef, MlsError>
pub fn expiration(&self) -> Result<u64, MlsError>
Trait Implementations§
Source§impl Clone for KeyPackage
 
impl Clone for KeyPackage
Source§fn clone(&self) -> KeyPackage
 
fn clone(&self) -> KeyPackage
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
 
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from 
source. Read moreSource§impl Debug for KeyPackage
 
impl Debug for KeyPackage
Source§impl From<KeyPackage> for AddProposal
 
impl From<KeyPackage> for AddProposal
Source§fn from(key_package: KeyPackage) -> Self
 
fn from(key_package: KeyPackage) -> Self
Converts to this type from the input type.
Source§impl From<KeyPackage> for ExternalReceivedMessage
Available on crate feature external_client only. 
impl From<KeyPackage> for ExternalReceivedMessage
Available on crate feature 
external_client only.Source§fn from(value: KeyPackage) -> Self
 
fn from(value: KeyPackage) -> Self
Converts to this type from the input type.
Source§impl From<KeyPackage> for ReceivedMessage
 
impl From<KeyPackage> for ReceivedMessage
Source§fn from(value: KeyPackage) -> Self
 
fn from(value: KeyPackage) -> Self
Converts to this type from the input type.
Source§impl MlsDecode for KeyPackage
 
impl MlsDecode for KeyPackage
Source§impl MlsEncode for KeyPackage
 
impl MlsEncode for KeyPackage
Source§impl MlsSize for KeyPackage
 
impl MlsSize for KeyPackage
fn mls_encoded_len(&self) -> usize
Source§impl PartialEq for KeyPackage
 
impl PartialEq for KeyPackage
impl StructuralPartialEq for KeyPackage
Auto Trait Implementations§
impl Freeze for KeyPackage
impl RefUnwindSafe for KeyPackage
impl Send for KeyPackage
impl Sync for KeyPackage
impl Unpin for KeyPackage
impl UnwindSafe for KeyPackage
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
Source§impl<T> CloneToUninit for Twhere
    T: Clone,
 
impl<T> CloneToUninit for Twhere
    T: Clone,
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