<!--
		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="StudentAssessmentTaskResultType">
    <xs:annotation>
      <xs:appinfo>
        <sifChar />
        <privacyRating>High</privacyRating>
      </xs:appinfo>
      <xs:documentation>Records the result achieved by a single student at a particular assessment task.</xs:documentation>
    </xs:annotation>
    <xs:sequence>
      <xs:element name="StudentAssessmentTaskResultRefId" 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="StudentAssessmentTaskResultLocalId" 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="NZQAEntryId" minOccurs="0" nillable="true" type="xs:normalizedString">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The student's NZQA entry Id provided upon confirmation of the student's registration
        to be assessed against a unit or achievement standard. Identifies what entry the result
        is for to NZQA.
      </xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="AssessmentTask" minOccurs="0" nillable="true" type="ObjectReferenceType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>Reference to the AssessmentTask the student was assessed against and the result is for.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="StudentAssessmentTask" minOccurs="0" nillable="true" type="ObjectReferenceType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>Reference to the StudentAssessmentTask data object that the assessment result belongs to.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="Student" minOccurs="0" type="StudentObjectReferenceType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>M</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>Generic object reference to the student held in the StudentPersonal
         data object whose assessment task result this is.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="AssessmentType" minOccurs="0" nillable="true" type="NZCodeSetsAssessmentTypeType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The type of assessment the result is for.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="AssessmentMethodology" minOccurs="0" type="NZCodeSetsAssessmentMethodologyType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>M</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>Code denoting the nature of the assessment process;  Primary assessment against NZ Curriculum or Te Marautanga
      o Aotearoa; Secondary assessment against NCEA, Cambridge, International Baccalaureate, or similar.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="ProviderInvolvedList" minOccurs="0" type="ProviderInvolvedListType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>M</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation />
        </xs:annotation>
      </xs:element>
      <xs:element name="StaffInvolvedList" minOccurs="0" nillable="true" type="StaffInvolvedListType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>A list of the staff involved and their role in relation to the assessment task, e.g. the moderator, the marker.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="ProviderCourse" minOccurs="0" nillable="true" type="ObjectReferenceType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>Reference to the ProviderCourse that this assessment task belongs to.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="LearningStandardList" minOccurs="0" nillable="true" type="LearningStandardListType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>A list of references to the LearningStandards the assessment task result is related to.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="SubjectAreaList" minOccurs="0" nillable="true" type="SubjectAreaListType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>A list of the subject areas that the assessment pertains to.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="AssessedAtYearLevel" minOccurs="0" nillable="true">
        <xs:simpleType>
          <xs:restriction base="xs:int">
            <xs:annotation>
              <xs:appinfo>
                <sifChar>O</sifChar>
                <privacyRating>Low</privacyRating>
              </xs:appinfo>
              <xs:documentation>Year Level of the Assessment Task the student is being assessed against. May only contain the values 1 through to 13 inclusive.</xs:documentation>
            </xs:annotation>
            <xs:minInclusive value="1" xmlns:xs="http://www.w3.org/2001/XMLSchema" />
            <xs:maxInclusive value="13" xmlns:xs="http://www.w3.org/2001/XMLSchema" />
          </xs:restriction>
        </xs:simpleType>
      </xs:element>
      <xs:element name="Curriculum" minOccurs="0" nillable="true" type="NZCodeSetsCurriculumType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>Code denoting the Year Level of the Assessment Task the result is for.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="AssessmentToolUsed" minOccurs="0" nillable="true" type="NZCodeSetsAssessmentToolType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The type of assessment tool used for the assessment task. Both the original free text value sent by the SMS vendors
       and the value it is mapped to in this code set are held.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="AssessmentToolTest" minOccurs="0" nillable="true" type="NZCodeSetsAssessmentToolTestType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The tests available within an assessment tool that is being used by this assessment task.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="Timeframe" minOccurs="0" nillable="true" type="NZCodeSetsAssessmentTimeframeType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The timeframe of the assessment, e.g. Mid-Year, End of Year.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="AssessmentAttempt" minOccurs="0" nillable="true" type="xs:int">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The attempt number the student is making to pass this assessment, e.g. is it their first, second attempt.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="EvaluationType" minOccurs="0" nillable="true" type="NZCodeSetsAssessmentEvaluationTypeType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The type of assessment evaluation, e.g. formative or summative.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="StandardType" minOccurs="0" nillable="true" type="NZCodeSetsLearningStandardTypeType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The type of standard the result is for. Applies to secondary level assessments, e.g. unit and achievement standards, scholarships and International Baccalaureate.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="DateMarked" minOccurs="0" nillable="true" type="xs:date">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>Date the assessment task was marked.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="DateTimeAssessed" minOccurs="0" nillable="true" type="xs:dateTime">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The date and time the student was assessed against the assessment task.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="DateStudentNotified" minOccurs="0" nillable="true" type="xs:date">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The date the student was notified of their final mark for the assessment task.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="NZQAConfirmation" minOccurs="0" nillable="true" type="NZCodeSetsYesOrNoCategoryType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>Confirmation from NZQA that they have received the result record for the student.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="Published" minOccurs="0" nillable="true" type="NZCodeSetsYesOrNoCategoryType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>Indicates whether or not the result has been published.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="PublishedDate" minOccurs="0" nillable="true" type="xs:date">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The date the assessment task result was first published in a report.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="Iteration" minOccurs="0" nillable="true" type="xs:int">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The iteration of this result for the assessment,
          e.g. some tasks require multiple assessments before being achieved.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="CreditsAchieved" minOccurs="0" nillable="true" type="xs:decimal">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>The number of credits the student achieved.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="ResultScoreList" minOccurs="0" type="AssessmentResultScoreListType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>M</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>A list of the assessment result scores that the student received for this assessment task.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="Weight" minOccurs="0" nillable="true" type="xs:decimal">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>Weight placed upon this result</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="EffortComment" 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 effort the student made for the assessment.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="OtherComment" minOccurs="0" nillable="true" type="xs:normalizedString">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>Free text comments providing additional information for the students assessment result.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="DocumentList" minOccurs="0" nillable="true" type="DocumentListType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</sifChar>
            <privacyRating>Low</privacyRating>
          </xs:appinfo>
          <xs:documentation>List which describes the meta-data for, and the Location of any associated documents.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="RecordAudit" minOccurs="0" nillable="true" type="RecordAuditType">
        <xs:annotation>
          <xs:appinfo>
            <sifChar>O</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="StudentAssessmentTaskResult" type="StudentAssessmentTaskResultType">
    <xs:unique name="StudentAssessmentTaskResultKey1">
      <xs:selector xpath="." />
      <xs:field xpath="./StudentAssessmentTaskResultRefId" />
    </xs:unique>
  </xs:element>

  <xs:complexType name="StudentAssessmentTaskResultCollectionType">
    <xs:sequence>
      <xs:element name="StudentAssessmentTaskResult" type="StudentAssessmentTaskResultType" minOccurs="0" maxOccurs="unbounded" />
    </xs:sequence>
  </xs:complexType>
  <xs:element name="StudentAssessmentTaskResults" type="StudentAssessmentTaskResultCollectionType" />

</xs:schema>