00001
00002
00003 #ifndef BASE_SOAP_SOAPHTTPTRANSPORT_H
00004 #define BASE_SOAP_SOAPHTTPTRANSPORT_H
00005
00006 #include "libppbase/base_http/HTTPServer.h"
00007 #include "SOAPTransport.h"
00008
00009 namespace base_soap {
00011
00015 class PPBASE_SOAP_EXPORT SOAPHTTPTransport: public SOAPTransport {
00016 public:
00018 SOAPHTTPTransport();
00019
00021
00026 SOAPHTTPTransport(const base::String &name, base::Socket *sock, const base::String &addr);
00027
00029 virtual ~SOAPHTTPTransport();
00030
00032
00038 SOAPResponse *invoke(SOAPRequest &request, bool throwex = true, int timeout = 300);
00039
00041
00049 SOAPResponse *invoke(SOAPRequest &request, const base::String &host, int port = 0, bool throwex = true, int timeout = 300);
00050
00052
00055 SOAPRequest *readRequest();
00056
00058
00061 void sendResponse(const SOAPResponse *response);
00062
00063 private:
00065
00068 SOAPRequest *parseRequest();
00069
00071
00076 SOAPResponse *parseResponse(const base::String &host, bool throwex);
00077
00078 base_http::HTTPServer *_http;
00079 base_http::HTTPRequest *_request;
00080 base_http::HTTPResponse *_response;
00081 };
00082 }
00083
00084 #endif