MPS
public final class MPS: NSObject
Automates the connection to MPS and Google Ads.
-
Gets MPS Site Config from MPS Server.
Declaration
Swift
public func getSiteConfig( success: @escaping((_ json: [String: Any]) -> Void), failure: @escaping((_ error: Error) -> Void))
Parameters
success
Success block that contains MPS Site Config JSON.
failure
Failure block to handle response errors.
-
Constructor. Creates the instance of SDK.
Declaration
Swift
public convenience init(url: URL, site: String)
Parameters
url
URL - MPS server URL.
site
String - MPS site value.
-
Constructor. Creates the instance of SDK.
Declaration
Swift
public convenience init(url: URL, site: String, enableTestMode: Bool)
Parameters
url
URL - MPS server URL.
site
String - MPS site value.
enableTestMode
Bool is test mode enabled.
-
Constructor. Creates the instance of SDK.
Declaration
Swift
public required init(url: URL, site: String, logLevel: MPSSDKLogLevel, enableTestMode: Bool)
Parameters
url
URL - MPS server URL.
site
String - MPS site value.
logLevel
MPSSDKLogLevel for library.
enableTestMode
Bool is test mode enabled.
-
Constructor. Creates the instance of SDK.
Declaration
Swift
public convenience init(url: URL, site: String, logLevel: MPSSDKLogLevel)
Parameters
url
URL - MPS server URL.
site
String - MPS site value.
logLevel
MPSSDKLogLevel for library.
-
Gets MPS page object for selected parameters.
Declaration
Swift
public func requestPageObject(mpsParams: MPSPageParameters) -> MPSPage
Parameters
mpsParams
MPSPageParameters - parameters for the ad.
-
Boolean to control updating Correlator between pages. Default is true.
Declaration
Swift
public var updateCorrelator: Bool
-
MPS Configuration.
Declaration
Swift
public var siteConfig: [String: Any]
-
Version dictionary of MPS and embedded frameworks.
Declaration
Swift
public var version: [String: String]