cpp-msgpack-rpc 0.2.0
An RPC library implementing MessagePack RPC.
|
Class of internal implementation of clients. More...
#include <msgpack_rpc/clients/impl/client_impl.h>
Public Member Functions | |
ClientImpl (ClientImpl &&)=delete | |
ClientImpl (const ClientImpl &)=delete | |
ClientImpl (std::shared_ptr< ClientConnector > connector, std::shared_ptr< CallList > call_list, std::shared_ptr< executors::IAsyncExecutor > executor, std::shared_ptr< logging::Logger > logger) | |
Constructor. | |
~ClientImpl () override | |
Destructor. | |
std::shared_ptr< ICallFutureImpl > | async_call (messages::MethodNameView method_name, const IParametersSerializer ¶meters) override |
Asynchronously call a method. | |
std::shared_ptr< executors::IExecutor > | executor () override |
Get the executor. | |
void | notify (messages::MethodNameView method_name, const IParametersSerializer ¶meters) override |
Notify to a method. | |
ClientImpl & | operator= (ClientImpl &&)=delete |
ClientImpl & | operator= (const ClientImpl &)=delete |
void | start () |
Start processing of this client. | |
void | stop () override |
Stop processing of this client. | |
Public Member Functions inherited from msgpack_rpc::clients::impl::IClientImpl | |
IClientImpl (const IClientImpl &)=delete | |
IClientImpl (IClientImpl &&)=delete | |
virtual | ~IClientImpl () noexcept=default |
Destructor. | |
IClientImpl & | operator= (const IClientImpl &)=delete |
IClientImpl & | operator= (IClientImpl &&)=delete |
Private Member Functions | |
void | check_executor_state () |
Check whether the executor is running. |
Private Attributes | |
std::shared_ptr< CallList > | call_list_ |
List of RPCs. | |
std::shared_ptr< ClientConnector > | connector_ |
Connector. | |
std::shared_ptr< executors::IAsyncExecutor > | executor_ |
Executor. | |
std::atomic< bool > | is_started_ {false} |
Whether this client has been started. | |
std::atomic< bool > | is_stopped_ {false} |
Whether this client has been stopped. | |
std::shared_ptr< logging::Logger > | logger_ |
Logger. | |
std::shared_ptr< MessageSender > | sender_ |
Sender of messages. |
Additional Inherited Members | |
Protected Member Functions inherited from msgpack_rpc::clients::impl::IClientImpl | |
IClientImpl () noexcept=default | |
Constructor. |
Class of internal implementation of clients.
Definition at line 48 of file client_impl.h.
|
inline |
Constructor.
[in] | connector | Connector. |
[in] | call_list | List of RPCs. |
[in] | executor | Executor. |
[in] | logger | Logger. |
Definition at line 58 of file client_impl.h.
|
inlineoverride |
Destructor.
Definition at line 71 of file client_impl.h.
|
inlinenodiscardoverridevirtual |
Asynchronously call a method.
[in] | method_name | Name of the method. |
[in] | parameters | Parameters. |
Implements msgpack_rpc::clients::impl::IClientImpl.
Definition at line 127 of file client_impl.h.
|
inlineprivate |
Check whether the executor is running.
Definition at line 165 of file client_impl.h.
|
inlinenodiscardoverridevirtual |
Get the executor.
Implements msgpack_rpc::clients::impl::IClientImpl.
Definition at line 157 of file client_impl.h.
|
inlineoverridevirtual |
Notify to a method.
[in] | method_name | Name of the method. |
[in] | parameters | Parameters. |
Implements msgpack_rpc::clients::impl::IClientImpl.
Definition at line 144 of file client_impl.h.
|
inline |
Start processing of this client.
Definition at line 90 of file client_impl.h.
|
inlineoverridevirtual |
Stop processing of this client.
Implements msgpack_rpc::clients::impl::IClientImpl.
Definition at line 111 of file client_impl.h.
|
private |
List of RPCs.
Definition at line 179 of file client_impl.h.
|
private |
Connector.
Definition at line 176 of file client_impl.h.
|
private |
Executor.
Definition at line 173 of file client_impl.h.
|
private |
Whether this client has been started.
Definition at line 188 of file client_impl.h.
|
private |
Whether this client has been stopped.
Definition at line 191 of file client_impl.h.
|
private |
Logger.
Definition at line 182 of file client_impl.h.
|
private |
Sender of messages.
Definition at line 185 of file client_impl.h.