<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" 
  elementFormDefault="qualified">

  <xs:annotation>
    <xs:documentation>
      This schema specifies the format of a directory listing.
    </xs:documentation>
  </xs:annotation>

  <xs:element name="directory">
    <xs:annotation>
      <xs:documentation>
        Directory listing.
      </xs:documentation>
    </xs:annotation>
    <xs:complexType>
      <xs:sequence>
        <xs:element ref="entry" minOccurs="0" maxOccurs="unbounded"/>
      </xs:sequence>
    </xs:complexType>
  </xs:element>

  <xs:element name="entry">
    <xs:annotation>
      <xs:documentation>
        One entry in the directory. It's identified by its name. Depending on
        the requested view it may contain additional data as subelements.
      </xs:documentation>
    </xs:annotation>
    <xs:complexType>
      <xs:sequence>
        <xs:any minOccurs="0" maxOccurs="unbounded" processContents="lax"/>
      </xs:sequence>
      <xs:attribute name="name" type="xs:string"/>
    </xs:complexType>
  </xs:element>

</xs:schema>
