Server User Manual

Table Of Contents
118 Developing Applications for J2EE Servers
Sample build scenarios
To select file types to be copied over to the projects output path and the module
directory,
1 Choose Project|Project Properties.
2 Select the Build|Resource page and select the custom file type.
3 Select the Copy option.
4 Choose OK.
Note You will need to refresh and make the project after this step before you rebuild the
module. You will have to add an include filter for this file type for all other modules
(**/*.<file type>) on the Content page of the Properties dialog box for the module.
Sample build scenarios
Here are a few common build scenarios to help you understand how to work with build
properties:
EJB JAR without any bean classes
This sample EJB JAR includes only stubs/skeletons and descriptors. The server used
is WebLogic Server. Follow these steps:
1 Right-click the EJB module in the project pane and choose Properties.
2 Select the Build|WebLogic page and uncheck the Remove Project Output Path
From Classpath option.
3 Select the Content page.
4 Remove the Java Class file type filter.
5 Choose OK.
EJB JAR with custom files
This sample adds .dat files to the EJB JAR. Please ensure that you create a .dat file in
the projects source path for this test.
1 Choose Tools|Preferences.
2 Select the Browser|File Types page.
3 Select Generic Resource File in the Recognized File Types list box.
4 Click the Add button to display the Add Custom Extension dialog box.
5 Enter dat and choose OK.
6 Choose Project|Project Properties and select the Build|Resource page.
7 Select dat from the list of extensions and click the Copy button.
8 Choose OK.
9 Right-click the EJB module and select Properties.
10 Select the Content page and click the Add Filters button to display the Add Filters
dialog box.
11 Select from one of these methods of specifying a filter:
Select the Include option and specify **/*.dat in the Expression field.
Click the File Types tab, select Generic Resource File, and choose OK.
12 Choose OK.