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
Approaching Clean Architecture in Android w/ Ko...
Search
Artyom Dorosh
March 24, 2018
Programming
0
250
Approaching Clean Architecture in Android w/ Kotlin
Speech for Kyiv Kotlin Night. #KNightKyiv #Kotlin #Kyiv
Artyom Dorosh
March 24, 2018
Tweet
Share
More Decks by Artyom Dorosh
See All by Artyom Dorosh
Android Forge:
doroshartyom
1
69
Other Decks in Programming
See All in Programming
Code as Context 〜 1にコードで 2にリンタ 34がなくて 5にルール? 〜
yodakeisuke
0
130
「テストは愚直&&網羅的に書くほどよい」という誤解 / Test Smarter, Not Harder
munetoshi
0
170
Deep Dive into ~/.claude/projects
hiragram
14
2.6k
git worktree × Claude Code × MCP ~生成AI時代の並列開発フロー~
hisuzuya
1
580
レベル1の開発生産性向上に取り組む − 日々の作業の効率化・自動化を通じた改善活動
kesoji
0
230
Railsアプリケーションと パフォーマンスチューニング ー 秒間5万リクエストの モバイルオーダーシステムを支える事例 ー Rubyセミナー 大阪
falcon8823
5
1.1k
AIともっと楽するE2Eテスト
myohei
7
2.7k
ニーリーにおけるプロダクトエンジニア
nealle
0
840
Node-RED を(HTTP で)つなげる MCP サーバーを作ってみた
highu
0
120
Goで作る、開発・CI環境
sin392
0
240
技術同人誌をMCP Serverにしてみた
74th
1
650
Hypervel - A Coroutine Framework for Laravel Artisans
albertcht
1
130
Featured
See All Featured
Into the Great Unknown - MozCon
thekraken
40
1.9k
Art, The Web, and Tiny UX
lynnandtonic
299
21k
Visualizing Your Data: Incorporating Mongo into Loggly Infrastructure
mongodb
46
9.6k
Site-Speed That Sticks
csswizardry
10
690
KATA
mclloyd
30
14k
Agile that works and the tools we love
rasmusluckow
329
21k
Balancing Empowerment & Direction
lara
1
430
XXLCSS - How to scale CSS and keep your sanity
sugarenia
248
1.3M
A designer walks into a library…
pauljervisheath
207
24k
Intergalactic Javascript Robots from Outer Space
tanoku
271
27k
4 Signs Your Business is Dying
shpigford
184
22k
CoffeeScript is Beautiful & I Never Want to Write Plain JavaScript Again
sstephenson
161
15k
Transcript
Approaching Clean Architecture w/ Kotlin in Android Artyom Dorosh 1
About me • 4+ years in Android Development • Writing
in Kotlin since the late beta • Helping people at StackOverflow • Making cool stuff at themind.io 2
3
Agenda 1. Clean Architecture 2. CA & Android 3. CA
& Kotlin 4
Clean Architecture 5
What is Clean Architecture? 6
7 Independent of Framework
8 Independent of UI
9 Independent of Data Sources
10 Testable
CA is • Independent of Frameworks • Testable • Independent
of UI • Independent of Data Sources 11
The Scheme Entities Use cases Presenters UI DB Network Domain
logic Business Rules Interface Adapters Frameworks & Sources Dependency Rule 12 Gateways
13 Android
Entities Use cases Presenters UI DB Network 14 Gateways
Dependency Presenters Repositories Use Cases Entities UI DB Web 15
Dependency Presenters Repositories Use Cases Entities UI DB Web 16
Presentation Data Domain
Data flow. Explained. Use Cases Entities Repos Domain Data Presentation
17 Web DB HAL UI Presenters
18 CA ♥ Android
19 CA ♥ CC
Kotlin 20
DEMO 21
Pros & Cons of CA 22
Easy to maintain 23 ♥
Easy to share 24 ♥
~ 70% code base sharing 25
Easy to test 26 ♥
Over-engineering 27
YAGNI Principle ✍ 28
One more thing … 29
The real issue Mobile developers thinking too much about software
architecture, because … 30
Software architecture is the money talk. 31
32
33
34
35
36
Slow and steady wins the race. 37
38
Source Code on GitHub 39 https://goo.gl/AT2bdS
Books to Read 40 https://goo.gl/p50lsZ
Books to Read 41 https://goo.gl/ZkyKsu
Contact me twitter.com/dniHze t.me/dniHze github.com/dniHze 42
Chat & Channel t.me/kpidroid t.me/androidpain 43
Thats all, folks! Any questions? 44