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
The Android Architecture
Search
မျိုးလွင်ဦး
July 09, 2019
Programming
1
150
The Android Architecture
Slides for DroidYangon2019
မျိုးလွင်ဦး
July 09, 2019
Tweet
Share
More Decks by မျိုးလွင်ဦး
See All by မျိုးလွင်ဦး
Android Media3: The Next Generation of Media Playback on Android
myolwin00
1
140
Whats new in Android Media?
myolwin00
2
320
MasteringDaggerWithHiltOnAndroid
myolwin00
0
160
BritishUniversityCollegeEventSlides.pdf
myolwin00
0
27
Road to become an Android Developer
myolwin00
1
360
Other Decks in Programming
See All in Programming
僕がつくった48個のWebサービス達
yusukebe
18
17k
Vue SFCのtemplateでTypeScriptの型を活用しよう
tsukkee
3
1.6k
VR HMDとしてのVision Pro+ゲーム開発について
yasei_no_otoko
0
110
2万ページのSSG運用における工夫と注意点 / Vue Fes Japan 2024
chinen
3
1.4k
色々なIaCツールを実際に触って比較してみる
iriikeita
0
290
PagerDuty を軸にした On-Call 構築と運用課題の解決 / PagerDuty Japan Community Meetup 4
horimislime
1
110
Outline View in SwiftUI
1024jp
1
230
Honoの来た道とこれから
yusukebe
19
3.1k
リアーキテクチャxDDD 1年間の取り組みと進化
hsawaji
1
130
Amazon Qを使ってIaCを触ろう!
maruto
0
300
Server Driven Compose With Firebase
skydoves
0
420
Amazon Neptuneで始めてみるグラフDB-OpenSearchによるグラフの全文検索-
satoshi256kbyte
4
350
Featured
See All Featured
Why Our Code Smells
bkeepers
PRO
334
57k
Rebuilding a faster, lazier Slack
samanthasiow
79
8.6k
Build your cross-platform service in a week with App Engine
jlugia
229
18k
Fashionably flexible responsive web design (full day workshop)
malarkey
404
65k
Building Your Own Lightsaber
phodgson
102
6.1k
Large-scale JavaScript Application Architecture
addyosmani
510
110k
Easily Structure & Communicate Ideas using Wireframe
afnizarnur
191
16k
Adopting Sorbet at Scale
ufuk
73
9k
The Success of Rails: Ensuring Growth for the Next 100 Years
eileencodes
43
6.6k
Understanding Cognitive Biases in Performance Measurement
bluesmoon
26
1.4k
The MySQL Ecosystem @ GitHub 2015
samlambert
250
12k
Scaling GitHub
holman
458
140k
Transcript
The Android Architecture @myolwin00
Why do we need this?
Separation of concerns(SoC) • Don’t write all your code in
an Activity or a Fragment • Separate into sections • Encapsulate informations
Issues • Limited resource • UI controllers are not for
business logic • You don't own implementations of Activity and Fragment • Destroyed after configuration changes • Potential memory leaks • Hard to test • Hard to maintain • And extending your app is more difficult
If you shouldn't use app components to store app data
and state, how should you design your app?
Clean Architecture, Chapter 15 “A good software architecture allows the
system to be easy to understand, to develop, to maintain and to implement.”
Common Architectures • MVC • MVP • MVVM • MVI,
Clean Architecture and more…
Model-View-Controller(MVC)
• Describe business logic • Data operation • Define data
manipulation Model • Represent UI components • Display the data from Controller View • Coordinate between View and Model Controller
MVP(Model-View-Presenter)
MVVM(Model-View-ViewModel)
Loaders • AsyncTaskLoader • CursorLoader
Loaders
MVVM with AAC Source: https://developer.android.com/jetpack/docs/guide
ViewModel From AAC • Replace loaders • Manage UI-related data
in a lifecycle conscious way • Survive configuration changes
ViewModel Lifecycle
Useful links • https://github.com/googlesamples/android-architecture • https://github.com/googlesamples/android- architecture-components • https://developer.android.com/jetpack/docs/guide
Thank You ! It’s question time ! @myolwin00