Swift is an open-source programming language that is created and designed by Apple to provide developers with high flexibility. Swift is used to build apps for iOS, Mac, Apple TV, and Apple Watch. A Swift-based SDK hides a majority of low-level implementation to provide a simplified way of utilizing API-based Swift services.
Native Function APIs (NFIs) on the other hand, are modules that can wrap the native (iOS, Android) APIs in JavaScript functions. The functions can then be used in a Quantum Visualizer app to facilitate native functions. For more information, refer to Native Function APIs in the Quantum Visualizer API Developers' Guide.
To create NFIs that support Swift-based SDKs, perform the following actions:
Wrap the functionality from Swift into Objective-C methods.
Put the Objective-C methods in a minimal wrapper framework.
Generate an NFI for the wrapper framework.
For detailed information about generating an NFI for the Swift framework, refer to the following sections.