Structures and classes are general-purpose, flexible constructs that become the building blocks of your program’s code. You define properties and methods to add functionality to your structures and classes using the same syntax you use to define constants, variables, and functions. Struct와 Class를 통해 요소를 유연하게 구성할 수 있다. 클래스 안에 method와 property들을 일반적인 상수, 변수, 메소드 정의하듯 정의하여 사용 할 수 있다고 한다. struct와 cl..
한 동안은 Swift 작업을 할 때 종종 사용했던 프로토콜에 대한 글을 쓰려고 한다. 그 중 첫 번째는 개인적으로 정말 많이 사용했던, Equatable이다. Equatable 오늘도 어김없이, 공식 문서의 내용을 가져왔다. Types that conform to the Equatable protocol can be compared for equality using the equal-to operator (==) or inequality using the not-equal-to operator (!=). Most basic types in the Swift standard library conform to Equatable. 간단하게 이야기하면, 비교 연산자들을 통해 비교 할 수 있도록 만들어주는 프로토..
최근에 알고리즘 공부 이야기를 하다가, Set에 대한 이야기가 나왔다. 중복 제거에 흔히 사용하는 Set은 어떻게 동작하는지, 또 Swift의 Set은 뭐가 다른지를 간단하게 적어보려 한다. Set? A set stores distinct values of the same type in a collection with no defined ordering. You can use a set instead of an array when the order of items isn’t important, or when you need to ensure that an item only appears once. 기본적으로 Set은 중복되지 않는 값을 저장하기 위한 Collection으로 정렬되지 않은 상태로 들어간다...
간단하게 Swift에서 정의하고 있는 ViewController와 여러 ViewController 중 핵심이었던 UIViewController를 알아보았던 지난 시간에 이어서, 오늘은 본격적으로 LifeCycle을 다뤄보려고 한다. LifeCycle? 한글로 직역하면, 생명주기 되시겠다. 말 그대로 UIViewController가 만들어져, 보여지고, 사라지기까지의 과정들을 다루는 것인데 이를 Swift에서는 Handle view-related notifications라는 이름으로 관리를 하고 있다. 아래는 Handle view-related notifications의 설명이다. When the visibility of its views changes, a view controller automatica..
일일 포스팅의 첫 글로 당첨된 건 LifeCycle 관련 글이다, 공식 문서와 함께 공부해보자 Application LifeCycle도 있지만, 일단 오늘 다루려고 하는 건 ViewController의 LifeCycle이다. 처음 개발을 배울때 게임으로부터 시작해서인지, 특히 이쪽에 관심이 많이 있고 기본적으로 알아야하는 요소라고 생각했다. 업데이트와 렌더를 따로 관리했었는데, 업데이트만 하고 그려주지 않았다거나, 그려주긴 했는데 업데이트를 안시켰다거나, 했던 경험이 What is the View Controller? LifeCycle을 다루기에 앞서, ViewController에 대해 알고 가보자 You use view controllers to manage your UIKit app’s interfa..
- Total
- Today
- Yesterday
- viewcontroller
- guri's dev
- POP
- 테크니컬라이팅
- 기술블로그
- flutter
- Async
- Provider
- message
- await
- 리팩토링
- Swift
- struct
- document
- 코드리뷰
- Equatable
- protocol
- combine
- IOS
- writing helpful error message
- lifecycle
- 개발자
- WWDC
- github
- UIKit
- techincal
- 개발문화
- OOP
- 주저리주저리
- getx
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 |