<!--SIF Implementation Specification UK 1.1-4 (September 18, 2009)-->
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" targetNamespace="http://www.sifinfo.org/uk/infrastructure/2.x" xmlns:sif="http://www.sifinfo.org/uk/infrastructure/2.x" elementFormDefault="qualified">
  <xs:import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="imports/xml/xml.xsd" />
  <xs:complexType name="LearnerAssessmentResponseSetType">
    <xs:annotation>
      <xs:documentation>The set of all responses provided by a learner while taking an assessment. This information represents the raw input data that is then evaluated to produce one or more scores, marks, or grades for the learner.</xs:documentation>
    </xs:annotation>
    <xs:sequence>
      <xs:element name="Items">
        <xs:complexType>
          <xs:sequence>
            <xs:element name="Item" minOccurs="0" maxOccurs="unbounded">
              <xs:complexType>
                <xs:sequence>
                  <xs:element name="Response" type="xs:string">
                    <xs:annotation>
                      <xs:documentation>Learner selection or response in raw format.</xs:documentation>
                    </xs:annotation>
                  </xs:element>
                  <xs:element name="ResponseStatus" minOccurs="0" nillable="true">
                    <xs:annotation>
                      <xs:documentation>Status of the response.</xs:documentation>
                    </xs:annotation>
                    <xs:simpleType>
                      <xs:restriction base="xs:token">
                        <xs:enumeration value="Correct" />
                        <xs:enumeration value="Incorrect" />
                        <xs:enumeration value="Complete" />
                        <xs:enumeration value="PartiallyComplete" />
                        <xs:enumeration value="Viewed" />
                        <xs:enumeration value="NotViewed" />
                        <xs:enumeration value="NotAnswered" />
                        <xs:enumeration value="Attempted (viewed but no response given)" />
                        <xs:enumeration value="Incomplete" />
                      </xs:restriction>
                    </xs:simpleType>
                  </xs:element>
                  <xs:element name="ResponseTime" minOccurs="0" nillable="true" type="xs:duration">
                    <xs:annotation>
                      <xs:documentation>The length of time the learner took to respond.</xs:documentation>
                    </xs:annotation>
                  </xs:element>
                  <xs:element name="Mark" minOccurs="0" nillable="true" type="xs:normalizedString">
                    <xs:annotation>
                      <xs:documentation>The mark achieved for this item as evaluated by the assessment tool at the time of assessment.</xs:documentation>
                    </xs:annotation>
                  </xs:element>
                  <xs:element name="Group" minOccurs="0" nillable="true" type="xs:normalizedString">
                    <xs:annotation>
                      <xs:documentation>The item group within the assessment.</xs:documentation>
                    </xs:annotation>
                  </xs:element>
                  <xs:element name="ItemName" minOccurs="0" nillable="true" type="xs:token">
                    <xs:annotation>
                      <xs:documentation>Identifies the item on the assessment by name.</xs:documentation>
                    </xs:annotation>
                  </xs:element>
                  <xs:element name="ItemNumber" minOccurs="0" nillable="true" type="xs:token">
                    <xs:annotation>
                      <xs:documentation>Identifies the item by number on the assessment.</xs:documentation>
                    </xs:annotation>
                  </xs:element>
                  <xs:element name="OrderAsked" minOccurs="0" nillable="true" type="xs:decimal">
                    <xs:annotation>
                      <xs:documentation>The order in which the item was asked.</xs:documentation>
                    </xs:annotation>
                  </xs:element>
                  <xs:element name="NumberOfAttempts" minOccurs="0" nillable="true" type="xs:unsignedInt">
                    <xs:annotation>
                      <xs:documentation>The number of times a learner changes their answer or attempts a response.</xs:documentation>
                    </xs:annotation>
                  </xs:element>
                </xs:sequence>
              </xs:complexType>
            </xs:element>
          </xs:sequence>
        </xs:complexType>
      </xs:element>
      <xs:element name="SIF_Metadata" minOccurs="0" nillable="true" type="sif:SIF_MetadataType" />
      <xs:element name="SIF_ExtendedElements" minOccurs="0" nillable="true" type="sif:SIF_ExtendedElementsType">
        <xs:key name="SIF_ExtendedElementsKey9">
          <xs:selector xpath="./sif:SIF_ExtendedElement" />
          <xs:field xpath="@Name" />
        </xs:key>
      </xs:element>
    </xs:sequence>
    <xs:attribute name="RefId" use="required" type="sif:RefIdType">
      <xs:annotation>
        <xs:documentation>The ID (GUID) that uniquely identifies this response set.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="AssessmentResponseComponentRefId" use="required" type="sif:IdRefType">
      <xs:annotation>
        <xs:documentation>The ID (GUID) of the assessment response component that the responses are associated with</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="LearnerPersonalRefId" use="required" type="sif:IdRefType">
      <xs:annotation>
        <xs:documentation>The ID (GUID) of the Learner for whom these responses are.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
  </xs:complexType>

  <xs:element name="LearnerAssessmentResponseSet" type="sif:LearnerAssessmentResponseSetType">
    <xs:key name="LearnerAssessmentResponseSetKey1">
      <xs:selector xpath="." />
      <xs:field xpath="@RefId" />
    </xs:key>
  </xs:element>

</xs:schema>