CL_ENH_BADI_IMPL_CONFLICTS - Utility for Finding Implementation Overlaps
ABAP Short Reference Addresses (Business Address Services)This documentation is copyright by SAP AG.
Functionality
- Check whether there are conflicts between different implementations of a single-use BAdI.
- Check whether filter conditions of implementations are contradictive.
The instances have to be initialized by one of the INIT-methods. The choice of the init method defines the scope of implementations to be checked:
- INIT_BY_IMPLEMENTATION
- Input: An enhancement implementation IM_BADI_IMPL for a BAdI Spot.
- Resulting implementation set: All BAdI implementations that implement a definition that is also implemented by an implementation contained in IM_BADI_IMPL.
- INIT_BY_BADI
- Input: A BAdI Spot, and a name of a BAdI Definition.
- Resulting implementation set: All BAdI implementations that implement the definition.
- INIT_BY_SPOT
- Input: A BAdI Spot.
- Resulting implementation set: All BAdI implementations of all enhancements that implement the spot.
The check is done by one of the following check routines:
- CHECK_IMPLEMENTATION
- Input: Name of an enhancement, name of an implementation contained in the enhancement.
- Checks performed: The implementation is compared with all other implementations that implement thesame definition. Default implementations are compared to other default implementations, non-default implementations are compared to other non-default implementations.
Checks that have already been performed by the same instance or by other instances of the class are omitted unless IM_PERFORM_DUPLICATE_CHECKS = ABAP_TRUE.
- Output: List of conflicts.
- Precondition: The instance has been initialized by INIT_BY_IMPLMENTATION.
- CHECK_IMPLEMENTATIONS
- Checks performed: All collected implementations are checked against each other. Default implementationsare compared to other default implementations, non-default implementations are compared to other non-default implementations.
Checks that have already been performed by the same instance or by other instances are omitted.
- Output: List of conflicts.
- CHECK_IMPLS_OF_BADI
- Input: Name of a BAdI Definition
- Checks performed: All collected implementations that implement the specified BAdI are compared againsteach other. Default implementations are compared to other default implementations, non-default implementations are compared to other non-default implementations.
Checks that have already been performed by the same instance or by other instances of the class are omitted.
- Output: List of conflicts.
- Precondition: The instance has been initialized by INIT_BY_SPOT or INIT_BY_BADI.
Cache Handling:
The class uses a cache for the results of all instances. The cache is cleared after all initializedinstances have executed their FREE method. There is also a method to clear the cache (CLEAR_CACHE). This method clears the cache as well as the list of "known" instances.
It is very important to keep control of the "unfreed" instances in order to avoid unwanted caching effects.
Limitations :
- The class does not check whether two BAdIs can be active at the same time due to their switches.
- Value tables are not taken into consideration.
Relationships
Example
The class contains some static methods (ANALYZE_*) that demonstrate the correct use of the instance methods.
Notes
Further information
CL_GUI_FRONTEND_SERVICES - Frontend Services General Material Data
This documentation is copyright by SAP AG.
Length: 4491 Date: 20120526 Time: 115945 triton ( 137 ms )






