Skip to content

ABAP Keyword Documentation →  ABAP − Reference →  Declarations →  Declaration Statements →  Classes and Interfaces →  Components in Classes and Interfaces →  Events 

EVENTS - parameters

Quick Reference

Other versions: 7.31 | 7.40 | 7.54

Syntax


... VALUE(p1) typing [OPTIONAL|{DEFAULT def1}] 
    VALUE(p2) typing [OPTIONAL|{DEFAULT def2}]
    ...

Effect

The syntax of the additions VALUE, OPTIONAL, and DEFAULT and the typing using typing corresponds to the definition of formal parameters in the interface of methods.

When an event is raised using RAISE EVENT, suitable actual parameters must be specified for all non-optional output parameters; these actual parameters are optional for all optional output parameters. Optional parameters for which no actual parameter has been specified are set to their type-dependent initial value or to the replacement parameter def1 def2 ...


Example

Declaration of an instant event with an output parameter in class CL_DEMO_OUTPUT_STREAM.

CLASS cl_demo_output_stream
  ...
  PUBLIC SECTION.
    ...
    EVENTS completed
      EXPORTING
        VALUE(ev_output) TYPE xstring .
    ...
ENDCLASS.