userver
C++ Async Framework
Toggle main menu visibility
Loading...
Searching...
No Matches
component_base.hpp
1
#
pragma
once
2
3
#
include
<
userver
/
components
/
component_base
.
hpp
>
4
#
include
<
userver
/
server
/
server_base
.
hpp
>
5
6
USERVER_NAMESPACE_BEGIN
7
8
namespace
server {
9
10
/// Component integration for HTTP servers registered under the name "server".
11
/// Concrete components own their server and forward component lifecycle callbacks.
12
/// The current implementation is @ref components::Server.
13
class
Component
:
public
components
::
ComponentBase
{
14
public
:
15
/// @ingroup userver_component_names
16
/// @brief The default name of the HTTP server component.
17
static
constexpr
std::string_view
kName
=
"server"
;
18
19
/// @brief Return the HTTP server runtime owned by this component.
20
virtual
ServerBase
&
GetServer
() = 0;
21
22
/// @brief Return the HTTP server runtime owned by this component.
23
virtual
const
ServerBase
&
GetServer
()
const
= 0;
24
25
protected
:
26
using
components
::
ComponentBase
::ComponentBase;
27
};
28
29
}
// namespace server
30
31
USERVER_NAMESPACE_END
userver
server
component_base.hpp
Generated on
for userver by
Doxygen
1.17.0