Friends class in SAP ABAP OOPS | ABAP Friend Class | Access private Components using friends class

Описание к видео Friends class in SAP ABAP OOPS | ABAP Friend Class | Access private Components using friends class

Hello Friends,

In this session, we are going to see what is Friend class in oops is and how to use it to access private and protected components of another class in SAP ABAP oops.

What is the use of the Friend class in SAP ABAP OOPS programming?
If you want to access the private and protected components of another class then we have concepts of friend class in OOPS ABAP.

How to define and declared Friends class in SAP ABAP.
A class can be defined as a private friend of another class. The statement is like this: CLASS cls2 DEFINITION CREATE PRIVATE FRIENDS cls1. Here cls2 is the private friend class of cls1.

Now the requisites are:
1. cls1 can use all protected and private components of cls2.
2. cls1 can instantiate cls2 in its method.

Click on the below link to read the blog on our website related to friend class in sap ABAP oops programming.
https://www.learnsapabap.com/2018/02/...

Please watch the complete video to see all those things practically.

VIDEO CHAPTERS:
0:00 Intro
1:01 How to define or create private friends class in oops
1:50 Class & method definition in ABAP program
4:05 Friends Class declarations in program
8:58 Friend Class method implementations in OOPS ABAP.
10:30 Access Private and protected components of Friends class.
12:40 Overview of friends class
15:45 end

Click on the link below Playlist to watch ---
All videos related to sap ABAP object-oriented programming.
   • SAP ABAP OOPS  

All Videos related to Module Pool Programming.
   • Module Pool Programming  

All videos related to Kernel Badi in sap ABAP
   • Kernel Badi in ABAP  

All Videos related to CDS View on Hana.
   • CDS View on HANA  

Please visit my website to learn more about ABAP.
https://www.learnsapabap.com/

Please connect us on the telegram channel.
https://t.me/learnsapabap

Thanks,
#LearnSapAbap
Instagram : @swap_neeeel

Комментарии

Информация по комментариям в разработке