root/Xml/Working/BinaryFile.xsd
| Revision 195, 4.9 kB (checked in by andrew, 4 months ago) |
|---|
| Line | |
|---|---|
| 1 | <?xml version = "1.0" encoding = "UTF-8"?> |
| 2 | <!-- |
| 3 | #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 4 | # |
| 5 | # Copyright (C) 2003-2008 Open Microscopy Environment |
| 6 | # Massachusetts Institute of Technology, |
| 7 | # National Institutes of Health, |
| 8 | # University of Dundee, |
| 9 | # University of Wisconsin at Madison |
| 10 | # |
| 11 | #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 12 | --> |
| 13 | <!-- |
| 14 | #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 15 | # Written by: Josiah Johnston <siah@nih.gov>, Andrew J Patterson |
| 16 | #~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ |
| 17 | --> |
| 18 | <xsd:schema |
| 19 | xmlns:xsd = "http://www.w3.org/2001/XMLSchema" |
| 20 | targetNamespace = "http://www.openmicroscopy.org/Schemas/BinaryFile/2008-02" |
| 21 | xmlns:Bin = "http://www.openmicroscopy.org/Schemas/BinaryFile/2008-02" |
| 22 | xmlns:xml="http://www.w3.org/XML/1998/namespace" |
| 23 | version = "1" |
| 24 | elementFormDefault = "qualified"> |
| 25 | <xsd:import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="http://www.w3.org/2001/xml.xsd"/> |
| 26 | <xsd:annotation> |
| 27 | <xsd:documentation> |
| 28 | The elements in this file are not yet represented by classes in the EA diagrams - ajp |
| 29 | </xsd:documentation> |
| 30 | </xsd:annotation> |
| 31 | <xsd:element name = "External"> <!-- top level definition --> |
| 32 | <xsd:annotation> |
| 33 | <xsd:documentation>Describes a file location. Can optionally specify a portion of a file using Offset and a ReadLength. |
| 34 | If Offset and ReadLength are specified in conjuction with Compression, then they point into the uncompressed file. |
| 35 | </xsd:documentation> |
| 36 | </xsd:annotation> |
| 37 | <xsd:complexType> |
| 38 | <xsd:attribute name = "href" use = "required" type = "xsd:anyURI"> |
| 39 | <xsd:annotation> |
| 40 | <xsd:documentation>file location</xsd:documentation> |
| 41 | </xsd:annotation> |
| 42 | </xsd:attribute> |
| 43 | <xsd:attribute name = "SHA1" use = "required" type = "Bin:Hex40"> |
| 44 | <xsd:annotation> |
| 45 | <xsd:documentation>The digest of the file specified in href.</xsd:documentation> |
| 46 | </xsd:annotation> |
| 47 | </xsd:attribute> |
| 48 | <xsd:attribute name = "Compression" default = "none" use="optional"> |
| 49 | <xsd:annotation> |
| 50 | <xsd:documentation>Specifies the compression scheme used to encode the data.</xsd:documentation> |
| 51 | </xsd:annotation> |
| 52 | <xsd:simpleType> |
| 53 | <xsd:restriction base = "xsd:string"> |
| 54 | <xsd:enumeration value = "zlib"/> |
| 55 | <xsd:enumeration value = "bzip2"/> |
| 56 | <xsd:enumeration value = "none"/> |
| 57 | </xsd:restriction> |
| 58 | </xsd:simpleType> |
| 59 | </xsd:attribute> |
| 60 | </xsd:complexType> |
| 61 | </xsd:element> |
| 62 | <xsd:element name = "BinData"> <!-- top level definition --> |
| 63 | <xsd:annotation> |
| 64 | <xsd:documentation>The contents of this element are base64-encoded. These are not CDATA sections, just a base64 stream.</xsd:documentation> |
| 65 | </xsd:annotation> |
| 66 | <xsd:complexType> |
| 67 | <xsd:simpleContent> |
| 68 | <xsd:extension base = "xsd:base64Binary"> |
| 69 | <xsd:attribute name = "Compression" default = "none" use="optional"> |
| 70 | <xsd:annotation> |
| 71 | <xsd:documentation>Specifies the compression scheme used to encode the data. </xsd:documentation> |
| 72 | </xsd:annotation> |
| 73 | <xsd:simpleType> |
| 74 | <xsd:restriction base = "xsd:string"> |
| 75 | <xsd:enumeration value = "zlib"/> |
| 76 | <xsd:enumeration value = "bzip2"/> |
| 77 | <xsd:enumeration value = "none"/> |
| 78 | </xsd:restriction> |
| 79 | </xsd:simpleType> |
| 80 | </xsd:attribute> |
| 81 | <xsd:attribute name="Length" use="required"> |
| 82 | <xsd:annotation> |
| 83 | <xsd:documentation>Character count attribute for the BinData field. This is the length of the base-64 encoded block. It allows easy skipping of the block when parsing the file. |
| 84 | Added in response to Evolution document - ajp</xsd:documentation> |
| 85 | </xsd:annotation> |
| 86 | <xsd:simpleType> |
| 87 | <xsd:restriction base="xsd:nonNegativeInteger"> |
| 88 | </xsd:restriction> |
| 89 | </xsd:simpleType> |
| 90 | </xsd:attribute> |
| 91 | </xsd:extension> |
| 92 | </xsd:simpleContent> |
| 93 | </xsd:complexType> |
| 94 | </xsd:element> |
| 95 | <xsd:element name = "BinaryFile"> <!-- top level definition --> |
| 96 | <xsd:annotation> |
| 97 | <xsd:documentation>Describes a binary file.</xsd:documentation> |
| 98 | </xsd:annotation> |
| 99 | <xsd:complexType> |
| 100 | <xsd:choice minOccurs="1" maxOccurs="1"> |
| 101 | <xsd:element ref = "Bin:External" minOccurs="1" maxOccurs="1"/> |
| 102 | <xsd:element ref = "Bin:BinData" minOccurs="1" maxOccurs="1"/> |
| 103 | </xsd:choice> |
| 104 | <xsd:attribute name = "FileName" use = "required"> |
| 105 | <xsd:simpleType> |
| 106 | <xsd:restriction base = "xsd:string"> |
| 107 | <xsd:maxLength value = "64"/> |
| 108 | </xsd:restriction> |
| 109 | </xsd:simpleType> |
| 110 | </xsd:attribute> |
| 111 | <xsd:attribute name = "Size" use = "required" type = "xsd:integer"> |
| 112 | <xsd:annotation> |
| 113 | <xsd:documentation>Size (in bytes) of the uncompressed file.</xsd:documentation> |
| 114 | </xsd:annotation> |
| 115 | </xsd:attribute> |
| 116 | </xsd:complexType> |
| 117 | </xsd:element> |
| 118 | <xsd:simpleType name = "Hex40"> |
| 119 | <xsd:restriction base = "xsd:hexBinary"> |
| 120 | <xsd:length value = "20"/> |
| 121 | </xsd:restriction> |
| 122 | </xsd:simpleType> |
| 123 | </xsd:schema> |
Note: See TracBrowser
for help on using the browser.
