Project

Profile

Help

How to connect?
Download (2.06 KB) Statistics
| Branch: | Tag: | Revision:

he / src / use-cases / strong / ipo.xsd @ a31dd97a

1
<?xml version="1.0"?>
2
<schema targetNamespace="http://www.example.com/IPO"
3
        xmlns="http://www.w3.org/2001/XMLSchema"
4
        xmlns:ipo="http://www.example.com/IPO">
5

    
6
  <annotation>
7
    <documentation xml:lang="en">
8
      International Purchase order schema for Example.com
9
      Copyright 2000 Example.com. All rights reserved.
10
    </documentation>
11
  </annotation>
12

    
13
  <!-- include address constructs -->
14
  <include
15
    schemaLocation="address.xsd"/>
16

    
17
  <element name="purchaseOrder" type="ipo:PurchaseOrderType"/>
18

    
19
  <element name="comment" type="string"/>
20
  <element name="shipComment" type="string" substitutionGroup="ipo:comment"/>
21
  <element name="customerComment" type="string" substitutionGroup="ipo:comment"/>
22

    
23
  <complexType name="PurchaseOrderType">
24
    <sequence>
25
      <element name="shipTo"     type="ipo:Address"/>
26
      <element name="billTo"     type="ipo:Address"/>
27
      <element ref="ipo:comment" minOccurs="0"/>
28
      <element name="items"      type="ipo:Items"/>
29
    </sequence>
30
    <attribute name="orderDate" type="date"/>
31
  </complexType>
32

    
33
  <complexType name="Items">
34
    <sequence>
35
      <element name="item" minOccurs="0" maxOccurs="unbounded">
36
        <complexType>
37
          <sequence>
38
            <element name="productName" type="string"/>
39
            <element name="quantity">
40
              <simpleType>
41
                <restriction base="positiveInteger">
42
                  <maxExclusive value="100"/>
43
                </restriction>
44
              </simpleType>
45
            </element>
46
            <element name="USPrice"    type="decimal"/>
47
            <element ref="ipo:comment" minOccurs="0" maxOccurs="unbounded"/>
48
            <element name="shipDate"   type="date" minOccurs="0" maxOccurs="unbounded"/>
49
          </sequence>
50
          <attribute name="partNum" type="ipo:SKU" use="required"/>
51
        </complexType>
52
      </element>
53
    </sequence>
54
  </complexType>
55

    
56
  <simpleType name="SKU">
57
    <restriction base="string">
58
      <pattern value="\d{3}-[A-Z]{2}"/>
59
    </restriction>
60
  </simpleType>
61

    
62
</schema>
(5-5/27)