Chapter 6. Using Protocols and Protocol Extensions

While watching the presentations from WWDC 2015 about protocol extensions and Protocol-Oriented Programming (POP), I will admit that I was very skeptical. I have worked with Object-Oriented Programming (OOP) for so long that I was unsure if this new programming paradigm would solve all of the problems that Apple was claiming it would. Since I am not one who lets my skepticism get in the way of trying something new, I set up a new project that mirrored the one I was currently working on, but wrote the code using Apple's recommendations for POP. I also used protocol extensions extensively in the code. I can honestly say that I was amazed with how much cleaner the new project was compared to the ...

Get Mastering Swift 3 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.