axis-c-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Samisa Abeysinghe <>
Subject The Stub base cllass
Date Wed, 26 May 2004 05:32:20 GMT
Hi All,
   At last, here it is!!! (see below)
   I had to do many changes like adding copy constructors to get this stub working.
   The hard part was not to write this stub class, but to get the rest of the code behave
in a way
to support setting SOAP/Transport headers.
   I have commited the changes to other classes but not this Stub class.

   I tested this and it works. This means that at the stub level, HTTP headers, SOAP headers
be set.
Sample usage:
    InteropTestPortType ws(endpoint); //create stub object
    ws.setEndPoint( "http://localhost:8080/axis/services/echo" );
    ws.setTransportProperty( "Accept-Language", " da, en-gb;q=0.8, en;q=0.7" );
    IHeaderBlock* phb = ws.createHeaderBlock( "Trans", "m", ""

   However there remains much more work: change stub generation to inherit from this class;
get/remove methods for SOAP/HTTP header manipulation etc...

   Your comments on this are welcome.

class Stub
        Stub(const char* pchEndpointUri);
        virtual ~Stub();
        int initilizeCall();
        void setEndPoint(char* pcEndPoint);
        void setTransportProperty(const char* pcKey, const char* pcValue);
        IHeaderBlock* createHeaderBlock(AxisChar *pachLocalName,
                AxisChar *pachPrefix, AxisChar *pachUri);

        void setTransportProperties();
        void setSOAPHeaders();
        Call* m_pCall;
        vector <char*> m_vKeys;
        vector <char*> m_vValues;
        vector <IHeaderBlock*> m_vSOAPHeaderBlocks;


Do you Yahoo!?
Friends.  Fun.  Try the all-new Yahoo! Messenger. 

View raw message