1 <?xml version="1.0" encoding="UTF-8"?>
3 * Copyright (C) 2009 The Android Open Source Project
5 * Licensed under the Apache License, Version 2.0 (the "License");
6 * you may not use this file except in compliance with the License.
7 * You may obtain a copy of the License at
9 * http://www.apache.org/licenses/LICENSE-2.0
11 * Unless required by applicable law or agreed to in writing, software
12 * distributed under the License is distributed on an "AS IS" BASIS,
13 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14 * See the License for the specific language governing permissions and
15 * limitations under the License.
18 targetNamespace="http://schemas.android.com/sdk/android/repository/1"
19 xmlns:xsd="http://www.w3.org/2001/XMLSchema"
20 xmlns:sdk="http://schemas.android.com/sdk/android/repository/1"
21 elementFormDefault="qualified"
22 attributeFormDefault="unqualified"
25 <!-- The repository contains a collection of downloadable items known as
26 "packages". Each package has a type and various attributes and contains
27 a list of file "archives" that can be downloaded for specific OSes.
29 An Android SDK repository is a web site that contains a "repository.xml"
30 file that conforms to this XML Schema.
33 <xsd:element name="sdk-repository">
36 The repository contains collections of downloadable packages.
41 <xsd:choice minOccurs="0" maxOccurs="unbounded">
43 <!-- The definition of an SDK platform package. -->
45 <xsd:element name="platform">
47 <xsd:documentation>An SDK platform package.</xsd:documentation>
51 <!-- The Android platform version. It is string such as "1.0". -->
52 <xsd:element name="version" type="xsd:normalizedString" />
53 <!-- The Android API Level for the platform. An int > 0. -->
54 <xsd:element name="api-level" type="xsd:positiveInteger" />
55 <!-- The optional codename for this platform, if it's a preview. -->
56 <xsd:element name="codename" type="xsd:string" minOccurs="0" />
58 <!-- The revision, an int > 0, incremented each time a new
59 package is generated. -->
60 <xsd:element name="revision" type="xsd:positiveInteger" />
61 <!-- The optional license of this package. If present, users will have
62 to agree to it before downloading. -->
63 <xsd:element name="uses-license" type="sdk:licenseType" minOccurs="0" />
64 <!-- The optional description of this package. -->
65 <xsd:element name="description" type="xsd:string" minOccurs="0" />
66 <!-- The optional description URL of this package -->
67 <xsd:element name="desc-url" type="xsd:token" minOccurs="0" />
68 <!-- A list of file archives for this package. -->
69 <xsd:element name="archives" type="sdk:archivesType" />
75 <!-- The definition of an SDK Add-on package. -->
77 <xsd:element name="add-on">
79 <xsd:documentation>An SDK add-on package.</xsd:documentation>
83 <!-- The name of the add-on. -->
84 <xsd:element name="name" type="xsd:normalizedString" />
85 <!-- The vendor of the add-on. -->
86 <xsd:element name="vendor" type="xsd:normalizedString" />
87 <!-- The Android API Level for the add-on. An int > 0. -->
88 <xsd:element name="api-level" type="xsd:positiveInteger" />
89 <!-- The optional codename for this add-on, if it's a preview. -->
90 <xsd:element name="codename" type="xsd:string" minOccurs="0" />
92 <!-- The revision, an int > 0, incremented each time a new
93 package is generated. -->
94 <xsd:element name="revision" type="xsd:positiveInteger" />
95 <!-- The optional license of this package. If present, users will have
96 to agree to it before downloading. -->
97 <xsd:element name="uses-license" type="sdk:licenseType" minOccurs="0" />
98 <!-- The optional description of this package. -->
99 <xsd:element name="description" type="xsd:string" minOccurs="0" />
100 <!-- The optional description URL of this package -->
101 <xsd:element name="desc-url" type="xsd:token" minOccurs="0" />
102 <!-- A list of file archives for this package. -->
103 <xsd:element name="archives" type="sdk:archivesType" />
105 <!-- An add-on can declare 0 or more libraries. -->
107 <xsd:element name="libs">
109 <xsd:sequence minOccurs="0" maxOccurs="unbounded">
110 <xsd:element name="lib">
113 <!-- The name of the library. -->
114 <xsd:element name="name" type="xsd:normalizedString" />
115 <!-- The optional description of this add-on library. -->
116 <xsd:element name="description" type="xsd:string" minOccurs="0" />
128 <!-- The definition of an SDK tool package. -->
130 <xsd:element name="tool">
132 <xsd:documentation>An SDK tool package.</xsd:documentation>
136 <!-- The revision, an int > 0, incremented each time a new
137 package is generated. -->
138 <xsd:element name="revision" type="xsd:positiveInteger" />
139 <!-- The optional license of this package. If present, users will have
140 to agree to it before downloading. -->
141 <xsd:element name="uses-license" type="sdk:licenseType" minOccurs="0" />
142 <!-- The optional description of this package. -->
143 <xsd:element name="description" type="xsd:string" minOccurs="0" />
144 <!-- The optional description URL of this package -->
145 <xsd:element name="desc-url" type="xsd:token" minOccurs="0" />
146 <!-- A list of file archives for this package. -->
147 <xsd:element name="archives" type="sdk:archivesType" />
153 <!-- The definition of an SDK doc package. -->
155 <xsd:element name="doc">
157 <xsd:documentation>An SDK doc package.</xsd:documentation>
161 <!-- The Android API Level for the documentation. An int > 0. -->
162 <xsd:element name="api-level" type="xsd:positiveInteger" />
163 <!-- The optional codename for this doc, if it's a preview. -->
164 <xsd:element name="codename" type="xsd:string" minOccurs="0" />
166 <!-- The revision, an int > 0, incremented each time a new
167 package is generated. -->
168 <xsd:element name="revision" type="xsd:positiveInteger" />
169 <!-- The optional license of this package. If present, users will have
170 to agree to it before downloading. -->
171 <xsd:element name="uses-license" type="sdk:licenseType" minOccurs="0" />
172 <!-- The optional description of this package. -->
173 <xsd:element name="description" type="xsd:string" minOccurs="0" />
174 <!-- The optional description URL of this package -->
175 <xsd:element name="desc-url" type="xsd:token" minOccurs="0" />
176 <!-- A list of file archives for this package. -->
177 <xsd:element name="archives" type="sdk:archivesType" />
183 <!-- The definition of an SDK extra package. This kind of package is for
184 "free" content and specifies in which fixed root directory it must be
188 <xsd:element name="extra">
191 An SDK extra package. This kind of package is for "free"
192 content and specifies in which fixed root directory it must be
194 The paths "add-ons", "platforms", "tools" and "docs" are
195 reserved and cannot be used.
200 <!-- The install folder name. It must be a single-segment path.
201 The paths "add-ons", "platforms", "tools" and "docs" are
202 reserved and cannot be used.
204 <xsd:element name="path">
206 <xsd:restriction base="xsd:token">
207 <xsd:pattern value="[^/\\]+"/>
212 <!-- The revision, an int > 0, incremented each time a new
213 package is generated. -->
214 <xsd:element name="revision" type="xsd:positiveInteger" />
215 <!-- The optional license of this package. If present, users will have
216 to agree to it before downloading. -->
217 <xsd:element name="uses-license" type="sdk:licenseType" minOccurs="0" />
218 <!-- The optional description of this package. -->
219 <xsd:element name="description" type="xsd:string" minOccurs="0" />
220 <!-- The optional description URL of this package -->
221 <xsd:element name="desc-url" type="xsd:token" minOccurs="0" />
222 <!-- A list of file archives for this package. -->
223 <xsd:element name="archives" type="sdk:archivesType" />
230 <!-- The definition of a license to be referenced by the uses-license element. -->
232 <xsd:element name="license">
235 A license definition. Such a license must be used later as a reference
236 using a uses-license element in one of the package elements.
241 <xsd:extension base="xsd:string">
242 <xsd:attribute name="id" type="xsd:ID" />
243 <xsd:attribute name="type" type="xsd:token" fixed="text" />
253 <!-- Type describing the license used by a package.
254 The license MUST be defined using a license node and referenced
255 using the ref attribute of the license element inside a package.
258 <xsd:complexType name="licenseType">
261 Describes the license used by a package. The license MUST be defined
262 using a license node and referenced using the ref attribute of the
263 license element inside a package.
266 <xsd:attribute name="ref" type="xsd:IDREF" />
270 <!-- A collection of files that can be downloaded for a given architecture.
271 The <archives> node is mandatory in the repository elements and the
272 collection must have at least one <archive> declared.
273 Each archive is a zip file that will be unzipped in a location that depends
277 <xsd:complexType name="archivesType">
280 A collection of files that can be downloaded for a given architecture.
281 The <archives> node is mandatory in the repository packages and the
282 collection must have at least one <archive> declared.
283 Each archive is a zip file that will be unzipped in a location that depends
287 <xsd:sequence minOccurs="1" maxOccurs="unbounded">
288 <!-- One archive file -->
289 <xsd:element name="archive">
291 <!-- Properties of the archive file -->
293 <!-- The size in bytes of the archive to download. -->
294 <xsd:element name="size" type="xsd:positiveInteger" />
295 <!-- The checksum of the archive file. -->
296 <xsd:element name="checksum" type="sdk:checksumType" />
297 <!-- The URL is an absolute URL if it starts with http://, https://
298 or ftp://. Otherwise it is relative to the parent directory that
299 contains this repository.xml -->
300 <xsd:element name="url" type="xsd:token" />
303 <!-- Attributes that identify the OS and architecture -->
304 <xsd:attribute name="os" use="required">
306 <xsd:restriction base="xsd:token">
307 <xsd:enumeration value="any" />
308 <xsd:enumeration value="linux" />
309 <xsd:enumeration value="macosx" />
310 <xsd:enumeration value="windows" />
314 <xsd:attribute name="arch" use="optional">
316 <xsd:restriction base="xsd:token">
317 <xsd:enumeration value="any" />
318 <xsd:enumeration value="ppc" />
319 <xsd:enumeration value="x86" />
320 <xsd:enumeration value="x86_64" />
330 <!-- The definition of a file checksum -->
332 <xsd:simpleType name="sha1Number">
334 <xsd:documentation>A SHA1 checksum.</xsd:documentation>
336 <xsd:restriction base="xsd:string">
337 <xsd:pattern value="([0-9a-fA-F]){40}"/>
341 <xsd:complexType name="checksumType">
343 <xsd:documentation>A file checksum, currently only SHA1.</xsd:documentation>
346 <xsd:extension base="sdk:sha1Number">
347 <xsd:attribute name="type" type="xsd:token" fixed="sha1" />