본문 바로가기

iOS/설명119

[iOS] '==' vs '===' https://ios-development.tistory.com/393 [iOS - swift] == 와 === 의 차이 (+ Equtable) `==` vs `===` a == b: a의 값과 b의 value가 같은지 비교 let value1 = 1 let value2 = 2 print(value1 == value2) // false a === b: a가 참조하고 있는 인스턴스와 b가 참조하고 있는 인스턴스가 같은지 비교 swift에서는 크 ios-development.tistory.com == vs === == 각 변수의 Value를 비교한다. Stack 영역의 값을 비교 Equatable을 채택해서 static func ==() method를 선언하면 사용할 수 있다. === 각 변수가 참조하고 있.. 2024. 3. 17.
[iOS] OOP와 POP는 어떤 경우에 써야 할까 (고찰) 근래에 OOP와 POP는 각각 어떤 경우에 사용해야하는 가에 대한 고민을 해본 적이 있다. 사실 그냥 막연하게 Swift는 POP 개발을 지향해! 라고만 알고 있지 실제로 어떤 경우에 사용해야하는 가에 대한 개인적인 기준이 없는 듯 하여 그에 대한 개인적인 생각을 적어본다. (OOP와 POP라고 표현하였지만 정확히는 'OOP의 상속'과 'Protocol의 초기구현'이라고 봐도 될듯 하다.) OOP vs POP https://skytitan.tistory.com/550 [Swift] 프로토콜 지향 프로그래밍 (Protocol Oriented Program) 프로토콜 지향 프로그래밍 스위프트는 프로토콜 지향 언어(Protocol-Oriented Language)이다. 스위프트는 대부분 구조체로 기본 타입이 .. 2024. 3. 17.
[iOS] High performance based drawing https://medium.com/@almalehdev/high-performance-drawing-on-ios-part-1-f3a24a0dcb31 High performance drawing on iOS — Part 1 How I optimized 2D drawing for my game, including what worked and what didn’t work medium.com https://medium.com/@almalehdev/high-performance-drawing-on-ios-part-2-2cb2bc957f6 High performance drawing on iOS — Part 2 This article covers two different ways to perform 2D draw.. 2024. 2. 24.
[iOS] Mirror Struct https://zeddios.tistory.com/943 Swift ) Mirror 안녕하세요 :) Zedd입니다. 요새 왜이렇게 바쁜지 모르겠어요 @0@... 운동을 하면 체력이 더 좋아져서 다 해버릴 수 있을것만 같았는데 그런것도 아니네요. 하하 오늘은 Mirror에 대해서 공부해보려 zeddios.tistory.com https://developer.apple.com/documentation/swift/mirror Mirror | Apple Developer Documentation A representation of the substructure and display style of an instance of any type. developer.apple.com Mirror 정의: 어떤 타입의 i.. 2024. 2. 24.