Interfaces allow you to define the capabilities of an object. These definitions make it easier to write automated tests and help your code follow the Liskov substitution principle (the L in the five SOLID principles of object-oriented programming).

We'll look at the how to define and implement an interface, we'll write automated tests using the interface to mock the object, and we'll swap out one object for another to see how the interface helps us make this change.

We'll also cover the differences between Interfaces & Traits ... as well as review the basics of how Inheritance works as well.

Come into this 2hr workshop with questions, and leave with a solid understanding of how PHP Objects work.

Comments

Comments are closed.

Mike Hancoski at 12:48 on 23 Oct 2019

Easy to follow amazing info and review

Cecili Reid at 13:52 on 23 Oct 2019

It was very easy to follow along and I loved the slides/website. The examples were understandable and I learned some things I was not aware was possible as a PHP newbie from a Java background.

Great talk. Easy to follow and amazing info that can be used as reference point while getting started with PHP Objects.