Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | ||||||
2 | 3 | 4 | 5 | 6 | 7 | 8 |
9 | 10 | 11 | 12 | 13 | 14 | 15 |
16 | 17 | 18 | 19 | 20 | 21 | 22 |
23 | 24 | 25 | 26 | 27 | 28 |
Tags
- onLayout
- kotlin
- 알림
- ViewModel
- notification
- Android
- DataBinding
- 코틀린
- Navigation
- CollapsingToolbarLayout
- lifecycle
- onMeasure
- Algorithm
- View
- activity
- Coroutine
- LiveData
- CustomView
- CoordinatorLayout
- AppBarLayout
- 알고리즘
- Behavior
- room
- 백준
- 안드로이드
- BOJ
- sqlite
- HTTP
- hilt
- recyclerview
Archives
- Today
- Total
목록asynk (1)
개발일지
Kotlin in A..Z - Coroutine(4) async
suspend함수는 순차적으로 실행되는게 기본이다. fun main() = runBlocking { val time = measureTimeMillis { val one = doSomethingOne() val two = doSomethingTwo() println("Result : ${one + two}") } println("Time : $time") } suspend fun doSomethingOne(): Int { delay(1000L) // 무거운 작업 return 10 // 결과 리턴 } suspend fun doSomethingTwo(): Int { delay(1000L) // 무거운 작업 return 20 // 결과 리턴 } Result : 30 Time : 2025 async 하지만 do..
Kotlin (코틀린)
2020. 10. 27. 21:11