Start of Content Area

Process documentation Developing a Web Dynpro Application (Java)  Locate the document in its SAP Library structure

Purpose

With this IT process, you carry out the individual development steps for creating a Web Dynpro application.

Use of the Process

This process is part of the following IT scenario:

IT Scenario

Scenario Variant

Developing, Configuring, and Adapting Applications

Developing Java Applications Using Web Dynpro

Prerequisites

You have modeled the Web Dynpro application – for example, arranged the project into components.

Process Flow

       1.      Implementing Model Access

Different data sources can be used to retrieve data for a Web Dynpro application. The Web Dynpro developer defines what is called a model for this purpose. The Web Dynpro model is the logical application entity that the interface displays for the existing back end. Local and external Web services, JavaBeans and function modules are reusable model objects that can be used by different Web Dynpro components. Even external data originating from a UML model can be used as a data source. It is also possible to encapsulate the processing logic in Enterprise JavaBeans (EJBs) with the following use in a Web Dynpro application (model type: Web service model). Assistants are available for a simple model definition, and the relevant classes are usually generated automatically. The SAP Enterprise Connector is available for generating Java proxies from the functions of function modules and Business APIs (BAPIs).

       2.      Define Binding

A controller contains a context, that is, the active part of an application entity such as a component, a view or a customer controller. The application has several controllers that are responsible for the data or control flow in the whole application. There are different types of controllers, and each controller type can be processed using the same tool, since all controller contexts have the same structure or hierarchy. The data transport between the model and the controller is called model binding, where the controller context keeps a reference to the back-end data. The data flow between the controller contexts is known as mapping. A data copy is passed from one context to the other.

       3.      Designing Views (for Desktop PCs and Mobile Devices)

The Web Dynpro tools provide support for interface development during the design and implementation phase. The view layout is designed in the View Editor and the necessary user interface elements are separated into different categories so that they are clearly arranged. Each element also has several properties, so the uses and appearance of the individual elements in a user interface are numerous. View designers always work with logical interface objects, although they can also access the Java source text directly, for example to generate the UI automatically and to have additional coding run at runtime. Examples of simple interface elements are labels and input fields, for example. A complex object such as a table provides nesting options, for example. Container elements are available for grouping related elements into an application. Even the interface element for integrating interactive forms can be displayed with a mouse-click in the View Editor’s work area, and from there it can be processed with the integrated Adobe Designer tool, which in turn contains the Web Dynpro-relevant form elements, such as for a value check against an SAP system (Adobe library). Special elements are similarly available for mobile applications. As Web Dynpro separates the layout data and the business data, the same Web Dynpro programming model can be used for mobile devices (Mobile Web Dynpro) as well as for conventional desktop applications.

       4.      Deploying the Application

Web Dynpro application developers benefit from the use of the NWDI: it is deployed on the Java engine, that is, the applications are installed on the SAP Web Application Server’s Java stack. The deployed applications can then run in the Component Build Service (CBS), which is a central component of the NWDI. The CBS is based on the SAP Java development component model (DC concept). The Web Dynpro Content Administrator provides functions for monitoring and administrating deployed application contents.

       5.      Testing and Debugging the Application

For testing Java Web Dynpro applications, a recording function is available for test scripts in the SAP NW Developer Studio. These are available for the application logic as well as for the user interface of the deployed applications. The test XML script file can be saved locally, as can the test results. You can subsequently process these files using an editor. It is also possible to maintain access to the complete test environment, including the Test Workbench, as an import function is available for the test scripts in the eCATT (extended Computer Aided Test Tool). To analyze Web Dynpro programs, there are also tools for debugging and comparing metadata.

       6.      Functional Application Testing

Developers can use eCATT to create and execute functional tests for their programs, although the primary aim is the automatic testing of business processes. Each test generates a detailed log file that documents the test process and its results. These functions are also available for Java Web Dynpro applications.

       7.      Defining Portal Roles and Portal Pages

For each Web Dynpro application, it is possible to integrate it easily into the SAP Enterprise Portal by using the Web Dynpro iView assistant. In the next step you can then assign the Web Dynpro iView to a portal page and to a portal role. SAP Enterprise Portal also provides a series of functions that are suitable for end users’ daily work. For example, there is portal event control, direct navigation between Web Dynpro applications or even to other portal contents as well as the WorkProtect mode.

       8.      Managing the Application Life Cycle

The SAP NW Java Development Infrastructure is used to manage and version Web Dynpro applications or parts thereof. If the different software layers are provided by a team of developers, the individual developers can use the design time perspective with the relevant infrastructural support; direct access to the DTR perspective is standard. Development configurations that contain the information for the relevant SC are provided for the use of the infrastructure (example: DTR workspace with the SC’s source files in the correct version).

Result

You now have an executable Web Dynpro application, which is integrated in the SAP Enterprise Portal. The tests were carried out and the application was included in the Design Time Repository.

 

End of Content Area