ejb-jar_1_1.dtd 29 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894
  1. <!--
  2. Copyright 1999 Sun Microsystems, Inc. 901 San Antonio Road,
  3. Palo Alto, CA 94303, U.S.A. All rights reserved.
  4. This product or document is protected by copyright and distributed
  5. under licenses restricting its use, copying, distribution, and
  6. decompilation. No part of this product or documentation may be
  7. reproduced in any form by any means without prior written authorization
  8. of Sun and its licensors, if any.
  9. Third party software, including font technology, is copyrighted and
  10. licensed from Sun suppliers.
  11. Sun, Sun Microsystems, the Sun Logo, Solaris, Java, JavaServer Pages, Java
  12. Naming and Directory Interface, JDBC, JDK, JavaMail and Enterprise JavaBeans,
  13. are trademarks or registered trademarks of Sun Microsystems, Inc in the U.S.
  14. and other countries.
  15. All SPARC trademarks are used under license and are trademarks
  16. or registered trademarks of SPARC International, Inc.
  17. in the U.S. and other countries. Products bearing SPARC
  18. trademarks are based upon an architecture developed by Sun Microsystems, Inc.
  19. PostScript is a registered trademark of Adobe Systems, Inc.
  20. Federal Acquisitions: Commercial Software - Government Users Subject to
  21. Standard License Terms and Conditions.
  22. DOCUMENTATION IS PROVIDED "AS IS" AND ALL EXPRESS OR IMPLIED
  23. CONDITIONS, REPRESENTATIONS AND WARRANTIES, INCLUDING ANY
  24. IMPLIED WARRANTY OF MERCHANTABILITY, FITNESS FOR A PARTICULAR
  25. PURPOSE OR NON-INFRINGEMENT, ARE DISCLAIMED, EXCEPT
  26. TO THE EXTENT THAT SUCH DISCLAIMERS ARE HELD TO BE LEGALLY
  27. INVALID.
  28. _________________________________________________________________________
  29. Copyright 1999 Sun Microsystems, Inc.,
  30. 901 San Antonio Road, Palo Alto, CA 94303, Etats-Unis.
  31. Tous droits re'serve's.
  32. Ce produit ou document est prote'ge' par un copyright et distribue' avec
  33. des licences qui en restreignent l'utilisation, la copie, la distribution,
  34. et la de'compilation. Aucune partie de ce produit ou de sa documentation
  35. associe'e ne peut e^tre reproduite sous aucune forme, par quelque moyen
  36. que ce soit, sans l'autorisation pre'alable et e'crite de Sun et de ses
  37. bailleurs de licence, s'il y en a.
  38. Le logiciel de'tenu par des tiers, et qui comprend la technologie
  39. relative aux polices de caracte`res, est prote'ge' par un copyright
  40. et licencie' par des fournisseurs de Sun.
  41. Sun, Sun Microsystems, le logo Sun, Solaris, Java, JavaServer Pages, Java
  42. Naming and Directory Interface, JDBC, JDK, JavaMail, et Enterprise JavaBeans,
  43. sont des marques de fabrique ou des marques de'pose'es de Sun
  44. Microsystems, Inc. aux Etats-Unis et dans d'autres pays.
  45. Toutes les marques SPARC sont utilise'es sous licence et sont
  46. des marques de fabrique ou des marques de'pose'es de SPARC
  47. International, Inc. aux Etats-Unis et dans
  48. d'autres pays. Les produits portant les marques SPARC sont
  49. base's sur une architecture de'veloppe'e par Sun Microsystems, Inc.
  50. Postcript est une marque enregistre'e d'Adobe Systems Inc.
  51. LA DOCUMENTATION EST FOURNIE "EN L'ETAT" ET TOUTES AUTRES CONDITIONS,
  52. DECLARATIONS ET GARANTIES EXPRESSES OU TACITES SONT FORMELLEMENT EXCLUES,
  53. DANS LA MESURE AUTORISEE PAR LA LOI APPLICABLE, Y COMPRIS NOTAMMENT
  54. TOUTE GARANTIE IMPLICITE RELATIVE A LA QUALITE MARCHANDE, A L'APTITUDE
  55. A UNE UTILISATION PARTICULIERE OU A L'ABSENCE DE CONTREFACON.
  56. -->
  57. <!--
  58. This is the XML DTD for the EJB 1.1 deployment descriptor.
  59. -->
  60. <!--
  61. The assembly-descriptor element contains application-assembly information.
  62. The application-assembly information consists of the following parts:
  63. the definition of security roles, the definition of method permissions,
  64. and the definition of transaction attributes for enterprise beans with
  65. container-managed transaction demarcation.
  66. All the parts are optional in the sense that they are omitted if the
  67. lists represented by them are empty.
  68. Providing an assembly-descriptor in the deployment descriptor is
  69. optional for the ejb-jar file producer.
  70. Used in: ejb-jar
  71. -->
  72. <!ELEMENT assembly-descriptor (security-role*, method-permission*,
  73. container-transaction*)>
  74. <!--
  75. The cmp-field element describes a container-managed field. The field
  76. element includes an optional description of the field, and the name of
  77. the field.
  78. Used in: entity
  79. -->
  80. <!ELEMENT cmp-field (description?, field-name)>
  81. <!--
  82. The container-transaction element specifies how the container must
  83. manage transaction scopes for the enterprise bean's method invocations.
  84. The element consists of an optional description, a list of method
  85. elements, and a transaction attribute.The transaction attribute is to
  86. be applied to all the specified methods.
  87. Used in: assembly-descriptor
  88. -->
  89. <!ELEMENT container-transaction (description?, method+,
  90. trans-attribute)>
  91. <!--
  92. The description element is used by the ejb-jar file producer to provide
  93. text describing the parent element.
  94. The description element should include any information that the ejb-jar
  95. file producer wants to provide to the consumer of the ejb-jar file
  96. (i.e. to the Deployer). Typically, the tools used by the ejb-jar file
  97. consumer will display the description when processing the parent
  98. element.
  99. Used in: cmp-field, container-transaction, ejb-jar, entity, env-entry,
  100. ejb-ref, method, method-permission, resource-ref, security-role,
  101. security-role-ref, and session.
  102. -->
  103. <!ELEMENT description (#PCDATA)>
  104. <!--
  105. The display-name element contains a short name that is intended to be
  106. display by tools.
  107. Used in: ejb-jar, session, and entity
  108. Example:
  109. <display-name>Employee Self Service</display-name>
  110. -->
  111. <!ELEMENT display-name (#PCDATA)>
  112. <!--
  113. The ejb-class element contains the fully-qualified name of the
  114. enterprise bean's class.
  115. Used in: entity and session
  116. Example:
  117. <ejb-class>com.wombat.empl.EmployeeServiceBean</ejb-class>
  118. -->
  119. <!ELEMENT ejb-class (#PCDATA)>
  120. <!--
  121. The optional ejb-client-jar element specifies a JAR file that contains
  122. the class files necessary for a client program to access the enterprise
  123. beans in the ejb-jar file. The Deployer should make the ejb-client JAR
  124. file accessible to the client's class-loader.
  125. Used in: ejb-jar
  126. Example:
  127. <ejb-client-jar>employee_service_client.jar</ejb-client-jar>
  128. -->
  129. <!ELEMENT ejb-client-jar (#PCDATA)>
  130. <!--
  131. The ejb-jar element is the root element of the EJB deployment
  132. descriptor. It contains an optional description of the ejb-jar file,
  133. optional display name, optional small icon file name, optional large
  134. icon file name, mandatory structural information about all included
  135. enterprise beans, optional application-assembly descriptor, and an
  136. optional name of an ejb-client-jar file for the ejb-jar.
  137. -->
  138. <!ELEMENT ejb-jar (description?, display-name?, small-icon?,
  139. large-icon?, enterprise-beans, assembly-descriptor?,
  140. ejb-client-jar?)>
  141. <!--
  142. The ejb-link element is used in the ejb-ref element to specify that an
  143. EJB reference is linked to another enterprise bean in the ejb-jar
  144. file.
  145. The value of the ejb-link element must be the ejb-name of an enterprise
  146. bean in the same ejb-jar file, or in another ejb-jar file in the same
  147. J2EE application unit.
  148. Used in: ejb-ref
  149. Example:
  150. <ejb-link>EmployeeRecord</ejb-link>
  151. -->
  152. <!ELEMENT ejb-link (#PCDATA)>
  153. <!--
  154. The ejb-name element specifies an enterprise bean's name. This name is
  155. assigned by the ejb-jar file producer to name the enterprise bean in
  156. the ejb-jar file's deployment descriptor. The name must be unique among
  157. the names of the enterprise beans in the same ejb-jar file.
  158. The enterprise bean code does not depend on the name; therefore the
  159. name can be changed during the application-assembly process without
  160. breaking the enterprise bean's function.
  161. There is no architected relationship between the ejb-name in the
  162. deployment descriptor and the JNDI name that the Deployer will assign
  163. to the enterprise bean's home.
  164. The name must conform to the lexical rules for an NMTOKEN.
  165. Used in: entity, method, and session
  166. Example:
  167. <ejb-name>EmployeeService</ejb-name>
  168. -->
  169. <!ELEMENT ejb-name (#PCDATA)>
  170. <!--
  171. The ejb-ref element is used for the declaration of a reference to
  172. another enterprise bean's home. The declaration consists of an optional
  173. description; the EJB reference name used in the code of the referencing
  174. enterprise bean; the expected type of the referenced enterprise bean;
  175. the expected home and remote interfaces of the referenced enterprise
  176. bean; and an optional ejb-link information.
  177. The optional ejb-link element is used to specify the referenced
  178. enterprise bean. It is used typically in ejb-jar files that contain an
  179. assembled application.
  180. Used in: entity and session
  181. -->
  182. <!ELEMENT ejb-ref (description?, ejb-ref-name, ejb-ref-type, home,
  183. remote, ejb-link?)>
  184. <!--
  185. The ejb-ref-name element contains the name of an EJB reference. The EJB
  186. reference is an entry in the enterprise bean's environment.
  187. It is recommended that name is prefixed with "ejb/".
  188. Used in: ejb-ref
  189. Example:
  190. <ejb-ref-name>ejb/Payroll</ejb-ref-name>
  191. -->
  192. <!ELEMENT ejb-ref-name (#PCDATA)>
  193. <!--
  194. The ejb-ref-type element contains the expected type of the referenced
  195. enterprise bean.
  196. The ejb-ref-type element must be one of the following:
  197. <ejb-ref-type>Entity</ejb-ref-type>
  198. <ejb-ref-type>Session</ejb-ref-type>
  199. Used in: ejb-ref
  200. -->
  201. <!ELEMENT ejb-ref-type (#PCDATA)>
  202. <!--
  203. The enterprise-beans element contains the declarations of one or more
  204. enterprise beans.
  205. -->
  206. <!ELEMENT enterprise-beans (session | entity)+>
  207. <!--
  208. The entity element declares an entity bean. The declaration consists
  209. of: an optional description; optional display name; optional small icon
  210. file name; optional large icon file name; a name assigned to the
  211. enterprise bean in the deployment descriptor; the names of the entity
  212. bean's home and remote interfaces; the entity bean's implementation
  213. class; the entity bean's persistence management type; the entity bean's
  214. primary key class name; an indication of the entity bean's reentrancy;
  215. an optional list of container-managed fields; an optional specification
  216. of the primary key field; an optional declaration of the bean's
  217. environment entries; an optional declaration of the bean's EJB
  218. references; an optional declaration of the security role references;
  219. and an optional declaration of the bean's resource manager connection
  220. factory references.
  221. The optional primkey-field may be present in the descriptor if the
  222. entity's persistency-type is Container.
  223. The other elements that are optional are "optional" in the sense that
  224. they are omitted if the lists represented by them are empty.
  225. At least one cmp-field element must be present in the descriptor if the
  226. entity's persistency-type is Container, and none must not be present if
  227. the entity's persistence-type is Bean.
  228. Used in: enterprise-beans
  229. -->
  230. <!ELEMENT entity (description?, display-name?, small-icon?,
  231. large-icon?, ejb-name, home, remote, ejb-class,
  232. persistence-type, prim-key-class, reentrant,
  233. cmp-field*, primkey-field?, env-entry*,
  234. ejb-ref*, security-role-ref*, resource-ref*)>
  235. <!--
  236. The env-entry element contains the declaration of an enterprise bean's
  237. environment entries. The declaration consists of an optional
  238. description, the name of the environment entry, and an optional value.
  239. Used in: entity and session
  240. -->
  241. <!ELEMENT env-entry (description?, env-entry-name, env-entry-type,
  242. env-entry-value?)>
  243. <!--
  244. The env-entry-name element contains the name of an enterprise bean's
  245. environment entry.
  246. Used in: env-entry
  247. Example:
  248. <env-entry-name>minAmount</env-entry-name>
  249. -->
  250. <!ELEMENT env-entry-name (#PCDATA)>
  251. <!--
  252. The env-entry-type element contains the fully-qualified Java type of
  253. the environment entry value that is expected by the enterprise bean's
  254. code.
  255. The following are the legal values of env-entry-type:
  256. java.lang.Boolean, java.lang.String, java.lang.Integer,
  257. java.lang.Double, java.lang.Byte, java.lang.Short, java.lang.Long, and
  258. java.lang.Float.
  259. Used in: env-entry
  260. Example:
  261. <env-entry-type>java.lang.Boolean</env-entry-type>
  262. -->
  263. <!ELEMENT env-entry-type (#PCDATA)>
  264. <!--
  265. The env-entry-value element contains the value of an enterprise bean's
  266. environment entry.
  267. Used in: env-entry
  268. Example:
  269. <env-entry-value>100.00</env-entry-value>
  270. -->
  271. <!ELEMENT env-entry-value (#PCDATA)>
  272. <!--
  273. The field-name element specifies the name of a container managed field.
  274. The name must be a public field of the enterprise bean class or one of
  275. its superclasses.
  276. Used in: cmp-field
  277. Example:
  278. <field-name>firstName</field-Name>
  279. -->
  280. <!ELEMENT field-name (#PCDATA)>
  281. <!--
  282. The home element contains the fully-qualified name of the enterprise
  283. bean's home interface.
  284. Used in: ejb-ref, entity, and session
  285. Example:
  286. <home>com.aardvark.payroll.PayrollHome</home>
  287. -->
  288. <!ELEMENT home (#PCDATA)>
  289. <!--
  290. The large-icon element contains the name of a file containing a large
  291. (32 x 32) icon image. The file name is relative path within the ejb-jar
  292. file.
  293. The image must be either in the JPEG or GIF format, and the file name
  294. must end with the suffix ".jpg" or ".gif" respectively. The icon can
  295. be used by tools.
  296. Example:
  297. <large-icon>employee-service-icon32x32.jpg</large-icon>
  298. -->
  299. <!ELEMENT large-icon (#PCDATA)>
  300. <!--
  301. The method element is used to denote a method of an enterprise bean's
  302. home or remote interface, or a set of methods. The ejb-name element
  303. must be the name of one of the enterprise beans in declared in the
  304. deployment descriptor; the optional method-intf element allows to
  305. distinguish between a method with the same signature that is defined in
  306. both the home and remote interface; the method-name element specifies
  307. the method name; and the optional method-params elements identify a
  308. single method among multiple methods with an overloaded method name.
  309. There are three possible styles of the method element syntax:
  310. 1. <method>
  311. <ejb-name>EJBNAME</ejb-name>
  312. <method-name>*</method-name>
  313. </method>
  314. This style is used to refer to all the methods of the specified
  315. enterprise bean's home and remote interfaces.
  316. 2. <method>
  317. <ejb-name>EJBNAME</ejb-name>
  318. <method-name>METHOD</method-name>
  319. </method>>
  320. This style is used to refer to the specified method of the
  321. specified enterprise bean. If there are multiple methods with
  322. the same overloaded name, the element of this style refers to
  323. all the methods with the overloaded name.
  324. 3. <method>
  325. <ejb-name>EJBNAME</ejb-name>
  326. <method-name>METHOD</method-name>
  327. <method-params>
  328. <method-param>PARAM-1</method-param>
  329. <method-param>PARAM-2</method-param>
  330. ...
  331. <method-param>PARAM-n</method-param>
  332. </method-params>
  333. <method>
  334. This style is used to refer to a single method within a set of
  335. methods with an overloaded name. PARAM-1 through PARAM-n are the
  336. fully-qualified Java types of the method's input parameters (if
  337. the method has no input arguments, the method-params element
  338. contains no method-param elements). Arrays are specified by the
  339. array element's type, followed by one or more pair of square
  340. brackets (e.g. int[][]).
  341. Used in: method-permission and container-transaction
  342. Examples:
  343. Style 1: The following method element refers to all the methods of
  344. the EmployeeService bean's home and remote interfaces:
  345. <method>
  346. <ejb-name>EmployeeService</ejb-name>
  347. <method-name>*</method-name>
  348. </method>
  349. Style 2: The following method element refers to all the create
  350. methods of the EmployeeService bean's home interface:
  351. <method>
  352. <ejb-name>EmployeeService</ejb-name>
  353. <method-name>create</method-name>
  354. </method>
  355. Style 3: The following method element refers to the
  356. create(String firstName, String LastName) method of the
  357. EmployeeService bean's home interface.
  358. <method>
  359. <ejb-name>EmployeeService</ejb-name>
  360. <method-name>create</method-name>
  361. <method-params>
  362. <method-param>java.lang.String</method-param>
  363. <method-param>java.lang.String</method-param>
  364. </method-params>
  365. </method>
  366. The following example illustrates a Style 3 element with
  367. more complex parameter types. The method
  368. foobar(char s, int i, int[] iar, mypackage.MyClass mycl,
  369. mypackage.MyClass[][] myclaar)
  370. would be specified as:
  371. <method>
  372. <ejb-name>EmployeeService</ejb-name>
  373. <method-name>foobar</method-name>
  374. <method-params>
  375. <method-param>char</method-param>
  376. <method-param>int</method-param>
  377. <method-param>int[]</method-param>
  378. <method-param>mypackage.MyClass</method-param>
  379. <method-param>mypackage.MyClass[][]</method-param>
  380. </method-params>
  381. </method>
  382. The optional method-intf element can be used when it becomes
  383. necessary to differentiate between a method defined in the home
  384. interface and a method with the same name and signature that is
  385. defined in the remote interface.
  386. For example, the method element
  387. <method>
  388. <ejb-name>EmployeeService</ejb-name>
  389. <method-intf>Remote</method-intf>
  390. <method-name>create</method-name>
  391. <method-params>
  392. <method-param>java.lang.String</method-param>
  393. <method-param>java.lang.String</method-param>
  394. </method-params>
  395. </method>
  396. can be used to differentiate the create(String, String) method
  397. defined in the remote interface from the create(String, String)
  398. method defined in the home interface, which would be defined as
  399. <method>
  400. <ejb-name>EmployeeService</ejb-name>
  401. <method-intf>Home</method-intf>
  402. <method-name>create</method-name>
  403. <method-params>
  404. <method-param>java.lang.String</method-param>
  405. <method-param>java.lang.String</method-param>
  406. </method-params>
  407. </method>
  408. -->
  409. <!ELEMENT method (description?, ejb-name, method-intf?, method-name,
  410. method-params?)>
  411. <!--
  412. The method-intf element allows a method element to differentiate
  413. between the methods with the same name and signature that are defined
  414. in both the remote and home interfaces.
  415. The method-intf element must be one of the following:
  416. <method-intf>Home</method-intf>
  417. <method-intf>Remote</method-intf>
  418. Used in: method
  419. -->
  420. <!ELEMENT method-intf (#PCDATA)>
  421. <!--
  422. The method-name element contains a name of an enterprise bean method,
  423. or the asterisk (*) character. The asterisk is used when the element
  424. denotes all the methods of an enterprise bean's remote and home
  425. interfaces.
  426. Used in: method
  427. -->
  428. <!ELEMENT method-name (#PCDATA)>
  429. <!--
  430. The method-param element contains the fully-qualified Java type name of
  431. a method parameter.
  432. Used in: method-params
  433. -->
  434. <!ELEMENT method-param (#PCDATA)>
  435. <!--
  436. The method-params element contains a list of the fully-qualified Java
  437. type names of the method parameters.
  438. Used in: method
  439. -->
  440. <!ELEMENT method-params (method-param*)>
  441. <!--
  442. The method-permission element specifies that one or more security roles
  443. are allowed to invoke one or more enterprise bean methods. The
  444. method-permission element consists of an optional description, a list
  445. of security role names, and a list of method elements.
  446. The security roles used in the method-permission element must be
  447. defined in the security-role element of the deployment descriptor, and
  448. the methods must be methods defined in the enterprise bean's remote
  449. and/or home interfaces.
  450. Used in: assembly-descriptor
  451. -->
  452. <!ELEMENT method-permission (description?, role-name+, method+)>
  453. <!--
  454. The persistence-type element specifies an entity bean's persistence
  455. management type.
  456. The persistence-type element must be one of the two following:
  457. <persistence-type>Bean</persistence-type>
  458. <persistence-type>Container</persistence-type>
  459. Used in: entity
  460. -->
  461. <!ELEMENT persistence-type (#PCDATA)>
  462. <!--
  463. The prim-key-class element contains the fully-qualified name of an
  464. entity bean's primary key class.
  465. If the definition of the primary key class is deferred to deployment
  466. time, the prim-key-class element should specify java.lang.Object.
  467. Used in: entity
  468. Examples:
  469. <prim-key-class>java.lang.String</prim-key-class>
  470. <prim-key-class>com.wombat.empl.EmployeeID</prim-key-class>
  471. <prim-key-class>java.lang.Object</prim-key-class>
  472. -->
  473. <!ELEMENT prim-key-class (#PCDATA)>
  474. <!--
  475. The primkey-field element is used to specify the name of the primary
  476. key field for an entity with container-managed persistence.
  477. The primkey-field must be one of the fields declared in the cmp-field
  478. element, and the type of the field must be the same as the primary key
  479. type.
  480. The primkey-field element is not used if the primary key maps to
  481. multiple container-managed fields (i.e. the key is a compound key). In
  482. this case, the fields of the primary key class must be public, and
  483. their names must correspond to the field names of the entity bean class
  484. that comprise the key.
  485. Used in: entity
  486. Example:
  487. <primkey-field>EmployeeId</primkey-field>
  488. -->
  489. <!ELEMENT primkey-field (#PCDATA)>
  490. <!--
  491. The reentrant element specifies whether an entity bean is reentrant or not.
  492. The reentrant element must be one of the two following:
  493. <reentrant>True</reentrant>
  494. <reentrant>False</reentrant>
  495. Used in: entity
  496. -->
  497. <!ELEMENT reentrant (#PCDATA)>
  498. <!--
  499. The remote element contains the fully-qualified name of the enterprise
  500. bean's remote interface.
  501. Used in: ejb-ref, entity, and session
  502. Example:
  503. <remote>com.wombat.empl.EmployeeService</remote>
  504. -->
  505. <!ELEMENT remote (#PCDATA)>
  506. <!--
  507. The res-auth element specifies whether the enterprise bean code signs
  508. on programmatically to the resource manager, or whether the Container
  509. will sign on to the resource manager on behalf of the bean. In the
  510. latter case, the Container uses information that is supplied by the
  511. Deployer.
  512. The value of this element must be one of the two following:
  513. <res-auth>Application</res-auth>
  514. <res-auth>Container</res-auth>
  515. -->
  516. <!ELEMENT res-auth (#PCDATA)>
  517. <!--
  518. The res-ref-name element specifies the name of a resource manager
  519. connection factory reference.
  520. Used in: resource-ref
  521. -->
  522. <!ELEMENT res-ref-name (#PCDATA)>
  523. <!--
  524. The res-type element specifies the type of the data source. The type is
  525. specified by the Java interface (or class) expected to be implemented
  526. by the data source.
  527. Used in: resource-ref
  528. -->
  529. <!ELEMENT res-type (#PCDATA)>
  530. <!--
  531. The resource-ref element contains a declaration of enterprise bean's
  532. reference to an external resource. It consists of an optional
  533. description, the resource manager connection factory reference name,
  534. the indication of the resource manager connection factory type expected
  535. by the enterprise bean code, and the type of authentication (bean or
  536. container).
  537. Used in: entity and session
  538. Example:
  539. <resource-ref>
  540. <res-ref-name>EmployeeAppDB</res-ref-name>
  541. <res-type>javax.sql.DataSource</res-type>
  542. <res-auth>Container</res-auth>
  543. </resource-ref>
  544. -->
  545. <!ELEMENT resource-ref (description?, res-ref-name, res-type,
  546. res-auth)>
  547. <!--
  548. The role-link element is used to link a security role reference to a
  549. defined security role. The role-link element must contain the name of
  550. one of the security roles defined in the security-role elements.
  551. Used in: security-role-ref
  552. -->
  553. <!ELEMENT role-link (#PCDATA)>
  554. <!--
  555. The role-name element contains the name of a security role.
  556. The name must conform to the lexical rules for an NMTOKEN.
  557. Used in: method-permission, security-role, and security-role-ref
  558. -->
  559. <!ELEMENT role-name (#PCDATA)>
  560. <!--
  561. The security-role element contains the definition of a security role.
  562. The definition consists of an optional description of the security
  563. role, and the security role name.
  564. Used in: assembly-descriptor
  565. Example:
  566. <security-role>
  567. <description>
  568. This role includes all employees who
  569. are authorized to access the employee
  570. service application.
  571. </description>
  572. <role-name>employee</role-name>
  573. </security-role>
  574. -->
  575. <!ELEMENT security-role (description?, role-name)>
  576. <!--
  577. The security-role-ref element contains the declaration of a security
  578. role reference in the enterprise bean's code. The declaration consists
  579. of an optional description, the security role name used in the code,
  580. and an optional link to a defined security role.
  581. The value of the role-name element must be the String used as the
  582. parameter to the EJBContext.isCallerInRole(String roleName) method.
  583. The value of the role-link element must be the name of one of the
  584. security roles defined in the security-role elements.
  585. Used in: entity and session
  586. -->
  587. <!ELEMENT security-role-ref (description?, role-name, role-link?)>
  588. <!--
  589. The session-type element describes whether the session bean is a
  590. stateful session, or stateless session.
  591. The session-type element must be one of the two following:
  592. <session-type>Stateful</session-type>
  593. <session-type>Stateless</session-type>
  594. -->
  595. <!ELEMENT session-type (#PCDATA)>
  596. <!--
  597. The session element declares an session bean. The declaration consists
  598. of: an optional description; optional display name; optional small icon
  599. file name; optional large icon file name; a name assigned to the
  600. enterprise bean in the deployment description; the names of the session
  601. bean's home and remote interfaces; the session bean's implementation
  602. class; the session bean's state management type; the session bean's
  603. transaction management type; an optional declaration of the bean's
  604. environment entries; an optional declaration of the bean's EJB
  605. references; an optional declaration of the security role references;
  606. and an optional declaration of the bean's resource manager connection
  607. factory references.
  608. The elements that are optional are "optional" in the sense that they
  609. are omitted when if lists represented by them are empty.
  610. Used in: enterprise-beans
  611. -->
  612. <!ELEMENT session (description?, display-name?, small-icon?,
  613. large-icon?, ejb-name, home, remote, ejb-class,
  614. session-type, transaction-type, env-entry*,
  615. ejb-ref*, security-role-ref*, resource-ref*)>
  616. <!--
  617. The small-icon element contains the name of a file containing a small
  618. (16 x 16) icon image. The file name is relative path within the ejb-jar
  619. file.
  620. The image must be either in the JPEG or GIF format, and the file name
  621. must end with the suffix ".jpg" or ".gif" respectively.
  622. The icon can be used by tools.
  623. Example:
  624. <small-icon>employee-service-icon16x16.jpg</small-icon>
  625. -->
  626. <!ELEMENT small-icon (#PCDATA)>
  627. <!--
  628. The transaction-type element specifies an enterprise bean's transaction
  629. management type.
  630. The transaction-type element must be one of the two following:
  631. <transaction-type>Bean</transaction-type>
  632. <transaction-type>Container</transaction-type>
  633. Used in: session
  634. -->
  635. <!ELEMENT transaction-type (#PCDATA)>
  636. <!--
  637. The trans-attribute element specifies how the container must manage the
  638. transaction boundaries when delegating a method invocation to an
  639. enterprise bean's business method.
  640. The value of trans-attribute must be one of the following:
  641. <trans-attribute>NotSupported</trans-attribute>
  642. <trans-attribute>Supports</trans-attribute>
  643. <trans-attribute>Required</trans-attribute>
  644. <trans-attribute>RequiresNew</trans-attribute>
  645. <trans-attribute>Mandatory</trans-attribute>
  646. <trans-attribute>Never</trans-attribute>
  647. Used in: container-transaction
  648. -->
  649. <!ELEMENT trans-attribute (#PCDATA)>
  650. <!--
  651. The ID mechanism is to allow tools that produce additional deployment
  652. information (i.e information beyond the standard EJB deployment
  653. descriptor information) to store the non-standard information in a
  654. separate file, and easily refer from these tools-specific files to the
  655. information in the standard deployment descriptor.
  656. The EJB architecture does not allow the tools to add the non-standard
  657. information into the EJB deployment descriptor.
  658. -->
  659. <!ATTLIST assembly-descriptor id ID #IMPLIED>
  660. <!ATTLIST cmp-field id ID #IMPLIED>
  661. <!ATTLIST container-transaction id ID #IMPLIED>
  662. <!ATTLIST description id ID #IMPLIED>
  663. <!ATTLIST display-name id ID #IMPLIED>
  664. <!ATTLIST ejb-class id ID #IMPLIED>
  665. <!ATTLIST ejb-client-jar id ID #IMPLIED>
  666. <!ATTLIST ejb-jar id ID #IMPLIED>
  667. <!ATTLIST ejb-link id ID #IMPLIED>
  668. <!ATTLIST ejb-name id ID #IMPLIED>
  669. <!ATTLIST ejb-ref id ID #IMPLIED>
  670. <!ATTLIST ejb-ref-name id ID #IMPLIED>
  671. <!ATTLIST ejb-ref-type id ID #IMPLIED>
  672. <!ATTLIST enterprise-beans id ID #IMPLIED>
  673. <!ATTLIST entity id ID #IMPLIED>
  674. <!ATTLIST env-entry id ID #IMPLIED>
  675. <!ATTLIST env-entry-name id ID #IMPLIED>
  676. <!ATTLIST env-entry-type id ID #IMPLIED>
  677. <!ATTLIST env-entry-value id ID #IMPLIED>
  678. <!ATTLIST field-name id ID #IMPLIED>
  679. <!ATTLIST home id ID #IMPLIED>
  680. <!ATTLIST large-icon id ID #IMPLIED>
  681. <!ATTLIST method id ID #IMPLIED>
  682. <!ATTLIST method-intf id ID #IMPLIED>
  683. <!ATTLIST method-name id ID #IMPLIED>
  684. <!ATTLIST method-param id ID #IMPLIED>
  685. <!ATTLIST method-params id ID #IMPLIED>
  686. <!ATTLIST method-permission id ID #IMPLIED>
  687. <!ATTLIST persistence-type id ID #IMPLIED>
  688. <!ATTLIST prim-key-class id ID #IMPLIED>
  689. <!ATTLIST primkey-field id ID #IMPLIED>
  690. <!ATTLIST reentrant id ID #IMPLIED>
  691. <!ATTLIST remote id ID #IMPLIED>
  692. <!ATTLIST res-auth id ID #IMPLIED>
  693. <!ATTLIST res-ref-name id ID #IMPLIED>
  694. <!ATTLIST res-type id ID #IMPLIED>
  695. <!ATTLIST resource-ref id ID #IMPLIED>
  696. <!ATTLIST role-link id ID #IMPLIED>
  697. <!ATTLIST role-name id ID #IMPLIED>
  698. <!ATTLIST security-role id ID #IMPLIED>
  699. <!ATTLIST security-role-ref id ID #IMPLIED>
  700. <!ATTLIST session-type id ID #IMPLIED>
  701. <!ATTLIST session id ID #IMPLIED>
  702. <!ATTLIST small-icon id ID #IMPLIED>
  703. <!ATTLIST transaction-type id ID #IMPLIED>
  704. <!ATTLIST trans-attribute id ID #IMPLIED>