Скачать
C++ Private Fields Can Be Accessed: How Is That Even Allowed?
Автор: Code To Cash Flow
Загружено: 2025-06-27
Просмотров: 1397
Описание:
In this video, we look at a clever C++ example where one class accesses the private member of another, without any getter or public method. How? Through the use of the friend class declaration. You'll learn how the friend keyword works in C++, what it allows, when to use it, and why it's sometimes necessary despite breaking encapsulation. This pattern is often misunderstood or misused, and we'll break down both the mechanics and the best practices around it.
#cpp #cplusplus #friendclass #encapsulation #learncpp
Не удается загрузить Youtube-плеер. Проверьте блокировку Youtube в вашей сети.
Повторяем попытку...
Повторяем попытку...
Доступные форматы для скачивания:
Скачать видео
-
Информация по загрузке: