[
Lists Home |
Date Index |
Thread Index
]
In fact, i use SourceGenerator in castor project to generate the sourcecode. So, should i change it by hand? I had thought the castor is fine.
<xs:simpleType name='MyEnum' >
<xs:restriction base='xs:QName' >
<xs:enumeration value='foo:Val1' />
<xs:enumeration value='foo:Val2' />
<xs:enumeration value='foo:Val3' />
</xs:restriction>
</xs:simpleType>
<xs:simpleType name='MyOpenEnum' >
<xs:union memberTypes='tns:MyEnum xs:QName' />
</xs:simpleType>
<xs:element name='MyData' type='tns:MyOpenEnum' />
Best Regards.
Chen Peng Keenmicro
Email:pchen@keenmicro.com
MSN: jacky_chenp@hotmail.com
----- Original Message -----
From: "Rich Salz" <rsalz@datapower.com>
To: "jacky" <jacky_chenp@ustc.edu>
Cc: "Jonathan Robie" <jonathan.robie@datadirect.com>; <xml-dev@lists.xml.org>
Sent: Friday, October 15, 2004 7:33 PM
Subject: Re: [xml-dev] Element declaring
> > but, in the code, MyData is the String type. That means i can't use a MyEnum instance for MyData.
> > Is that right?
>
> I guess so. :) It complete depends on how your environment binds XML and
> programming language types. It's not a generic question.
> /r$
> --
> Rich Salz Chief Security Architect
> DataPower Technology http://www.datapower.com
> XS40 XML Security Gateway http://www.datapower.com/products/xs40.html
> XML Security Overview http://www.datapower.com/xmldev/xmlsecurity.html
>
>
|