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 |
29 | 30 |
Tags
- 옵저버 패턴
- factory method
- 빌터패턴
- 싱글톤
- 코틀린
- Design Pattern
- 함수형프로그래밍
- Abstract Factory
- designPattern
- 추상팩토리패턴
- El
- builderPattern
- 프로토타입 패턴
- 추상 팩토리
- r
- ㅓ
- ㅋㅁ
- a
- F
- 팩토리 메소드
- Observer Pattern
- Singleton
- 디자인패턴
- Kotlin
- 디자인패턴 #
- PrototypePattern
- Functional Programming
Archives
- Today
- Total
목록Android Jetpack Architecture/LiveData (5)
오늘도 더 나은 코드를 작성하였습니까?
LiveData 개요와 이점
LiveData 개요 LiveData는 관찰 가능한(Observable) 한 데이터 홀더 클래스이다. LiveData는 LifeCycle을 인식한다. 즉, activity, fragment service 등 안드로이드 구성요소의 생명주기를 인식. LiveData는 활성 수명 주기 상태에 있는 앱 구성요소 관찰자(Observer)만 데이터를 업데이트합니다. LiveData는 Observer 패턴을 따른다. 데이터의 변경이 일어났을 때 콜백으로 받아 처리할 수 있습니다. 이렇게 데이터의 변경이 될 때마다 콜백을 실행하는데 활성화 상태가 아닌 경우 Lifecycle을 알기 때문에 필요하지 않을 땐 콜백이 실행 안된다. LifecycleOwner 인터페이스를 구현하는 객체(Activity, fragment)를 ..
Android Jetpack Architecture/LiveData
2020. 8. 15. 03:08