Show TOC Start of Content Area

Procedure documentation Defining Controllers  Locate the document in its SAP Library structure

Controllers are the active parts of a Web Dynpro application. The data that a controller can access is defined in the controller context. Different instances of controllers and contexts exist within a Web Dynpro application: In addition to view controllers, which control the behavior of an individual view, there are also global controllers that offer more general services for all the views of a component.

Component Controller

Each Web Dynpro component is supplied with a corresponding Component Controller per default. This controller is responsible for retrieving the data required; accordingly, it must be able to map the corresponding input and output structures of the Web Dynpro model. For the structure mapping you need to bind the context of the component controller with the created Web Dynpro model.

Custom Controller

A custom controller is a special type of controller of a Web Dynpro application, which the Web Dynpro application developer can create explicitly if required. Like all other controller types, the custom controller contains a context class, which is automatically generated when the custom controller is defined. Furthermore, the custom controller contains imported packages and methods that are then relevant to all classes in a Web Dynpro application. You can define more than one custom controller for a Web Dynpro application.

Window Controller

A window controller implements the presentation logic of its related window. The presentation logic mainly deals with handling or firing navigation events (inbound and outbound plugs, startup and exit plugs, suspend and resume plugs).

A window controller can additionally implement one or many component interface view controllers defined in local or standalone component interface definitions

View Controller

View controllers are automatically available with the creation of Web Dynpro views, and they are the active parts of the views. Via data binding the dataflow between the view itself and the other controller units is defined; graphical support is provided for the node and attribute definition for the controller part.

 

More Information

Adding Custom Controllers

Using Templates in Web Dynpro

Wrapping Services in Controllers

Implementing Components with Their Controllers and Interfaces

End of Content Area