25 #ifndef CARGO_IPC_METHOD_RESULT_HPP
26 #define CARGO_IPC_METHOD_RESULT_HPP
47 typedef std::shared_ptr<MethodResult>
Pointer;
55 template<
typename Data>
56 void set(
const std::shared_ptr<Data>&
data)
62 void setError(
const int code,
const std::string& message);
74 template<
typename SentDataType,
typename ReceivedDataType>
76 typedef std::function <bool(
PeerID peerID,
77 std::shared_ptr<ReceivedDataType>&
data,
84 #endif // CARGO_IPC_METHOD_RESULT_HPP
MethodResult(Processor &processor, const MethodID methodID, const MessageID &messageID, const PeerID &peerID)
Definition: method-result.cpp:33
std::shared_ptr< MethodResult > Pointer
Definition: method-result.hpp:47
std::string PeerID
Definition: types.hpp:45
void setError(const int code, const std::string &message)
Definition: method-result.cpp:53
void set(const std::shared_ptr< Data > &data)
Definition: method-result.hpp:56
void setVoid()
Definition: method-result.cpp:48
char data[368]
Definition: initctl.cpp:41
MessageID mMessageID
Definition: method-result.hpp:69
PeerID getPeerID() const
Definition: method-result.cpp:58
MethodID mMethodID
Definition: method-result.hpp:67
Definition: method-result.hpp:75
unsigned int MethodID
Definition: types.hpp:43
PeerID mPeerID
Definition: method-result.hpp:68
Class used to obtain method call result code.
Definition: method-result.hpp:45
std::function< bool(PeerID peerID, std::shared_ptr< ReceivedDataType > &data, MethodResult::Pointer methodResult) > type
Definition: method-result.hpp:78
This class wraps communication via UX sockets.
Definition: processor.hpp:88
Processor & mProcessor
Definition: method-result.hpp:66
void setInternal(const std::shared_ptr< void > &data)
Definition: method-result.cpp:43
std::string MessageID
Definition: types.hpp:44