imscp_rootv1p1p2.xsd 14 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345
  1. <?xml version="1.0"?>
  2. <!-- edited with XML Spy v3.5 (http://www.xmlspy.com) by Thomas Wason (private) -->
  3. <!-- filename=ims_cp_rootv1p1p2.xsd -->
  4. <!-- Copyright (2) 2001 IMS Global Learning Consortium, Inc. -->
  5. <!-- edited by Thomas Wason -->
  6. <!-- Conforms to w3c http://www.w3.org/TR/xmlschema-1/ 2000-10-24-->
  7. <xsd:schema xmlns="http://www.imsproject.org/xsd/imscp_rootv1p1p2"
  8. targetNamespace="http://www.imsproject.org/xsd/imscp_rootv1p1p2"
  9. xmlns:xml="http://www.w3.org/XML/1998/namespace"
  10. xmlns:xsd="http://www.w3.org/2001/XMLSchema"
  11. elementFormDefault="unqualified" version="IMS CP 1.1.2">
  12. <!-- ******************** -->
  13. <!-- ** Change History ** -->
  14. <!-- ******************** -->
  15. <xsd:annotation>
  16. <xsd:documentation xml:lang="en">DRAFT XSD for IMS Content Packaging version 1.1 DRAFT</xsd:documentation>
  17. <xsd:documentation> Copyright (c) 2001 IMS GLC, Inc. </xsd:documentation>
  18. <xsd:documentation>2000-04-21, Adjustments by T.D. Wason from CP 1.0.</xsd:documentation>
  19. <xsd:documentation>2001-02-22, T.D.Wason: Modify for 2000-10-24 XML-Schema version. Modified to support extension.</xsd:documentation>
  20. <xsd:documentation>2001-03-12, T.D.Wason: Change filename, target and meta-data namespaces and meta-data fielname. Add meta-data to itemType, fileType and organizationType.</xsd:documentation>
  21. <xsd:documentation>Do not define namespaces for xml in XML instances generated from this xsd.</xsd:documentation>
  22. <xsd:documentation>Imports IMS meta-data xsd, lower case element names. </xsd:documentation>
  23. <xsd:documentation>This XSD provides a reference to the IMS meta-data root element as imsmd:record</xsd:documentation>
  24. <xsd:documentation>If the IMS meta-data is to be used in the XML instance then the instance must define an IMS meta-data prefix with a namespace. The meta-data targetNamespace should be used. </xsd:documentation>
  25. <xsd:documentation>2001-03-20, Thor Anderson: Remove manifestref, change resourceref back to identifierref, change manifest back to contained by manifest. --Tom Wason: manifest may contain _none_ or more manifests.</xsd:documentation>
  26. <xsd:documentation>2001-04-13 Tom Wason: corrected attirbute name structure. Was misnamed type. </xsd:documentation>
  27. <xsd:documentation>2001-05-14 Schawn Thropp: Made all complexType extensible with the group.any</xsd:documentation>
  28. <xsd:documentation>Added the anyAttribute to all complexTypes. Changed the href attribute on the fileType and resourceType to xsd:string</xsd:documentation>
  29. <xsd:documentation>Changed the maxLength of the href, identifierref, parameters, structure attributes to match the Information model.</xsd:documentation>
  30. <xsd:documentation>2001-07-25 Schawn Thropp: Changed the namespace for the Schema of Schemas to the 5/2/2001 W3C XML Schema</xsd:documentation>
  31. <xsd:documentation>Recommendation. attributeGroup attr.imsmd deleted, was not used anywhere. Any attribute declarations that have</xsd:documentation>
  32. <xsd:documentation>use = "default" changed to use="optional" - attr.structure.req.</xsd:documentation>
  33. <xsd:documentation>Any attribute declarations that have value="somevalue" changed to default="somevalue",</xsd:documentation>
  34. <xsd:documentation>attr.structure.req (hierarchical). Removed references to IMS MD Version 1.1.</xsd:documentation>
  35. <xsd:documentation>Modified attribute group "attr.resourcetype.req" to change use from optional</xsd:documentation>
  36. <xsd:documentation>to required to match the information model. As a result the default value also needed to be removed</xsd:documentation>
  37. <xsd:documentation>Name change for XSD. Changed to match version of CP Spec </xsd:documentation>
  38. </xsd:annotation>
  39. <xsd:annotation>
  40. <xsd:documentation>Inclusions and Imports</xsd:documentation>
  41. </xsd:annotation>
  42. <xsd:import namespace="http://www.w3.org/XML/1998/namespace" schemaLocation="ims_xml.xsd"/>
  43. <xsd:annotation>
  44. <xsd:documentation>Attribute Declarations</xsd:documentation>
  45. </xsd:annotation>
  46. <!-- **************************** -->
  47. <!-- ** Attribute Declarations ** -->
  48. <!-- **************************** -->
  49. <xsd:attributeGroup name="attr.base">
  50. <xsd:attribute ref="xml:base" use="optional"/>
  51. </xsd:attributeGroup>
  52. <xsd:attributeGroup name="attr.default">
  53. <xsd:attribute name="default" type="xsd:IDREF" use="optional"/>
  54. </xsd:attributeGroup>
  55. <xsd:attributeGroup name="attr.href">
  56. <xsd:attribute name="href" use="optional">
  57. <xsd:simpleType>
  58. <xsd:restriction base="xsd:anyURI">
  59. <xsd:maxLength value="2000"/>
  60. </xsd:restriction>
  61. </xsd:simpleType>
  62. </xsd:attribute>
  63. </xsd:attributeGroup>
  64. <xsd:attributeGroup name="attr.href.req">
  65. <xsd:attribute name="href" use="required">
  66. <xsd:simpleType>
  67. <xsd:restriction base="xsd:anyURI">
  68. <xsd:maxLength value="2000"/>
  69. </xsd:restriction>
  70. </xsd:simpleType>
  71. </xsd:attribute>
  72. </xsd:attributeGroup>
  73. <xsd:attributeGroup name="attr.identifier.req">
  74. <xsd:attribute name="identifier" type="xsd:ID" use="required"/>
  75. </xsd:attributeGroup>
  76. <xsd:attributeGroup name="attr.identifier">
  77. <xsd:attribute name="identifier" type="xsd:ID" use="optional"/>
  78. </xsd:attributeGroup>
  79. <xsd:attributeGroup name="attr.isvisible">
  80. <xsd:attribute name="isvisible" type="xsd:boolean" use="optional"/>
  81. </xsd:attributeGroup>
  82. <xsd:attributeGroup name="attr.parameters">
  83. <xsd:attribute name="parameters" use="optional">
  84. <xsd:simpleType>
  85. <xsd:restriction base="xsd:string">
  86. <xsd:maxLength value="1000"/>
  87. </xsd:restriction>
  88. </xsd:simpleType>
  89. </xsd:attribute>
  90. </xsd:attributeGroup>
  91. <xsd:attributeGroup name="attr.identifierref">
  92. <xsd:attribute name="identifierref" use="optional">
  93. <xsd:simpleType>
  94. <xsd:restriction base="xsd:string">
  95. <xsd:maxLength value="2000"/>
  96. </xsd:restriction>
  97. </xsd:simpleType>
  98. </xsd:attribute>
  99. </xsd:attributeGroup>
  100. <xsd:attributeGroup name="attr.identifierref.req">
  101. <xsd:attribute name="identifierref" use="required">
  102. <xsd:simpleType>
  103. <xsd:restriction base="xsd:string">
  104. <xsd:maxLength value="2000"/>
  105. </xsd:restriction>
  106. </xsd:simpleType>
  107. </xsd:attribute>
  108. </xsd:attributeGroup>
  109. <xsd:attributeGroup name="attr.resourcetype.req">
  110. <xsd:attribute name="type" use="required">
  111. <xsd:simpleType>
  112. <xsd:restriction base="xsd:string">
  113. <xsd:maxLength value="1000"/>
  114. </xsd:restriction>
  115. </xsd:simpleType>
  116. </xsd:attribute>
  117. </xsd:attributeGroup>
  118. <xsd:attributeGroup name="attr.structure.req">
  119. <xsd:attribute name="structure" use="optional" default="hierarchical">
  120. <xsd:simpleType>
  121. <xsd:restriction base="xsd:string">
  122. <xsd:maxLength value="200"/>
  123. </xsd:restriction>
  124. </xsd:simpleType>
  125. </xsd:attribute>
  126. </xsd:attributeGroup>
  127. <xsd:attributeGroup name="attr.version">
  128. <xsd:attribute name="version" use="optional">
  129. <xsd:simpleType>
  130. <xsd:restriction base="xsd:string">
  131. <xsd:maxLength value="20"/>
  132. </xsd:restriction>
  133. </xsd:simpleType>
  134. </xsd:attribute>
  135. </xsd:attributeGroup>
  136. <xsd:annotation>
  137. <xsd:documentation>element groups</xsd:documentation>
  138. </xsd:annotation>
  139. <xsd:group name="grp.any">
  140. <xsd:annotation>
  141. <xsd:documentation>Any namespaced element from any namespace may be included within an &quot;any&quot; element. The namespace for the imported element must be defined in the instance, and the schema must be imported. </xsd:documentation>
  142. </xsd:annotation>
  143. <xsd:sequence>
  144. <xsd:any namespace="##other" processContents="strict" minOccurs="0" maxOccurs="unbounded"/>
  145. </xsd:sequence>
  146. </xsd:group>
  147. <!-- ************************** -->
  148. <!-- ** Element Declarations ** -->
  149. <!-- ************************** -->
  150. <xsd:element name="dependency" type="dependencyType"/>
  151. <xsd:element name="file" type="fileType"/>
  152. <xsd:element name="item" type="itemType"/>
  153. <xsd:element name="manifest" type="manifestType"/>
  154. <xsd:element name="metadata" type="metadataType"/>
  155. <xsd:element name="organization" type="organizationType"/>
  156. <xsd:element name="organizations" type="organizationsType"/>
  157. <xsd:element name="resource" type="resourceType"/>
  158. <xsd:element name="resources" type="resourcesType"/>
  159. <xsd:element name="schema" type="schemaType"/>
  160. <xsd:element name="schemaversion" type="schemaversionType"/>
  161. <xsd:element name="title" type="titleType"/>
  162. <!-- ******************* -->
  163. <!-- ** Complex Types ** -->
  164. <!-- ******************* -->
  165. <!-- **************** -->
  166. <!-- ** dependency ** -->
  167. <!-- **************** -->
  168. <xsd:complexType name="dependencyType">
  169. <xsd:sequence>
  170. <xsd:group ref="grp.any"/>
  171. </xsd:sequence>
  172. <xsd:attributeGroup ref="attr.identifierref.req"/>
  173. <xsd:anyAttribute namespace="##other" processContents="strict"/>
  174. </xsd:complexType>
  175. <!-- ********** -->
  176. <!-- ** file ** -->
  177. <!-- ********** -->
  178. <xsd:complexType name="fileType">
  179. <xsd:sequence>
  180. <xsd:element ref="metadata" minOccurs="0"/>
  181. <xsd:group ref="grp.any"/>
  182. </xsd:sequence>
  183. <xsd:attributeGroup ref="attr.href.req"/>
  184. <xsd:anyAttribute namespace="##other" processContents="strict"/>
  185. </xsd:complexType>
  186. <!-- ********** -->
  187. <!-- ** item ** -->
  188. <!-- ********** -->
  189. <xsd:complexType name="itemType">
  190. <xsd:sequence>
  191. <xsd:element ref="title" minOccurs="0"/>
  192. <xsd:element ref="item" minOccurs="0" maxOccurs="unbounded"/>
  193. <xsd:element ref="metadata" minOccurs="0"/>
  194. <xsd:group ref="grp.any"/>
  195. </xsd:sequence>
  196. <xsd:attributeGroup ref="attr.identifier.req"/>
  197. <xsd:attributeGroup ref="attr.identifierref"/>
  198. <xsd:attributeGroup ref="attr.isvisible"/>
  199. <xsd:attributeGroup ref="attr.parameters"/>
  200. <xsd:anyAttribute namespace="##other" processContents="strict"/>
  201. </xsd:complexType>
  202. <!-- ************** -->
  203. <!-- ** manifest ** -->
  204. <!-- ************** -->
  205. <xsd:complexType name="manifestType">
  206. <xsd:sequence>
  207. <xsd:element ref="metadata" minOccurs="0"/>
  208. <xsd:element ref="organizations"/>
  209. <xsd:element ref="resources"/>
  210. <xsd:element ref="manifest" minOccurs="0" maxOccurs="unbounded"/>
  211. <xsd:group ref="grp.any"/>
  212. </xsd:sequence>
  213. <xsd:attributeGroup ref="attr.identifier.req"/>
  214. <xsd:attributeGroup ref="attr.version"/>
  215. <xsd:attribute ref="xml:base"/>
  216. <xsd:anyAttribute namespace="##other" processContents="strict"/>
  217. </xsd:complexType>
  218. <!-- ************** -->
  219. <!-- ** metadata ** -->
  220. <!-- ************** -->
  221. <xsd:complexType name="metadataType">
  222. <xsd:sequence>
  223. <xsd:element ref="schema" minOccurs="0"/>
  224. <xsd:element ref="schemaversion" minOccurs="0"/>
  225. <xsd:group ref="grp.any"/>
  226. </xsd:sequence>
  227. </xsd:complexType>
  228. <!-- ******************* -->
  229. <!-- ** organizations ** -->
  230. <!-- ******************* -->
  231. <xsd:complexType name="organizationsType">
  232. <xsd:sequence>
  233. <xsd:element ref="organization" minOccurs="0" maxOccurs="unbounded"/>
  234. <xsd:group ref="grp.any"/>
  235. </xsd:sequence>
  236. <xsd:attributeGroup ref="attr.default"/>
  237. <xsd:anyAttribute namespace="##other" processContents="strict"/>
  238. </xsd:complexType>
  239. <!-- ****************** -->
  240. <!-- ** organization ** -->
  241. <!-- ****************** -->
  242. <xsd:complexType name="organizationType">
  243. <xsd:sequence>
  244. <xsd:element ref="title" minOccurs="0"/>
  245. <xsd:element ref="item" minOccurs="0" maxOccurs="unbounded"/>
  246. <xsd:element ref="metadata" minOccurs="0"/>
  247. <xsd:group ref="grp.any"/>
  248. </xsd:sequence>
  249. <xsd:attributeGroup ref="attr.identifier.req"/>
  250. <xsd:attributeGroup ref="attr.structure.req"/>
  251. <xsd:anyAttribute namespace="##other" processContents="strict"/>
  252. </xsd:complexType>
  253. <!-- *************** -->
  254. <!-- ** resources ** -->
  255. <!-- *************** -->
  256. <xsd:complexType name="resourcesType">
  257. <xsd:sequence>
  258. <xsd:element ref="resource" minOccurs="0" maxOccurs="unbounded"/>
  259. <xsd:group ref="grp.any"/>
  260. </xsd:sequence>
  261. <xsd:attributeGroup ref="attr.base"/>
  262. <xsd:anyAttribute namespace="##other" processContents="strict"/>
  263. </xsd:complexType>
  264. <!-- ************** -->
  265. <!-- ** resource ** -->
  266. <!-- ************** -->
  267. <xsd:complexType name="resourceType">
  268. <xsd:sequence>
  269. <xsd:element ref="metadata" minOccurs="0"/>
  270. <xsd:element ref="file" minOccurs="0" maxOccurs="unbounded"/>
  271. <xsd:element ref="dependency" minOccurs="0" maxOccurs="unbounded"/>
  272. <xsd:group ref="grp.any"/>
  273. </xsd:sequence>
  274. <xsd:attributeGroup ref="attr.identifier.req"/>
  275. <xsd:attributeGroup ref="attr.resourcetype.req"/>
  276. <xsd:attributeGroup ref="attr.base"/>
  277. <xsd:attributeGroup ref="attr.href"/>
  278. <xsd:anyAttribute namespace="##other" processContents="strict"/>
  279. </xsd:complexType>
  280. <!-- ****************** -->
  281. <!-- ** Simple Types ** -->
  282. <!-- ****************** -->
  283. <!-- ************ -->
  284. <!-- ** schema ** -->
  285. <!-- ************ -->
  286. <xsd:simpleType name="schemaType">
  287. <xsd:restriction base="xsd:string">
  288. <xsd:maxLength value="100"/>
  289. </xsd:restriction>
  290. </xsd:simpleType>
  291. <!-- ******************* -->
  292. <!-- ** schemaversion ** -->
  293. <!-- ******************* -->
  294. <xsd:simpleType name="schemaversionType">
  295. <xsd:restriction base="xsd:string">
  296. <xsd:maxLength value="20"/>
  297. </xsd:restriction>
  298. </xsd:simpleType>
  299. <!-- *********** -->
  300. <!-- ** title ** -->
  301. <!-- *********** -->
  302. <xsd:simpleType name="titleType">
  303. <xsd:restriction base="xsd:string">
  304. <xsd:maxLength value="200"/>
  305. </xsd:restriction>
  306. </xsd:simpleType>
  307. </xsd:schema>