1 <?xml version="1.0" encoding="UTF-8"?>
2 <xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema">
4 <!-- déclaration des attributs -->
6 <xs:attribute name="ref_name" type="xs:string"/>
7 <xs:attribute name="ref_md5" type="xs:string"/>
8 <xs:attribute name="firstname" type="xs:string"/>
9 <xs:attribute name="lastname" type="xs:string"/>
10 <xs:attribute name="mail" type="xs:string"/>
11 <xs:attribute name="creation" type="xs:date"/>
12 <xs:attribute name="list" type="xs:string"/>
13 <xs:attribute name="name" type="xs:string"/>
14 <xs:attribute name="use" type="xs:string" />
15 <xs:attribute name="value" type="xs:string" />
16 <xs:attribute name="pattern" type="xs:string"/>
17 <xs:attribute name="counter" type="xs:string"/>
19 <!-- déclaration des groupes d'éléments -->
21 <xs:group name="blockElmtGroup">
23 <xs:element ref="comments"/>
24 <xs:element ref="libraries"/>
25 <xs:element ref="architecture"/>
26 <xs:element ref="patterns" minOccurs="0"/>
30 <xs:group name="commentsElmtGroup">
32 <xs:element ref="author"/>
33 <xs:element ref="date"/>
34 <xs:element ref="related_files"/>
35 <xs:element ref="description"/>
36 <xs:element ref="notes"/>
40 <xs:group name="patternsElmtGroup">
42 <xs:element ref="delta"/>
43 <xs:element ref="consumption"/>
44 <xs:element ref="production"/>
48 <!-- déclaration des éléments -->
50 <xs:element name="comments">
52 <xs:group ref="commentsElmtGroup"/>
56 <xs:element name="author">
58 <xs:attribute ref="firstname" />
59 <xs:attribute ref="lastname" />
60 <xs:attribute ref="mail" />
64 <xs:element name="date">
66 <xs:attribute ref="creation" />
70 <xs:element name="related_files">
72 <xs:attribute ref="list" />
76 <xs:element name="description" type="xs:string" />
78 <xs:element name="notes" type="xs:string" />
80 <xs:element name="libraries">
83 <xs:element ref="library" minOccurs="0" maxOccurs="unbounded" />
88 <xs:element name="library">
91 <xs:element ref="package" minOccurs="1" maxOccurs="unbounded" />
93 <xs:attribute ref="name" />
97 <xs:element name="package">
99 <xs:attribute ref="name" />
100 <xs:attribute ref="use" />
104 <xs:element name="architecture" type="xs:string" />
106 <xs:element name="patterns">
108 <xs:group ref="patternsElmtGroup"/>
112 <xs:element name="delta">
114 <xs:attribute ref="value" />
118 <xs:element name="consumption">
121 <xs:element ref="input" minOccurs="0" maxOccurs="unbounded"/>
126 <xs:element name="input">
128 <xs:attribute ref="name" />
129 <xs:attribute ref="pattern" />
133 <xs:element name="production">
136 <xs:element ref="output" minOccurs="0" maxOccurs="unbounded"/>
138 <xs:attribute ref="counter" />
142 <xs:element name="output">
144 <xs:attribute ref="name" />
145 <xs:attribute ref="pattern" />
149 <!-- Racine du document -->
151 <xs:element name="block_impl">
153 <xs:group ref="blockElmtGroup"/>
154 <xs:attribute ref="ref_name" />
155 <xs:attribute ref="ref_md5" />