- Swift Functional Programming(Second Edition)
- Dr. Fatih Nayebi
- 73字
- 2021-07-02 23:54:28
Methods
Methods are functions that are associated with a particular type. Instance methods are functions that are called on an instance of a particular type. Type methods are functions that are called on the type itself.
The following example presents a class containing a type method that is named someTypeMethod():
class AClass {
class func someTypeMethod() {
// type method body
}
}
// We can call this method as follows:
AClass.someTypeMethod()
推薦閱讀
- 計算機組成原理與接口技術(shù):基于MIPS架構(gòu)實驗教程(第2版)
- 大數(shù)據(jù)技術(shù)基礎(chǔ)
- 云計算環(huán)境下的信息資源集成與服務(wù)
- Spark大數(shù)據(jù)分析實戰(zhàn)
- Game Development with Swift
- 算法與數(shù)據(jù)中臺:基于Google、Facebook與微博實踐
- Python醫(yī)學(xué)數(shù)據(jù)分析入門
- 企業(yè)級數(shù)據(jù)與AI項目成功之道
- 網(wǎng)站數(shù)據(jù)庫技術(shù)
- Mastering LOB Development for Silverlight 5:A Case Study in Action
- 從實踐中學(xué)習(xí)sqlmap數(shù)據(jù)庫注入測試
- 區(qū)塊鏈+:落地場景與應(yīng)用實戰(zhàn)
- 大數(shù)據(jù)技術(shù)體系詳解:原理、架構(gòu)與實踐
- Oracle 內(nèi)核技術(shù)揭密
- 數(shù)據(jù)庫基礎(chǔ)與應(yīng)用