Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Protocols All The Way Down - dotSwift, Paris, J...

Protocols All The Way Down - dotSwift, Paris, January 2018

A talk about the benefits and drawbacks of Protocol Oriented Programming, and protocols with default implementations.

Video:
https://www.dotconferences.com/2018/01/ellen-shapiro-protocols-all-the-way-down

Playground:
https://github.com/designatednerd/ProtocolPlayground

Ellen Shapiro

January 29, 2018
Tweet

More Decks by Ellen Shapiro

Other Decks in Technology

Transcript

  1. PROTOCOLS ALL THE WAY DOWN DOT SWIFT | PARIS, FRANCE

    | JANUARY 2018 @DESIGNATEDNERD | BAKKENBAECK.COM | JUSTHUM.COM
  2. > Do I need this to work on all instances

    and/or subclasses of a particular thing? Extension! > Do I need this method to work only when I say it should, or in a particular combination of circumstances? Default implementation! > Does this always need to be called from a particular lifecycle or delegate method? Subclass!
  3. LINKS! > Protocol-Oriented Programming, WWDC 2015 developer.apple.com/videos/play/wwdc2015/408 > The ghost

    of Swift Bugs Future, Alexandros Salazar nomothetis.svbtle.com/the-ghost-of-swift-bugs- future
  4. PHOTO CREDITS! > Businessman, by Daniel X. O'Neil flickr.com/photos/juggernautco/6037175371 >

    Hammered Screw, by Justin Baeder flickr.com/photos/justinbaeder/5317820857 > Knot, by JP Davidson flickr.com/photos/jpdavidsonimages/4677642617