Show TOC Start of Content Area

Background documentation Components  Locate the document in its SAP Library structure

One of the main advantages of the original Model View Controller (MVC) design was its focus on the reusability of models, views, and controllers as individual coding units. However, Web Dynpro is focused on more than just the technical reuse of coding entities. Instead, Web Dynpro has been designed to be the foundation for implementing business solutions. Therefore, one of the key elements in its design was the need to provide a reusable unit of code that corresponded to an atomic step within a business process, rather than trying to build business solutions from reusable units of low level code that, in themselves, were not directly related to the business process.

In other words, the Web Dynpro component is a reusable unit of code at the business process level, rather than the technical coding level.

The resulting change in the nature of code reuse produces a shift in the developer’s focus of attention during coding. No longer are they concerned so much with the reuse of technical coding units; instead, the design of a Web Dynpro component focuses on the reuse of atomic units of business processing.

A component can be thought of as a set of controllers, views, and model usage declarations that have been aggregated for the specific purpose of reuse.

Always think of the Web Dynpro component as both:

      unit of development

      unit of reuse

A component is therefore the minimum unit of coding required when developing an executable Web Dynpro application.

As can be seen in the figure below, a Web Dynpro component is not a single coding entity; rather, it is an aggregation of various controllers, views, windows, and model usages which, when taken together, form the reusable unit of business processing known as a component.

More information: Constituent Parts of a Component

This graphic is explained in the accompanying text

There are several key features that must be clearly understood concerning the structure of a Web Dynpro component:

      It contains coding entities that are hidden from the outside world and only internally visible. In the figure above, these coding entities are placed in the lower part of the diagram.

      The component also contains coding entities that are visible to the outside world. In the figure above, these coding entities are placed in the upper part of the diagram.

      It contains coding entities that handle the visual representation of data, and coding entities that handle the processing of data. These two types of coding entity are divided from each other by the vertical dotted line down the middle of the figure above.

      Within the scope of a component, the various controllers are designed as independent, yet interrelated programs. Therefore, if one controller wishes to gain access to the data and functionality within another controller (in the same component), a usage declaration must first be made: hence the Usage Declaration arrows between the various controllers in the figure above.

      Model objects are defined outside the scope of any particular Web Dynpro component. Once a model object has been created, any component can access its functionality by means of a usage declaration.

      Web Dynpro components can use the data and functionality found within other Web Dynpro components. In order to achieve this, a usage declaration must be made in order to establish a parent child relationship between the two components.

More Information

      Faceless Component  

      Lifespan of a Component   

      Creating Components   

End of Content Area