OMIDSDK

Objective-C

@interface OMIDSDK : NSObject

Swift

class OMIDSDK : NSObject

This application level class will be called by all integration partners to ensure OM SDK has been activated before calling any other API methods. Any attempt to use other API methods prior to activation will result in an error.

Note that OM SDK may only be used on the main UI thread. Make sure you are on the main thread when you initialize the SDK, create its objects, and invoke its methods.

  • The current semantic version of the integrated OMID library.

    Declaration

    Objective-C

    + (nonnull NSString *)versionString;

    Swift

    class func versionString() -> String
  • Shared OMIDSDK instance.

    Declaration

    Objective-C

    @property (class, readonly, nonnull) OMIDSDK *sharedInstance;

    Swift

    class var shared: OMIDSDK { get }
  • A Boolean value indicating whether the OMID library has been activated.

    The value of this property is YES if the OMID library has already been activated. Allows the integration partner to check that they are compatible with the running OMID library version.

    Declaration

    Objective-C

    @property (readonly, getter=isActive) BOOL active;

    Swift

    var isActive: Bool { get }
  • Enables the integration partner to activate OMID.

    Declaration

    Objective-C

    - (BOOL)activate;

    Swift

    func activate() -> Bool