| Home | Libraries | People | FAQ | More

### cancel_at

Create a partial completion token adapter that cancels an operation if not complete by the specified absolute time.

    template<
        typename Clock,
        typename Duration>
    partial_cancel_at< Clock > cancel_at(
        const chrono::time_point< Clock, Duration > & expiry,
        cancellation_type_t cancel_type = cancellation_type::terminal);
      » more...

    template<
        typename Clock,
        typename WaitTraits,
        typename Executor,
        typename Duration>
    partial_cancel_at_timer< Clock, WaitTraits, Executor > cancel_at(
        basic_waitable_timer< Clock, WaitTraits, Executor > & timer,
        const chrono::time_point< Clock, Duration > & expiry,
        cancellation_type_t cancel_type = cancellation_type::terminal);
      » more...

Adapt a completion token to cancel an operation if not complete by the specified absolute time.

    template<
        typename CompletionToken,
        typename Clock,
        typename Duration>
    cancel_at_t< decay_t< CompletionToken >, Clock > cancel_at(
        const chrono::time_point< Clock, Duration > & expiry,
        CompletionToken && completion_token);
      » more...

    template<
        typename CompletionToken,
        typename Clock,
        typename Duration>
    cancel_at_t< decay_t< CompletionToken >, Clock > cancel_at(
        const chrono::time_point< Clock, Duration > & expiry,
        cancellation_type_t cancel_type,
        CompletionToken && completion_token);
      » more...

    template<
        typename CompletionToken,
        typename Clock,
        typename WaitTraits,
        typename Executor,
        typename Duration>
    cancel_at_timer< decay_t< CompletionToken >, Clock, WaitTraits, Executor > cancel_at(
        basic_waitable_timer< Clock, WaitTraits, Executor > & timer,
        const chrono::time_point< Clock, Duration > & expiry,
        CompletionToken && completion_token);
      » more...

    template<
        typename CompletionToken,
        typename Clock,
        typename WaitTraits,
        typename Executor,
        typename Duration>
    cancel_at_timer< decay_t< CompletionToken >, Clock, WaitTraits, Executor > cancel_at(
        basic_waitable_timer< Clock, WaitTraits, Executor > & timer,
        const chrono::time_point< Clock, Duration > & expiry,
        cancellation_type_t cancel_type,
        CompletionToken && completion_token);
      » more...

##### Requirements

Header: `boost/asio/cancel_at.hpp`

Convenience header: `boost/asio.hpp`