pub struct HandshakeType(pub u8);Expand description
The HandshakeType TLS protocol enum. Values in this enum are taken
from the various RFCs covering TLS, and are listed by IANA.
Protocol enumerations in rustls are represented with a struct, which contains the numeric value used on the wire (in this case, u8). Each known value has a named const item on this type – this can be used in a match arm or to access the numeric value.
If a known value does not exist for a value you need, you can simply create it locally:
pub const MyValue: HandshakeType = HandshakeType(123);The Debug impl for this type also looks up and pretty-prints
known named items. Unknown values are formatted in hexadecimal.
Tuple Fields§
§0: u8Implementations§
Source§impl HandshakeType
impl HandshakeType
pub const HelloRequest: Self
pub const ClientHello: Self
pub const ServerHello: Self
pub const HelloVerifyRequest: Self
pub const NewSessionTicket: Self
pub const EndOfEarlyData: Self
pub const HelloRetryRequest: Self
pub const EncryptedExtensions: Self
pub const Certificate: Self
pub const ServerKeyExchange: Self
pub const CertificateRequest: Self
pub const ServerHelloDone: Self
pub const CertificateVerify: Self
pub const ClientKeyExchange: Self
pub const Finished: Self
pub const CertificateURL: Self
pub const CertificateStatus: Self
pub const KeyUpdate: Self
pub const CompressedCertificate: Self
pub const MessageHash: Self
Trait Implementations§
Source§impl Clone for HandshakeType
impl Clone for HandshakeType
Source§fn clone(&self) -> HandshakeType
fn clone(&self) -> HandshakeType
Returns a duplicate 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 HandshakeType
impl Debug for HandshakeType
Source§impl From<HandshakeType> for u8
impl From<HandshakeType> for u8
Source§fn from(x: HandshakeType) -> Self
fn from(x: HandshakeType) -> Self
Converts to this type from the input type.
Source§impl From<u8> for HandshakeType
impl From<u8> for HandshakeType
Source§impl Hash for HandshakeType
impl Hash for HandshakeType
Source§impl PartialEq for HandshakeType
impl PartialEq for HandshakeType
impl Copy for HandshakeType
impl Eq for HandshakeType
impl StructuralPartialEq for HandshakeType
Auto Trait Implementations§
impl Freeze for HandshakeType
impl RefUnwindSafe for HandshakeType
impl Send for HandshakeType
impl Sync for HandshakeType
impl Unpin for HandshakeType
impl UnsafeUnpin for HandshakeType
impl UnwindSafe for HandshakeType
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