How to access swift public function in objective c files?

前端 未结 2 1702
青春惊慌失措
青春惊慌失措 2021-01-18 16:32

I am using the public method as below to convert the API data type into Int.

public func convertToInt( value : Any) -> Int{
    if let v = value as? Strin         


        
2条回答
  •  一整个雨季
    2021-01-18 17:13

    Setup your project to use both swift and objective c. Here is the link for that Then you need to import the Swift class in the similar way you import Objective C class and use it in the same way you would have used in Objective C Class.

提交回复
热议问题