ServiceRequest.hpp
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021
00022
00023
00024
00025
00026
00027
00028
00029
00030
00031 #ifndef __SERVICE_SERVICEREQUEST_H
00032 #define __SERVICE_SERVICEREQUEST_H
00033
00034 namespace mermaid
00035 {
00036 namespace support
00037 {
00038 namespace service
00039 {
00040 class ServiceRequest;
00041 }
00042 }
00043 }
00044
00045 #include <DataBox.hpp>
00046 #include <DataValueVector.hpp>
00047
00048
00049 #include "ServiceRequestState.hpp"
00050
00051 namespace mermaid
00052 {
00053 namespace support
00054 {
00055 namespace service
00056 {
00057
00058 using mermaid::support::data::DataBox;
00059 using mermaid::support::data::DataValueVector;
00060 using boost::shared_ptr;
00061
00062
00063
00064
00065
00066
00067 class ServiceRequest
00068 {
00069 public:
00070 ServiceRequest (std::string requesterEntityName, std::string requesterServiceName, std::string targetEntityName, std::string targetServiceName, std::string targetServiceInterfaceName, int requestId);
00071 ServiceRequest (const ServiceRequest &sar);
00072 ServiceRequest& operator= (const ServiceRequest &sar);
00073
00074 std::string getRequesterEntityName();
00075 std::string getRequesterServiceName();
00076 std::string getTargetEntityName();
00077 std::string getTargetServiceName();
00078 std::string getTargetServiceInterfaceName();
00079 int getRequestId();
00080
00081 shared_ptr<DataBox> getRequestDataBox();
00082 void setRequestDataBox (shared_ptr<DataBox> dataBox);
00083
00084 ServiceRequestState& getState();
00085 void notifySent();
00086 void notifyReplyReceived();
00087
00088 private:
00089
00090 ServiceRequest();
00091
00092 std::string requesterEntityName_;
00093 std::string requesterServiceName_;
00094 std::string targetEntityName_;
00095 std::string targetServiceName_;
00096 std::string targetServiceInterfaceName_;
00097 int requestId_;
00098 shared_ptr<DataBox> requestDataBox_;
00099
00100 ServiceRequestState state_;
00101
00102 };
00103 }
00104 }
00105 }
00106 #endif // __SERVICE_SERVICEREQUEST_H