]> git.evergreen-ils.org Git - working/Evergreen.git/blob - Open-ILS/examples/fm_IDL.xsd
Update fieldmapper schema to match latest changes to fm_IDL.xml
[working/Evergreen.git] / Open-ILS / examples / fm_IDL.xsd
1 <?xml version="1.0" encoding="UTF-8" ?>
2
3 <!--
4
5 Copyright (C) 2007 Laurentian University
6 Dan Scott <dscott@laurentian.ca>
7
8 This program is free software; you can redistribute it and/or
9 modify it under the terms of the GNU General Public License
10 as published by the Free Software Foundation; either version 2
11 of the License, or (at your option) any later version.
12
13 This program is distributed in the hope that it will be useful,
14 but WITHOUT ANY WARRANTY; without even the implied warranty of
15 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
16 GNU General Public License for more details.
17
18 You should have received a copy of the GNU General Public License
19 along with this program; if not, write to the Free Software
20 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA
21
22 -->
23
24 <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
25  xmlns:idl="http://opensrf.org/spec/IDL/base/v1"
26  xmlns:oils_persist="http://open-ils.org/spec/opensrf/IDL/persistence/v1"
27  xmlns:oils_obj="http://open-ils.org/spec/opensrf/IDL/objects/v1"
28  xmlns:reporter="http://open-ils.org/spec/opensrf/IDL/reporter/v1"
29  targetNamespace="http://opensrf.org/spec/IDL/base/v1"
30  elementFormDefault="qualified"
31  attributeFormDefault="unqualified"
32 >
33
34 <xs:import namespace="http://open-ils.org/spec/opensrf/IDL/persistence/v1"
35  schemaLocation="oils_persist.xsd"/>
36
37 <xs:import namespace="http://open-ils.org/spec/opensrf/IDL/objects/v1"
38  schemaLocation="oils_obj.xsd"/>
39
40 <xs:import namespace="http://open-ils.org/spec/opensrf/IDL/reporter/v1"
41  schemaLocation="reporter.xsd"/>
42
43 <!-- define simple elements -->
44 <xs:element name="field" nillable="true">
45  <xs:complexType>
46   <xs:attribute name="name"/>
47   <xs:attribute ref="oils_obj:array_position"/>
48   <xs:attribute ref="oils_persist:primitive"/>
49   <xs:attribute ref="oils_persist:virtual"/>
50   <xs:attribute ref="reporter:label"/>
51   <xs:attribute ref="reporter:datatype"/>
52   <xs:attribute ref="reporter:selector"/>
53  </xs:complexType>
54 </xs:element>
55
56 <xs:element name="link" nillable="true">
57  <xs:complexType>
58   <xs:attribute name="field" type="xs:string" use="required"/>
59   <xs:attribute name="reltype" type="xs:string" use="required"/>
60   <xs:attribute name="key" type="xs:string" use="required"/>
61   <xs:attribute name="map" type="xs:string" use="required"/>
62   <xs:attribute name="class" type="xs:string" use="required"/>
63   <xs:attribute ref="reporter:label"/>
64  </xs:complexType>
65 </xs:element>
66
67 <xs:element name="fields">
68  <xs:complexType>
69   <xs:sequence>
70    <xs:element ref="idl:field" minOccurs="1" maxOccurs="unbounded"/>
71   </xs:sequence>
72   <xs:attribute ref="oils_persist:primary"/>
73   <xs:attribute ref="oils_persist:sequence"/>
74  </xs:complexType>
75 </xs:element>
76
77 <xs:element name="links">
78  <xs:complexType>
79   <xs:sequence>
80    <xs:element ref="idl:link" minOccurs="0" maxOccurs="unbounded"/>
81   </xs:sequence>
82  </xs:complexType>
83 </xs:element>
84
85 <xs:element name="class">
86  <xs:complexType>
87   <xs:sequence>
88    <xs:element ref="oils_persist:source_definition" minOccurs="0" maxOccurs="unbounded"/>
89    <xs:element ref="idl:fields"/>
90    <xs:element ref="idl:links" minOccurs="0"/>
91   </xs:sequence>
92   <xs:attribute name="id"/>
93   <xs:attribute name="controller"/>
94   <xs:attribute ref="oils_obj:fieldmapper"/>
95   <xs:attribute ref="oils_persist:readonly"/>
96   <xs:attribute ref="oils_persist:tablename"/>
97   <xs:attribute ref="oils_persist:virtual"/>
98   <xs:attribute ref="reporter:core"/>
99   <xs:attribute ref="reporter:label"/>
100  </xs:complexType>
101 </xs:element>
102
103 <xs:element name="IDL">
104  <xs:complexType>
105   <xs:sequence>
106    <xs:element ref="idl:class" minOccurs="1" maxOccurs="unbounded"/>
107   </xs:sequence>
108  </xs:complexType>
109 </xs:element>
110
111 </xs:schema>