1 | <?xml version="1.0" encoding="UTF-8" ?> |
---|
2 | <!-- |
---|
3 | $Id: extensions.xsd 5607 2011-04-15 07:52:28Z nicklas $ |
---|
4 | |
---|
5 | Copyright (C) Nicklas Nordborg |
---|
6 | |
---|
7 | This file is part of BASE - BioArray Software Environment. |
---|
8 | Available at http://base.thep.lu.se/ |
---|
9 | |
---|
10 | BASE is free software; you can redistribute it and/or |
---|
11 | modify it under the terms of the GNU General Public License |
---|
12 | as published by the Free Software Foundation; either version 3 |
---|
13 | of the License, or (at your option) any later version. |
---|
14 | |
---|
15 | BASE is distributed in the hope that it will be useful, |
---|
16 | but WITHOUT ANY WARRANTY; without even the implied warranty of |
---|
17 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
---|
18 | GNU General Public License for more details. |
---|
19 | |
---|
20 | You should have received a copy of the GNU General Public License |
---|
21 | along with BASE. If not, see <http://www.gnu.org/licenses/>. |
---|
22 | --> |
---|
23 | <xsd:schema |
---|
24 | xmlns:xsd="http://www.w3.org/2001/XMLSchema" |
---|
25 | targetNamespace="http://base.thep.lu.se/extensions.xsd" |
---|
26 | xmlns="http://base.thep.lu.se/extensions.xsd" |
---|
27 | elementFormDefault="qualified" |
---|
28 | > |
---|
29 | <xsd:element name="extensions"> |
---|
30 | <xsd:complexType> |
---|
31 | <xsd:sequence> |
---|
32 | <!-- global 'about' element --> |
---|
33 | <xsd:element name="about" type="aboutType" minOccurs="0" /> |
---|
34 | |
---|
35 | <!-- 'extension-point' element --> |
---|
36 | <xsd:element name="extension-point" minOccurs="0" maxOccurs="unbounded"> |
---|
37 | <xsd:complexType> |
---|
38 | <xsd:all> |
---|
39 | <xsd:element name="action-class" type="classNameType" /> |
---|
40 | <xsd:element name="renderer-factory" minOccurs="0"> |
---|
41 | <xsd:complexType> |
---|
42 | <xsd:complexContent> |
---|
43 | <xsd:extension base="factoryType"> |
---|
44 | <xsd:attribute name="override" type="xsd:boolean" default="true" /> |
---|
45 | </xsd:extension> |
---|
46 | </xsd:complexContent> |
---|
47 | </xsd:complexType> |
---|
48 | </xsd:element> |
---|
49 | <xsd:element name="error-handler-factory" type="factoryType" minOccurs="0" /> |
---|
50 | <xsd:element name="name" type="xsd:string" minOccurs="0" /> |
---|
51 | <xsd:element name="description" type="xsd:string" minOccurs="0" /> |
---|
52 | </xsd:all> |
---|
53 | <xsd:attribute name="id" type="xsd:ID" use="required" /> |
---|
54 | </xsd:complexType> |
---|
55 | </xsd:element> |
---|
56 | |
---|
57 | <!-- 'extension' element --> |
---|
58 | <xsd:element name="extension" minOccurs="0" maxOccurs="unbounded"> |
---|
59 | <xsd:complexType> |
---|
60 | <xsd:all> |
---|
61 | <xsd:element name="extends" minOccurs="0"> |
---|
62 | <xsd:complexType> |
---|
63 | <xsd:sequence> |
---|
64 | <xsd:element name="ref" minOccurs="1" maxOccurs="unbounded"> |
---|
65 | <xsd:complexType> |
---|
66 | <xsd:simpleContent> |
---|
67 | <xsd:extension base="xsd:string"> |
---|
68 | <xsd:attribute name="index" type="xsd:float" /> |
---|
69 | </xsd:extension> |
---|
70 | </xsd:simpleContent> |
---|
71 | </xsd:complexType> |
---|
72 | </xsd:element> |
---|
73 | </xsd:sequence> |
---|
74 | </xsd:complexType> |
---|
75 | </xsd:element> |
---|
76 | <xsd:element name="action-factory" type="factoryType" /> |
---|
77 | <xsd:element name="renderer-factory" type="factoryType" minOccurs="0" /> |
---|
78 | <xsd:element name="about" type="aboutType" minOccurs="0" /> |
---|
79 | <xsd:element name="index" type="xsd:float" minOccurs="0" /> |
---|
80 | </xsd:all> |
---|
81 | <xsd:attribute name="id" type="xsd:ID" use="required" /> |
---|
82 | <xsd:attribute name="extends" type="xsd:string" use="optional" /> |
---|
83 | </xsd:complexType> |
---|
84 | </xsd:element> |
---|
85 | </xsd:sequence> |
---|
86 | <xsd:attribute name="id-base" type="xsd:ID" use="optional" /> |
---|
87 | </xsd:complexType> |
---|
88 | </xsd:element> |
---|
89 | |
---|
90 | <!-- Type declarations --> |
---|
91 | <!-- A Java class name --> |
---|
92 | <xsd:simpleType name="classNameType"> |
---|
93 | <xsd:restriction base="xsd:string"> |
---|
94 | </xsd:restriction> |
---|
95 | </xsd:simpleType> |
---|
96 | |
---|
97 | <!-- Information about the authors of an extension --> |
---|
98 | <xsd:complexType name="aboutType"> |
---|
99 | <xsd:all> |
---|
100 | <xsd:element name="name" type="xsd:string" minOccurs="0" maxOccurs="1" /> |
---|
101 | <xsd:element name="description" type="xsd:string" minOccurs="0" maxOccurs="1" /> |
---|
102 | <xsd:element name="version" type="xsd:string" minOccurs="0" maxOccurs="1" /> |
---|
103 | <xsd:element name="min-base-version" type="baseVersionType" minOccurs="0" maxOccurs="1" /> |
---|
104 | <xsd:element name="max-base-version" type="baseVersionType" minOccurs="0" maxOccurs="1" /> |
---|
105 | <xsd:element name="copyright" type="xsd:string" minOccurs="0" maxOccurs="1" /> |
---|
106 | <xsd:element name="contact" type="xsd:string" minOccurs="0" maxOccurs="1" /> |
---|
107 | <xsd:element name="email" type="xsd:string" minOccurs="0" maxOccurs="1" /> |
---|
108 | <xsd:element name="url" type="xsd:string" minOccurs="0" maxOccurs="1" /> |
---|
109 | </xsd:all> |
---|
110 | </xsd:complexType> |
---|
111 | |
---|
112 | <!-- A string matching BASE version number with or without patch number --> |
---|
113 | <xsd:simpleType name="baseVersionType" > |
---|
114 | <xsd:restriction base="xsd:string"> |
---|
115 | <xsd:pattern value="\d\.\d+\.?\d*"></xsd:pattern> |
---|
116 | </xsd:restriction> |
---|
117 | </xsd:simpleType> |
---|
118 | |
---|
119 | <!-- |
---|
120 | A factory is the name of a factory class + optional initialisation |
---|
121 | parameters that are set by reflection. Method name is 'set'+uppercase tagname. |
---|
122 | for example: <image>foo.png</image> results in a call to setImage("foo.png") |
---|
123 | --> |
---|
124 | <xsd:complexType name="factoryType"> |
---|
125 | <xsd:sequence> |
---|
126 | <xsd:element name="factory-class" type="classNameType" minOccurs="1" maxOccurs="1" /> |
---|
127 | <xsd:element name="parameters" minOccurs="0" maxOccurs="1"> |
---|
128 | <xsd:complexType> |
---|
129 | <xsd:sequence> |
---|
130 | <xsd:any minOccurs="0" maxOccurs="unbounded" processContents="skip" /> |
---|
131 | </xsd:sequence> |
---|
132 | </xsd:complexType> |
---|
133 | </xsd:element> |
---|
134 | </xsd:sequence> |
---|
135 | </xsd:complexType> |
---|
136 | |
---|
137 | </xsd:schema> |
---|