Added release notes for 'ContentHandler::runLegacyHooks' removal
[mediawiki.git] / docs / export-0.2.xsd
blob55b05f8de9e91ebaf04ee9845c08c805929218d4
1 <?xml version="1.0" encoding="UTF-8" ?>
2 <!--
3 This is an XML Schema description of the format
4 output by MediaWiki's Special:Export system.
6 Version 0.2 adds optional basic file upload info support,
7 which is used by our OAI export/import submodule.
9 The canonical URL to the schema document is:
10 http://www.mediawiki.org/xml/export-0.2.xsd
12 Use the namespace:
13 http://www.mediawiki.org/xml/export-0.2/
14 -->
15 <schema xmlns="http://www.w3.org/2001/XMLSchema"
16 xmlns:mw="http://www.mediawiki.org/xml/export-0.2/"
17 targetNamespace="http://www.mediawiki.org/xml/export-0.2/"
18 elementFormDefault="qualified">
20 <annotation>
21 <documentation xml:lang="en">
22 MediaWiki's page export format
23 </documentation>
24 </annotation>
26 <!-- Need this to reference xml:lang -->
27 <import namespace="http://www.w3.org/XML/1998/namespace"
28 schemaLocation="http://www.w3.org/2001/xml.xsd"/>
30 <!-- Our root element -->
31 <element name="mediawiki" type="mw:MediaWikiType"/>
33 <complexType name="MediaWikiType">
34 <sequence>
35 <element name="page" type="mw:PageType"
36 minOccurs="0" maxOccurs="unbounded"/>
37 </sequence>
38 <attribute name="version" type="string" use="required"/>
39 <attribute ref="xml:lang" use="required"/>
40 </complexType>
42 <complexType name="PageType">
43 <sequence>
44 <!-- Title in text form. (Using spaces, not underscores; with namespace ) -->
45 <element name="title" type="string"/>
47 <!-- optional page ID number -->
48 <element name="id" type="positiveInteger" minOccurs="0"/>
50 <!-- comma-separated list of string tokens, if present -->
51 <element name="restrictions" type="string" minOccurs="0"/>
53 <!-- Zero or more sets of revision or upload data -->
54 <choice minOccurs="0" maxOccurs="unbounded">
55 <element name="revision" type="mw:RevisionType" />
56 <element name="upload" type="mw:UploadType" />
57 </choice>
58 </sequence>
59 </complexType>
61 <complexType name="RevisionType">
62 <sequence>
63 <element name="id" type="positiveInteger" minOccurs="0"/>
64 <element name="timestamp" type="dateTime"/>
65 <element name="contributor" type="mw:ContributorType"/>
66 <element name="minor" minOccurs="0" />
67 <element name="comment" type="string" minOccurs="0"/>
68 <element name="text" type="string"/>
69 </sequence>
70 </complexType>
72 <complexType name="ContributorType">
73 <sequence>
74 <element name="username" type="string" minOccurs="0"/>
75 <element name="id" type="positiveInteger" minOccurs="0" />
77 <element name="ip" type="string" minOccurs="0"/>
78 </sequence>
79 </complexType>
81 <complexType name="UploadType">
82 <sequence>
83 <!-- Revision-style data... -->
84 <element name="timestamp" type="dateTime"/>
85 <element name="contributor" type="mw:ContributorType"/>
86 <element name="comment" type="string" minOccurs="0"/>
88 <!-- Filename. (Using underscores, not spaces. No 'Image:' namespace marker.) -->
89 <element name="filename" type="string"/>
91 <!-- URI at which this resource can be obtained -->
92 <element name="src" type="anyURI"/>
94 <element name="size" type="positiveInteger" />
96 <!-- TODO: add other metadata fields -->
97 </sequence>
98 </complexType>
100 </schema>