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
- 연산자
- 프래그먼트
- 이스케이핑
- 프로퍼티
- 차이
- 스위프트
- 리스트뷰
- concurrency
- 생명주기
- Swift
- 안드로이드
- 풀이
- 알고리즘
- 해시
- observable
- noncopyable
- RxSwift
- 자바
- 백준
- 옵셔널
- weak
- rx
- View
- async
- 클로저
- 프로그래머스
- Subject
- ios
- Self
- 구조체
Archives
- Today
- Total
목록concurrency (5)
study record
[Swift Concurrency] Getting Started with async/await
async: 메서드가 비동기로 작동할 것임을 보여준다. 이 메서드가 결과를 리턴할 때까지 실행을 멈춘다. await: 코드가 실행을 멈출 수 있음을 보여준다. async 메서드가 리턴할 때까지 기다린다. Task: 비동기 작업의 단위. 작업이 끝나거나 취소되는 것을 기다릴 수 있다. 🧪 completion handler → async 메서드로 변경해보기 // escaping closure func fetchStatus(completion: @escaping (String) -> Void) { URLSession.shared.dataTask( with: URL(string: "")! ) { data, response, error in guard let data = data else { return } co..
Swift/Concurrency
2023. 5. 21. 17:54