As the title states. The main part that I am having trouble with is making the elements not appear more than once. For some reason I cannot figure it out. I thought the min and max occurs would solve the problem.
Here are the specifications for the elements, and below that is the code I have so far.
<!--
13.1. The element info has an optional updated element. If present, appears exactly once.
Represents the last day and time the feed was updated on your company’s servers.
13.2. The element info has an optional copyright element. If present, appears exactly once.
Represents the copyright holder of the feed data.
13.3. The element info has an optional location element. If present, appears exactly once.
Represents the physical location of the company with the feed.
13.3.1. These three elements can appear in any order, and all three are optional.
-->
<xs:element name="info" >
<xs:complexType mixed="true">
<xs:choice minOccurs="0" maxOccurs="unbounded">
<xs:element ref="target:updated" minOccurs="0" maxOccurs="1" />
<xs:element ref="target:copyright" minOccurs="0" maxOccurs="1" />
<xs:element ref="target:location" minOccurs="0" maxOccurs="1" />
</xs:choice>
</xs:complexType>
</xs:element>
In XSD 1.0, Use xs:all element.
<xs:element name="info" >
<xs:complexType mixed="true">
<xs:all>
<xs:element ref="target:updated" minOccurs="0" maxOccurs="1" />
<xs:element ref="target:copyright" minOccurs="0" maxOccurs="1" />
<xs:element ref="target:location" minOccurs="0" maxOccurs="1" />
</xs:all>
</xs:complexType>
</xs:element>