Installation
It is recommended to use Xcode to develop and build the project.
Requirements
- Device must be able to connect to the Internet.
- iOS version must be 11.0 or above.
Xcode
It is recommended to use Xcode to develop and build the project.
Adding Framework and Configuration to Xcode Project
Download
mtc-<environment>-<version>.zip
.Use provided Nexus Repository credentials to sign in:
- Test:
https://nexus.ext.meawallet.com/repository/mtc-ios-group/ios/mtc-test/<version>/mtc-test-<version>.zip
- Prod:
https://nexus.ext.meawallet.com/repository/mtc-ios-group/ios/mtc-prod/<version>/mtc-prod-<version>.zip
- Test:
Unzip the archive. Archive contains iOS XCFramework -
MeaTokenControl.xcframework
.Add
MeaTokenControl.xcframework
toFrameworks, Libraries and Embedded Content
section ofGeneral
settings in iOS project target. SetEmbed & Sign
.Download
mea_config.<issuer>.zip
.Unzip the archive. Archive contains configuration file
mea_config
.Add
mea_config
to iOS AppResources
folder and AppTarget
. File must be included in the final app bundle. Framework automatically loads configuration from app bundle during runtime. Framework raises an exception if configuration file is missing, broken or otherwise fails to load.
Loading Configuration
By default MTC SDK is loading mea_config
configuration file, however a custom name can be used. When defining a custom name for the configuration file
use MeaTokenControl.loadConfig(configFileName: String)
to load the configuration. Configuration file can be placed anywhere in application bundle.
import MeaTokenControl
...
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool {
MeaTokenControl.loadConfig("custom_config_name")
...
return true
}
#import <MeaTokenControl/MeaTokenControl.h>
...
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions
{
[MeaTokenControl loadConfig:@"custom_config_name"];
...
return YES;
}
MTC SDK raises an exception if configuration file is missing, broken or otherwise fails to load.