<xsd:element name="file_state" substitutionGroup="oval-def:state">
<xsd:annotation>
<xsd:documentation>The file_state element defines the different metadata associate with a Windows file. This includes the path, filename, owner, size, last modified time, version, etc. Please refer to the individual elements in the schema for more details about what each represents.</xsd:documentation>
</xsd:annotation>
<xsd:complexType>
<xsd:complexContent>
<xsd:extension base="oval-def:StateType">
<xsd:sequence>
<xsd:element name="path" type="oval-def:EntityStateStringType" minOccurs="0">
<xsd:annotation>
<xsd:documentation>The path element specifies the absolute path to a file on the machine.</xsd:documentation>
<xsd:appinfo>
<sch:pattern id="filestepath" xmlns:sch="http://purl.oclc.org/dsdl/schematron">
<sch:rule context="win-def:file_state/win-def:path">
<sch:assert test="not(@datatype) or @datatype='string'">
<sch:value-of select="../@id" /> - datatype attribute for the path entity of a file_state should be 'string'</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
</xsd:element>
<xsd:element name="filename" type="oval-def:EntityStateStringType" minOccurs="0">
<xsd:annotation>
<xsd:documentation>The filename element specifies the name of the file.</xsd:documentation>
<xsd:appinfo>
<sch:pattern id="filestefilename" xmlns:sch="http://purl.oclc.org/dsdl/schematron">
<sch:rule context="win-def:file_state/win-def:filename">
<sch:assert test="not(@datatype) or @datatype='string'">
<sch:value-of select="../@id" /> - datatype attribute for the filename entity of a file_state should be 'string'</sch:assert>
<sch:assert test="if (not(@operation) or @operation='equals' or @operation='not equal') then (not(contains(.,'\') or contains(.,'/') or contains(.,':') or contains(.,'*') or contains(.,'?') or contains(.,'>') or contains(.,'|'))) else (1=1)">
<sch:value-of select="../@id" /> - filename entity can not contain the characters / \ : * ? > | </sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
</xsd:element>
<xsd:element name="owner" type="oval-def:EntityStateStringType" minOccurs="0">
<xsd:annotation>
<xsd:documentation>The owner element is a string that contains the name of the owner.</xsd:documentation>
<xsd:appinfo>
<sch:pattern id="filesteowner" xmlns:sch="http://purl.oclc.org/dsdl/schematron">
<sch:rule context="win-def:file_state/win-def:owner">
<sch:assert test="not(@datatype) or @datatype='string'">
<sch:value-of select="../@id" /> - datatype attribute for the owner entity of a file_state should be 'string'</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
</xsd:element>
<xsd:element name="size" type="oval-def:EntityStateIntType" minOccurs="0">
<xsd:annotation>
<xsd:documentation>The size element is the size of the file in bytes.</xsd:documentation>
<xsd:appinfo>
<valid_datatypes>integer</valid_datatypes>
<valid_operators>equals, not equal, greater than, less than, greater than or equal, less than or equal</valid_operators>
<sch:pattern id="filestesize" xmlns:sch="http://purl.oclc.org/dsdl/schematron">
<sch:rule context="win-def:file_state/win-def:size">
<sch:assert test="@datatype='int'">
<sch:value-of select="../@id" /> - datatype attribute for the size entity of a file_state should be 'int'</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
</xsd:element>
<xsd:element name="a_time" type="oval-def:EntityStateIntType" minOccurs="0">
<xsd:annotation>
<xsd:documentation>Time of last access of file. Valid on NTFS but not on FAT formatted disk drives. The string should represent the FILETIME structure which is a 64-bit value representing the number of 100-nanosecond intervals since January 1, 1601 (UTC).</xsd:documentation>
<xsd:appinfo>
<sch:pattern id="filestea_time" xmlns:sch="http://purl.oclc.org/dsdl/schematron">
<sch:rule context="win-def:file_state/win-def:a_time">
<sch:assert test="@datatype='int'">
<sch:value-of select="../@id" /> - datatype attribute for the a_time entity of a file_state should be 'int'</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
</xsd:element>
<xsd:element name="c_time" type="oval-def:EntityStateIntType" minOccurs="0">
<xsd:annotation>
<xsd:documentation>Time of creation of file. Valid on NTFS but not on FAT formatted disk drives. The string should represent the FILETIME structure which is a 64-bit value representing the number of 100-nanosecond intervals since January 1, 1601 (UTC).</xsd:documentation>
<xsd:appinfo>
<sch:pattern id="filestec_time" xmlns:sch="http://purl.oclc.org/dsdl/schematron">
<sch:rule context="win-def:file_state/win-def:c_time">
<sch:assert test="@datatype='int'">
<sch:value-of select="../@id" /> - datatype attribute for the c_time entity of a file_state should be 'int'</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
</xsd:element>
<xsd:element name="m_time" type="oval-def:EntityStateIntType" minOccurs="0">
<xsd:annotation>
<xsd:documentation>Time of last modification of file. The string should represent the FILETIME structure which is a 64-bit value representing the number of 100-nanosecond intervals since January 1, 1601 (UTC).</xsd:documentation>
<xsd:appinfo>
<sch:pattern id="filestem_time" xmlns:sch="http://purl.oclc.org/dsdl/schematron">
<sch:rule context="win-def:file_state/win-def:m_time">
<sch:assert test="@datatype='int'">
<sch:value-of select="../@id" /> - datatype attribute for the m_time entity of a file_state should be 'int'</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
</xsd:element>
<xsd:element name="ms_checksum" type="oval-def:EntityStateStringType" minOccurs="0">
<xsd:annotation>
<xsd:documentation>The ms_checksum element is the md5 checksum of the file as supplied by Microsoft.</xsd:documentation>
<xsd:appinfo>
<sch:pattern id="filestems_checksum" xmlns:sch="http://purl.oclc.org/dsdl/schematron">
<sch:rule context="win-def:file_state/win-def:ms_checksum">
<sch:assert test="not(@datatype) or @datatype='string'">
<sch:value-of select="../@id" /> - datatype attribute for the ms_checksum entity of a file_state should be 'string'</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
</xsd:element>
<xsd:element name="version" type="oval-def:EntityStateStringType" minOccurs="0">
<xsd:annotation>
<xsd:documentation>The version element is the delimited version string of the file.</xsd:documentation>
<xsd:appinfo>
<sch:pattern id="filesteversion" xmlns:sch="http://purl.oclc.org/dsdl/schematron">
<sch:rule context="win-def:file_state/win-def:version">
<sch:assert test="@datatype='version'">
<sch:value-of select="../@id" /> - datatype attribute for the version entity of a file_state should be 'version'</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
</xsd:element>
<xsd:element name="type" type="win-def:EntityStateFileTypeType" minOccurs="0">
<xsd:annotation>
<xsd:documentation>The type element marks whether the file is a directory, named pipe, standard file, etc. These types are the return values for GetFileType, with the exception of FILE_ATTRIBUTE_DIRECTORY which is obtained by looking at GetFileAttributesEx. NOTE: Should this entity be split into two in future versions of the language as there are other values associated with GetFileAttributesEx that are not represented here?</xsd:documentation>
<xsd:appinfo>
<sch:pattern id="filestetype" xmlns:sch="http://purl.oclc.org/dsdl/schematron">
<sch:rule context="win-def:file_state/win-def:type">
<sch:assert test="not(@datatype) or @datatype='string'">
<sch:value-of select="../@id" /> - datatype attribute for the type entity of a file_state should be 'string'</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
</xsd:element>
<xsd:element name="development_class" type="oval-def:EntityStateStringType" minOccurs="0">
<xsd:annotation>
<xsd:documentation>The development_class element allows the distinction to be made between the GDR development environment and the QFE development environment. This field holds the text found in front of the mmmmmm-nnnn version, for example srv03_gdr.</xsd:documentation>
<xsd:appinfo>
<sch:pattern id="filestedevelopment_class" xmlns:sch="http://purl.oclc.org/dsdl/schematron">
<sch:rule context="win-def:file_state/win-def:development_class">
<sch:assert test="not(@datatype) or @datatype='string'">
<sch:value-of select="../@id" /> - datatype attribute for the development_class entity of a file_state should be 'string'</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
</xsd:element>
<xsd:element name="company" type="oval-def:EntityStateStringType" minOccurs="0">
<xsd:annotation>
<xsd:documentation>This entity defines a company name to be found within the version-information structure.</xsd:documentation>
<xsd:appinfo>
<sch:pattern id="filestecompany" xmlns:sch="http://purl.oclc.org/dsdl/schematron">
<sch:rule context="win-def:file_state/win-def:company">
<sch:assert test="not(@datatype) or @datatype='string'">
<sch:value-of select="../@id" /> - datatype attribute for the company entity of a file_state should be 'string'</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
</xsd:element>
<xsd:element name="internal_name" type="oval-def:EntityStateStringType" minOccurs="0">
<xsd:annotation>
<xsd:documentation>This entity defines an internal name to be found within the version-information structure.</xsd:documentation>
<xsd:appinfo>
<sch:pattern id="filesteinternalname" xmlns:sch="http://purl.oclc.org/dsdl/schematron">
<sch:rule context="win-def:file_state/win-def:internal_name">
<sch:assert test="not(@datatype) or @datatype='string'">
<sch:value-of select="../@id" /> - datatype attribute for the internal_name entity of a file_state should be 'string'</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
</xsd:element>
<xsd:element name="language" type="oval-def:EntityStateStringType" minOccurs="0">
<xsd:annotation>
<xsd:documentation>This entity defines a language to be found within the version-information structure.</xsd:documentation>
<xsd:appinfo>
<sch:pattern id="filestelanguage" xmlns:sch="http://purl.oclc.org/dsdl/schematron">
<sch:rule context="win-def:file_state/win-def:language">
<sch:assert test="not(@datatype) or @datatype='string'">
<sch:value-of select="../@id" /> - datatype attribute for the language entity of a file_state should be 'string'</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
</xsd:element>
<xsd:element name="original_filename" type="oval-def:EntityStateStringType" minOccurs="0">
<xsd:annotation>
<xsd:documentation>This entity defines an original filename to be found within the version-information structure.</xsd:documentation>
<xsd:appinfo>
<sch:pattern id="filesteoriginalfilename" xmlns:sch="http://purl.oclc.org/dsdl/schematron">
<sch:rule context="win-def:file_state/win-def:original_filename">
<sch:assert test="not(@datatype) or @datatype='string'">
<sch:value-of select="../@id" /> - datatype attribute for the original_filename entity of a file_state should be 'string'</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
</xsd:element>
<xsd:element name="product_name" type="oval-def:EntityStateStringType" minOccurs="0">
<xsd:annotation>
<xsd:documentation>This entity defines a product name to be found within the version-information structure.</xsd:documentation>
<xsd:appinfo>
<sch:pattern id="filesteproductname" xmlns:sch="http://purl.oclc.org/dsdl/schematron">
<sch:rule context="win-def:file_state/win-def:product_name">
<sch:assert test="not(@datatype) or @datatype='string'">
<sch:value-of select="../@id" /> - datatype attribute for the product_name entity of a file_state should be 'string'</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
</xsd:element>
<xsd:element name="product_version" type="oval-def:EntityStateStringType" minOccurs="0">
<xsd:annotation>
<xsd:documentation>This entity defines a product version to be found within the version-information structure.</xsd:documentation>
<xsd:appinfo>
<sch:pattern id="filesteproductversion" xmlns:sch="http://purl.oclc.org/dsdl/schematron">
<sch:rule context="win-def:file_state/win-def:product_version">
<sch:assert test="@datatype='version'">
<sch:value-of select="../@id" /> - datatype attribute for the product_version entity of a file_state should be 'string'</sch:assert>
</sch:rule>
</sch:pattern>
</xsd:appinfo>
</xsd:annotation>
</xsd:element>
</xsd:sequence>
</xsd:extension>
</xsd:complexContent>
</xsd:complexType>
</xsd:element>
|