<?xml version="1.0" encoding="utf-8" ?> 
<xs:schema targetNamespace="urn:esr-vha-gov:internal:hl7-messages" xmlns="urn:esr-vha-gov:internal:hl7-messages" 
    xmlns:xs="http://www.w3.org/2001/XMLSchema" 
    elementFormDefault="qualified">
<!--	
  <xs:include schemaLocation="edb/messaging/hl7/xsd/HL7Types.xsd" />
  <xs:include schemaLocation="edb/messaging/hl7/xsd/VATables.xsd" />
  <xs:include schemaLocation="edb/messaging/hl7/xsd/zSegments/Common.xsd" />
-->
  <xs:complexType name="zgd.content">
    <xs:annotation>
      <xs:documentation>
        VA Specific Guardian Segment
      </xs:documentation>
    </xs:annotation>
    <xs:complexContent>
      <xs:extension base="anyZSegment.content">
        <xs:sequence>
          <xs:element name="zgd.1" type="si" minOccurs="1" maxOccurs="1" />
          <xs:element name="zgd.2" minOccurs="0" maxOccurs="1">
            <xs:simpleType>
              <xs:restriction base="id">
                <xs:enumeration value="" />
                <xs:enumeration value="1" />
                <xs:enumeration value="2" />
              </xs:restriction>
            </xs:simpleType>
          </xs:element>
          <xs:element name="zgd.3" type="st" minOccurs="0" maxOccurs="1" />
          <xs:element name="zgd.4" type="st" minOccurs="0" maxOccurs="1" />
          <xs:element name="zgd.5" type="st" minOccurs="0" maxOccurs="1" />
          <xs:element name="zgd.6" type="ad" minOccurs="0" maxOccurs="1" />
          <xs:element name="zgd.7" type="tn" minOccurs="0" maxOccurs="1" />
          <xs:element name="zgd.8" type="dt" minOccurs="0" maxOccurs="1" />
        </xs:sequence>
      </xs:extension>
    </xs:complexContent>
  </xs:complexType>

  <xs:element name="zgd" type="zgd.content" substitutionGroup="anyZSegment" />
</xs:schema>
