|
rad 8.2.0
|
#include <request.hpp>
Public Member Functions | |
| Request () | |
| Request (const void &req_payload) | |
Default copy constructor. | |
| Request (const Request &)=default | |
| Request (Request &&) noexcept=default | |
Default copy constructor. | |
| Request (const Request &)=default | |
| Request (Request &&) noexcept(std::is_nothrow_move_constructible< void >())=default | |
Default assignment operators. | |
| Request & | operator= (const Request &)=default |
| Request & | operator= (Request &&) noexcept=default |
| elt::mal::future< REP_TYPE > | GetReplyFuture () const |
| std::shared_ptr< elt::mal::promise< REP_TYPE > > | GetReplyPromise () const |
| void | SetReplyValue (const REP_TYPE &reply) const |
| template<class T> | |
| void | SetException (const T &e) const |
Default assignment operators. | |
| Request & | operator= (const Request &)=default |
| Request & | operator= (Request &&) noexcept(std::is_nothrow_move_assignable_v< void >)=default |
| const void & | GetRequestPayload () const |
| elt::mal::future< REP_TYPE > | GetReplyFuture () const |
| std::shared_ptr< elt::mal::promise< REP_TYPE > > | GetReplyPromise () const |
| void | SetReplyValue (const REP_TYPE &reply) const |
| void | SetException (const T &e) const |
This class allows to send a MAL reply to a request WITHOUT payload.
| REP_TYPE | Type of the reply's payload. |
|
inline |
Default constructor that creates a promise associated to the MAL reply.
|
default |
|
defaultnoexcept |
|
inlineexplicit |
This constructor copies the payload associated to a MAL request and creates a promise for the MAL reply.
| req_payload | Payload associated to the MAL request. |
| REQ_TYPE | Type of the payload associated to the MAL request. |
|
default |
|
defaultnoexcept |
|
inline |
This method can be used to get the 'future' indicating when a reply is ready to be sent.
|
inline |
This method can be used to get the 'future' indicating when a reply is ready to be sent.
|
inline |
This method can be used to expose the promise that backs the 'future' indicating when a reply is ready to be sent.
In some scenario (see EICSSW-2560) the MAL reply promise is required to live beyond the life time of the Request object.
|
inline |
This method can be used to expose the promise that backs the 'future' indicating when a reply is ready to be sent.
In some scenario (see EICSSW-2560) the MAL reply promise is required to live beyond the life time of the Request object.
|
inline |
This method can be used to retrieve the payload associated to the received MAL request.
|
default |
|
default |
|
defaultnoexcept |
|
defaultnoexcept |
|
inline |
This method allows to set an error reply.
| T | Type of exception, which as a precondition from MAL must derive from elt::mal::MalException. |
| e | Exception containing error description. |
|
inline |
This method allows to set the payload for an ERROR reply.
| T | Type of exception which should derive from elt::mal::MalException. |
| e | Exception containing error description. |
|
inline |
This method allows to set the payload for the OK reply.
| reply | Payload of the reply. |
|
inline |
This method allows to set the payload for the OK reply.
| reply | Payload of the reply. |