File tree Expand file tree Collapse file tree 1 file changed +32
-3
lines changed Expand file tree Collapse file tree 1 file changed +32
-3
lines changed Original file line number Diff line number Diff line change @@ -12,15 +12,44 @@ NO WARRANTIES, [MIT License](https://github.com/abapPM/ABAP-Error/blob/main/LICE
12
12
13
13
## Usage
14
14
15
- ...
15
+ Raise exception with free form text:
16
+
17
+ ``` abap
18
+ zcx_error=>raise( 'Not found' ).
19
+ ```
20
+
21
+ Raise exception with reference to another exception:
22
+
23
+ ``` abap
24
+ TRY.
25
+ "... some code that raises an exception
26
+ CATCH cx_root INTO DATA(error).
27
+ zcx_error=>raise_with_text( error ).
28
+ " or
29
+ zcx_error=>raise(
30
+ text = 'Overwrite error text'
31
+ previous = error ).
32
+ ENDTRY.
33
+ ```
34
+
35
+ Raise exception with T100 system message:
36
+
37
+ ``` abap
38
+ MESSAGE e001(00) WITH 'error value' 'more text' INTO zcx_error=>null. " or any other message
39
+ zcx_error=>raise_t100( ).
40
+ ```
16
41
17
42
## Prerequisites
18
43
19
- SAP Basis 7.40 or higher
44
+ SAP Basis 7.50 or higher
20
45
21
46
## Installation
22
47
23
- Import ABAP Error to your project using [ apm] ( https://abappm.com ) .
48
+ Install the ` error ` module in your system using [ apm] ( https://abappm.com ) .
49
+
50
+ ## Import
51
+
52
+ Specify the ` error ` module as a dependency in your project and import it to your namespace using [ apm] ( https://abappm.com ) .
24
53
25
54
``` abap
26
55
IMPORT '*' TO 'z$1_your_project$2' FROM 'error'.
You can’t perform that action at this time.
0 commit comments