Skip to content

Commit 270edb9

Browse files
committed
Update
1 parent 0b2e7aa commit 270edb9

File tree

56 files changed

+10942
-2366
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

56 files changed

+10942
-2366
lines changed
Lines changed: 5 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,13 @@
1-
***********************************************************************
2-
*
3-
* RAP BO provider (i. e. ABAP behavior pool/ABP)
4-
* for a RAP demo scenario
5-
*
6-
* See more information in the CCIMP include (local types tab in ADT).
7-
*
8-
**********************************************************************
9-
"! <p class="shorttext synchronized">Behavior implementation for RAP demo scenario (draft BO)</p>
10-
"! The class represents a RAP BO provider (i. e. an ABAP behavior pool/ABP) for a RAP demo scenario
11-
"! (managed, draft-enabled RAP BO with late numbering).
1+
"! <p class="shorttext"><strong>RAP BO provider for a RAP demo scenario</strong><br/>ABAP cheat sheet example class </p>
2+
"!
3+
"! <p>The class represents a RAP BO provider (i. e. an ABAP behavior pool/ABP) for a RAP demo scenario:<br/>
4+
"! Managed, draft-enabled RAP BO with late numbering.</p>
125
CLASS zbp_demo_abap_rap_draft_m DEFINITION PUBLIC ABSTRACT FINAL FOR BEHAVIOR OF zdemo_abap_rap_draft_m.
136
PROTECTED SECTION.
147
PRIVATE SECTION.
158
ENDCLASS.
169

1710

1811

19-
CLASS ZBP_DEMO_ABAP_RAP_DRAFT_M IMPLEMENTATION.
12+
CLASS zbp_demo_abap_rap_draft_m IMPLEMENTATION.
2013
ENDCLASS.
Lines changed: 5 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,13 @@
1-
***********************************************************************
2-
*
3-
* RAP BO provider (i. e. ABAP behavior pool/ABP)
4-
* for a RAP demo scenario
5-
*
6-
* See more information in the CCIMP include (local types tab in ADT).
7-
*
8-
**********************************************************************
9-
"! <p class="shorttext synchronized">Behavior implementation for RAP demo scenario (managed BO)</p>
10-
"! The class represents a RAP BO provider (i. e. an ABAP behavior pool/ABP) for a RAP demo scenario
11-
"! (managed RAP BO with external numbering).
1+
"! <p class="shorttext"><strong>RAP BO provider for a RAP demo scenario</strong><br/>ABAP cheat sheet example class </p>
2+
"!
3+
"! <p>The class represents a RAP BO provider (i. e. an ABAP behavior pool/ABP) for a RAP demo scenario:<br/>
4+
"! Managed RAP BO with external numbering.</p>
125
CLASS zbp_demo_abap_rap_ro_m DEFINITION PUBLIC ABSTRACT FINAL FOR BEHAVIOR OF zdemo_abap_rap_ro_m.
136
PROTECTED SECTION.
147
PRIVATE SECTION.
158
ENDCLASS.
169

1710

1811

19-
CLASS ZBP_DEMO_ABAP_RAP_RO_M IMPLEMENTATION.
12+
CLASS zbp_demo_abap_rap_ro_m IMPLEMENTATION.
2013
ENDCLASS.

src/zbp_demo_abap_rap_ro_m_as.clas.abap

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
"! <p class="shorttext"><strong>RAP BO provider for a RAP demo scenario</strong><br/>ABAP cheat sheet example class </p>
2+
"!
3+
"! <p>The class represents a RAP BO provider (i. e. an ABAP behavior pool/ABP) for a RAP demo scenario:<br/>
4+
"! Managed RAP BO with managed internal numbering and additional save, demonstrating the local consumption
5+
"! of RAP business events.</p>
16
CLASS zbp_demo_abap_rap_ro_m_as DEFINITION PUBLIC ABSTRACT FINAL FOR BEHAVIOR OF zdemo_abap_rap_ro_m_as.
27
PUBLIC SECTION.
38
CLASS-DATA num_raised_events TYPE i.

src/zbp_demo_abap_rap_ro_u.clas.abap

Lines changed: 4 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,7 @@
1-
***********************************************************************
2-
*
3-
* RAP BO provider (i. e. ABAP behavior pool/ABP)
4-
* for a RAP demo scenario
5-
*
6-
* See more information in the CCIMP include (local types tab in ADT).
7-
*
8-
**********************************************************************
9-
"! <p class="shorttext synchronized">Behavior implementation for RAP demo scenario (unmanaged BO)</p>
10-
"! The class represents a RAP BO provider (i. e. an ABAP behavior pool/ABP) for a RAP demo scenario
11-
"! (unmanaged RAP BO with external numbering).
1+
"! <p class="shorttext"><strong>RAP BO provider for a RAP demo scenario</strong><br/>ABAP cheat sheet example class </p>
2+
"!
3+
"! <p>The class represents a RAP BO provider (i. e. an ABAP behavior pool/ABP) for a RAP demo scenario:<br/>
4+
"! Unmanaged RAP BO with external numbering.</p>
125
CLASS zbp_demo_abap_rap_ro_u DEFINITION PUBLIC ABSTRACT FINAL FOR BEHAVIOR OF zdemo_abap_rap_ro_u.
136
PROTECTED SECTION.
147
PRIVATE SECTION.

src/zbp_demo_abap_rap_ro_u.clas.locals_imp.abap

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1028,4 +1028,4 @@ CLASS lhc_child IMPLEMENTATION.
10281028

10291029
ENDMETHOD.
10301030

1031-
ENDCLASS.
1031+
ENDCLASS.

src/zcl_demo_abap_amdp.clas.abap

Lines changed: 16 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -1,52 +1,19 @@
1-
***********************************************************************
2-
*
3-
* ABAP cheat sheet: AMDP
4-
*
5-
* -------------------------- PURPOSE ----------------------------------
6-
* - Example to demonstrate AMDP procedures and functions. It includes
7-
* a CDS table function.
8-
* - NOTE:
9-
* - The example covers basics regarding AMDP method declarations
10-
* and implementations.
11-
* - The purpose is to give you a rough idea about AMDP. Therefore,
12-
* the SQLScript code used in the method implementations is
13-
* fairly simple. AMDP is not needed in simple cases like these.
14-
* - The example is primarily intended for ABAP Cloud.
15-
* For example, in ABAP Cloud only read-only operations are possible.
16-
* In general, there are more syntax options available in classic
17-
* ABAP. Check the ABAP Keyword Documentation for more details and
18-
* examples.
19-
*
20-
* ----------------------- GETTING STARTED -----------------------------
21-
* - Open the class with the ABAP development tools for Eclipse (ADT).
22-
* - Choose F9 to run the class.
23-
* - Check the console output.
24-
* - To understand the context and the ABAP syntax used, check the notes
25-
* included in the class as comments or refer to the respective topic
26-
* in the ABAP Keyword Documentation.
27-
* - Due to the amount of output in the console, the examples include
28-
* numbers (e. g. 1) ..., 2) ..., 3) ...) for the individual example
29-
* sections. Plus, the variable name is displayed in most cases. Hence,
30-
* to easier and faster find the relevant output in the console, just
31-
* search in the console for the number/variable name (CTRL+F in the
32-
* console) or use the debugger.
33-
*
34-
* ----------------------------- NOTE -----------------------------------
35-
* The code presented in this class is intended only to support the ABAP
36-
* cheat sheets. It is not intended for direct use in a production system
37-
* environment. The code examples in the ABAP cheat sheets are primarily
38-
* intended to provide a better explanation and visualization of the
39-
* syntax and semantics of ABAP statements, not to solve concrete
40-
* programming tasks. For production application programs, you should
41-
* always work out your own solution for each individual case. There is
42-
* no guarantee for the correctness or completeness of the code.
43-
* Furthermore, there is no legal responsibility or liability for any
44-
* errors or their consequences that may occur when using the the example
45-
* code.
46-
*
47-
***********************************************************************
48-
"! <p class="shorttext synchronized">ABAP cheat sheet: AMDP</p>
49-
"! Example to demonstrate AMDP procedures and functions.<br>Choose F9 in ADT to run the class.
1+
"! <p class="shorttext"><strong>AMDP</strong><br/>ABAP cheat sheet example class</p>
2+
"!
3+
"! <p>The example class demonstrates AMDP procedures and functions.<br/>
4+
"! Choose F9 in ADT to run the class.</p>
5+
"!
6+
"! <h2>Note</h2>
7+
"! <ul>
8+
"! <li>The example covers the basics of AMDP method declarations and implementations.</li>
9+
"! <li>The goal is to provide a general overview of AMDP, so the SQLScript code used in these
10+
"! methods is quite simple. AMDP is usually not necessary for such simple cases.</li>
11+
"! <li>This example is mainly intended for ABAP Cloud, where only read-only operations are
12+
"! possible. In classic ABAP, there are more syntax options available. Refer to the ABAP
13+
"! Keyword Documentation for more details and examples.</li>
14+
"! <li>The example includes a CDS table function.</li>
15+
"! <li>Find information on <strong>getting started with the example class</strong> and the
16+
"! <strong>disclaimer</strong> in the ABAP Doc comment of class {@link zcl_demo_abap_aux}.</li></ul>
5017
CLASS zcl_demo_abap_amdp DEFINITION
5118
PUBLIC
5219
FINAL

src/zcl_demo_abap_aux.clas.abap

Lines changed: 30 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,25 +1,32 @@
1-
***********************************************************************
2-
*
3-
* Class for ABAP cheat sheet examples designed to clear and populate
4-
* demo database tables
5-
*
6-
* -------------------------- NOTE -------------------------------------
7-
* The code presented in this class is only meant for supporting the ABAP
8-
* cheat sheets. It is not intended for direct use in a
9-
* production system environment. The code examples in the ABAP cheat
10-
* sheets are primarily intended to provide a better explanation and
11-
* visualization of the syntax and semantics of ABAP statements and not to
12-
* solve concrete programming tasks. For production application programs,
13-
* a dedicated solution should therefore always be worked out for each
14-
* individual case. There is no guarantee for either the correctness or
15-
* the completeness of the code. In addition, there is no legal
16-
* responsibility or liability for possible errors or their consequences
17-
* which occur through the use of the example code.
18-
*
19-
***********************************************************************
20-
"! <p class="shorttext synchronized">Class supporting ABAP cheat sheet examples</p>
21-
"! The class supports the ABAP cheat examples by clearing and populating demo database tables that are used there.
22-
"! The demo database tables contain airline and flight information.
1+
"! <p class="shorttext">ABAP cheat sheet example class: ABAP cheat sheet auxiliary class</p>
2+
"!
3+
"! <p>The class supports the ABAP cheat examples by clearing and populating demo database tables that are used there.
4+
"! The demo database tables contain airline and flight information.</p>
5+
"!
6+
"! <h2>Getting started with ABAP cheat sheet example classes</h2>
7+
"! <ol><li>Open the class using ABAP development tools for Eclipse (ADT).</li>
8+
"! <li>Choose F9 to run the class.</li>
9+
"! <li>Check the console output.</li>
10+
"! <li>To understand the context and ABAP syntax used, refer to the notes in the
11+
"! class comments or the relevant topic in the ABAP Keyword Documentation.</li>
12+
"! <li>The console output contains numbered sections (e.g., 1) ... , 2) ..., 3) ...)
13+
"! for each example. Most of the time, the variable name is diplayed. To quickly find
14+
"! the output, use CTRL+F to search for the specific number or variable name in the
15+
"! console. Alternatively, debug the class using the debugger to check the data
16+
"! objects' content and values.</li></ol>
17+
"!
18+
"! <h2>Disclaimer</h2>
19+
"! <p>The code presented in this class is only meant for supporting the ABAP
20+
"! cheat sheets. It is not intended for direct use in a
21+
"! production system environment. The code examples in the ABAP cheat
22+
"! sheets are primarily intended to provide a better explanation and
23+
"! visualization of the syntax and semantics of ABAP statements and not to
24+
"! solve concrete programming tasks. For production application programs,
25+
"! a dedicated solution should therefore always be worked out for each
26+
"! individual case. There is no guarantee for either the correctness or
27+
"! the completeness of the code. In addition, there is no legal
28+
"! responsibility or liability for possible errors or their consequences
29+
"! which occur through the use of the example code.</p>
2330
CLASS zcl_demo_abap_aux DEFINITION
2431
PUBLIC
2532
FINAL
@@ -30,6 +37,7 @@ CLASS zcl_demo_abap_aux DEFINITION
3037
fill_dbtabs,
3138
heading IMPORTING text TYPE string
3239
RETURNING VALUE(output) TYPE string.
40+
CONSTANTS no_output TYPE string VALUE `No output for this section. You can set breakpoints and check the content of data objects (if available) in the debugger.`.
3341

3442
PROTECTED SECTION.
3543
PRIVATE SECTION.
@@ -39,7 +47,6 @@ ENDCLASS.
3947

4048
CLASS zcl_demo_abap_aux IMPLEMENTATION.
4149

42-
4350
METHOD clear_dbtabs.
4451
DELETE FROM zdemo_abap_flsch.
4552
DELETE FROM zdemo_abap_carr.

src/zcl_demo_abap_aux.clas.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<VSEOCLASS>
66
<CLSNAME>ZCL_DEMO_ABAP_AUX</CLSNAME>
77
<LANGU>E</LANGU>
8-
<DESCRIPT>Class supporting ABAP cheat sheet examples</DESCRIPT>
8+
<DESCRIPT>ABAP cheat sheet example class: ABAP cheat sheet auxiliary c</DESCRIPT>
99
<STATE>1</STATE>
1010
<CLSCCINCL>X</CLSCCINCL>
1111
<FIXPT>X</FIXPT>

src/zcl_demo_abap_cds_ve.clas.abap

Lines changed: 19 additions & 49 deletions
Original file line numberDiff line numberDiff line change
@@ -1,48 +1,18 @@
1-
***********************************************************************
2-
*
3-
* ABAP cheat sheet: CDS View Entities
4-
*
5-
* -------------------------- PURPOSE ----------------------------------
6-
* - Example to demonstrate CDS view entities. See the CDS view entities
7-
* that are used in the example for more details.
8-
* - Topics covered: Operands, expressions, and built-in functions in the
9-
* element list of CDS view entities, input parameters, joins,
10-
* associations
11-
* - Note: In ADT, check out the CDS view entities used in this example
12-
* by holding down CTRL and clicking on the CDS view entity. This will
13-
* take you to the artifact. There you can choose F8 to open the data
14-
* preview.
15-
16-
* ----------------------- GETTING STARTED -----------------------------
17-
* - Open the class with the ABAP development tools for Eclipse (ADT).
18-
* - Choose F9 to run the class.
19-
* - Check the console output.
20-
* - To understand the context and the ABAP syntax used, refer to the
21-
* notes included in the class as comments or refer to the respective
22-
* topic in the ABAP Keyword Documentation.
23-
* - Due to the amount of console output, the examples contain numbers
24-
* (e.g. 1) ..., 2) ..., 3) ...) for the individual example sections.
25-
* Also, the variable name is displayed in most cases. So to find
26-
* the relevant output in the console easier and faster, just search
27-
* for the number/variable name in the console (CTRL+F in the console)
28-
* or use the debugger.
29-
*
30-
* ----------------------------- NOTE -----------------------------------
31-
* The code presented in this class is intended only to support the ABAP
32-
* cheat sheets. It is not intended for direct use in a production system
33-
* environment. The code examples in the ABAP cheat sheets are primarily
34-
* intended to provide a better explanation and visualization of the
35-
* syntax and semantics of ABAP statements, not to solve concrete
36-
* programming tasks. For production application programs, you should
37-
* always work out your own solution for each individual case. There is
38-
* no guarantee for the correctness or completeness of the code.
39-
* Furthermore, there is no legal responsibility or liability for any
40-
* errors or their consequences that may occur when using the the example
41-
* code.
42-
*
43-
***********************************************************************
44-
"! <p class="shorttext synchronized">ABAP cheat sheet: CDS view entities</p>
45-
"! Example to demonstrate CDS view entities.<br>Choose F9 in ADT to run the class.
1+
"! <p class="shorttext"><strong>CDS view entities</strong><br/>ABAP cheat sheet example class</p>
2+
"!
3+
"! <p>The example class demonstrates CDS view entities.<br/>
4+
"! Choose F9 in ADT to run the class.</p>
5+
"!
6+
"! <h2>Note</h2>
7+
"! <ul>
8+
"! <li>Example demonstrating CDS view entities. Refer to the CDS view entities used
9+
"! here for more details.</li>
10+
"! <li>Topics covered: Operands, expressions, built-in functions in the element list
11+
"! of CDS view entities, input parameters, joins, associations.</li>
12+
"! <li>Note: In ADT, hold CTRL and click on the CDS view entity in this example to
13+
"! access the artifact. You can choose F8 there to open the data preview.</li>
14+
"! <li>Find information on <strong>getting started with the example class</strong> and the
15+
"! <strong>disclaimer</strong> in the ABAP Doc comment of class {@link zcl_demo_abap_aux}.</li></ul>
4616
CLASS zcl_demo_abap_cds_ve DEFINITION
4717
PUBLIC
4818
FINAL
@@ -53,18 +23,18 @@ CLASS zcl_demo_abap_cds_ve DEFINITION
5323
if_oo_adt_classrun.
5424

5525
CLASS-METHODS class_constructor.
56-
protected section.
57-
private section.
26+
PROTECTED SECTION.
27+
PRIVATE SECTION.
5828
ENDCLASS.
5929

6030

6131

62-
CLASS ZCL_DEMO_ABAP_CDS_VE IMPLEMENTATION.
32+
CLASS zcl_demo_abap_cds_ve IMPLEMENTATION.
6333

6434

6535
METHOD class_constructor.
6636
"Filling demo database tables.
67-
zcl_demo_abap_aux=>fill_dbtabs( ).
37+
zcl_demo_abap_aux=>fill_dbtabs( ).
6838

6939
"Some more database table insertions for this particular example
7040
MODIFY zdemo_abap_carr FROM TABLE @( VALUE #(

0 commit comments

Comments
 (0)