axis-c-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "David Taylor (Lowell)" <dktay...@F5.com>
Subject xs:any minOccurs Check is Wrong
Date Tue, 11 Nov 2008 22:59:57 GMT
I have a WSDL that I am using to generate ADB stubs.  This WSDL includes
a type with xs:any that is causing the stub to have code generated to
check for at least 1 element in the list, even though the element lists
minOccurs="0".  Here's the fragment of the WSDL:

 

 

            <complexType name="ItemListType">

                        <sequence maxOccurs="unbounded">

                                    <any namespace="##other"
processContents="lax" minOccurs="0" maxOccurs="unbounded" />

                        </sequence>

            </complexType>

 

Here is the erroneous check in the generated stub deserialize function:

 

                                   if (i < 1)

                                   {

                                     /* found element out of order */

                                     AXIS2_LOG_ERROR(env->log,
AXIS2_LOG_SI, "ItemListTypeSequence (@minOccurs = '1') only have %d
elements", i);

                                     if(element_qname)

                                     {

                                        axutil_qname_free(element_qname,
env);

                                     }

                                     if(arr_list)

                                     {

                                        axutil_array_list_free(arr_list,
env);

                                     }

                                     return AXIS2_FAILURE;

                                   }

 

The problem appears to be that the XSLT stylesheet is looking for an
@any attribute to be set, to avoid generating this section of code.  It
seems that the xs:any element should set this attribute.  However, I
can't figure out where that attribute should be set.  Any help would be
greatly appreciated.

Thanks,

-David

 


Mime
View raw message