1. Whether to add private in front of func depends on whether you want it to be exposed to the outside world. 2. In Swift, String is generally used instead of NSString. The conversion between them can be done with as String and as NSString. 3. This writing method is It is written with reference to the tableview method. Inside the brackets are the parameters, -> followed by the return value type, as follows:
1. Whether to add private in front of func depends on whether you want it to be exposed to the outside world. 2. In Swift, String is generally used instead of NSString. The conversion between them can be done with as String and as NSString. 3. This writing method is It is written with reference to the tableview method. Inside the brackets are the parameters, -> followed by the return value type, as follows: