GoogleDAI_Objc

@objc(THEOplayerGoogleDAI)
public protocol GoogleDAI_Objc

Represents information regarding content with dynamically inserted advertisements.

  • Converts stream time (including ads) to content time (excluding ads). For livestreams no conversion is done and the stream time parameter is returned.

    Declaration

    Swift

    @objc(contentTimeFromStreamTime:)
    func contentTime(from streamTime: Double) -> Double

    Parameters

    streamTime

    The point in time of your stream including ads.

    Return Value

    The point in time of your content without ads.

  • Converts content time (excluding ads) to stream time (including ads) For livestreams no conversion is done and the content time parameter is returned.

    Declaration

    Swift

    @objc(streamTimeFromContentTime:)
    func streamTime(from contentTime: Double) -> Double

    Parameters

    contentTime

    The point in time of your content without ads.

    Return Value

    The point in time of your stream including ads.

  • Requests whether snapback is enabled.

    Declaration

    Swift

    @objc(requestSnapBack:)
    func requestSnapBack_Objc(completionHandler: @escaping (Bool, Error?) -> Void)

    Parameters

    completionHandler

    A closure to invoke when the operation completes or fails.

  • Enable/disable snapback.

    Declaration

    Swift

    @objc(setSnapBack:completion:)
    func setSnapBack_Objc(_ newValue: Bool, completionHandler: ((Bool, Error?) -> Void)?)

    Parameters

    completionHandler

    An optional closure to invoke when the operation completes or fails.