A.xml

Материал из Фабиус wiki
Перейти к: навигация, поиск

<?xml version = "1.0" encoding = "utf-8"?>

<xs:schema id = "A" xmlns:xs = "http://www.w3.org/2001/XMLSchema">
 <xs:element name = "A">
  <xs:complexType>
   <xs:annotation>
    <xs:documentation>Квитанция УТМ</xs:documentation>
   </xs:annotation>
   <xs:sequence>
    <xs:element name = "url"  type = "URL"        minOccurs = "1" maxOccurs = "1"/>
    <xs:element name = "sign" type = "SIGN"       minOccurs = "1" maxOccurs = "1"/>
    <xs:element name = "ver"  type = "xs:integer" minOccurs = "1" maxOccurs = "1"/>
   </xs:sequence>
  </xs:complexType>
 </xs:element>
 <xs:simpleType name = "URL">
  <xs:restriction base = "xs:string">
   <xs:pattern value = "(http:\/\/check\.egais\.ru\?id=)?([0-9a-f]{4}-?){8}(&dt=[0-9]{10}&cn=[0-9]{12})?"/>
  </xs:restriction>
 </xs:simpleType>
 <xs:simpleType name = "SIGN">
  <xs:restriction base = "xs:string">
   <xs:pattern value = "[0-9A-F]{128}"/>
  </xs:restriction>
 </xs:simpleType>
</xs:schema>

Смотрите также

XML схемы