We must create our own OOP classes architecture in order to practice and understand well what we have been talking about OOP.
You must implement:
- Base class that will be inherited at least once. This base case must have at least: -3 properties -3 methods -1 constructor and 1 destructor
- One class that inherits the base class. This class must add: 1 static property 1 method This class must override: 1 property 1 method
- One abstract class with at least: 2 properties 2 methods
- One interface that must be implemented by one class. This interface must have at least 2 methods.
We show an Example of this with this topic:
- Animal.php is the base class who implements the aliveAnimal.php interface
- aliveAnimal.php is an interface with to methods.
- Cat inherits the Animal.php.
- Feline is an abstract class