Let’s build a simple login(sign-in) simulation app with Jetpack data store and coroutine. After login(sign in), we will save the token from server(dummy server method) and account information(for example id, shouldAutoLogin) .
And when we start app again, if shouldAutoLogin is true, then app will load token from data store and then get user information from the server(dummy server method)
In this video you can see a file named "DataStoreManager.kt" made by me.
How to build "DataStoreManager.kt" as a data store utility: • Kotlin jetpack datastore tutorial | j...
Timeline:
0:00 project setting review
0:45 XML review
1:26 user model
1:52 coroutine basic activity
3:12 login controller
10:01 datastore manager review
10:29 activity
10:29 finish activity click event
18:17 auto should auto sign-in when the app starts
21:30 test
[ - If you need Source Code, you can contact me - ]
Facebook: / djseokho
Instagram: / coding_with_cat
Email: [email protected]
Facebook group: https://www.facebook.com/groups/46272...
[ - Subscribe 👍 - ]
Subscribe: / @codingwithcat
[ - Please Support me and Hit the like button🧡 - ]
Buy me a coffee: https://www.paypal.com/paypalme/djseokho
project environment:
IDE: Android Studio 4.2.1
Kotlin version 1.5.0
CN ===============================================
本期视频我们用谷歌的Jetpack datastore 和 coroutine 协程 来做一个模拟登陆的app。谢谢观看。
[ - 如果您需要源代码,请联系我. - ]
Facebook: / djseokho
Instagram: / coding_with_cat
Email: [email protected]
Facebook group: https://www.facebook.com/groups/46272...
[ - 请记得订阅 👍 - ]
Subscribe: / @codingwithcat
[ - 点击顶一下来支持我🧡 - ]
如果您愿意支持我,打赏一杯咖啡,感谢: https://www.paypal.com/paypalme/djseokho
KR ===============================================
이번동영상에서 jetpack datastore 하고 coroutine 이용하여 로그인후 토근저장하는 샘플 앱 제작합니다.
[ - 소스코드 필요하시면 연락하세요. - ]
Facebook: / djseokho
Instagram: / coding_with_cat
Email: [email protected]
Facebook group: https://www.facebook.com/groups/46272...
[ - 구독하세요 👍 - ]
Subscribe: / @codingwithcat
[ - 좋아요 버튼 부탁합니다🧡 - ]
원하시면 커피한잔 감사하겠습니다: https://www.paypal.com/paypalme/djseokho
#android #jetpack #jepacks #preference #preferences #datastore #proto #data #store #architecture #components #how to #guide #tutorial #replace #use #implement #android studio #flow #coroutines #storage #key #value #pair #thread-safe #background #thread #type-safety #type #safe #thread #coroutine