application_1_4.xsd 9.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314
  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <xsd:schema xmlns="http://www.w3.org/2001/XMLSchema"
  3. targetNamespace="http://java.sun.com/xml/ns/j2ee"
  4. xmlns:j2ee="http://java.sun.com/xml/ns/j2ee"
  5. xmlns:xsd="http://www.w3.org/2001/XMLSchema"
  6. elementFormDefault="qualified"
  7. attributeFormDefault="unqualified"
  8. version="1.4">
  9. <xsd:annotation>
  10. <xsd:documentation>
  11. @(#)application_1_4.xsds 1.13 02/11/03
  12. </xsd:documentation>
  13. </xsd:annotation>
  14. <xsd:annotation>
  15. <xsd:documentation>
  16. Copyright 2002 Sun Microsystems, Inc., 901 San Antonio
  17. Road, Palo Alto, California 94303, U.S.A. All rights
  18. reserved.
  19. Sun Microsystems, Inc. has intellectual property rights
  20. relating to technology described in this document. In
  21. particular, and without limitation, these intellectual
  22. property rights may include one or more of the U.S. patents
  23. listed at http://www.sun.com/patents and one or more
  24. additional patents or pending patent applications in the
  25. U.S. and other countries.
  26. This document and the technology which it describes are
  27. distributed under licenses restricting their use, copying,
  28. distribution, and decompilation. No part of this document
  29. may be reproduced in any form by any means without prior
  30. written authorization of Sun and its licensors, if any.
  31. Third-party software, including font technology, is
  32. copyrighted and licensed from Sun suppliers.
  33. Sun, Sun Microsystems, the Sun logo, Solaris, Java, J2EE,
  34. JavaServer Pages, Enterprise JavaBeans and the Java Coffee
  35. Cup logo are trademarks or registered trademarks of Sun
  36. Microsystems, Inc. in the U.S. and other countries.
  37. Federal Acquisitions: Commercial Software - Government Users
  38. Subject to Standard License Terms and Conditions.
  39. </xsd:documentation>
  40. </xsd:annotation>
  41. <xsd:annotation>
  42. <xsd:documentation>
  43. <![CDATA[
  44. This is the XML Schema for the application 1.4 deployment
  45. descriptor. The deployment descriptor must be named
  46. "META-INF/application.xml" in the application's ear file.
  47. All application deployment descriptors must indicate
  48. the application schema by using the J2EE namespace:
  49. http://java.sun.com/xml/ns/j2ee
  50. and indicate the version of the schema by
  51. using the version element as shown below:
  52. <application xmlns="http://java.sun.com/xml/ns/j2ee"
  53. xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
  54. xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee
  55. http://java.sun.com/xml/ns/j2ee/application_1_4.xsd"
  56. version="1.4">
  57. ...
  58. </application>
  59. The instance documents may indicate the published version of
  60. the schema using the xsi:schemaLocation attribute for J2EE
  61. namespace with the following location:
  62. http://java.sun.com/xml/ns/j2ee/application_1_4.xsd
  63. ]]>
  64. </xsd:documentation>
  65. </xsd:annotation>
  66. <xsd:annotation>
  67. <xsd:documentation>
  68. The following conventions apply to all J2EE
  69. deployment descriptor elements unless indicated otherwise.
  70. - In elements that specify a pathname to a file within the
  71. same JAR file, relative filenames (i.e., those not
  72. starting with "/") are considered relative to the root of
  73. the JAR file's namespace. Absolute filenames (i.e., those
  74. starting with "/") also specify names in the root of the
  75. JAR file's namespace. In general, relative names are
  76. preferred. The exception is .war files where absolute
  77. names are preferred for consistency with the Servlet API.
  78. </xsd:documentation>
  79. </xsd:annotation>
  80. <xsd:include schemaLocation="j2ee_1_4.xsd"/>
  81. <!-- **************************************************** -->
  82. <xsd:element name="application" type="j2ee:applicationType">
  83. <xsd:annotation>
  84. <xsd:documentation>
  85. The application element is the root element of a J2EE
  86. application deployment descriptor.
  87. </xsd:documentation>
  88. </xsd:annotation>
  89. <xsd:unique name="context-root-uniqueness">
  90. <xsd:annotation>
  91. <xsd:documentation>
  92. The context-root element content must be unique
  93. in the ear.
  94. </xsd:documentation>
  95. </xsd:annotation>
  96. <xsd:selector xpath="j2ee:module/j2ee:web"/>
  97. <xsd:field xpath="j2ee:context-root"/>
  98. </xsd:unique>
  99. <xsd:unique name="security-role-uniqueness">
  100. <xsd:annotation>
  101. <xsd:documentation>
  102. The security-role-name element content
  103. must be unique in the ear.
  104. </xsd:documentation>
  105. </xsd:annotation>
  106. <xsd:selector xpath="j2ee:security-role"/>
  107. <xsd:field xpath="j2ee:role-name"/>
  108. </xsd:unique>
  109. </xsd:element>
  110. <!-- **************************************************** -->
  111. <xsd:complexType name="applicationType">
  112. <xsd:annotation>
  113. <xsd:documentation>
  114. The applicationType defines the structure of the
  115. application.
  116. </xsd:documentation>
  117. </xsd:annotation>
  118. <xsd:sequence>
  119. <xsd:group ref="j2ee:descriptionGroup"/>
  120. <xsd:element name="module"
  121. type="j2ee:moduleType"
  122. maxOccurs="unbounded">
  123. <xsd:annotation>
  124. <xsd:documentation>
  125. The application deployment descriptor must have one
  126. module element for each J2EE module in the
  127. application package. A module element is defined
  128. by moduleType definition.
  129. </xsd:documentation>
  130. </xsd:annotation>
  131. </xsd:element>
  132. <xsd:element name="security-role"
  133. type="j2ee:security-roleType"
  134. minOccurs="0"
  135. maxOccurs="unbounded"/>
  136. </xsd:sequence>
  137. <xsd:attribute name="version"
  138. type="j2ee:dewey-versionType"
  139. fixed="1.4"
  140. use="required">
  141. <xsd:annotation>
  142. <xsd:documentation>
  143. The required value for the version is 1.4.
  144. </xsd:documentation>
  145. </xsd:annotation>
  146. </xsd:attribute>
  147. <xsd:attribute name="id" type="xsd:ID"/>
  148. </xsd:complexType>
  149. <!-- **************************************************** -->
  150. <xsd:complexType name="moduleType">
  151. <xsd:annotation>
  152. <xsd:documentation>
  153. The moduleType defines a single J2EE module and contains a
  154. connector, ejb, java, or web element, which indicates the
  155. module type and contains a path to the module file, and an
  156. optional alt-dd element, which specifies an optional URI to
  157. the post-assembly version of the deployment descriptor.
  158. </xsd:documentation>
  159. </xsd:annotation>
  160. <xsd:sequence>
  161. <xsd:choice>
  162. <xsd:element name="connector"
  163. type="j2ee:pathType">
  164. <xsd:annotation>
  165. <xsd:documentation>
  166. The connector element specifies the URI of a
  167. resource adapter archive file, relative to the
  168. top level of the application package.
  169. </xsd:documentation>
  170. </xsd:annotation>
  171. </xsd:element>
  172. <xsd:element name="ejb"
  173. type="j2ee:pathType">
  174. <xsd:annotation>
  175. <xsd:documentation>
  176. The ejb element specifies the URI of an ejb-jar,
  177. relative to the top level of the application
  178. package.
  179. </xsd:documentation>
  180. </xsd:annotation>
  181. </xsd:element>
  182. <xsd:element name="java"
  183. type="j2ee:pathType">
  184. <xsd:annotation>
  185. <xsd:documentation>
  186. The java element specifies the URI of a java
  187. application client module, relative to the top
  188. level of the application package.
  189. </xsd:documentation>
  190. </xsd:annotation>
  191. </xsd:element>
  192. <xsd:element name="web"
  193. type="j2ee:webType"/>
  194. </xsd:choice>
  195. <xsd:element name="alt-dd"
  196. type="j2ee:pathType"
  197. minOccurs="0">
  198. <xsd:annotation>
  199. <xsd:documentation>
  200. The alt-dd element specifies an optional URI to the
  201. post-assembly version of the deployment descriptor
  202. file for a particular J2EE module. The URI must
  203. specify the full pathname of the deployment
  204. descriptor file relative to the application's root
  205. directory. If alt-dd is not specified, the deployer
  206. must read the deployment descriptor from the default
  207. location and file name required by the respective
  208. component specification.
  209. </xsd:documentation>
  210. </xsd:annotation>
  211. </xsd:element>
  212. </xsd:sequence>
  213. <xsd:attribute name="id" type="xsd:ID"/>
  214. </xsd:complexType>
  215. <!-- **************************************************** -->
  216. <xsd:complexType name="webType">
  217. <xsd:annotation>
  218. <xsd:documentation>
  219. The webType defines the web-uri and context-root of
  220. a web application module.
  221. </xsd:documentation>
  222. </xsd:annotation>
  223. <xsd:sequence>
  224. <xsd:element name="web-uri"
  225. type="j2ee:pathType">
  226. <xsd:annotation>
  227. <xsd:documentation>
  228. The web-uri element specifies the URI of a web
  229. application file, relative to the top level of the
  230. application package.
  231. </xsd:documentation>
  232. </xsd:annotation>
  233. </xsd:element>
  234. <xsd:element name="context-root"
  235. type="j2ee:string">
  236. <xsd:annotation>
  237. <xsd:documentation>
  238. The context-root element specifies the context root
  239. of a web application.
  240. </xsd:documentation>
  241. </xsd:annotation>
  242. </xsd:element>
  243. </xsd:sequence>
  244. <xsd:attribute name="id" type="xsd:ID"/>
  245. </xsd:complexType>
  246. </xsd:schema>