Defining references in Java EE modules (J2EE 1.4)

Java EE application clients, Web modules, and individual enterprise beans in EJB modules can include references to other resources. Reference types include EJB references, message destination references, resource references, resource environment references, security role references, and Web service references.

The Java EE and EJB specifications provide for the means for components to define "logical" names that refer to other resources. For example, an EJB reference is a logical name that refers to the home of an enterprise bean. A Web service reference is a logical name that refers to a Web service.

You can use the various deployment descriptor editors to define references. A wizard helps you to define new references, and you can quickly remove or modify properties of existing references within the deployment descriptor editor.

To open the Add Reference wizard from a deployment descriptor editor, complete the following steps:

  1. In the Enterprise Explorer of the Java EE perspective, select the Deployment Descriptor for your project where you want to include a reference. You can define references for EJB projects, application client projects, and dynamic Web projects.

  2. Right-click the Deployment Descriptor and select

    Open With | Deployment Descriptor Editor from the pop-up menu.

  3. Click the

    References tab to go to the References page of the deployment descriptor editor.

  4. Click

    Add to open the Add Reference wizard.

    Note: For EJB projects, references are defined on a per bean basis. You must select an existing bean before you can click

    Add to define a reference.

    For more information on how to use the Add Reference wizard, see the related tasks links in this topic.

 

Related concepts

Application Client Deployment Descriptor editor

 

Related tasks

Adding EJB references (EJB 1.x)

Adding message destination references (J2EE 1.4)

Adding resource manager connection factory references (J2EE 1.x)

Adding resource environment references (J2EE 1.4)

Adding security role references (J2EE 1.4)

Adding Web service references (J2EE 1.4)

Adding message destinations