Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Protocol Oriented Programming
Search
zezzi
December 11, 2017
Technology
0
53
Protocol Oriented Programming
zezzi
December 11, 2017
Tweet
Share
More Decks by zezzi
See All by zezzi
Swiftlint
zezzi
0
74
Kotlin & Swift
zezzi
1
87
Angular JS
zezzi
0
270
WTM Google Glass 2014
zezzi
2
900
WTMLima 2014
zezzi
0
130
Other Decks in Technology
See All in Technology
品質と速度の両立:生成AI時代の品質保証アプローチ
odasho
1
360
Tokyo_reInforce_2025_recap_iam_access_analyzer
hiashisan
0
190
ビズリーチにおけるリアーキテクティング実践事例 / JJUG CCC 2025 Spring
visional_engineering_and_design
1
120
Beyond Kaniko: Navigating Unprivileged Container Image Creation
f30
0
130
DatabricksにOLTPデータベース『Lakebase』がやってきた!
inoutk
0
110
OPENLOGI Company Profile
hr01
0
67k
FOSS4G 2025 KANSAI QGISで点群データをいろいろしてみた
kou_kita
0
400
Flutter向けPDFビューア、pdfrxのpdfium WASM対応について
espresso3389
0
130
赤煉瓦倉庫勉強会「Databricksを選んだ理由と、絶賛真っ只中のデータ基盤移行体験記」
ivry_presentationmaterials
2
360
american aa airlines®️ USA Contact Numbers: Complete 2025 Support Guide
aaguide
0
120
高速なプロダクト開発を実現、創業期から掲げるエンタープライズアーキテクチャ
kawauso
2
9.3k
LangSmith×Webhook連携で実現するプロンプトドリブンCI/CD
sergicalsix
1
230
Featured
See All Featured
A better future with KSS
kneath
238
17k
XXLCSS - How to scale CSS and keep your sanity
sugarenia
248
1.3M
Product Roadmaps are Hard
iamctodd
PRO
54
11k
Adopting Sorbet at Scale
ufuk
77
9.5k
How STYLIGHT went responsive
nonsquared
100
5.6k
Build your cross-platform service in a week with App Engine
jlugia
231
18k
A designer walks into a library…
pauljervisheath
207
24k
The Straight Up "How To Draw Better" Workshop
denniskardys
234
140k
Git: the NoSQL Database
bkeepers
PRO
430
65k
Docker and Python
trallard
44
3.5k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
29
1.8k
Improving Core Web Vitals using Speculation Rules API
sergeychernyshev
18
970
Transcript
PROTOCOL ORIENTED PROGRAMMING
TEXT OBJECT ORIENTED PROGRAMMING ▸ Object Oriented Programming: Design is
focused on Objects. ▸ Interfaces: Are a contract of what needs to be implemented. And are used as a way to achieve polymorphism. They are a back seat.
TEXT DOG EXAMPLE
TEXT DOG EXAMPLE Code Duplication
TEXT DOG EXAMPLE German Shepard is not a service
dog Pug does not sniff Drugs
TEXT DOG CLASS SERVICE DOG SECURITY DOG PASTOR ALEMAN LABRADOR
TEXT DOG CLASS SERVICE DOG SECURITY DOG PASTOR ALEMAN LABRADOR
TEXT PROTOCOL ORIENTED PROGRAMMING DOGS EXAMPLE
TEXT PROTOCOL ORIENTED PROGRAMMING DOGS EXAMPLE
TEXT DOG PROTOCOL DOG PROTOCOL EXTENSION SERVICE DOG PROTOCOL SECURITY
DOG PROTOCOL PASTOR ALEMAN LABRADOR SERVICE DOG PROTOCOL EXTENSION SERVICE DOG PROTOCOL EXTENSION
TEXT IMPLICIT SHARING
TEXT INHERITANCE TO INTRUSIVE ▸ 1 super class ▸ Bloating
your super class ▸ Changes can become difficult when inheritance is over used.
TEXT WHY? ▸ Why do we want to use protocols?
TEXT PROTOCOLS ▸ The “I” in SOLID ▸ No client
should depend on (or know about) methods it does not use ▸ Makes code modular ▸ Testable ▸ Small separated interfaces == focused API ▸ Restrict access
TEXT PROTOCOL SYNTAX, INHERITANCE, COMPOSITION
DAY TO DAY PROTOCOL USAGE
TEXT
TEXT
TEXT
TEXT
TEXT
TEXT
TEXT
TEXT
TEXT
TEXT
OTHER AREAS CORE DATA
TEXT
TEXT
TEXT VALIDATION
TEXT
TEXT
TEXT