|
Orbit Framework
An ultra-modern, asynchronous, cross-platform C++ Web Framework.
|
Manages the server's event loop, handling I/O operations and dispatching tasks. More...
#include <EventLoop.hpp>
Public Member Functions | |
| EventLoop (Listener &listener, const routing::Router &router, const config::ServerConfig &config, network::TlsContext *tls_context=nullptr, network::UdpSocket *quic_socket=nullptr, QuicConnectionManager *quic_manager=nullptr) | |
| Constructs an EventLoop. | |
| void | run () |
| Starts the event loop. | |
| void | stop () |
| Stops the event loop. | |
| void | stop_accepting () |
| Stops accepting new connections but continues processing existing ones. | |
| concurrency::ThreadPool & | get_thread_pool () |
| Gets the thread pool. | |
Manages the server's event loop, handling I/O operations and dispatching tasks.
| server::EventLoop::EventLoop | ( | Listener & | listener, |
| const routing::Router & | router, | ||
| const config::ServerConfig & | config, | ||
| network::TlsContext * | tls_context = nullptr, |
||
| network::UdpSocket * | quic_socket = nullptr, |
||
| QuicConnectionManager * | quic_manager = nullptr |
||
| ) |
Constructs an EventLoop.
| listener | The server listener. |
| router | The router instance. |
| config | The server configuration. |
| tls_context | The TLS context (optional). |
| quic_socket | The QUIC UDP socket (optional). |
| quic_manager | The QUIC connection manager (optional). |
|
inline |
Gets the thread pool.
| void server::EventLoop::run | ( | ) |
Starts the event loop.
| void server::EventLoop::stop | ( | ) |
Stops the event loop.
| void server::EventLoop::stop_accepting | ( | ) |
Stops accepting new connections but continues processing existing ones.