OfflineContentManager
Provides the means to download and store sources locally that can be played back with a Player without an active network connection. An OfflineContentManager instance can be created via the OfflineContentManager.getOfflineContentManager function.
The OfflineContentManager emits OfflineEvents during its lifecycle. See EventEmitter on how to subscribe to events.
Functions
Downloads the offline license. When finished successfully OfflineContentManagerListener.onDrmLicenseUpdated will be called. Errors are transmitted by a OfflineContentManagerListener.onError call and an OfflineEvent.Error event.
Loads the current OfflineContentOptions and passes them to OfflineContentManagerListener.onOptionsAvailable.
Enqueues downloads and deletions according to the current OfflineOptionEntryState and OfflineOptionEntryAction of the OfflineOptionEntry in the OfflineContentOptions.
Releases the memory resources. IMPORTANT: Call this when the Activity/Context, in which it was created, is destroy. The OfflineContentManager should not be used after calling this method.
Releases the currently held offline license. When finished successfully OfflineContentManagerListener.onDrmLicenseUpdated will be called. Errors are transmitted by a OfflineContentManagerListener.onError call and an OfflineEvent.Error event.
Renews the already downloaded DRM license. When successfully finished OfflineContentManagerListener.onDrmLicenseUpdated will be called. Errors are transmitted by a OfflineContentManagerListener.onError call and an OfflineEvent.Error event.
Properties
Creates an OfflineSourceConfig, which can be used to play the offline content with a Player or returns null, if no offline content is available.
A DrmLicenseInformation object containing the remaining drm license duration and the remaining playback duration. Throws an IOException if the loading of the DRM key fails. Throws an UnsupportedDrmException if the provided DRM technology is not supported. Throws a DrmSessionException if the DRM licensing call to the server fails
Returns how many bytes of storage are used by the offline content.