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 |
31 |
Tags
- segue
- 글또
- Refresh
- escaping
- Observer
- Switch
- http
- viewlifecycle
- IOS
- NotificationCenter
- 고차함수
- ScrollView
- Animation
- class
- SWIFT
- SWIFTUI
- list
- mvvm
- protocol
- apns
- struct
- calendar
- self
- 화면전환
- uikit
- PushNotification
- Git
- array
- singleton
- error
Archives
- Today
- Total
목록AnyObject (1)
seong_hye, the developer
Swift) 문법 정리 - 타입 캐스팅(Type Casting) / Any, AnyObject
타입 캐스팅이란?인스턴스의 타입을 확인하거나 어떠한 클래스의 인스턴스를해당 클래스 계층 구조의 슈퍼클래스나 서브 클래스로 취급하는 방법 - 메모리 값을 수정하는 것은 아님- 단순히 해당 타입의 인스턴스인 것처럼 취급하려는 목적class Person { var id = 0 var name = "이름" var email = "abc@gmail.com"}class Student: Person { var studentId = 1}class Undergraduate: Student { var major = "전공"}let person = Person()let student = Student()let undergraduate = Undergradutae()is 연산자타입에 대한 검사를 수행하는 연산자 (..
IOS
2022. 7. 12.