OTVSSPLicenseDelegate
public class OTVSSPLicenseDelegate : OTVCommonLicenseDelegate
OTVSSPLicenseDelegate is a default implementation of SSP with SSM Service.
-
Creates an instance of
OTVSSPLicenceDelegate.Declaration
Swift
@objc public init(certificateURL: URL, licenseURL: URL, ssmServerURL: URL? = nil, syncSSMSetupTeardown: Bool = true)Parameters
certificateURLURL of certificate file.
licenseURLURL of license request.
ssmServerURLOptional URL of SSM service request. Default is nil if SSM service not required.
syncSSMSetupTeardownIf ssmServerURL is provided this defines whether the setup and teardown network requests block the main thread or not. Default is to block.
-
Overrided function to pass HTTP header for license request. It is based on the setStream(token:with:) to generate SSP required headers.
Declaration
Swift
@objc override public func generateHTTPHeaders(assetID: String) -> [String : String]? -
Set the token and the url which associated with the stream.
Declaration
Swift
@objc public func setStream(token: OTVMediaToken, with url: URL, success: @escaping () -> Void = { /* Default Empty Closure */ }, failure: @escaping () -> Void = { /* Default Empty Closure */ })Parameters
tokenthe stream’s SSP specific media token.
urlURL of the stream.
successclosure for when the stream token and url are sucessfully set. Default to empty.
failureclosure for when the stream token and url fail to be set. Default to empty.
OTVSSPLicenseDelegate Class Reference