| Home | Libraries | People | FAQ | More

##### basic_deadline_timer::expires_from_now (2 of 3 overloads)

Set the timer's expiry time relative to now.

    std::size_t expires_from_now(
        const duration_type & expiry_time);

This function sets the expiry time. Any pending asynchronous wait operations will be cancelled. The handler for each cancelled operation will be invoked with the boost::asio::error::operation_aborted error code.

###### Parameters

expiry_time

  The expiry time to be used for the timer.

###### Return Value

The number of asynchronous operations that were cancelled.

###### Exceptions

boost::system::system_error

  Thrown on failure.