Ansicht
Dokumentation

ABENPCRE_CALLOUT_ABEXA - PCRE CALLOUT ABEXA

ABENPCRE_CALLOUT_ABEXA - PCRE CALLOUT ABEXA

General Material Data   SUBST_MERGE_LIST - merge external lists to one complete list with #if... logic for R3up  
This documentation is copyright by SAP AG.
SAP E-Book

- PCRE Regular Expression with Callouts

The example demonstrates how to call an ABAP method from a PCRE regular expression.

Source Code

Execute

Description

An object-oriented representation of a PCRE regular expression is created from class CL_ABAP_REGEX. The regular expression contains the special characters (?C...) for callouts. The first three callouts pass numerical data, the other two pass string data.

A local class handle_regex implements the interface IF_ABAP_MATCHER_CALLOUT and an instance of that class is set as the callout handler. When the regular expression is matched, the interface method CALLOUT is called for each callout position and can access the passed parameter.






Fill RESBD Structure from EBP Component Structure   SUBST_MERGE_LIST - merge external lists to one complete list with #if... logic for R3up  
This documentation is copyright by SAP AG.

Length: 1137 Date: 20240425 Time: 141724     sap01-206 ( 20 ms )