pub struct BorrowedPlainMessage<'a> {
    pub typ: ContentType,
    pub version: ProtocolVersion,
    pub payload: &'a [u8],
}
Expand description

A TLS frame, named TLSPlaintext in the standard.

This type differs from OpaqueMessage because it borrows its payload. You can make a OpaqueMessage from an BorrowMessage, but this involves a copy.

This type also cannot decode its internals and cannot be read/encoded; only OpaqueMessage can do that.

Fields

typ: ContentTypeversion: ProtocolVersionpayload: &'a [u8]

Implementations

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more
Immutably borrows from an owned value. Read more
Mutably borrows from an owned value. Read more

Returns the argument unchanged.

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.