MCPcopy Create free account
hub / github.com/chenshuo/muduo / print

Method print

examples/asio/tutorial/timer4/timer.cc:21–34  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

19 }
20
21 void print()
22 {
23 if (count_ < 5)
24 {
25 std::cout << count_ << "\n";
26 ++count_;
27
28 loop_->runAfter(1, std::bind(&Printer::print, this));
29 }
30 else
31 {
32 loop_->quit();
33 }
34 }
35
36private:
37 muduo::net::EventLoop* loop_;

Callers

nothing calls this directly

Calls 2

runAfterMethod · 0.80
quitMethod · 0.45

Tested by

no test coverage detected