How Do I: Import an Enterprise JavaBean?

If you have developed Enterprise JavaBeans in another development environment and plan to continue development of these EJBs in WebLogic Workshop, you can import the beans into an EJB project. In order to do so you must have the EJB JAR and the source code of the EJBs. To find out how to create an EJB project, see How Do I Create an EJB Project?

Note. If you have developed EJBs in another development environment and plan to reuse these EJBs in a WebLogic Workshop application, but are not planning to continue development on these beans, you only have to add the EJB JAR to the application. For more information, see How Do I: Add an Existing Enterprise JavaBean to an Application?

To Import EJBs

  1. Right-click the EJB project folder in the Application pane, and choose Import EJB from jar. The Import Wizard appears.
  2. Browse to and select the EJB JAR containing the bean(s) you want to import in the top field.
  3. Browse to and select the folder that contains the source code of the bean(s) starting from the package name. For example, if the source code of a Customer bean is located in MyFolder/com/shop/customers, where com.shop.customers is the package name, you should select MyFolder. Click Next.
  4. The wizard displays all the beans that were found and can be imported. Include the beans that you want to import (all are included by default). Click Finish.
  5. An Import Progress window appears. When the import is complete, click OK.

Related Topics

How Do I: Test an Enterprise JavaBean?

How Do I: Use an Enterprise JavaBean in a Web Application?