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
How to be a POP-Star
Search
Sponsored
·
SiteGround - Reliable hosting with speed, security, and support you can count on.
→
Ritesh Gupta
July 05, 2017
Programming
410
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
How to be a POP-Star
POP - Protocol Oriented Programming
Ritesh Gupta
July 05, 2017
More Decks by Ritesh Gupta
See All by Ritesh Gupta
Declarative Networking with Combine –– iOS Conf SG 2020
riteshhh
0
200
Combine! All the things
riteshhh
3
710
Deep dive into Protocols
riteshhh
1
470
Thinking in Swift!
riteshhh
3
460
Other Decks in Programming
See All in Programming
From 6 People Classroom Meetup to 100 People Regional Conference / FOSS4G Hiroshima 2026
furukawayasuto
0
100
週末にAI-DLCを本気で回したら$1,600溶けた
hbashimizu
0
120
変化を抱擁するドキュメントの作り方 - ビジネスルール駆動開発がもたらす、コードとの新しい関係
ioki
2
110
不幸な GC
chencmd
0
870
AIは賢い。でも実行環境は? CLIおじさんがAI時代に伝えたいこと ~ CLIおじさんがAI時代に伝えたいこと ~
curekoshimizu
1
140
Flow は今どうなっているか
mizdra
PRO
0
900
What We Talk About When We Talk About XP
m_seki
2
340
My Marp Sample
sinoue0108
0
140
Foundry Localでエージェント開発
seosoft
0
120
iOS開発×AI駆動開発 〜最近使って便利だったスキルの話〜
nogu66
0
140
まだ間に合う!今年の夏こそSchemeのマクロ展開器を完全理解!
omasanori
0
620
ソフトウェアラスタライザ
fadis
1
780
Featured
See All Featured
Easily Structure & Communicate Ideas using Wireframe
afnizarnur
194
17k
Become a Pro
speakerdeck
PRO
31
6.2k
I Don’t Have Time: Getting Over the Fear to Launch Your Podcast
jcasabona
35
2.8k
Leo the Paperboy
mayatellez
8
2.2k
KATA
mclloyd
PRO
35
15k
JAMstack: Web Apps at Ludicrous Speed - All Things Open 2022
reverentgeek
1
590
エンジニアに許された特別な時間の終わり
watany
108
250k
The Illustrated Children's Guide to Kubernetes
chrisshort
51
53k
RailsConf 2023
tenderlove
30
1.5k
Pawsitive SEO: Lessons from My Dog (and Many Mistakes) on Thriving as a Consultant in the Age of AI
davidcarrasco
0
230
How Software Deployment tools have changed in the past 20 years
geshan
1
34k
The Web Performance Landscape in 2024 [PerfNow 2024]
tammyeverts
12
1.3k
Transcript
how to be a POP-Star (Swift Chennai Meetup) ~ Ritesh
Gupta
/@_riteshhh /riteshhgupta /issues/295 /swift-snippets
None
None
`Protocol-Oriented Programming in Swift` https://developer.apple.com/videos/play/wwdc2015/408/ WWDC - 2015
`Protocol and Value Oriented Programming in UIKit Apps` https://developer.apple.com/videos/play/wwdc2016/419/ WWDC
- 2016
Swift is just not a syntax migration from Objective-C…
Swift is not objective-c styled language…
C ~> C++ Objective-C ~> Swift { imperative } {
object oriented } { object oriented } { protocol oriented }
Entity (class, struct - UI or Model) vs Behaviour (protocol)
Entity is collection of behaviours…
UIButton UIBarButtonItem
UIBarButtonItem UIBarItem NSObject UIButton UIControl UIView
UIBarButtonItem UIBarItem NSObject UIButton UIControl UIView
None
None
UIKit + Protocols
UIView Framable
UIImageView ImageRenderable, Framable
UIButton Tappable, ImageRenderable, Framable
compose everything with Protocols..
UITableViewCell UICollectionViewCell Reusable, Framable
UIScrollView Scrollable, Framable
UITableView UICollectionView Listable, Scrollable, Framable
thinking in protocol..
protocol ->
protocol -> protocol extension ->
protocol -> protocol extension -> protocol constrained extension ->
playground demos..
protocol is not a silver bullet.. http://chris.eidhof.nl/post/protocol-oriented-programming/
..computed variables, extensions, values types, immutability, functional programming, generics, enums,
associative types/ values..
None