Prerequisites
Do iOS Get Started all the way until finishing step 3
Step Summary
Add the Initialization code for the SDK
Register all the app
UIViewControllers
to the SDKAdd the Tagged Wrappers, Tagged Buttons using the
accessabilityLabel
Note the Transitions
Add the testing Single Data
Test everything is working
Change everything to production code
Your app is now prepared for monetization with us.
Initialize the SDK
We require the SDK to be initialized only once and as early as possible,
The recommended place to initialize the SDK is the Initial UIViewController
on viewDidLoad()
class ViewController: UIViewController { override func viewDidLoad() { super.viewDidLoad() R89SDK.shared.setLogLevel(level: LogLevels.debug) R89SDK.shared.setDebug() R89SDK.shared.initialize(publisherId: "TestRefinery89ID", appId: "TestConfigDemoApp", singleLine: true, publisherInitializationEvents: nil) R89SDK.shared.registerLifecycle(uiViewController: self) } } }
Register all UIViewController’s
Then on every UIViewController
viewDidLoad()
add the following line.
class ViewController: UIViewController { override func viewDidLoad() { super.viewDidLoad() R89SDK.shared.registerLifecycle(uiViewController: self) } } }
Tagged Wrappers
Tagged wrapper is an iOS UIView with a requirement to have accessibilityLabel
specified, either from the XCode UI builder or programmatically. This is used to find the views in the Single tag where you want us to add the monetization inventory.
You need to add as many as you can, remember that placing a tagged wrapper does not mean we need to use it.
Check iOS Creating a wrapper if you want to know more details on how to create them.