Trait tbot::util::ChatActionLoop[][src]

pub trait ChatActionLoop: Message {
    fn send_chat_action_in_loop(
        &self,
        action: Action
    ) -> BoxFuture<'_, Result<Infallible, MethodCall>> { ... } }

An utility trait for contexts with a method to send a chat action in a loop.

Provided methods

fn send_chat_action_in_loop(
    &self,
    action: Action
) -> BoxFuture<'_, Result<Infallible, MethodCall>>
[src]

Sends a chat action in an infinite loop, returning only if failed to send the action.

This utility is supposed to be select!ed with another future. As soon as the other future completes, this future is dropped and the chat action is no longer sent.

Loading content...

Implementors

impl<T: Message> ChatActionLoop for T[src]

Loading content...