﻿<?xml version="1.0" encoding="utf-8"?>
<xs:schema attributeFormDefault="unqualified" elementFormDefault="qualified" targetNamespace="http://wats.virinco.com/schemas/WATS/Report/wsxf" xmlns="http://wats.virinco.com/schemas/WATS/Report/wsxf" xmlns:xs="http://www.w3.org/2001/XMLSchema">
  <xs:element name="Reports">
    <xs:complexType>
      <xs:sequence>
        <xs:element name="Report" minOccurs="0" maxOccurs="unbounded" type="WATSReport"></xs:element>
      </xs:sequence>
    </xs:complexType>
  </xs:element>

  <xs:complexType name="WATSReport">
    <xs:annotation>
      <xs:documentation>Report element for UUT (Unit Under Test) or UUR (Unit Under Repair)</xs:documentation>
    </xs:annotation>
    <xs:sequence>
      <xs:choice minOccurs="0" maxOccurs="1">
        <xs:element name="UUT" minOccurs="0" maxOccurs="1" type="UUT_type" />
        <xs:element name="UUR" minOccurs="0" maxOccurs="1" type="UUR_type" />
      </xs:choice>
      <xs:element name="Process" type="Process_type" minOccurs="1" maxOccurs="1"/>
      <xs:element name="AdditionalData" type="AdditionalData_type" minOccurs="0" maxOccurs="unbounded"/>
      <!--UUT and UUR-->
      <xs:choice minOccurs="0" maxOccurs="unbounded">
        <xs:element name="MiscInfo" minOccurs="0" maxOccurs="unbounded" type="MiscInfo_type" />
        <xs:element name="ReportUnitHierarchy" minOccurs="0" maxOccurs="unbounded" type="ReportUnitHierarchy_type" />
        <xs:element name="Step" minOccurs="0" maxOccurs="1" type="Step_type" />
        <!--
        Elements removed from report, these types must reference a step and are therefore invalid on a Report element.
        <xs:element name="Chart" minOccurs="0" maxOccurs="unbounded" type="Chart_type" />
        <xs:element name="NumericLimit" minOccurs="0" maxOccurs="unbounded" type="NumericLimit_type" />
        <xs:element name="StringValue" minOccurs="0" maxOccurs="unbounded" type="StringValue_type" />
        <xs:element name="PassFail" minOccurs="0" maxOccurs="unbounded" type="PassFail_type" />
        <xs:element name="SequenceCall" minOccurs="0" maxOccurs="unbounded" type="SequenceCall_type" />
        <xs:element name="MessagePopup" minOccurs="0" maxOccurs="unbounded" type="MessagePopup_type" />
        <xs:element name="PropertyLoader" minOccurs="0" maxOccurs="unbounded" type="PropertyLoader_type" />
        <xs:element name="Callexe" minOccurs="0" maxOccurs="unbounded" type="Callexe_type" />
        <xs:element name="AdditionalResults" minOccurs="0" maxOccurs="unbounded" type="AdditionalResults_type" />
        -->
        <xs:element name="ReportInfo" minOccurs="0" maxOccurs="unbounded" type="ReportInfo_type" />
        <xs:element name="Binary" minOccurs="0" maxOccurs="unbounded" type="Binary_type" />
        <xs:element name="Failures" minOccurs="0" maxOccurs="unbounded" type="Failures_type" />
      </xs:choice>
    </xs:sequence>
    <xs:attribute name="type" type="ReportType" use="required">
      <xs:annotation>
        <xs:documentation>Report type is either UUT (Unit Under Test) or UUR (Unit Under Repair)</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="ID" type="guid" use="optional" >
      <xs:annotation>
        <xs:documentation>Globally unique identifier (GUID) identifying a report.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="Start" type="xs:dateTime" use="optional" >
      <xs:annotation>
        <xs:documentation>Date/time when the report was started. Can be specified with or without timezone. If timezone is specified Start_utc attribute can safely be omitted. This value will be used to calculate utc start date/time. Otherwise Start_utc should be specified as well</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="Start_utc" type="xs:dateTime" use="optional" >
      <xs:annotation>
        <xs:documentation>UTC Date/time when the report was started. This value should be specified with Z timezone (UTC) or without timezone. If Start is specified with timezone, this attribute can safely be omitted.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="Result" type="ReportResultType" use="required" >
      <xs:annotation>
        <xs:documentation>Report result, required for UUT (Unit Under Test) and not used for UUR (Unit under Repair). Can be either Passed, Failed, Error or Terminated. </xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="SN" type="xs:string" use="required" >
      <xs:annotation>
        <xs:documentation>Unit's serial number.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="PN" type="xs:string" use="required" >
      <xs:annotation>
        <xs:documentation>Unit's part number.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="Rev" type="xs:string" use="optional" >
      <xs:annotation>
        <xs:documentation>Unit's revision number.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="origin" type="clientId" use="optional" >
      <xs:annotation>
        <xs:documentation>Origin of report. ATE Identifier (A Registered Globally Unique Identifier - GUID).</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="MachineName" type="xs:string" use="optional" >
      <xs:annotation>
        <xs:documentation>Identifying name of ATE (Report origin). Should be unique throughout a WATS Installation.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="Location" type="xs:string" use="optional" >
      <xs:annotation>
        <xs:documentation>ATE Location (Report origin).</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="Purpose" type="xs:string" use="optional" >
      <xs:annotation>
        <xs:documentation>ATE Purpose (Report origin).</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="ProductName" type="xs:string" use="optional" >
      <xs:annotation>
        <xs:documentation>Name of product.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
  </xs:complexType>
  <xs:complexType name="UUT_type">
    <xs:annotation>
      <xs:documentation>UUT (Unit Under Test) additional header information</xs:documentation>
    </xs:annotation>
    <xs:sequence>
      <xs:element name="Comment" type="xs:string" minOccurs="0" maxOccurs="1" />
    </xs:sequence>
    <xs:attribute name="UserLoginName" type="xs:string" use="optional" />
    <xs:attribute name="BatchSN" type="xs:string" use="optional" />
    <xs:attribute name="TestSocketIndex" type="xs:short" use="optional" />
    <xs:attribute name="ExecutionTime" type="xs:double" use="optional" />
    <xs:attribute name="ParameterBaseVersion" type="xs:string" use="optional" />
    <xs:attribute name="FixtureId" type="xs:string" use="optional" />
    <xs:attribute name="ErrorCode" type="xs:int" use="optional" />
    <xs:attribute name="ErrorMessage" type="xs:string" use="optional" />
    <xs:attribute name="BatchLoopIndex" type="xs:int" use="optional" />
    <xs:attribute name="BatchFailCount" type="xs:int" use="optional" />
    <xs:attribute name="StepIdCausedUUTFailure" type="xs:int" use="optional" />
  </xs:complexType>
  <xs:complexType name="UUR_type">
    <xs:annotation>
      <xs:documentation>UUR (Unit Under Repair) additional header information</xs:documentation>
    </xs:annotation>
    <xs:sequence>
      <xs:element name="Comment" type="xs:string" minOccurs="0" maxOccurs="1" />
      <xs:element name="Process" type="Process_type" minOccurs="1" maxOccurs="1" />
      <xs:element name="Children" type="xs:string" minOccurs="0" maxOccurs="unbounded" />
    </xs:sequence>
    <xs:attribute name="UserLoginName" type="xs:string" use="optional" />
    <xs:attribute name="ConfirmDate" type="xs:dateTime" use="optional" />
    <xs:attribute name="FinalizeDate" type="xs:dateTime" use="optional" />
    <xs:attribute name="Active" type="xs:boolean" use="optional" />
    <xs:attribute name="ExecutionTime" type="xs:double" use="optional" />
    <xs:attribute name="ReferencedUUT" type="guid" use="optional" />
    <xs:attribute name="Parent" type="guid" use="optional">
      <xs:annotation>
        <xs:documentation>Reference to parent repair report. This repair report is considered a "sub-repair" if this value is present</xs:documentation>
      </xs:annotation>
    </xs:attribute>
  </xs:complexType>
  <xs:complexType name="Process_type">
    <xs:annotation>
      <xs:documentation>Must reference a valid Process code. The Process code must be marked as a Test operation for UUT Reports, and Repair operation for UUR Reports. The process code specified under the UUR Element is the test operation from the referenced test. Either Code or Name must be specified. Code takes precedence over Name.</xs:documentation>
    </xs:annotation>
    <xs:attribute name="Code" type="xs:short" use="optional" />
    <xs:attribute name="Name" type="xs:string" use="optional" />
  </xs:complexType>

  <xs:complexType name="MiscInfo_type">
    <xs:annotation>
      <xs:documentation>Miscellaneous information about the Unit. Can be specified in both UUT and UUR Reports.</xs:documentation>
    </xs:annotation>
    <xs:simpleContent>
      <xs:extension base="xs:string">
        <xs:attribute name="Typedef" type="xs:string" use="optional" />
        <!-- Required by server. WSXF Converter set to empty string if missing -->
        <xs:attribute name="Id" type="guid" use="optional">
          <xs:annotation>
            <xs:documentation>Unique identifier referencing a valid repair-type miscinfo definition. Only valid in UUR Reports</xs:documentation>
          </xs:annotation>
        </xs:attribute>
        <xs:attribute name="Description" type="xs:string" use="optional" >
          <xs:annotation>
            <xs:documentation>Misc info description. Freetext in UUT Reports, used for looking up a valid repair-type miscinfo definition in UUR Reports.</xs:documentation>
          </xs:annotation>
        </xs:attribute>
        <!--<xs:attribute name="String" type="xs:string" use="optional" />-->
        <!-- Both miscinfo recordtypes use element content for string-value-->
        <xs:attribute name="Numeric" type="xs:short" use="optional" >
          <xs:annotation>
            <xs:documentation>Optional numeric value. Only valid in UUT Reports.</xs:documentation>
          </xs:annotation>
        </xs:attribute>
        <xs:attribute name="idx" type="xs:short" use="optional" >
          <xs:annotation>
            <xs:documentation>Optional internal record index. If present, this value must be unique within a report. Will be generated automatically if not present.</xs:documentation>
          </xs:annotation>
        </xs:attribute>
        <xs:attribute name="order_no" type="xs:short" use="optional" >
          <xs:annotation>
            <xs:documentation>Optional short order value.</xs:documentation>
          </xs:annotation>
        </xs:attribute>
      </xs:extension>
    </xs:simpleContent>
  </xs:complexType>
  <xs:complexType name="ReportUnitHierarchy_type">
    <xs:annotation>
      <xs:documentation>Contains information about unit hierarchy (subunits). If Idx is not specified, all units are considered subunits of the unit under repair. Otherwise one, and only one subunit must be mar</xs:documentation>
    </xs:annotation>
    <xs:attribute name="Idx" type="xs:int" use="optional" >
      <xs:annotation>
        <xs:documentation>Sub-part index. If specified, this value must be unique within a report.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="ParentIDX" type="xs:int" use="optional" >
      <xs:annotation>
        <xs:documentation>Sub-part's parent sub part. Used to define the hierarchy of subparts.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="ReplacedIDX" type="xs:int" use="optional" >
      <xs:annotation>
        <xs:documentation>If specified, indicates that this subpart was replaced by the subpart with the Idx specified in this attribute.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="PartType" type="xs:string" use="optional" >
      <xs:annotation>
        <xs:documentation>Sub-part type or category.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="PN" type="xs:string" use="required" >
      <xs:annotation>
        <xs:documentation>Sub-part's partnumber.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="SN" type="xs:string" use="required" >
      <xs:annotation>
        <xs:documentation>Sub-part's serialnumber.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="Rev" type="xs:string" use="optional" >
      <!-- Required by server. WSXF Converter set to empty string if missing -->
      <xs:annotation>
        <xs:documentation>Sub-part's revision number.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="Position" type="xs:short" use="optional" >
      <xs:annotation>
        <xs:documentation>Optional short sort-order value.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
  </xs:complexType>
  <xs:complexType name="Step_type">
    <xs:annotation>
      <xs:documentation>The hierarchy of teststeps. One, and only one Step must be specified as root step, all other steps will be children of the root step. The main step is known as the root step, and must be a SequenceCall step with a related SequenceCall Element.</xs:documentation>
    </xs:annotation>
    <xs:sequence minOccurs="0">
      <xs:element name="Loop" minOccurs="0">
        <xs:complexType>
          <xs:attribute name="num" type="xs:short" use="optional" />
          <xs:attribute name="passed" type="xs:short" use="optional" />
          <xs:attribute name="failed" type="xs:short" use="optional" />
          <xs:attribute name="ending_index" type="xs:short" use="optional" />
          <xs:attribute name="index" type="xs:short" use="optional" />
        </xs:complexType>
      </xs:element>
      <xs:element name="ReportText" type="xs:string" minOccurs="0"/>
      <xs:choice minOccurs="0" maxOccurs="unbounded">
        <xs:element name="AdditionalResults" minOccurs="0" maxOccurs="unbounded" type="AdditionalResults_type" />
        <xs:element name="NumericLimit" minOccurs="0" maxOccurs="unbounded" type="NumericLimit_type" />
        <xs:element name="StringValue" minOccurs="0" maxOccurs="unbounded" type="StringValue_type" />
        <xs:element name="PassFail" minOccurs="0" maxOccurs="unbounded" type="PassFail_type" />
        <xs:element name="SequenceCall" minOccurs="0" maxOccurs="unbounded" type="SequenceCall_type" />
        <xs:element name="MessagePopup" minOccurs="0" maxOccurs="unbounded" type="MessagePopup_type" />
        <xs:element name="PropertyLoader" minOccurs="0" maxOccurs="unbounded" type="PropertyLoader_type" />
        <xs:element name="Callexe" minOccurs="0" maxOccurs="unbounded" type="Callexe_type" />
        <xs:element name="Chart" minOccurs="0" maxOccurs="1" type="Chart_type" />
        <xs:element name="Attachment" minOccurs="0" maxOccurs="1" type="Attachment_type" />
      </xs:choice>
      <xs:element name="Step" minOccurs="0" maxOccurs="unbounded" type="Step_type" />
    </xs:sequence>
    <xs:attribute name="Id" type="xs:int" use="optional" >
      <xs:annotation>
        <xs:documentation>Step identifier, must be unique within a report.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <!--<xs:attribute name="ParentStepID" type="xs:int" use="optional" >
      <xs:annotation>
        <xs:documentation>Reference to parent step (StepID). Only one step must omit this attribute. This step is known as the root step, and must be a SequenceCall step with a related SequenceCall Element.</xs:documentation>
      </xs:annotation>
    </xs:attribute>-->
    <xs:attribute name="Group" type="StepGroup_type" use="required" >
      <xs:annotation>
        <xs:documentation>Specifies the step group (Setup, Main or Cleanup)</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="Name" type="xs:string" use="required" >
      <xs:annotation>
        <xs:documentation>The step name</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="StepType" type="xs:string" use="optional" >
      <xs:annotation>
        <xs:documentation>Step type or category, use SequenceCall for steps containing childsteps, NumericLimitTest for steps containing Numeric measurements, PassFailTest for steps containing boolean measurements, StringValueTest for steps containing textual measurements</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="Status" type="StepResultType" use="required" >
      <xs:annotation>
        <xs:documentation>The outcome of the test step (step result)</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="total_time" type="xs:double" use="optional" >
      <xs:annotation>
        <xs:documentation>Total time consumed in this test step</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="module_time" type="xs:double" use="optional" >
      <xs:annotation>
        <xs:documentation>Time consumed in the external module</xs:documentation>
      </xs:annotation>
    </xs:attribute>

    <xs:attribute name="StepIndex" type="xs:int" use="optional">
      <xs:annotation>
        <xs:documentation>Design-time step index.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="TSGuid" type="xs:string" use="optional" >
      <xs:annotation>
        <xs:documentation>Design-time step identificator, a base64 encoded globally unique identifier (GUID) prefixed with &quot;ID#:&quot;</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="Idx" type="xs:int" use="optional" >
      <xs:annotation>
        <xs:documentation>Internal Index. If specified, it must be unique within a report</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="StepErrorCode" type="xs:int" use="optional" >
      <xs:annotation>
        <xs:documentation>Step error code. Integer specifying an external error code.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="StepErrorMessage" type="xs:string" use="optional" >
      <xs:annotation>
        <xs:documentation>Step error message. Message from external system with details on the error.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="Start" type="xs:dateTime" use="optional" >
      <xs:annotation>
        <xs:documentation>Step start date/time.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="InteractiveExeNum" type="xs:int" use="optional" >
      <xs:annotation>
        <xs:documentation>Interactive exe-num. This value is a TestStand specific value.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="StepCausedSequenceFailure" type="xs:boolean" use="optional" >
      <xs:annotation>
        <xs:documentation>Indicates if this step caused the parent sequence to fail.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="StepCausedUUTFailure" type="xs:boolean" use="optional" >
      <xs:annotation>
        <xs:documentation>Indicates if this step caused the UUT to fail.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
  </xs:complexType>
  <xs:complexType name="Chart_type">
    <xs:sequence minOccurs="0" maxOccurs="1">
      <xs:element name="Series" minOccurs="0" maxOccurs="unbounded" type="ChartSeries_type"/>
      <!--<xs:element name="Data" type="xs:base64Binary" />-->
    </xs:sequence>
    <!--<xs:attribute name="StepID" type="xs:int" use="required" />-->
    <xs:attribute name="idx" type="xs:short" use="optional" />
    <xs:attribute name="ChartType" type="xs:string" use="optional" />
    <xs:attribute name="Label" type="xs:string" use="optional" />
    <xs:attribute name="PlotName" type="xs:string" use="optional" />
    <xs:attribute name="XLabel" type="xs:string" use="optional" />
    <xs:attribute name="XUnit" type="xs:string" use="optional" />
    <xs:attribute name="YLabel" type="xs:string" use="optional" />
    <xs:attribute name="YUnit" type="xs:string" use="optional" />
    <xs:attribute name="DataType" type="xs:string" use="optional" />
  </xs:complexType>
  <xs:complexType name="NumericLimit_type">
    <xs:annotation>
      <xs:documentation>A numeric limit test. One step may contain many numeric limit test, known as Multiple numeric limit test. for multiple numeric limit tests it is recommended to specify MeasIndex, MeasOrderNumber or both.</xs:documentation>
    </xs:annotation>
    <xs:attribute name="Name" type="xs:string" use="optional" >
      <xs:annotation>
        <xs:documentation>Step Name</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="NumericValue" type="xs:double" use="required" >
      <xs:annotation>
        <xs:documentation>Measured numeric value.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="Units" type="xs:string" use="optional" >
      <xs:annotation>
        <xs:documentation>Unit of measured numeric value.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="CompOperator" type="xs:string" use="required" >
      <xs:annotation>
        <xs:documentation>Comparison operator.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="HighLimit" type="xs:double" use="optional" >
      <xs:annotation>
        <xs:documentation>Upper limit numeric value.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="LowLimit" type="xs:double" use="optional" >
      <xs:annotation>
        <xs:documentation>Lower limit numeric value.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="Status" type="MeasurementResultType" use="required" >
      <xs:annotation>
        <xs:documentation>Measurement limit test outcome.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="MeasIndex" type="xs:int" use="optional" >
      <xs:annotation>
        <xs:documentation>Internal record index. If specified, it must be unique within a step.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="MeasOrderNumber" type="xs:int" use="optional" >
      <xs:annotation>
        <xs:documentation>Measurement order number, recommended to be unique within a report. Can be omitted.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
  </xs:complexType>
  <xs:complexType name="StringValue_type">
    <xs:attribute name="Name" type="xs:string" use="optional" />
    <xs:attribute name="CompOperator" type="xs:string" use="required" />
    <xs:attribute name="StringLimit" type="xs:string" use="optional" />
    <xs:attribute name="StringValue" type="xs:string" use="required" />
    <xs:attribute name="Status" type="MeasurementResultType" use="required" />
    <xs:attribute name="MeasOrderNumber" type="xs:int" use="optional" />
    <xs:attribute name="MeasIndex" type="xs:int" use="optional" />
  </xs:complexType>
  <xs:complexType name="PassFail_type">
    <xs:attribute name="Name" type="xs:string" use="optional" />
    <xs:attribute name="MeasIndex" type="xs:int" use="optional" />
    <xs:attribute name="Status" type="MeasurementResultType" use="required" />
    <xs:attribute name="MeasOrderNumber" type="xs:int" use="optional" />
  </xs:complexType>
  <xs:complexType name="SequenceCall_type">
    <xs:attribute name="Name" type="xs:string" use="optional" />
    <xs:attribute name="Version" type="xs:string" use="optional" />
    <xs:attribute name="Filename" type="xs:string" use="optional" />
    <xs:attribute name="Filepath" type="xs:string" use="optional" />
    <xs:attribute name="MeasIndex" type="xs:int" use="optional" />
  </xs:complexType>
  <xs:complexType name="MessagePopup_type">
    <xs:attribute name="Button" type="xs:short" use="optional" />
    <xs:attribute name="Response" type="xs:string" use="required" />
    <xs:attribute name="MeasIndex" type="xs:int" use="optional" />
  </xs:complexType>
  <xs:complexType name="PropertyLoader_type">
    <xs:attribute name="Read" type="xs:short" use="optional" />
    <xs:attribute name="Applied" type="xs:short" use="optional" />
    <xs:attribute name="MeasIndex" type="xs:int" use="optional" />
  </xs:complexType>
  <xs:complexType name="Callexe_type">
    <xs:attribute name="ExitCode" type="xs:double" use="optional" />
    <xs:attribute name="MeasIndex" type="xs:int" use="optional" />
  </xs:complexType>
  <xs:complexType name="ReportInfo_type">
    <xs:attribute name="key" type="xs:string" use="required" />
    <xs:attribute name="value" type="xs:string" use="required" />
  </xs:complexType>
  <xs:complexType name="Binary_type">
    <xs:sequence>
      <xs:element name="Data">
        <xs:complexType>
          <xs:simpleContent>
            <xs:extension base="xs:base64Binary">
              <xs:attribute name="BinaryDataGUID" type="guid" use="optional" />
              <xs:attribute name="ContentType" type="xs:string" use="optional" />
              <xs:attribute name="size" type="xs:int" use="optional" />
              <xs:attribute name="FileName" type="xs:string" use="optional" />
            </xs:extension>
          </xs:simpleContent>
        </xs:complexType>
      </xs:element>
    </xs:sequence>
    <xs:attribute name="FailIdx" type="xs:int" use="optional" />
    <xs:attribute name="BinaryDataIndex" type="xs:short" use="optional" />
  </xs:complexType>
  <xs:complexType name="Failures_type">
    <xs:sequence>
      <xs:element name="Comment" type="xs:string" minOccurs="0" maxOccurs="unbounded" />
    </xs:sequence>
    <xs:attribute name="Category" type="xs:string" use="optional" />
    <xs:attribute name="Code" type="xs:string" use="required" />
    <xs:attribute name="Idx" type="xs:int" use="optional" />
    <xs:attribute name="PartIdx" type="xs:int" use="optional" />
    <xs:attribute name="CompRef" type="xs:string" use="optional" />
    <xs:attribute name="StepID" type="xs:int" use="optional" />
    <xs:attribute name="StepName" type="xs:string" use="optional" />
    <xs:attribute name="Failcode" type="xs:string" use="optional" />
    <xs:attribute name="FunctionBlock" type="xs:string" use="optional" />
    <xs:attribute name="ArticleNumber" type="xs:string" use="optional" />
    <xs:attribute name="ArticleRevision" type="xs:string" use="optional" />
    <xs:attribute name="ArticleVendor" type="xs:string" use="optional" />
    <xs:attribute name="ArticleDescription" type="xs:string" use="optional"/>
  </xs:complexType>

  <xs:complexType name="AdditionalResults_type">
    <xs:sequence>
      <xs:any minOccurs="0" maxOccurs="unbounded" processContents="lax"/>
    </xs:sequence>
    <xs:attribute name="StepID" type="xs:int" use="optional" />
    <xs:attribute name="Name" type="xs:string" use="required" />
    <xs:attribute name="Idx" type="xs:int" use="optional" />
  </xs:complexType>
  <xs:complexType name="AdditionalData_type">
    <xs:sequence>
      <xs:any minOccurs="0" maxOccurs="unbounded" processContents="lax"/>
    </xs:sequence>
    <xs:attribute name="Name" use="optional">
      <xs:simpleType >
        <xs:restriction base="xs:string">
          <xs:maxLength value="200"/>
        </xs:restriction>
      </xs:simpleType>
    </xs:attribute>
    <xs:attribute name="Idx" type="xs:int" use="optional" />
  </xs:complexType>

  <xs:complexType name="ChartSeries_type">
    <xs:annotation>
      <xs:documentation>A Series element (or XY-plot) contains a semicolon separated list of x-values and y-values. X-values can be omitted for import, and will in such case be generated string with 1 and incremented by 1. This version only supports the XYG datatype.</xs:documentation>
    </xs:annotation>
    <xs:sequence>
      <xs:element name="ydata" minOccurs="1" maxOccurs="1" type="xs:string" >
        <xs:annotation>
          <xs:documentation>Semicolon separeted list of Y values, use invariant culture to avoid misconceptions.</xs:documentation>
        </xs:annotation>
      </xs:element>
      <xs:element name="xdata" minOccurs="0" maxOccurs="1" type="xs:string" >
        <xs:annotation>
          <xs:documentation>Semicolon separeted list of X values, use invariant culture to avoid misconceptions. If omitted on import, autogenerated X values will be created.</xs:documentation>
        </xs:annotation>
      </xs:element>
    </xs:sequence>
    <xs:attribute name="Name" type="xs:string" use="required" >
      <xs:annotation>
        <xs:documentation>Series name (plot-name) for this series.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
    <xs:attribute name="DataType" type="ChartSeriesDataType" use="optional" >
      <xs:annotation>
        <xs:documentation>Only XYG datatype is supported in this version.</xs:documentation>
      </xs:annotation>
    </xs:attribute>
  </xs:complexType>

  <xs:complexType name="Attachment_type">
    <xs:annotation>
      <xs:documentation>
        Element contents contains base-64 encoded contents of attached file.
        Element contents is required for import, but may be suppressed for outputs to preserve bandwith and resources.
        Size attribute can be used to indicate if data output has been suppressed.
      </xs:documentation>
    </xs:annotation>
    <xs:simpleContent>
      <xs:extension base="xs:base64Binary">
        <xs:attribute name="Name" type="xs:string" use="required" >
          <xs:annotation>
            <xs:documentation>Filename of attached document</xs:documentation>
          </xs:annotation>
        </xs:attribute>
        <xs:attribute name="ContentType" type="xs:string" use="required" >
          <xs:annotation>
            <xs:documentation>Content-type (mime-type) of attached document</xs:documentation>
          </xs:annotation>
        </xs:attribute>
        <xs:attribute name="Size" type="xs:int" use="optional">
          <xs:annotation>
            <xs:documentation>Size of attachment (readonly)</xs:documentation>
          </xs:annotation>
        </xs:attribute>
      </xs:extension>
    </xs:simpleContent>
  </xs:complexType>


  <xs:simpleType name="ReportType">
    <xs:annotation>
      <xs:documentation>Simple enumeration to specify reporttype UUT/UUR.</xs:documentation>
    </xs:annotation>
    <xs:restriction base="xs:string">
      <xs:enumeration value="UUT"/>
      <xs:enumeration value="UUR"/>
      <!--<xs:enumeration value="TDD"/>-->
    </xs:restriction>
  </xs:simpleType>
  <xs:simpleType name="ReportResultType">
    <xs:annotation>
      <xs:documentation>Simple enumeration to specify report result Passed/Failed/Error/Terminated.</xs:documentation>
    </xs:annotation>
    <xs:restriction base="xs:string">
      <xs:enumeration value="Passed"/>
      <xs:enumeration value="Failed"/>
      <xs:enumeration value="Error"/>
      <xs:enumeration value="Terminated"/>
    </xs:restriction>
  </xs:simpleType>
  <xs:simpleType name="StepResultType">
    <xs:annotation>
      <xs:documentation>Simple enumeration to specify step or measurement result.</xs:documentation>
    </xs:annotation>
    <xs:restriction base="xs:string">
      <xs:enumeration value="Passed"/>
      <xs:enumeration value="Failed"/>
      <xs:enumeration value="Skipped"/>
      <xs:enumeration value="Error"/>
      <xs:enumeration value="Terminated"/>
      <xs:enumeration value="Unknown"/>
    </xs:restriction>
  </xs:simpleType>
  <xs:simpleType name="MeasurementResultType">
    <xs:annotation>
      <xs:documentation>Simple enumeration to specify boolean measurement result (PassFail).</xs:documentation>
    </xs:annotation>
    <xs:restriction base="xs:string">
      <xs:enumeration value="Passed"/>
      <xs:enumeration value="Failed"/>
      <xs:enumeration value="Skipped"/>
    </xs:restriction>
  </xs:simpleType>
  <xs:simpleType name="StepGroup_type">
    <xs:annotation>
      <xs:documentation>Simple enumeration to specify reporttype UUT/UUR.</xs:documentation>
    </xs:annotation>
    <xs:restriction base="xs:string">
      <xs:enumeration value="Setup"/>
      <xs:enumeration value="Main"/>
      <xs:enumeration value="Cleanup"/>
    </xs:restriction>
  </xs:simpleType>

  <xs:simpleType name="ChartSeriesDataType">
    <xs:annotation>
      <xs:documentation>Chart-Series datatypes.</xs:documentation>
    </xs:annotation>
    <xs:restriction base="xs:string">
      <xs:enumeration value="XYG"/>
    </xs:restriction>
  </xs:simpleType>

  <xs:simpleType name="guid">
    <xs:annotation>
      <xs:documentation xml:lang="en">
        The representation of a GUID, generally the id of an element.
      </xs:documentation>
    </xs:annotation>
    <xs:restriction base="xs:string">
      <xs:pattern value="([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})|(\{[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}\})"/>
    </xs:restriction>
  </xs:simpleType>

  <xs:simpleType name="clientId">
    <xs:annotation>
      <xs:documentation xml:lang="en">
        The representation of a GUID, generally the id of an element.
      </xs:documentation>
    </xs:annotation>
    <xs:restriction base="xs:string">
      <xs:pattern value="([0-9a-fA-F]{12}|[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})|(\{[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}\})"/>
    </xs:restriction>
  </xs:simpleType>
</xs:schema>