| Fast DDS Version 3.3.0 Fast DDS

Loading...
Searching...
No Matches
RpcServer.hpp
1// Copyright 2025 Proyectos y Sistemas de Mantenimiento SL (eProsima).
2//
3// Licensed under the Apache License, Version 2.0 (the "License");
4// you may not use this file except in compliance with the License.
5// You may obtain a copy of the License at
6//
7// http://www.apache.org/licenses/LICENSE-2.0
8//
9// Unless required by applicable law or agreed to in writing, software
10// distributed under the License is distributed on an "AS IS" BASIS,
11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12// See the License for the specific language governing permissions and
13// limitations under the License.
14
18
19#ifndef FASTDDS_DDS_RPC_INTERFACES__RPCSERVER_HPP
20#define FASTDDS_DDS_RPC_INTERFACES__RPCSERVER_HPP
21
22#include <memory>
23
24 namespace eprosima {
25 namespace fastdds {
26 namespace dds {
27 namespace rpc {
28
29// Forward declaration of RpcRequest class.
30 class RpcRequest;
31
35 class RpcServer
36{
37 public:
38
42 virtual ~RpcServer() noexcept = default;
43
50 virtual void run() = 0;
51
58 virtual void stop() = 0;
59
65 virtual void execute_request(
66 const std::shared_ptr<RpcRequest>& request) = 0;
67
68};
69
70} // namespace rpc
71} // namespace dds
72} // namespace fastdds
73} // namespace eprosima
74
75#endif // FASTDDS_DDS_RPC_INTERFACES__RPCSERVER_HPP
eprosima::fastdds::dds::rpc::RpcRequest
An interface with generic RPC requests functionality.
Definition RpcRequest.hpp:34
eprosima::fastdds::dds::rpc::RpcServer
An interface with generic RPC server functionality.
Definition RpcServer.hpp:36
eprosima::fastdds::dds::rpc::RpcServer::stop
virtual void stop()=0
Stop the server.
eprosima::fastdds::dds::rpc::RpcServer::~RpcServer
virtual ~RpcServer() noexcept=default
Destructor.
eprosima::fastdds::dds::rpc::RpcServer::run
virtual void run()=0
Run the server.
eprosima::fastdds::dds::rpc::RpcServer::execute_request
virtual void execute_request(const std::shared_ptr< RpcRequest > &request)=0
Perform execution of a client request.
eprosima::fastdds::dds::rpc
Definition DomainParticipant.hpp:59
eprosima::fastdds::dds
Definition BuiltinTopicKey.hpp:26
eprosima::fastdds
eprosima
eProsima namespace.
std
Definition EntityId_t.hpp:388