Orbit Framework 2.0.0
A high-performance asynchronous C++20 HTTP server framework.
Loading...
Searching...
No Matches
legacy_namespaces.hpp
Go to the documentation of this file.
1#pragma once
2
3// Orbit's public API lives in namespace orbit (orbit::server, orbit::http,
4// ...) since 2.0 (#39). The old top-level names stay available as aliases so
5// code written for 1.x keeps compiling:
6//
7// server::App app(cfg); // same as orbit::server::App
8//
9// They put generic names such as server, http and config in the global
10// namespace, which clashes with any code that uses those names itself.
11// Define ORBIT_NO_LEGACY_NAMESPACES (before including any Orbit header, or
12// on the compiler command line) to leave them out. They will be removed in
13// Orbit 3.0.
14
15namespace orbit {
16namespace concurrency {}
17namespace config {}
18namespace database {}
19namespace http {}
20namespace middleware {}
21namespace network {}
22namespace openapi {}
23namespace orm {}
24namespace routing {}
25namespace server {}
26namespace utils {}
27namespace websocket {}
28} // namespace orbit
29
30#ifndef ORBIT_NO_LEGACY_NAMESPACES
32namespace config = orbit::config;
33namespace database = orbit::database;
34namespace http = orbit::http;
36namespace network = orbit::network;
37namespace openapi = orbit::openapi;
38namespace orm = orbit::orm;
39namespace routing = orbit::routing;
40namespace server = orbit::server;
41namespace utils = orbit::utils;
42namespace websocket = orbit::websocket;
43#endif
Definition Awaitable.hpp:10
Definition Config.hpp:8
Definition ConnectionPool.hpp:14
Definition Task.hpp:10
Definition HttpRequest.hpp:19
Definition Http2Session.hpp:21
Definition legacy_namespaces.hpp:22
Definition legacy_namespaces.hpp:23
Definition legacy_namespaces.hpp:24
Definition Http2Session.hpp:18
Definition legacy_namespaces.hpp:26
Definition legacy_namespaces.hpp:27
Definition Awaitable.hpp:10