Boost ASIO async operation

I have read the tutorials from the boost docs.

I care more about the async operation framework.

What I need is:
After finishing a function 'A', call the function 'B'.

The tutorial always needs a timer, but What I provide is a function 'A'.


Should I create a timer whose expired time is 0, then I call A and B together in the timer's handler?





> Should I create a timer whose expired time is 0

No; the tutorial has a timer because it is about using a timer asynchronously.

Here's an example of using asynchronous network operations:
https://theboostcpplibraries.com/boost.asio-network-programming
Topic archived. No new replies allowed.