<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema" xml:lang="en">
  <xsd:annotation>
    <xsd:documentation>
      NagiosGen config schema for bcfg2
      Chris St. Pierre
    </xsd:documentation>
  </xsd:annotation>

  <xsd:complexType name="NagiosGenGroupType">
    <xsd:choice minOccurs="1" maxOccurs="unbounded">
      <xsd:element name="Option" type="OptionType"/>
      <xsd:element name="Group" type="NagiosGenGroupType"/>
      <xsd:element name="Client" type="NagiosGenGroupType"/>
    </xsd:choice>
    <xsd:attribute type="xsd:string" name="name" use="required"/>
    <xsd:attribute type="xsd:string" name="negate"/>
  </xsd:complexType>

  <xsd:complexType name="OptionType" mixed="true">
    <xsd:attribute type="xsd:string" name="name" use="required"/>
  </xsd:complexType>

  <xsd:element name="NagiosGen">
    <xsd:complexType>
      <xsd:choice minOccurs="1" maxOccurs="unbounded">
        <xsd:element name="Group" type="NagiosGenGroupType"/>
        <xsd:element name="Client" type="NagiosGenGroupType"/>
      </xsd:choice>
    </xsd:complexType>
  </xsd:element>
</xsd:schema>
