<!--
		SIF Implementation Specification (New Zealand) 3.1
		(8 December, 2020
)
		
		Infrastructure Version: v3.1
	-->
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns="http://www.sifassociation.org/datamodel/nz/3.1" targetNamespace="http://www.sifassociation.org/datamodel/nz/3.1" elementFormDefault="qualified" version="3.1 (rc 5)">
  <xs:complexType name="StudentLearningSupportResponseType">
    <xs:annotation>
      <xs:appinfo>
        <sifChar />
        <privacyRating>Low</privacyRating>
      </xs:appinfo>
      <xs:documentation>Provides information about a response provided for a students learning support need.</xs:documentation>
    </xs:annotation>
    <xs:sequence>
      <xs:element name="StudentLearningSupportResponseRefId" minOccurs="0" nillable="true" type="RefIdType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The universally unique identifier for the data object record that is used across systems.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="StudentLearningSupportResponseLocalId" minOccurs="0" nillable="true" type="LocalIdType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The Id of the data object record that was provided by the system that the information was originally sourced from.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="Student" type="StudentObjectReferenceType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>M</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The student that the learning support need response its for.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="Provider" type="ProviderObjectReferenceType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>M</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The provider that created this learning support need reponse.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="LearningSupportNeed" type="ObjectReferenceType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>M</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The learning support need the reponse is for.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="ResponseType" type="NZCodeSetsLearningSupportResponseTypeType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>M</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The type of response provided to the student to support the need.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="ResponseDetail" minOccurs="0" nillable="true" type="NZCodeSetsLearningSupportResponseDetailType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>Code set denoting the additional detail about the response type provided to the student to support the need.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="ReviewDate" type="xs:date">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>M</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The date the response is due to be reviewed.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="ResponseGoals" minOccurs="0" nillable="true" type="xs:normalizedString">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The goals of the response in relation to the student's learning support need.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="ResponseNote" minOccurs="0" nillable="true" type="xs:normalizedString">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>Free text notes about the response.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="NoteList" minOccurs="0" nillable="true" type="NoteListType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>High</privacyRating>
          </xs:appinfo>
          <xs:documentation>A list of notes that have been written about the learning support response.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="ResponseDesc" minOccurs="0" nillable="true" type="xs:normalizedString">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>Free text description about the response type and detail. Mandatory when a response detail of 'Other' is selected.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="TierOfResponse" minOccurs="0" nillable="true" type="NZCodeSetsLearningSupportResponseTierType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The tier of response for the learning support need response.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:choice>
        <xs:element name="ExternalResponse" minOccurs="0" nillable="true" type="SupportNeedExternalResponseType">
          <xs:annotation>
            <xs:appinfo>
              <sifChar>C</sifChar>
              <privacyRating>Low</privacyRating>
            </xs:appinfo>
            <xs:documentation>Additional information for an external response.</xs:documentation>
          </xs:annotation>
        </xs:element>
        <xs:element name="InternalResponse" minOccurs="0" nillable="true" type="SupportNeedInternalResponseType">
          <xs:annotation>
            <xs:appinfo>
              <sifChar>C</sifChar>
              <privacyRating>Low</privacyRating>
            </xs:appinfo>
            <xs:documentation>Additional information for an internal response.</xs:documentation>
          </xs:annotation>
        </xs:element>
      </xs:choice>
      <xs:element name="ReviewList" minOccurs="0" nillable="true" type="SupportNeedResponseReviewListType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>A list of the reviews made about the response.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="AttachmentList" minOccurs="0" nillable="true" type="DocumentListType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>A list of attachments associated to the learning support need response.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="CompletionDate" minOccurs="0" nillable="true" type="xs:date">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The date the response was completed.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="Outcome" minOccurs="0" nillable="true" type="NZCodeSetsLearningSupportResponseOutcomeType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The outcome of the response.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="OutcomeComment" minOccurs="0" nillable="true" type="xs:normalizedString">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>Free text comment about the outcome of the response made for the students learning support need.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="ClosureStatus" minOccurs="0" nillable="true" type="NZCodeSetsLearningSupportResponseClosureStatusType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The status of the learning support need response when it is closed.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="ClosureStatusDetail" minOccurs="0" nillable="true" type="xs:normalizedString">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>Additional detail about the responses closure status.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="CompletionNote" minOccurs="0" nillable="true" type="xs:normalizedString">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>Free text notes about the completion of the response to the students learning support need.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="RecordAudit" type="RecordAuditType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>M</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The audit details for a record, e.g. Created/Last Updated DateTime and Created/Last Updated By.</xs:documentation>
        </xs:annotation>
      </xs:element>
    </xs:sequence>
  </xs:complexType>

  <xs:element name="StudentLearningSupportResponse" type="StudentLearningSupportResponseType">
    <xs:key name="StudentLearningSupportResponseKey1">
      <xs:selector xpath="." />
      <xs:field xpath="./StudentLearningSupportResponseRefId" />
    </xs:key>
  </xs:element>

  <xs:complexType name="StudentLearningSupportResponseCollectionType">
    <xs:sequence>
      <xs:element name="StudentLearningSupportResponse" type="StudentLearningSupportResponseType" minOccurs="0" maxOccurs="unbounded" />
    </xs:sequence>
  </xs:complexType>
  <xs:element name="StudentLearningSupportResponses" type="StudentLearningSupportResponseCollectionType" />

</xs:schema>