iOS 🍎/Swift

typealias, associatedtype

yongmin.Lee 2022. 4. 15. 17:23

typealias

typealias란 타입에 붙일 수 있는 별칭

 

associatedtype

associatedType 은 Protocol을 위한 Generic 

An associated type gives a placeholder name to a type that’s used as part of the protocol. 

 

 

 

 

 

 

 

 

참고자료

https://docs.swift.org/swift-book/LanguageGuide/Generics.html

https://woongsios.tistory.com/97