Interface Downloader.ModelReadyCallback

Enclosing class:
Downloader

public static interface Downloader.ModelReadyCallback
Callback that is triggered after a Manifest URL was parsed and a model can be generated from the list of available tracks and qualities, see DownloadServiceBinder.prepareDownload(android.content.Context, android.os.Bundle, com.castlabs.sdk.downloader.Downloader.ModelReadyCallback)
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Called when an error occurred while loading the manifest or preparing the data
    void
    Called with the current download model.
  • Method Details

    • onError

      void onError(@NonNull Exception e)
      Called when an error occurred while loading the manifest or preparing the data
      Parameters:
      e - The source error or the CastlabsPlayerException whenever the PlayerSDK.init(Context) failed.
    • onModelAvailable

      void onModelAvailable(@NonNull Download download)
      Called with the current download model. The model contains video qualities, audio tracks, and subtitle tracks and implementations need to select which of these tracks should be downloaded.
      Parameters:
      download - The download