Getting Started: Web Application Core Concepts

This topic sets out the basic concepts of page flow design and development.

What is a Page Flow?

A page flow application is a web application with a special architecture. It contains the following elements.

JSP Files

The JSP files contain the presentation elements of a page flow applications. In other words, it contains the user interface displayed in a browser. The web application can have as many JSP pages as necessary, and each JSP page can contain all the elements of any regular JSP page. A JSP page in a page flow typically contains HTML elements and netui tags, which are custom tags provided in WebLogic Workshop.

Controller Files

The controller file contains the business logic and the navigation logic of a web application. You can have exactly one controller file for your web application, or you can have many controller files with each controller file implementing the business and navigation logic of a part of the web application. A controller file typically contains numerous Action Methods. When a user sends a request to the server, for instance by hitting a Submit button on a web page, a specific action method contains the business logic describing how to process this user request. The action method also contains the navigation logic describing what JSP page should be returned to the user next. A controller file can be read in a special graphical view called the Flow View that shows the navigational flow through the web application.

Data Binding

A user request typically contains data that the user provided by filling in fields on a JSP page. When a user submits this data, for instance his name and age, it must be properly received by the controller file such that it is unequivocally clear what data corresponds to his name and what data corresponds to his age. The process of properly tying user input entered in a field to a certain property is called data binding.

Conversely, a JSP page often needs to display data. This data is not static but might be read from a database, received earlier from a user, or computed on the basis of other dynamic data. Again, data binding must be done correctly such that a certain presentation element on a JSP page displays the correct data.

There are various methods to accomplish data binding. User input is typically handled using a form bean, which contains a set of properties corresponding to the data entered in the fields on a page. For instance, a form bean might have a String name property to store the name, an int age property to store the age, and so forth. To display data, you can use a form bean or you can add parameters to a URL, to name just two examples. In this tutorial you will make the data to be displayed an attribute of a request object, which is a special object readable by a JSP page.

Designing Page Flows with WebLogic Workshop

Page flows are developed using WebLogic Workshop, a visual tool for designing J2EE applications. The image below shows the finished tutorial.

The Application tab (area 1) shows the application's source files.

The main work area (area 2) shows several views of the page flow components you are building. In the above picture a controller (JPF) file is shown in Flow View. The Flow View shows the navigational flow of the web application.

The Property Editor (area 3) allows you to see and set properties of the page flow component opened in the main area.

A web project folder holds all the page flow components required to run a web application. In this tutorial you will develop the page flow application in a web project folder called GettingStarted_WebApp (area 4).

Related Topics

Guide to Building Page Flows

Click one of the following arrows to navigate through the tutorial: