Section 21: Protocols


This section describes protocols, a powerful mechanism in objective-C and now Swift allowing a foundation of properties, method and requirements for structures and classes to be defined. Protocols have no functionality themselves, and only describe attributes that either a class or structure must have to conform to a protocol. Only once these are all implemented does it mean that the class or structure fully conforms to that protocol. These requirements can be optional, however those required must still be satisfied in order to conform to that protocol.

Protocols resource sheet

Posted in Chapter 2: Language Guide