Skip to content

Instantly share code, notes, and snippets.

@acanakoglu
Created October 12, 2017 15:13
Show Gist options
  • Save acanakoglu/33905b4d9dd7e9c07f5eea347ef0ef4e to your computer and use it in GitHub Desktop.
Save acanakoglu/33905b4d9dd7e9c07f5eea347ef0ef4e to your computer and use it in GitHub Desktop.
<?xml version="1.0" encoding="ISO-8859-1" ?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">
<xs:element name="reservation_list">
<xs:complexType>
<xs:sequence>
<xs:element name="reservation" minOccurs="0" maxOccurs="unbounded">
<xs:complexType>
<xs:sequence>
<xs:element name="customer">
<xs:complexType>
<xs:sequence>
<!-- name and surname has single occurance and middle name is optinal can be multiple -->
<xs:element type="xs:string" name="name"/>
<xs:element type="xs:string" name="middle_name" minOccurs="0" maxOccurs="unbounded"/>
<xs:element type="xs:string" name="surname"/>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="trip">
<xs:complexType>
<xs:sequence>
<xs:element type="xs:string" name="destination"/>
<xs:element type="xs:string" name="date"/>
<xs:element type="xs:string" name="transportation" minOccurs="1" maxOccurs="unbounded"/>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:sequence>
</xs:complexType>
</xs:element>
</xs:schema>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment