cpp-msgpack-rpc
0.2.0
An RPC library implementing MessagePack RPC.
Toggle main menu visibility
Loading...
Searching...
No Matches
i_server_impl.h
Go to the documentation of this file.
1
/*
2
* Copyright 2023 MusicScience37 (Kenta Kabashima)
3
*
4
* Licensed under the Apache License, Version 2.0 (the "License");
5
* you may not use this file except in compliance with the License.
6
* You may obtain a copy of the License at
7
*
8
* http://www.apache.org/licenses/LICENSE-2.0
9
*
10
* Unless required by applicable law or agreed to in writing, software
11
* distributed under the License is distributed on an "AS IS" BASIS,
12
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
* See the License for the specific language governing permissions and
14
* limitations under the License.
15
*/
20
#pragma once
21
22
#include <memory>
23
#include <vector>
24
25
#include "
msgpack_rpc/addresses/uri.h
"
26
#include "
msgpack_rpc/executors/i_executor.h
"
27
28
namespace
msgpack_rpc::servers::impl
{
29
33
class
IServerImpl {
34
public
:
38
virtual
void
stop
() = 0;
39
45
virtual
void
run_until_signal
() = 0;
46
52
[[nodiscard]]
virtual
std::vector<addresses::URI>
local_endpoint_uris
() = 0;
53
62
[[nodiscard]]
virtual
std::shared_ptr<executors::IExecutor>
executor
() = 0;
63
64
IServerImpl
(
const
IServerImpl&) =
delete
;
65
IServerImpl
(IServerImpl&&) =
delete
;
66
IServerImpl& operator=(
const
IServerImpl&) =
delete
;
67
IServerImpl& operator=(IServerImpl&&) =
delete
;
68
70
virtual
~IServerImpl
() noexcept = default;
71
72
protected:
74
IServerImpl() noexcept = default;
75
};
76
77
}
// namespace msgpack_rpc::servers::impl
msgpack_rpc::servers::impl::IServerImpl::local_endpoint_uris
virtual std::vector< addresses::URI > local_endpoint_uris()=0
Get the URIs of the local endpoints in this server.
msgpack_rpc::servers::impl::IServerImpl::run_until_signal
virtual void run_until_signal()=0
Run processing of this server until SIGINT or SIGTERM is received.
msgpack_rpc::servers::impl::IServerImpl::~IServerImpl
virtual ~IServerImpl() noexcept=default
Destructor.
msgpack_rpc::servers::impl::IServerImpl::executor
virtual std::shared_ptr< executors::IExecutor > executor()=0
Get the executor.
msgpack_rpc::servers::impl::IServerImpl::stop
virtual void stop()=0
Stop processing of this server.
msgpack_rpc::servers::impl::IServerImpl::IServerImpl
IServerImpl() noexcept=default
Constructor.
i_executor.h
Definition of IExecutor class.
msgpack_rpc::servers::impl
Namespace of internal implementation.
Definition
i_server_builder_impl.h:33
uri.h
Definition of URI class.
include
msgpack_rpc
servers
impl
i_server_impl.h
Generated on
for cpp-msgpack-rpc by
1.18.0