Horizon
Loading...
Searching...
No Matches
once.hpp
1#pragma once
2
3namespace horizon {
4class Once {
5public:
6 bool operator()()
7 {
8 if (first) {
9 first = false;
10 return true;
11 }
12 return false;
13 }
14
15private:
16 bool first = true;
17};
18} // namespace horizon
Definition once.hpp:4