pub struct CancelTimerMsg {
pub timer_id: u64,
}Expand description
A message to cancel a specific timer.
This message stops a running timer identified by its unique ID. If the timer has already completed or been cancelled, this message has no effect.
§Fields
timer_id- The unique identifier of the timer to cancel
§Examples
use bubbletea_rs::event::{CancelTimerMsg, next_timer_id};
// Cancel a specific timer
let timer_id = next_timer_id();
let cancel_msg = CancelTimerMsg { timer_id };Fields§
§timer_id: u64The unique identifier of the timer to cancel.
Trait Implementations§
Source§impl Clone for CancelTimerMsg
impl Clone for CancelTimerMsg
Source§fn clone(&self) -> CancelTimerMsg
fn clone(&self) -> CancelTimerMsg
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 moreAuto Trait Implementations§
impl Freeze for CancelTimerMsg
impl RefUnwindSafe for CancelTimerMsg
impl Send for CancelTimerMsg
impl Sync for CancelTimerMsg
impl Unpin for CancelTimerMsg
impl UnwindSafe for CancelTimerMsg
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