I've successfully deployed an axis java server and was
trying the c++ client to access it.  My test function
takes a string and returns a string. The wsdl2ws
program produced a wrapper function that takes two
string and retruns void, so presumably one of the the
input parameters returns the result by reference. when
I try running my client code, the following message
gets printed out:
m_MsgSize == 0, so return NULL

and nothing gets written to my result parameter.
What's going wrong? 
My client code:


#include "ProtegeServerHeartVascularization.h"
int main()
{
        char result[512];
        char cls[512];
        strcpy (cls, "Heart");
        ProtegeServerHeartVascularization p;
        p.getClassName(cls, result);
        printf("result = %s\n", result);
        printf("Done.\n");
        return 0;
}

And the getClassName code that was automatically
generated by wsdl2ws:

void
ProtegeServerHeartVascularization::getClassName(xsd__string
Value0, xsd__string Value1)
{
        if (AXIS_SUCCESS !=
m_pCall->Initialize(CPP_RPC_PROVIDER, NORMAL_CHANNEL))
return ;
        m_pCall->SetTransportProperty(SOAPACTION_HEADER ,
"");
        m_pCall->SetSOAPVersion(SOAP_VER_1_1);
        m_pCall->SetOperation("getClassName",
"http://fonseca.stanford.edu:8081/axis/services/ProtegeServerHeartVascularization";);
        m_pCall->AddParameter((void*)&Value0, "in0",
XSD_STRING);
        m_pCall->AddParameter((void*)&Value1,
"getClassNameReturn", XSD_STRING);
        if (AXIS_SUCCESS == m_pCall->Invoke())
        {
                if(AXIS_SUCCESS ==
m_pCall->CheckMessage("getClassNameResponse",
"http://foo.bar.edu/axis/services/ProtegeServerHeartVascularization";))
                {
                        /*not successful*/
                }
        }
        m_pCall->UnInitialize();
}



        
                
__________________________________
Do you Yahoo!?
Friends.  Fun.  Try the all-new Yahoo! Messenger.
http://messenger.yahoo.com/ 

Reply via email to