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 |
Tags
- map
- combine
- 스위프트
- Refactoring
- swift documentation
- UICollectionView
- 애니메이션
- rxswift
- uitableview
- swiftUI
- Clean Code
- SWIFT
- uiscrollview
- UITextView
- Human interface guide
- 클린 코드
- MVVM
- 리팩토링
- Xcode
- 리펙터링
- collectionview
- clean architecture
- 리펙토링
- tableView
- HIG
- Protocol
- ios
- ribs
- RxCocoa
- Observable
Archives
- Today
- Total
목록2024/02/20 (1)
김종권의 iOS 앱 개발 알아가기
[iOS - swift] AssociatedObject 생명주기 (objc_getAssociatedObject, objc_setAssociatedObject)
AssociatedObject 생명주기 AssociatedObject를 사용하면 extension에도 stored property 처럼 표현이 가능한데, ARC에 의하여 참조 카운트가 0이되면 자동으로 AssociatedObject도 사라지는것인가? AssociatedObject를 사용하여 extension에 stored property 추가 방법은 이전 포스팅 글 참고 ex) AssociatedObject extension UIScrollView { var lastOffsetY: CGFloat { get { (objc_getAssociatedObject(self, &AssociatedKeys.lastOffsetY) as? CGFloat) ?? 0.0 } set { objc_setAssociatedObj..
iOS 응용 (swift)
2024. 2. 20. 00:28