Condy v1.8
C++ Asynchronous System Call Layer for Linux
Loading...
Searching...
No Matches
context.hpp
Go to the documentation of this file.
1
4
5#pragma once
6
8
9namespace condy {
10
11class Runtime;
12
13namespace detail {
14
15class Context : public ThreadLocalSingleton<Context> {
16public:
17 void init(Runtime *runtime) noexcept { runtime_ = runtime; }
18 void reset() noexcept { runtime_ = nullptr; }
19
20 Runtime *runtime() noexcept { return runtime_; }
21
22private:
23 Runtime *runtime_ = nullptr;
24};
25
26} // namespace detail
27
28} // namespace condy
The event loop runtime for executing asynchronous.
Definition runtime.hpp:36
The main namespace for the Condy library.
Definition condy.hpp:37