iOS mobile SDK integration: preliminaries
Version 4 of the Unblu iOS mobile SDK only works with version 7 of the Unblu Collaboration Server and iOS 14.5 or newer. It doesn’t work with version 6 of the Collaboration Server or iOS versions before iOS 14.5.
Resource usage
The total size of the iOS mobile SDK ranges from 4 to 30 MB, depending on your use case.
Initializing the SDK requires 4-5 MB of RAM. Depending on the intensity of use, it can take up an additional 20 MB of RAM.
The CPU usage of the SDK depends heavily on which Unblu feature is in use. Operations within the WebView use from 1% to 5% of the CPU.
For video calls, CPU usage can be 50% or higher, depending on the number of call participants and the phone model. RAM usage can go up to 400 MB.
Network traffic
During initialization, the SDK downloads approximately 0.3 MB of JavaScript files. The SDK also has to download around 2.5 MB of additional resources for the UI. Some of these downloads may be cached on the device, resulting in less network traffic for later uses.
For text messaging, only the message itself and the HTTP request overhead is transmitted.
By default, Unblu transmits an image around five times per second in mobile co-browsing sessions if the content has changed. You can adjust the maximum frame capture rate with the configuration property com.unblu.mobiledevice.iosMaxFpsRate. The size of the image depends on the size of the mobile device’s screen but is typically 5—20 KB large.
In audio and video calls, network traffic depends on the quality of the connection, as both LiveKit and Vonage change the codec based on the network connection.
Swift compatibility
The frameworks Unblu provides are written in Swift, not Objective-C, as Swift is the recommended language for iOS development.
Objective-C
In principle, Swift code can be used in Objective-C, but there are some limitations. For example, enums in Swift need to have a raw type of Int
. It therefore isn’t possible simply to use the SDKs in an Objective-C environment.
If your project is formally an Objective-C project, you must convert it to a Swift project that mainly uses Objective-C. You must then wrap the usage of the Unblu SDK in a Swift helper which in turn may be used in Objective-C. Currently Unblu doesn’t provide any Swift helper classes.
Swift versions
In 2014, Apple wrote:
[I]f your project uses frameworks to share code with an embedded extension, you will want to build the frameworks, app, and extensions together. It would be dangerous to rely upon binary frameworks that use Swift—especially from third parties. As Swift changes, those frameworks will be incompatible with the rest of your app. When the binary interface stabilizes in a year or two, the Swift runtime will become part of the host OS and this limitation will no longer exist.
Swift is ABI stable as of version 5.0, so if your project is running Swift 5.0 or newer, it should be able to interface with the Unblu SDK. If you require a version of the Unblu SDK built with an older version of Swift, contact the Unblu support team.
Unblu aims to provide the iOS SDKs for the newest Swift version.
See also
-
For more information on version 4 of the Unblu iOS mobile SDK, refer to its reference documentation.
-
For more information on using Swift and Objective-C together, refer to the article Importing Swift into Objective-C in the Apple documentation.