OTVPersistenceManager
final public class OTVPersistenceManager : NSObject
OTVPersistenceManager is a singleton that manages all download related functionality.
It utilises OTVDownloadingAssetManager for outstanding downloads and OTVAssetsManager for
completed downloads.
-
Persistence Manager singleton instance.
Declaration
Swift
@objc public static let shared: OTVPersistenceManager -
Declaration
Swift
@objc(startDownloadWithUrlAsset:title:licenseDelegate:artwork:options:) public func startDownload(urlAsset: AVURLAsset, title: String, licenseDelegate: OTVLicenseDelegate?, artwork: Data?, options: [String : Any]? = nil) -> OTVPersistenceAsset? -
Return downloading and downloaded assets.
Declaration
Swift
@objc public func getDownloads() -> [OTVPersistenceAsset]? -
Pause the downloading of assigned asset
Declaration
Swift
@objc public func pauseDownload(asset: OTVPersistenceAsset) -> BoolParameters
assetthe asset to be paused.
-
Resume the paused downloading asset
Declaration
Swift
@objc public func resumeDownload(asset: OTVPersistenceAsset) -> BoolParameters
assetthe asset to be resumed.
-
Cancel or remove the asset
Declaration
Swift
@objc public func deleteDownload(asset: OTVPersistenceAsset) -> BoolParameters
assetthe asset to be cancelled or removed.
-
Extends
See moreOTVPersistenceManagerto define a number of values to use as keys in dictionary options.Declaration
Swift
public struct Keys
OTVPersistenceManager Class Reference