In the New Gallery, expand General, select Deployment Profiles and then JAR In the Edit JAR Deployment Profile Properties dialog, select JAR Options. Expand Files Groups Project Output Filters. In the Files tab, select the customization classes you want

8-10 Java EE Developers Guide for Oracle Application Development Framework Before you begin: Make sure that your project has customization classes. You do not need to perform this procedure if the application does not have customization classes. For more information about customization classes, see the How to Create Customization Classes section of the Oracle Fusion Middleware Fusion Developers Guide for Oracle Application Development Framework. To add customization classes into a JAR: 1. In the Application Navigator, right-click the data model project that contains the customization classes you want to create a JAR for, and choose New.

2. In the New Gallery, expand General, select Deployment Profiles and then JAR

File , and click OK. Alternatively, if you want to create a shared library, select Shared Library JAR File from the list of profile types, and click OK. 3. In the Create Deployment Profile -- JAR File dialog, enter a name for the project deployment profile for example, CCArchive and click OK.

4. In the Edit JAR Deployment Profile Properties dialog, select JAR Options.

5. Enter the location for the JAR file.

6. Expand Files Groups Project Output Filters.

7. In the Files tab, select the customization classes you want to add to the JAR file. If

you are using a customization.properties file, it needs to be in the same class loader as the JAR file. You can select the customization.properties file to package it along with the customization classes in the same JAR.

8. Click OK to exit the Edit JAR Deployment Profile Properties dialog.

9. Click OK again to exit the Project Properties dialog.

10. In the Application Navigator, right-click the project containing the JAR deployment profile, and choose Deploy deployment profile to JAR file.

8.3.2.2 Creating a WAR Deployment Profile

You will need to create a WAR deployment profile for each web-based project you want to package into the application. Typically, the WAR profile will include the dependent model projects it requires. To create WAR deployment profiles for an application: 1. In the Application Navigator, right-click the web project that you want to deploy and choose New. You will create a WAR profile for each web project. Note: If you don’t see Deployment Profiles in the Categories tree, click the All Technologies tab. Note: If this is the first time you deploy to a JAR from this deployment profile, you choose Deploy deployment profile and select Deploy to JAR in the wizard. Deploying an ADF Java EE Application 8-11

2. In the New Gallery, expand General, select Deployment Profiles and then WAR

File , and click OK. If you don’t see Deployment Profiles in the Categories tree, click the All Technologies tab. 3. In the Create Deployment Profile -- WAR File dialog, enter a name for the project deployment profile and click OK. 4. In the Edit WAR Deployment Profile Properties dialog, choose items in the left pane to open dialog pages in the right pane. Configure the profile by setting property values in the pages of the dialog. ■ If you have customization classes in your application, they must be loaded from the EAR-level application class loader and not from the WAR. You will later add these customization classes to the EAR. By default, customization classes are added to the model projects WAR class path. So for each WAR, you must exclude the customization classes. If you created your customization classes in an extension project of the application, be sure to deselect any customization class archive on the Library Dependencies page of the WAR deployment profile for each view controller project. If you created your customization classes in the model project of the application, deselect any customization classes on the File Groups WEB-INFclasses Filters page of the WAR deployment profile for each view controller project. If you are using a customization.properties file, it should also be deselected. ■ You might also want to change the Java EE web context root setting choose General in the left pane. By default, when Use Project’s Java EE Web Context Root is selected, the associated value is set to the project name, for example, Application1-Project1-context-root . You need to change this if you want users to use a different name to access the application. If you are using custom JAAS LoginModule for authentication with JAZN, the context root name also defines the application name that is used to look up the JAAS LoginModule.

5. Click OK to exit the Edit WAR Deployment Profile Properties dialog.