Hi, I provide training in SAP UI5. Also feel free to checkout my new web page https://saptechblog.com
Webdynpro ABAP

FPM Interface

UIBB:

From the FPM perspective UIBB are nothing but the interface view (ABAP Webdynpro window) of the component.

Interface for FPM:

In order for the FPM Framework to recognize the UIBB ( i.e Webdynpro window) the webdynpro component must implement the webdynpro component interface IF_FPM_UI_BUILDING_BLOCK. This interface ensures that the webdynpro application can take part in the FPM event loop.

Interface methods:

clip_image002

1.      FLUSH

2.      NEEDS_CONFIRMATION

3.      PROCESS_EVENTS

4.      AFTER_FAILED_EVENT

5.      PROCESS_BEFORE_OUTPUT

The usage of the methods of this interface is as below.

Note: This is a webdynpro component interface and can be viewed in SE80 and not SE24.

FLUSH:

This is the first method which is called as the FPM event loop is started.  In this method the UIBB, transports all the modified data to the component that the UIBB wanted to communicate. This data transfer is done automatically using the context mapping and hence we need specific implementation of this method only when we are not using the automatic mechanism.

Parameters of method FLUSH:

clip_image004

 

NEEDS_CONFIRMATION:

With this method the UIBB request that the subsequent event processing is stopped and ask for the confirmation of action by means of a dialog box. Based upon the user input in the dialog box the subsequent events is processed or terminated.

Parameters of method NEEDS_CONFIRMATION:

clip_image006

 

PROCESS_EVENT:

With this method the UIBB Completes the following tasks like:

 

1.      Check for local consistency of data like validation, missing data etc

2.      Perform actual event processing.

 

The local checks are needed to inform the user of input as soon as possible.  According to UX(User Experience) guidelines checks are to be performed continually as long as they are not performance intensive. For example if we are moving from one view(UIBB) to another using an OIF application the view which is moved away has  to be checked for consistency.

Besides consistency check the current event can be processed in this method. The attributes MV_EVENT_ID and MO_EVENT_DATA of importing parameter IO_EVENT can be used to determine the event processing. Depending upon whether the event processing is successful or not the exporting parameter EV_RETURN is set.

Parameters of method PROCESS_EVENT:

clip_image008

AFTER_FAILED_EVENT:

This method is called if the FPM event is not processed successfully. Under such conditions the UIBB must ensure that the UI reverts back to the state that was there before the user interaction occurred.

Say for example you are processing two UIBB and if the PROCESS_EVENT method of one UIBB is executed successfully and the PROCESS_EVENT of another UIBB is ended with error then the first event processing is to be reverted as well. The importing parameter IV_REVERT indicates this situation.

Parameters of method AFTER_FAILED_EVENT:

clip_image010

 

PROCESS_BEFORE_OUTPUT:

This is the last method to be called on UIBB. The data to be displayed is read from Model.

Parameters of the method PROCESS_BEFORE_OUTPUT:

clip_image012

 

Order of Execution:

Before the screen is displayed the method PROCESS_BEFORE_OUTPUT is called.

After the screen is displayed and user does some action the following method are called.

1.      FLUSH

2.      NEEDS_CONFIRMATION

3.      PROCESS_EVENT

Then again PBO method before the screen is displayed.  AFTER_FAILED_EVENT method is called after PROCESS_EVENT in case of any event fails in the PROCESS_EVENT method.

About Arun

0 Comments:

Post a Comment

Powered by Blogger.