In modern PHP, you're going to spend a lot of time working with other people's classes: via external libraries that you bring into your project to get things done faster. Of course, when you do that: you can't actually edit their code if you need to change or add some behavior.
Fortunately, OO code gives us some really neat ways to deal with this limitation. In this tutorial, you'll learn a method called composition in which we'll create a wrapper class, which has some subtle advantages over using inheritance.
https://symfonycasts.com/screencast/oo-ep4/composition-ftw
https://drive.google.com/file/d/1fTRmwiBB0cZzNQNYabM0SXUDErFIUaBk/view?usp=sharing