source: trunk/src/core/net/sf/basedb/core/xsd/extensions.xsd @ 4874

Last change on this file since 4874 was 4874, checked in by Nicklas Nordborg, 13 years ago

Fixes #1286: Add support of id-base attribute to extension xml files

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 4.1 KB
Line 
1<?xml version="1.0" encoding="UTF-8" ?>
2<!--
3  $Id: extensions.xsd 4874 2009-04-02 10:40:35Z 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        <xsd:element name="about" type="aboutType" minOccurs="0" />
33        <xsd:element name="extension-point" minOccurs="0" maxOccurs="unbounded">
34          <xsd:complexType>
35            <xsd:all>
36              <xsd:element name="action-class" type="classNameType" />
37              <xsd:element name="renderer-factory" minOccurs="0">
38                <xsd:complexType>
39                  <xsd:complexContent>
40                    <xsd:extension base="factoryType">
41                      <xsd:attribute name="override" type="xsd:boolean" default="true" />
42                    </xsd:extension>
43                  </xsd:complexContent>
44                </xsd:complexType>
45              </xsd:element>
46              <xsd:element name="name" type="xsd:string" minOccurs="0" />
47              <xsd:element name="description" type="xsd:string" minOccurs="0" />
48            </xsd:all>
49            <xsd:attribute name="id" type="xsd:ID" use="required" />
50          </xsd:complexType>
51        </xsd:element>
52       
53        <xsd:element name="extension" minOccurs="0" maxOccurs="unbounded">
54          <xsd:complexType>
55            <xsd:all>
56              <xsd:element name="action-factory" type="factoryType" />
57              <xsd:element name="renderer-factory" type="factoryType" minOccurs="0" />
58              <xsd:element name="about" type="aboutType" minOccurs="0" />
59              <xsd:element name="index" type="xsd:float" minOccurs="0" />
60            </xsd:all>
61            <xsd:attribute name="id" type="xsd:ID" use="required" />
62            <xsd:attribute name="extends" type="xsd:string" use="required" />
63          </xsd:complexType>
64        </xsd:element>
65      </xsd:sequence>
66      <xsd:attribute name="id-base" type="xsd:ID" use="optional" />
67    </xsd:complexType>
68  </xsd:element>
69 
70  <!-- Type declarations -->
71  <!-- A Java class name -->
72  <xsd:simpleType name="classNameType">
73    <xsd:restriction base="xsd:string">
74    </xsd:restriction>
75  </xsd:simpleType>
76 
77  <!-- Information about the authors of an extension -->
78  <xsd:complexType name="aboutType">
79    <xsd:all>
80      <xsd:element name="name" type="xsd:string" minOccurs="0" maxOccurs="1" />
81      <xsd:element name="description" type="xsd:string" minOccurs="0" maxOccurs="1" />
82      <xsd:element name="version" type="xsd:string" minOccurs="0" maxOccurs="1" />
83      <xsd:element name="copyright" type="xsd:string" minOccurs="0" maxOccurs="1" />
84      <xsd:element name="contact" type="xsd:string" minOccurs="0" maxOccurs="1" />
85      <xsd:element name="email" type="xsd:string" minOccurs="0" maxOccurs="1" />
86      <xsd:element name="url" type="xsd:string" minOccurs="0" maxOccurs="1" />
87    </xsd:all>
88  </xsd:complexType>
89 
90  <!--
91    A factory is the name of a factory class + optional initialisation
92    parameters that are set by reflection. Method name is 'set'+uppercase tagname.
93    for example: <image>foo.png</image> results in a call to setImage("foo.png")
94   -->
95  <xsd:complexType name="factoryType">
96    <xsd:sequence>
97      <xsd:element name="factory-class" type="classNameType" minOccurs="1" maxOccurs="1" />
98      <xsd:element name="parameters" minOccurs="0" maxOccurs="1">
99        <xsd:complexType>
100          <xsd:sequence>
101            <xsd:any minOccurs="0" maxOccurs="unbounded" processContents="skip" />
102          </xsd:sequence>       
103        </xsd:complexType>
104      </xsd:element>
105    </xsd:sequence>
106  </xsd:complexType>
107 
108</xsd:schema>
Note: See TracBrowser for help on using the repository browser.