8#include "./someip_rpc_message.h"
26 const uint8_t mProtocolVersion;
27 const uint8_t mInterfaceVersion;
28 std::map<uint32_t, uint16_t> mSessionIds;
29 std::map<uint32_t, HandlerType> mHandlers;
36 uint8_t protocolVersion,
37 uint8_t interfaceVersion)
noexcept;
41 void InvokeHandler(
const std::vector<uint8_t> &payload)
const;
45 virtual void Send(
const std::vector<uint8_t> &payload) = 0;
53 uint16_t serviceId, uint16_t methodId,
HandlerType handler);
64 const std::vector<uint8_t> &rpcPayload);
SOME/IP RPC abstract client.
Definition: rpc_client.h:20
virtual void Send(const std::vector< uint8_t > &payload)=0
Send a SOME/IP request to the RPC server.
void InvokeHandler(const std::vector< uint8_t > &payload) const
Invoke corresponding response handler at a message reception.
Definition: rpc_client.cpp:18
void SetHandler(uint16_t serviceId, uint16_t methodId, HandlerType handler)
Set a RPC response handler.
Definition: rpc_client.cpp:37
std::function< void(const SomeIpRpcMessage &)> HandlerType
SOME/IP RPC response handler type.
Definition: rpc_client.h:23
RpcClient(uint8_t protocolVersion, uint8_t interfaceVersion) noexcept
Constructor.
Definition: rpc_client.cpp:11
SOME/IP remote procedure call message.
Definition: someip_rpc_message.h:16