I forgot to mention, I have fixes for the project files as well.

AxisClientDLL.dsp
Remove AxisConfigException.cpp, AxisEngineException.cpp,
AxisGenException.cpp, AxisParseException.cpp, AxisSoapException.cpp
AxisWsddException.cpp.

transport\axis3\Axis3.dsp
Add soap\apr_base64.cpp
Remove transport\axis3\HTTPTransportException.cpp

transport\axis3\HTTPChannel\HTTPChannel.dsp
remove transport\axis3\HTTPTransportException.cpp

xml\xerces\AxisXMLParserXerces.dsp
remove xml\AxisParseException.cpp


I also found that I needed to change '/MT' to '/MD (multi-threaded to
multi-threaded dll) to get the libraries to load correctly on windows xp
with IE7 (stupid dwmapi.dll issue).

-Ryan

-----Original Message-----
From: McCullough, Ryan [mailto:[EMAIL PROTECTED] 
Sent: Friday, May 23, 2008 10:23 AM
To: Apache AXIS C User List
Cc: [EMAIL PROTECTED]
Subject: RE: No answers?

Here are a list of issues I encountered with the generated soap objects.


1) I found a bug in BeanParamWriter.java.

In writeRestrictionCheckerFunction(), the opening brace '{' was not being
commented out.

writer.write( "//)\n\t{\n");

should be

writer.write( "//)\n");
writer.write( "//\t{\n");

Notice how there was a newline, then a tab and the open brace with no
comment. This caused compilation errors.



2) I also think I found a problem with XSD_DOUBLE and XSD_DATETIME.

I have this in my schema xsd:
<xs:complexType name="ac_value">
    <xs:choice>
        <xs:element name="cval"      minOccurs="0" nillable="true"
type="currency" />
        <xs:element name="dval"      minOccurs="0" nillable="true"
type="xs:double" />
        <xs:element name="ival"      minOccurs="0" nillable="true"
type="xs:long" />
        <xs:element name="sval"      minOccurs="0" nillable="true"
type="xs:string" />
        <xs:element name="tval"      minOccurs="0" nillable="true"
type="dttm" />
    </xs:choice>
</xs:complexType>

It was generating this code in the "Serialize sub-elements." section:
else if(param->dval)
{
        if (param->dval != NULL)
        pSZ->serializeAsElement("dval", Axis_URI_Ac_value,
(void*)(*(param->dval)), XSD_DOUBLE);
}
// snipped irrelevant code
else if(param->tval)
{
        if (param->tval != NULL)
        pSZ->serializeAsElement("tval", Axis_URI_Ac_value,
(void*)(*(param->tval)), XSD_DATETIME);
}

When I tried to compile this file, I received these 2 errors:
error C2440: 'type cast' : cannot convert from 'double' to 'void *'
error C2440: 'type cast' : cannot convert from 'struct tm' to 'void *'

If I removed the de-reference * from param, the compile errors went away.
pSZ->serializeAsElement("dval", Axis_URI_Ac_value, (void*)(param->dval),
XSD_DOUBLE);
pSZ->serializeAsElement("tval", Axis_URI_Ac_value, (void*)(param->tval),
XSD_DATETIME);



3) I received warnings all over the place about peekedElementName not being
used (unreferenced). So, I removed the lines:
// We always use this...
writer.write("\tconst char* peekedElementName;\n");

And then where peekedElementName is used, I added this code:
// We only peek for elements, not element attributes!
if (attribs[i].isOptional() && !attribs[i].isAttribute())
{
    writer.write(tab1 + "\tconst char* peekedElementName" + soapTagName +
";\n");
    writer.write(tab1 + "peekedElementName" + soapTagName + " =
pIWSDZ->peekNextElementName();\n");
    writer.write(tab1 + "if (strcmp(peekedElementName" + soapTagName + ",
\"" + soapTagName + "\") == 0)\n");
    writer.write(tab1 + "{\n");
    tab2 += "\t";
}

if (attribs[i].isOptional())
{
    writer.write(tab1 + "\tconst char* peekedElementName" + soapTagName +
";\n");
    writer.write(tab1 + "peekedElementName" + soapTagName + " =
pIWSDZ->peekNextElementName();\n");
    writer.write(tab1 + "if (strcmp(peekedElementName" + soapTagName + ",
\"" + soapTagName + "\") == 0)\n");
    tab2 += "\t";
}

I had to append the soapTagName to the peekedElementName, otherwise I got
re-definition errors.



4) The fourth issue I had is more specific to my wsdl and c++. I have a
class called timezone, this caused compilation errors because timezone
already exists in vc98\include\time.h. So, what I did was add a function to
CUtils that formats the name of user defined types to start with a capital
letter. I know this is ugly, but it works for me.

I don't expect issue 4 to make it into the source tree, but I would like it
if 1-3 could be considered for inclusion in the WSDL2Ws soap stub generator.

-Ryan

-----Original Message-----
From: Nadir Amra [mailto:[EMAIL PROTECTED] 
Sent: Thursday, May 22, 2008 2:02 PM
To: Apache AXIS C User List
Cc: Apache AXIS C User List
Subject: RE: No answers?

Using 1.5 and 1.6Beta is bad idea...yes, latest code in SVN is better than 
zip distributions.

Nadir Amra
Integrated Web services for i5/OS
IBM Rochester, MN,  (Tel. 507-253-0645, t/l 553-0645)
Internet: [EMAIL PROTECTED]

"McCullough, Ryan" <[EMAIL PROTECTED]> wrote on 05/22/2008 01:58:03 
PM:

> Am I better off using the code in SVN rather than the zip distributions? 
Is
> using 1.5 a bad idea?
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Attachment: smime.p7s
Description: S/MIME cryptographic signature

Reply via email to