jst j2ee
Creating a Application Client Project
WTP LogoWTP Home

This test case outlines the steps required to create a Application Client Project.

Creating a Application Client
  1. From any perspective, click File > New > Other > J2EE > Application Client Project ...

  2. Click Next.

  3. Enter 'AppClientProject' into Project Name field. Select a J2EE Runtime Library server target. Take the other default values as shown below.

  4. Click Next to go to Select Project Facets Page. You can install additional factets and bind to a runtime.

  5. Click Next to go to Settings Page. You can overwrite the default settings here.

  6. Click Finish on the New Application Client Project wizard. Your Application Client project and EAR project have now been created.

  7. After the wizard finishes, if you are not already in the J2EE perspective, you will be prompted to switch, agree by selecting 'Yes'. In the J2EE perspective, you will see the AppClientProject in the Project Explorer.

    After expanding take special notice of the component folders which have been created. Notice the contained appClientModule/META-INF which represents the App Client module. Likewise, notice the AppClientProjectEAR (and contained folders and files) which represents the EAR which contains the App Client.

  8. Next create a Test java class in the App Clients source folder 'AppClientProject/appClientModule'. Defaults are provided in the following image.

    After the class is created, perform a Project > Clean to kick off a full build.

  9. Switching now to the Resource perspective the ouput of the builder can be verified. In the Navigator you will see all resources as they exist on disk. After expanding the Java Project you will notice a '.deployables' folder. This folder represents the deployable output (J2EE spec compliant) generated via the Component Structural Builder.

    After expanding take notice of the component under the .deployables. In the App Client, take special notice of the sample/Test.class representing the output of the previously created java class. Also in the 'AppClientProjectEAR' check the application.xml to insure it contains an entry to the App Client and also open the AppClientProject.jar contained in the EAR with a zip utility to insure the contents contain the App Client's Manifest.MF, application-client.xml and the Test.class.