SOAPonHTTP.h

Go to the documentation of this file.
00001 
00024 // SOAPonHTTP.h: interface for the SOAPonHTTP class.
00025 // Class Description: Handles sending and receiving messages using
00026 //      the HTTP protocol.  This is based off of the information found
00027 //      in the SOAP v1.1 draft.
00029 
00030 /*
00031 #if !defined(SOAPONHTTP_H)
00032     #include "SOAPonHTTP.h"    
00033 #endif // !defined(SOAPONHTTP_H)
00034 */
00035 
00036 #if !defined(SOAPONHTTP_H)
00037 #define SOAPONHTTP_H
00038 
00039 #if _MSC_VER > 1000
00040 #pragma once
00041 #endif // _MSC_VER > 1000
00042 
00043 #if !defined(SOAPonProtocol_H)
00044     #include "SOAPonProtocol.h"    
00045 #endif // !defined(SOAPonProtocol_H)
00046 
00047 #ifndef _MAP_
00048     #include <map>
00049 #endif // _MAP_
00050 
00051 #ifndef SOCKETADDRESS_H_
00052     #include "SocketAddress.h"
00053 #endif // SOCKETADDRESS_H_
00054 
00055 class SOAPElement;
00056 class SOAPMethod;
00057 
00058 class SOAPonHTTP : SOAPonProtocol
00059 {
00060 public:
00061     // Constructor/Destructor
00062     SOAPonHTTP();
00063     virtual ~SOAPonHTTP();
00064     
00065     // getMethodDetails
00066     // Description: See base class
00067     // Arguments: See base class
00068     // Return value: See base class
00069     virtual bool getMethodDetails( const std::string& KszMessage, 
00070         std::string& szObjectName, std::string& szMethodName, 
00071         SOAPElement& theCall );
00072     
00073     // setHostAndPort
00074     // Description: Sets the host and port of the destination SOAP
00075     //  server.  This method should only be called by SOAP clients
00076     //  (or servers acting as clients).
00077     // Arguments:
00078     //  szHost: Name of the machine.  Can be numeric or character.
00079     // Return value: N/A
00080     void setHostAndPort( std::string szHost, long nPort = 80 );
00081     
00082     // getSendableResponse
00083     // Description: See base class
00084     // Arguments: See base class
00085     // Return value: See base class
00086     virtual std::string getSendableResponse( 
00087         const std::string& szSOAPMessage, bool bIsFault = false );
00088     
00089     // send
00090     // Description: See base class
00091     // Arguments: See base class
00092     // Return value: See base class
00093     virtual std::string send( 
00094         const std::string& szClassName, SOAPMethod& aMethod );
00095     
00096 protected:
00097     
00098     // getSendableMessage
00099     // Description: Called by send to generate a message that
00100     //  is suitable for sending over HTTP.
00101     // Arguments:
00102     //  szSOAPMessage: The message being sent.
00103     //  szClassName: Name of the class being called.
00104     //  szMethodName: Name of the method being called.
00105     // Return value:
00106     virtual std::string getSendableMessage( 
00107         const std::string& szSOAPMessage, 
00108         const std::string& szClassName,
00109         const std::string& szMethodName );
00110     
00111 private:
00112     // SocketAddress 
00113     // Description: Contains the address (IP and Port) of the 
00114     //  server.  Should only be filled in for SOAP clients.
00115     SocketAddress m_socketAddress;
00116 };
00117 
00118 #endif // !defined(SOAPONHTTP_H)

Generated on Tue Mar 28 09:10:15 2006 for Simple SOAP by  doxygen 1.4.6