pub fn send_later<T>(&self, msg: T, after: Duration)
    where
        A: Handler<T>,
        T: Message<Result = ()>,
    {
        let mut addr = self.addr.clone();
        task::spawn(async move {
            task::sleep(after).await;
            addr.send(msg).ok();
        });
    }
/// Sends the message `msg` to self after a specified period of time.
Sends the message `msg` to self after a specified period of time.
Sends the message ` msg ` to self after a specified period of time .
pub fn send_later<T>(&self, msg: T, after: Duration)
    where
        A: Handler<T>,
        T: Message<Result = ()>,
    {
        let mut addr = self.addr.clone();
        task::spawn(async move {
            task::sleep(after).await;
            addr.send(msg).ok();
        });
    }
pub fn send_later < T > ( & self , msg : T , after : Duration ) where A : Handler < T > , T : Message < Result = ( ) > , { let mut addr = self . addr . clone ( ) ; task :: spawn ( async move { task :: sleep ( after ) . await ; addr . send ( msg ) . ok ( ) ; } ) ; }
Sends the message `msg` to self after a specified period of time.
Sends the message ` msg ` to self after a specified period of time .
&self
msg
T
after
Duration
&self
msg
T
after
Duration