Monday, 30 April 2018

Step 1: Create a Fusion Web Application

When you work in JDeveloper, you organize your work in projects within an application. JDeveloper provides several template applications that you can use when creating an application and projects. The template applications are pre-configured with a basic set of technologies that are needed for developing the various types of applications. You create your working environment by selecting the template that best fits your needs and then configure it to add any additional technologies you plan to use.
In the first part of this tutorial you are going to create a new Fusion Web application and build reusable business components that will access the database. You'll be using Oracle ADF Business Components to map Java objects to existing tables in your database.
  1. Start JDeveloper by selecting Start > Programs > JDEVELOPER_HOME > OracleHome > Oracle JDeveloper Studio > Oracle JDeveloper Studio.
    If a dialog box opens asking if you would like to import preferences from a previous JDeveloper installation, click No.
  2. In the Select Role dialog, select Studio Developer (All Features) and click OK.
    This screenshot shows the role Studio Developer (All Features) in the list of available developer roles is selected by default.
    Shaping, which is based on the role of the user, allows the JDeveloper environment to tailor itself. It does this by removing unneeded items from the menus, preferences, new gallery, and even individual fields on dialogs.
    Shaping can even control the default values for fields on dialogs within the tool. When you first start JDeveloper, you are prompted to choose a role that describes how you are going to use JDeveloper. If you choose a role of "Java Developer" versus "Database Developer " versus "Customization Developer " you will get a totally different experience!
  3. If a dialog box opens asking if you would like to import preferences from a previous JDeveloper installation, click No.
    This screenshot shows the Yes and No buttons that give the option to import JDeveloper preferences from an existing installation.
  4. In the Track Usage popup, click OK.
    This screenshot shows a selected checkbox that enables automated usage tracking by default.
  5. Once loaded, the JDeveloper IDE appears. The very first time you open JDeveloper, the Start Page displays. You can re-invoke the Start Page later by choosing Help > Start Page.
    Notice the various options available to help you learn about JDeveloper. After exploring some of these options, close the Start Page by clicking the X on its tab (the X appears when you mouse over the tab).
    This screenshot displays various options to explore more about JDeveloper.
  6. Click the New Application link in the Applications window.
    This screenshot shows the Applications window with New Application selected by default and also displays the Open Application option.
  7. In the New Gallery, select ADF Fusion Web Application and click OK.
    This screenshot shows the New Gallery dialog that is divided into two panes, Categories on the left and Items on the right. The right pane displays the items for the selected category.
  8. JDeveloper loads the required features for a Fusion Web application and the Create Fusion Web Application (ADF) wizard launches. In the Name your application page of the wizard, type HRSystem as the name. If required, you can change the directory path to create your files in another location.
    In the Application Package Prefix field set the value to be demo and click Next.
    This screenshot displays the application name as specified in the previous praragraph. The directory name defaults to the application name entered and the directory path defaults to c:\JDeveloper\mywork, by default.
  9. In the Name your project page ensure that the project name is Model (the default). Notice that ADF Business Components and Java are listed as the project features of a Fusion Web application.
    Then click Next
    This screenshot displays the project name as specified in the previous praragraph. The project directory defaults to the project name within the application directory. This screen also displays the Project Features.
  10. The Configure Java settings page allows you to define a default package, a Java source path and an output directory. Click Next to accept the default values.
    This screenshot shows the default Java Settings. The source path and the output directory are created by default within the application directory.
  11. In the second Name your project page, ensure that the Project Name is ViewController. Scroll through the list of project features to see the types of technologies that can be used with a Fusion Web application.
    Click Next.
    This screenshot shows the project name as specified in the previous praragraph. The project directory defaults to the project name within the application directory. This screen also displays the Project Features.
  12. In the Configure Java settings page accept the defaults and click Finish to create your Fusion Web application and projects.
    This screenshot displays the default Java Settings. The source path and the output directory are created by default within the application directory.
  13. The HRSystem application and the two projects are displayed in the Applications window on the left of the screen. Save your work.
    Notice too, the Checklist on the right side of the screen. This checklist is displayed by default when a Fusion Web application is created. It is designed as a guide to lead you through the tasks involved in building this type of application. The next steps show you how the checklist might be used while developing an application.
    This screenshot shows the Applications window on the left and the Overview page of the selected application on the right. By default, it also shows the checklist that you need to accomplish to create a Fusion Web Application.