cpp-msgpack-rpc 0.2.0
An RPC library implementing MessagePack RPC.
|
Class to wrap existing executors. More...
Public Member Functions | |
WrappingExecutor (std::shared_ptr< IExecutor > executor) | |
Constructor. | |
AsioContextType & | context (OperationType type) noexcept override |
Get the context in asio library. | |
bool | is_running () override |
Check whether this executor is running. | |
std::exception_ptr | last_exception () override |
Get the last exception thrown in asynchronous tasks. | |
void | on_exception (std::function< void(std::exception_ptr)> exception_callback) override |
Register a function called when an exception is thrown in asynchronous tasks. | |
void | start () override |
Start internal event loops to process asynchronous tasks. | |
void | stop () override |
Stops operation. | |
Public Member Functions inherited from msgpack_rpc::executors::IAsyncExecutor | |
IAsyncExecutor (const IAsyncExecutor &)=delete | |
IAsyncExecutor (IAsyncExecutor &&)=delete | |
~IAsyncExecutor () noexcept override=default | |
Destructor. | |
IAsyncExecutor & | operator= (const IAsyncExecutor &)=delete |
IAsyncExecutor & | operator= (IAsyncExecutor &&)=delete |
Public Member Functions inherited from msgpack_rpc::executors::IExecutor | |
IExecutor (const IExecutor &)=delete | |
IExecutor (IExecutor &&)=delete | |
virtual | ~IExecutor () noexcept=default |
Destructor. | |
IExecutor & | operator= (const IExecutor &)=delete |
IExecutor & | operator= (IExecutor &&)=delete |
Private Attributes | |
std::shared_ptr< IExecutor > | executor_ |
Executor. |
Additional Inherited Members | |
Protected Member Functions inherited from msgpack_rpc::executors::IAsyncExecutor | |
IAsyncExecutor () noexcept=default | |
Constructor. | |
Protected Member Functions inherited from msgpack_rpc::executors::IExecutor | |
IExecutor () noexcept=default | |
Constructor. |
Class to wrap existing executors.
Definition at line 39 of file wrapping_executor.cpp.
|
inlineexplicit |
Constructor.
[in] | executor | An existing executor. |
Definition at line 46 of file wrapping_executor.cpp.
|
inlineoverridevirtualnoexcept |
Get the context in asio library.
[in] | type | Operation type. |
Implements msgpack_rpc::executors::IExecutor.
Definition at line 50 of file wrapping_executor.cpp.
|
inlinenodiscardoverridevirtual |
Check whether this executor is running.
true | This executor is running. |
false | This executor is not running. |
Implements msgpack_rpc::executors::IAsyncExecutor.
Definition at line 77 of file wrapping_executor.cpp.
|
inlinenodiscardoverridevirtual |
Get the last exception thrown in asynchronous tasks.
Implements msgpack_rpc::executors::IAsyncExecutor.
Definition at line 65 of file wrapping_executor.cpp.
|
inlineoverridevirtual |
Register a function called when an exception is thrown in asynchronous tasks.
[in] | exception_callback | Function called when an exception is thrown in asynchronous tasks. The pointer of the exception is passed as an argument. |
Implements msgpack_rpc::executors::IAsyncExecutor.
Definition at line 70 of file wrapping_executor.cpp.
|
inlineoverridevirtual |
Start internal event loops to process asynchronous tasks.
Implements msgpack_rpc::executors::IAsyncExecutor.
Definition at line 55 of file wrapping_executor.cpp.
|
inlineoverridevirtual |
Stops operation.
Implements msgpack_rpc::executors::IAsyncExecutor.
Definition at line 60 of file wrapping_executor.cpp.
|
private |
Executor.
Definition at line 81 of file wrapping_executor.cpp.