#[non_exhaustive]pub enum Output<'a> {
Packet(&'a [u8]),
Timeout(Instant),
Connected,
PeerCert(&'a [u8]),
KeyingMaterial(KeyingMaterial, SrtpProfile),
ApplicationData(&'a [u8]),
}Expand description
Output events produced by the DTLS engine when polled.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Packet(&'a [u8])
A DTLS record to transmit on the wire.
Timeout(Instant)
Schedule a timer and call Dtls::handle_timeout at this instant.
This is always the last variant returned by a poll cycle.
Internal state is only consistent after reaching Timeout.
Connected
The handshake completed and the connection is established.
PeerCert(&'a [u8])
The peer’s leaf certificate in DER encoding.
Applications must validate this certificate independently (chain, name/EKU checks, pinning, etc.).
KeyingMaterial(KeyingMaterial, SrtpProfile)
Extracted DTLS-SRTP keying material and selected SRTP profile.
ApplicationData(&'a [u8])
Received application data plaintext.
Trait Implementations§
Auto Trait Implementations§
impl<'a> Freeze for Output<'a>
impl<'a> RefUnwindSafe for Output<'a>
impl<'a> Send for Output<'a>
impl<'a> Sync for Output<'a>
impl<'a> Unpin for Output<'a>
impl<'a> UnsafeUnpin for Output<'a>
impl<'a> UnwindSafe for Output<'a>
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