Saturday, August 24, 2013

SAP ABAP Webdynpro Component Architecture MVC Windows

Welcome to SAP ABAP Interview Questions. SAP ABAP Webdynpro Component Architecture,Windows and Nested Views, MVC Architecture

window in ABAP Webdynpro defines which views are displayed in which combination and how the view combination may be changed by firing outbound plugs.


SAP ABAP Webdynpro MVC Windows Component Architecture



Read previous article on ABAP Webdynpro Architecture, before going to read this one 

Windows and Nested Views in SAP ABAP Web dynpro

A window defines which views are displayed in which combination and how the view combination may be changed by firing outbound plugs. 

SAP ABAP Webdynpro Windows and Nested Views

Windows-and-Nested-Views


Thus, when creating a window, you define three things:

All the possible views that could exist in the component‘s visual interface must be embedded in the window.

• If multiple views must be displayed in parallel, the layout and position of these views is defined by a special view containing View Container UI elements in its layout. 

This container view is embedded in the window and, inside each area defined by a View Container UI element, all possible views for this view area are embedded (nested embedding). 

For each View Container UI element, there is one default view displayed at start up.

• The navigation links between the different views must be defined. Only one view can be displayed in the view area at a time. 

Navigation links must be defined between views in order for the contents of a view area to be replaced. 

View areas can be blanked out by creating an empty view whose inbound plug responds to an appropriate navigation event.


View Assembly

View-Assembly


Outbound plugs are the triggers that cause a view area to contain a particular view. For a given window definitions in which multiple views are embedded into view areas, there could be many permutations of views visible. 

The permutation that is visible depends on which navigation links the user follows. The subset of views visible at any time is known as a view assembly.


Web Dynpro Architecture: Relation between Web Dynpro Entities

Model View Controller (MVC) in Webdynpro ABAP


SAP's WebDynpro is built on the foundation of the Model View Controller (MVC) design paradigm. MVC was originally invented by the Norwegian software designer Trygve Reenskaug while working at Xerox PARC in the late 1970s.



Model-View-Controller -MVC


The first implementation of this design paradigm was with the release of the Smalltalk-80 programming language. MVC was a revolutionary design paradigm because it was the first to describe software components in terms of:

• The functional responsibilities each should fulfill

• The message protocols to which each component should respond

SAP has modified and extended the original MVC specification to create the Web Dynpro toolset.

Web Dynpro Component Architecture


Internally Visible Web Dynpro Entities


Internally-Visible-Web-Dynpro-Entities


The architecture of a Web Dynpro component can be divided into two parts: external and internal visibility.

The horizontal dashed line in the above figure separates the entities that are visible from outside the component from those that are only visible from within the component.

The internally visible parts can further be divided into visual entities and programming entities. Visual entities are those related to the UI, generated by the Web Dynpro framework, and passed to the client. The internally visible entities consist of windows and views.

A view consists of a view layout and the corresponding view controller. The view controller can contain navigation plugs, methods, and a context. A window embeds one or more views and has a corresponding window controller.


A window controller can contain navigation plugs, methods, and a context. Each view can be embedded in multiple windows.

The outbound plug of a window can be connected to any inbound plug of embedded views, and the outbound plug of a view can be connected to any inbound plug of the embedding window. However, navigation between windows of the same component is not possible.


Internally Visible Web Dynpro Entities (2)


Internally-Visible-Web-Dynpro-Entities

The component controller acts as a component wide controller. Program logic related to only a certain view (for example, checking user input) should be coded in the related view controller. Usage declarations between the controllers allow you to access the context data and methods of the declared controller (used controller). 

A view controller cannot be declared as a used controller for other controllers, since this would violate good programming (MVC programmingparadigm). Business logic should not be part of the Web Dynpro component, but should be defined outside of the component to have high reusability. It is preferable that ABAP classes be used to encapsulate the related source code.


Internally Visible Web Dynpro entities (3)

WebDynpro-entities



Custom controllers are optional controllers that must be defined by the developer. These controllers can be used to modularize the component content. 

For example, custom controllers can act as local controllers for some views, or they can be used to encapsulate the logic related to a certain model class (business logic). This allows you to reduce the content of the component controller by populating sub-functions.



Externally Visible Web Dynpro Entities



Externally-Visible-WebDynpro-Entities


If one Web Dynpro component (parent component) needs access to another Web Dynpro component ( child component ) the parent component can declare the use of the child component. A specific component usage instance is then created and the parent component accesses the functionality of the child component via its component interface controller.

The only parts of a Web Dynpro component that are visible to the user, are the interface controller and the interface view(s).

• All WebDynpro components have only one interface controller. Via the interface controller, data, methods, and event handlers can be exposed to other components.

• Interface views represent the visual interface of a Web Dynpro component. There is a one-to-one relationship between a Window and an interface view. Each time a window is defined, a related interface view is automatically generated, which makes the window accessible from outside the component. 

The interface view only exposes those inbound and outbound plugs to the component user that have the interface property checked. Methods and context data of the window are not accessible via the related interface view.


• If the component has no views, there is no need to have Windows. In this case, the component will not implement an interface view. Such components having no visual interface are known as faceless components .

Web Dynpro Application


WebDynpro-Application


A Web Dynpro application is an entry point into a Web Dynpro component and is the only Web Dynpro entity that can be addressed via a URL. There is often (but not always) a one-to-one relationship between an interface view and an application. 

In the same way that the functionality in an ABAP module pool can be accessed by defining multiple transaction codes, the functionality of a single Web Dynpro component can be accessed by defining multiple applications, each addressing a different interface view and/or a different inbound plug of the interface view. In order to define a Web Dynpro application, you must specify:

• The component to be invoked; this component is then known as the root component

• Which interface view of the root component will be used; the default view(s) in this interface view define(s) the default view assembly.


• Which inbound plug will act as the entry point for the nominated interface view (this inbound plug must be of type Start up)

SAP ABAP Interview Questions and Answers

SAP ABAP Webdynpro Interview Questions

"You found the information helpful and want to say thanks? Your donation is enough to inspire us to do more. Thanks a bunch!"

0 comments:

Post a Comment

Note: Only a member of this blog may post a comment.

Categories

ABAP (1) ABAP Interview Questions (112) ABAP Open SQL Statements (1) ABAP Syntax Rules (6) ABAP WORKBENCH (2) ABAP-Interview-Questions (52) ALE IDOC (6) ALE IDOC Interview Questions (6) ale-idoc (6) ALE-IDOC-Interview-Questions (19) ALV Interview Questions (5) ALV-Interview-Questions (22) BADI (2) BAPI (1) BAPI Interview Questions (1) BAPI-Interview-Questions (14) BDC (6) BDC Interview Questions (6) BDC-Interview-Questions (9) big data (2) big data interview questions (1) Classical Reports Interview Question (3) Classical-Reports-Interview-Questions (22) Conditional Statements (1) Cross Applications (3) Cross-Applications (14) Data Dictionary (22) Data Type Questins (1) Data types (1) Data-Dictionary (48) Data-Type-Questins (6) Dialog programming (5) Dialog Programming Interview Questions (4) Dialog-Programming (30) DOMAIN Interview Questions (1) Domain-Interview-Questions (8) Function Module (2) hadoop (2) hadoop interview questions (2) hdfs (1) IDoc Tutorials (6) Interactive Report Interview Questions (4) Interactive-Reports-Interview-Questions (22) Internal Tables (1) interview questions (1) Lock Object Interview Questions (1) Lock-Objects-Interview-Questions (10) Logical Database (1) Modularization Interview Questions (4) Modularization-Interview-Questions (25) Module Pool Programming (5) Module-Pool-Programming (39) modules in sap (1) Object Oriented ABAP (19) Object Oriented ABAP Interview Questions (15) object-oriented-abap (2) Object-Oriented-ABAP-Interview-Questions (34) OOABAP (9) Reports (14) Reports Interview Questions (9) Reports-Interview-Questions (19) RFC (1) RFC Interview Questions (1) RFC-Interview-Questions (14) RICEF (1) RICEF Objects (1) SAP (4) SAP ABAP (4) SAP ABAP Interview Questions (42) SAP ABAP Introduction (46) SAP ABAP Message Types (2) SAP BADI Interview Questions (2) SAP Basics (71) SAP Books (2) SAP Certification (1) SAP CONSULTANTS (5) SAP CRM (1) SAP ENHANCEMENTS (3) SAP EXITS (2) SAP EXITS ( SAP ENHANCEMENTS ) Interview Questions (1) SAP Free Books (1) SAP HR (2) SAP Lock Object (1) sap modules (2) SAP Open SQL Statements (1) SAP R/3 Architecture (4) SAP Search help (1) SAP Smartforms (1) SAP Smartforms Interview Questions (2) SAP Tables (5) SAP Tcodes (10) SAP Views (1) SAP Webdynpro ABAP (12) SAP Work Processors (2) SAP Workflow (3) SAP-BADI-Interview-Questions (11) SAP-Enhancements (39) SAP-Exits (39) SAP-Exits-Enhancements-Interview Questions (3) SAP-HANA (1) SAP-HANA-Interview-Questions (1) SAP-Smartforms-Interview-Questions (2) SAP-Workflow (3) Scripts (3) Scripts Interview Questions (2) Scripts-Interview-Questions (32) Search Help Interview Questions (1) Search-Help-Interview-Questions (9) Smartforms (1) Table Maintenance Generator (1) Table-Maintenance-Generator (4) Tables in SAP (2) Tables Interview Questions (3) Tables-Interview-Questions (3) Type Group Interview Questions (1) Type-Group-Interview-Questions (7) Variable Declaration (1) Views Interview Questions (1) Views-Interview-Questions (5) Webdynpro (12) what is big data (1)

Protected Blog

 
This blog is not affiliated to SAP AG |SAP is trademark of SAP AG |The information collected from various sources use information with your own risk.