Name

<ejb-local-ref>

Synopsis

The <ejb-local-ref> element is often used to declare a local EJB reference used by the application.

Syntax

<ejb-local-ref>
  [<description [xml:lang="lang"]>description</description>]*
  <ejb-ref-name>ejbRefName</ejb-ref-name>
  <ejb-ref-type>Entity|Session</ejb-ref-type>
  <local-home>homeInterfaceName</local-home>
  <local>localInterfaceName</local>
  [<ejb-link>linkedEJBName</ejb-link>]
</ejb-local-ref>

The <ejb-local-ref> element serves the same purpose as the <ejb-ref> element but for local beans. It supports all the same nested elements, except that <home> is replaced by <local-home> and <remote> is replaced by <local>:

<ejb-local-ref>
  <ejb-ref-name>ejb/Payroll</ejb-ref-name>
  <ejb-ref-type>Session</ejb-ref-type>
  <local-home>com.mycomp.PayrollHome</local-home>
  <local>com.mycomp.Payroll</local>
</ejb-local-ref>

Get JavaServer Pages, 3rd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.