What's the difference between boost::io_service poll_one and run_one?

前端 未结 1 478
深忆病人
深忆病人 2020-12-10 06:16

io_service::poll_one Run the io_service object\'s event processing loop to execute one ready handler.

vs

io_ser

相关标签:
1条回答
  • 2020-12-10 06:44

    poll_one will return immediately (non-blocking) in case there is no event to process.

    run_one will block the calling thread until one event is ready to process.

    You could also check some documentation here

    0 讨论(0)
提交回复
热议问题