Mentor SAP

You create global interfaces like you create global classes. Right-click the program name in the Object Name screen area, and choose CreateClass. The naming convention is IF_ for SAP interfaces and ZIF_ or YIF_ for user-defined interfaces.

 

 

Implementation of Global Interfaces

If you want to include a global interface in your global class, you must enter the name of the interface on the Interfaces tab page.

 

Once you have done that, all of the interface’s components automatically appear on the relevant tab pages according to the naming convention with the interface resolution operator. In the example, the global interface ZIF_00_PARTNER containing the method DISPLAY_PARTNER is incorporated. Double-click the method name to implement the method.

 

 

Import of Local Classes and Interfaces

The following procedure is an easy way to make global copies of local classes and local interfaces.

Hint: The function to copy local classes to global classes cannot be used from within OBJECT-NAVIGATOR.

 

 To Import Local Classes and Interfaces

Steps

  1. On the SAP Easy Access screen, choose ToolsABAP WorkbenchDevelopmentClass Builder or call transaction SE24.
  2. On the Class Builder: Initial Screen, choose Object typeImportLocal classes in program.
  3. In the Import from Program dialog box, enter the name of the main program and, if the local classes and interfaces were defined within include programs, select the Explode INCLUDEs
  4. Choose the Display Classes/Interfaces
  5. Enter names for the global classes and interfaces that you want to create.
  6. If applicable, remember the customer namespace.
  7. To select all the global names, choose the Select All
  8. Choose the global classes and interfaces that you want to create and choose the Import