W3C home > Mailing lists > Public > xmlschema-dev@w3.org > January 2010

help with xsd

From: apollo <apollo135@gmail.com>
Date: Fri, 15 Jan 2010 03:14:31 +0100
Message-ID: <4B4FCF87.40500@gmail.com>
To: xmlschema-dev@w3.org
Hi

I am a new-user of xsd, and at the moment I got confusing with some stuff
Could someone please correct me if we can declare something like:

<xsd:sequence>
   <xsd:element name="var_name" type="xsd:string"/>

<!-- this means optional. which is similar to  
<xsd:element name="var_name" type="xsd:string" use="optional"/> 
--> 

   <xsd:element name="var_value" type="xsd:integer" use="required"/>
</xsd:sequence>

In some stuff, it is mentioned that  'use="optional/required" ' can be 
added to attribute only. but elements are instances of attributes . Is 
this correct?

Thanks for reply
Received on Friday, 15 January 2010 08:58:01 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 11 January 2011 00:15:16 GMT