pub enum StuntClientEvent {
OutputPacket(StunPacket),
RestransmissionTimeOut((TransactionId, Duration)),
Retry(TransactionId),
TransactionFailed((TransactionId, StunTransactionError)),
StunMessageReceived(StunMessage),
}Expand description
Stun client events
Variants§
OutputPacket(StunPacket)
Notification used by the STUN client to send a STUN packet to the server
RestransmissionTimeOut((TransactionId, Duration))
This event sets a timeout for a transaction identified by the TransactionId.
Once the timeout is reached, the client must call the on_timeout method on
the StunClient instance.
If multiple timeouts are scheduled for different outgoing transactions,
the client will only be notified about the most recent timeout.
Retry(TransactionId)
Notification used to retry a transaction identified by the TransactionId.
TransactionFailed((TransactionId, StunTransactionError))
Event used by the STUN client to notify that a transaction identified by the TransactionId
has failed. The StunTransactionError indicates the reason of the failure.
StunMessageReceived(StunMessage)
Event used by the STUN client to notify that a STUN message has been received.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for StuntClientEvent
impl RefUnwindSafe for StuntClientEvent
impl !Send for StuntClientEvent
impl !Sync for StuntClientEvent
impl Unpin for StuntClientEvent
impl UnwindSafe for StuntClientEvent
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