Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Regarding BADI

Former Member
0 Likes
538

Hi Experts,

1. using CL_EXITHANDLER ,we create the instance for any BADI in the standard transactio.

2.Is there any other way to generate instance for BADI in the transaction.

In the standard program SAPMV56A , i have seen using of this cl_le_badi_manager=>get_instance

and passing one badi name to this.

is cl_le_badi_manager=>get_instance and cl_exithandler=>get_instance do the same functionality.

Regards

Ramakrishna L

Hi Experts,

1. using CL_EXITHANDLER ,we create the instance for any BADI in the standard transactio.

2.Is there any other way to generate instance for BADI in the transaction.

In the standard program SAPMV56A , i have seen using of this cl_le_badi_manager=>get_instance

and passing one badi name to this.

is cl_le_badi_manager=>get_instance and cl_exithandler=>get_instance do the same functionality.

Regards

Ramakrishna L

3 REPLIES 3
Read only

Former Member
0 Likes
496

Hi,

Set a break point on that class and check whether it plays the same way as of cl_exithandler.

kindly go through the documentation if avaiable.

Regards,

Ranjith Nambiar

Read only

Former Member
0 Likes
496

Hi,

both have the same functionality. If there is a place where cl_le_badi_manager=>get_instance is called, you will find it putting break-point on cl_exithandler=>get_instance, because cl_exithandler=>get_instance is called inside cl_le_badi_manager=>get_instance .

Regards,

Adrian

Read only

Pawan_Kesari
Active Contributor
0 Likes
496

Within GET_INSTANCE method of CL_LE_BADI_MANAGER there is a call to CL_EXITHANDLER=>GET_INSTANCE so effectively they are same.

However important difference is, CL_LE_BADI_MANAGER=>GET_INSTANCE will only create one instances of BADI per transaction.

For example if you are calling CL_LE_BADI_MANAGER=>GET_INSTANCE more than once, for same BADI, in your program then this method will only create object on first call, later calls will return the same instance of BADI object (which was created in first call).

Edited by: Pawan Kesari on Jan 8, 2010 6:00 PM