axis-c-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dimuthu Gamage <dimut...@gmail.com>
Subject Re: simpleType restrictions not in ADB from codegen
Date Fri, 26 Mar 2010 02:55:34 GMT
Hi Cail,

Yea it is a limitation.

Anyway there will not be a special adb class generated for a simple type. It
will use the base primitive class name. (i.e in your example TestSimpleType
is a axis2_char_t*).
But we should implement some constrain checks to validate the content to
support the simple type restrictions in the setter functions.

But we have a difficulty currently we are not using any pattern matching
library inside axis2/c, so to support facets like "pattern" we may need to
agree on a third party library. But facets like "maxLength" is trivial to
implement. So these are todos in WSDL2C tools.

But remember unless you are expecting tight schema validation from WSDL2C,
you can use simple type restriction with the tool, without affecting the
functionality.

Thanks,
Dimuthu

On Thu, Mar 25, 2010 at 3:13 AM, Cail Borrell <cail.borrell@gmail.com>wrote:

> Hi List
>
> I am using the wsdl2c tool and cannot get my type definitions converted
> to adb properly.
>
> I am using Axis2 1.5.1 and Axis2c 1.6 on MacOSX and generate the
> service skeleton like this.
>
> wsdl2c.sh -uri file:///services.wsdl -ss -sd -d adb -u -f
>
> To be more specific I am trying to get the restrictions from a "simpleType"
> into the adb type.
>
> <xs:simpleType name="TestSimpleType">
>   <xs:restriction base="xs:string">
>     <xs:maxLength value="100"/>
>     <xs:pattern value="[A-Z]"/>
>   </xs:restriction>
> </xs:simpleType>
>
> I get the adb type generated but without the restrictions.
>
> Is this a know limitation or am I just doing something wrong?
>
> Thanks,
> Cail
>



-- 
Thanks,
Dimuthu Gamage

http://www.dimuthu.org
http://www.wso2.org

Mime
View raw message