Our app needs to do integration with IOT devices and we get the NFC driver framework from device manufacturer. But the lib and APIs from the framework is in Swift. I was able to follow this tutorial to invoke bridge at objective-c level, but I have no idea how to invoke the function from Swift. Following is an example of swift integration code from the device manufacturer. Thanks in advance.
import DeviceLib
class NFCViewController: UIViewController {
private var nfcDriver: NFCDriver?
override func viewDidLoad() {
super.viewDidLoad()
self.nfcDriver = NFCDriver(delegate: self)
}
@IBAction func startNFC(_ sender: Any) {
if self.nfcDriver != nil {
do {
try self.nfcDriver!.sessionBegin()
} catch {}
}
}