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
Clean Architecture
Search
Thibaut Coutard
January 27, 2020
Technology
0
40
Clean Architecture
Short introduction about Clean Architecture
Thibaut Coutard
January 27, 2020
Tweet
Share
More Decks by Thibaut Coutard
See All by Thibaut Coutard
iOS ecosystem
coutart
0
27
Tests
coutart
0
54
Iterate your Klingon
coutart
0
63
Workshop : CI - CD using Bitrise
coutart
0
54
Internationalisation
coutart
0
33
Other Decks in Technology
See All in Technology
公開初日に Gemini CLI を試した話や FFmpeg と組み合わせてみた話など / Gemini CLI 初学者勉強会(#AI道場)
you
PRO
0
1.2k
microCMSではじめるAIライティング
himaratsu
0
140
AIエージェントが書くのなら直接CloudFormationを書かせればいいじゃないですか何故AWS CDKを使う必要があるのさ
watany
18
7.4k
Autify Company Deck
autifyhq
2
44k
ソフトウェアQAがハードウェアの人になったの
mineo_matsuya
3
190
SREのためのeBPF活用ステップアップガイド
egmc
2
1.1k
AI エージェントと考え直すデータ基盤
na0
19
7.7k
オフィスビルを監視しよう:フィジカル×デジタルにまたがるSLI/SLO設計と運用の難しさ / Monitoring Office Buildings: The Challenge of Physical-Digital SLI/SLO Design & Operation
bitkey
1
380
データ戦略部門 紹介資料
sansan33
PRO
1
3.3k
ソフトウェアテストのAI活用_ver1.25
fumisuke
1
590
Contributing to Rails? Start with the Gems You Already Use
yahonda
2
120
CDK Toolkit Libraryにおけるテストの考え方
smt7174
1
530
Featured
See All Featured
Mobile First: as difficult as doing things right
swwweet
223
9.7k
The Invisible Side of Design
smashingmag
301
51k
Exploring the Power of Turbo Streams & Action Cable | RailsConf2023
kevinliebholz
34
5.9k
It's Worth the Effort
3n
185
28k
Producing Creativity
orderedlist
PRO
346
40k
Agile that works and the tools we love
rasmusluckow
329
21k
The Straight Up "How To Draw Better" Workshop
denniskardys
235
140k
Making Projects Easy
brettharned
116
6.3k
A better future with KSS
kneath
238
17k
実際に使うSQLの書き方 徹底解説 / pgcon21j-tutorial
soudai
PRO
181
54k
What’s in a name? Adding method to the madness
productmarketing
PRO
23
3.5k
Fight the Zombie Pattern Library - RWD Summit 2016
marcelosomers
233
17k
Transcript
Clean Architecture Thibaut Coutard iOS developer
What is it ?
Uncle Bob • co-autor of the agile manifest • Author
of Clean Code • His blog cleancoder.com
Why ? • Easier to change • Easier to maintain
• Less bugs • Less developers needed
S.O.L.I.D
S.O.L.I.D • Single Responsibility Principle
S.O.L.I.D • Single Responsibility Principle • Open Close Principle
S.O.L.I.D • Single Responsibility Principle • Open Close Principle •
Liskov Substitution Principle
S.O.L.I.D • Single Responsibility Principle • Open Close Principle •
Liskov Substitution Principle • Interface Segregation Principle
S.O.L.I.D • Single Responsibility Principle • Open Close Principle •
Liskov Substitution Principle • Interface Segregation Principle • Dependency Inversion Principle
S.O.L.I.D
S.ingle Responsibility Principle
S.ingle Responsibility Principle • One reason to change • Do
one thing • Responsible to one actor
O.pen Close Principle
O.pen Close Principle • Open for extension - Close for
modi fi cation • Protects higher-level components from changes in lower-level components
View Presenter Interactor Repository
L.iskov Substition Principle
L.iskov Substition Principle • Class substituted by another without breaking
the caller
Repository DBInterface Realm Gateway CoreData Gateway <I>
I.nterface Segregation Principle
I.nterface Segregation Principle • Harmful to depend on modules that
contains more than you need • Give only the essentials
UserAPI ———— +getAll +get +post UserList AddUser GetAllUserAPI ———— +getAll
<I> GetUserAPI ———— +get <I> PostUserAPI ———— +post <I> UserPro fi le
D.ependency Inversion Principle
D.ependency Inversion Principle • Flexible using abstraction • Interfaces less
volatiles • Never mention the name of anything concrete or volatile
D.ependency Inversion Principle Interactor Interactor Output Presenter
Clean Architecture
-M. Conway « organizations which design systems ... are constrained
to produce designs which are copies of the communication structures of these organizations. »
Clean Architecture • A good architecture allow changes • Be
careful of duplication that is not real • Premature decisions are ones that have nothing to do with business requirements • Draw Boundaries between business and GUI, GUI and DB, DB and business
None
None
None
None
None
None
None
Don’t depend on volatile things !
Going deeper • https://github.com/coutar-t/GW2Achievements • Clean Architecture, Robert C. Martin
• V.I.P.E.R • Clean Swift • https://speakerdeck.com/coutart/clean-architecture