Monday 25 January 2016

Basics of ABAP Webdynpro: Getting familiar with Webdynpro jargons part 2


Component usage: To use the functionality of other WD component (say WDC1) in our component (say WDC2), we have to do the component usage of WDC1 in WDC2 at component level. While implementing ALV, We make use of a standard component salv_wd_table in our component.

Controller: Below are the available controllers in WD component.

                Component Controller: This controller is at the component level and can be assumed like a global controller. We can defile context node, attributes, methods here and those will be accessible throughout the component in any view or in any method.
                View Controller: Each view comes with a view controller and like component controller, we can define context node, attributes, and methods here also, but their visibility and accessibility will remain till this view only. Apart from it we can define inbound/outbound plug also in view controller.
                Window controller: Every window will have a window controller. Window controller is also a global controller.
             Interface controller: A WD component will by default have Interface controller. Any context node, event and method whose interface property is checked, will be visible in interface controller. When we use such component in any other component (though component usage), we will be able to use those nodes, events and methods. Any view which is bind to a window will automatically be available to interface controller.
                 Custom controller: This controller can be created additionally in any WD component and will have the same effect as component controller.

MVC architecture: Like any other current UI technologies, ABAP WD is also based on Model View Controller architecture.

Model: This part is solely responsible for fetching the data. How this data is going to be displayed on browser is none of its business. In WD ABAP we have provisions of giving assistance class at component level, which can have all the methods for fetching the data. For that matter, even any normal class can play the role of model.
View: View is meant for displaying the data on browser. What data will be displayed, it will get from Model. We design view in WD component and while doing so, our only aim is to give the best possible user interface experience to customer. All screens designing stuff is entirely segregated from data fetching.
Controller: Controller comes in between model and view and binds these 2 components together. Also all the intermediate processing is done here.

To be Continued...

Happy Learning :)


No comments:

Post a Comment