Objects can indicate that their state has changed by triggering a method. You can define events in both classes and interfaces, which you can then trigger from within a method using the RAISE EVENT statement. Each class (or interface) that is going to handle the corresponding event must implement a relevant handler method, and register it using the SET HANDLER statement. When an event occurs, the system calls all of the handler methods registered for that event.
Like method definitions, events have a parameter interface. The only difference is that events may only have EXPORTING parameters.
Prerequisites
You must already have created the class or interface.
The following description assumes that you are familiar with the principles of ABAP Objects.
Procedure
Result
You have now created events for your object type. The events are listed in the declaration part of the class or interface after the EVENTS statement.
You can specify events further by giving them EXPORTING parameters. For the procedure, refer to
Creating parameters and exceptions and Implementing methods.For further information about event handling within ABAP Objects, refer to the syntax documentation in the ABAP Editor (for example, for the RAISE EVENT statement).