Java Code Examples for com.google.android.exoplayer2.upstream.DefaultLoadErrorHandlingPolicy#DEFAULT_MIN_LOADABLE_RETRY_COUNT

The following examples show how to use com.google.android.exoplayer2.upstream.DefaultLoadErrorHandlingPolicy#DEFAULT_MIN_LOADABLE_RETRY_COUNT . You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: DashMediaSource.java    From MediaSDK with Apache License 2.0 6 votes vote down vote up
/**
 * Constructs an instance to play the manifest at a given {@link Uri}, which may be dynamic or
 * static.
 *
 * @param manifestUri The manifest {@link Uri}.
 * @param manifestDataSourceFactory A factory for {@link DataSource} instances that will be used
 *     to load (and refresh) the manifest.
 * @param chunkSourceFactory A factory for {@link DashChunkSource} instances.
 * @param eventHandler A handler for events. May be null if delivery of events is not required.
 * @param eventListener A listener of events. May be null if delivery of events is not required.
 * @deprecated Use {@link Factory} instead.
 */
@Deprecated
@SuppressWarnings("deprecation")
public DashMediaSource(
    Uri manifestUri,
    DataSource.Factory manifestDataSourceFactory,
    DashChunkSource.Factory chunkSourceFactory,
    @Nullable Handler eventHandler,
    @Nullable MediaSourceEventListener eventListener) {
  this(
      manifestUri,
      manifestDataSourceFactory,
      chunkSourceFactory,
      DefaultLoadErrorHandlingPolicy.DEFAULT_MIN_LOADABLE_RETRY_COUNT,
      DEFAULT_LIVE_PRESENTATION_DELAY_PREFER_MANIFEST_MS,
      eventHandler,
      eventListener);
}
 
Example 2
Source File: SsMediaSource.java    From MediaSDK with Apache License 2.0 6 votes vote down vote up
/**
 * Constructs an instance to play the manifest at a given {@link Uri}, which may be live or
 * on-demand.
 *
 * @param manifestUri The manifest {@link Uri}.
 * @param manifestDataSourceFactory A factory for {@link DataSource} instances that will be used
 *     to load (and refresh) the manifest.
 * @param chunkSourceFactory A factory for {@link SsChunkSource} instances.
 * @param eventHandler A handler for events. May be null if delivery of events is not required.
 * @param eventListener A listener of events. May be null if delivery of events is not required.
 * @deprecated Use {@link Factory} instead.
 */
@Deprecated
@SuppressWarnings("deprecation")
public SsMediaSource(
    Uri manifestUri,
    DataSource.Factory manifestDataSourceFactory,
    SsChunkSource.Factory chunkSourceFactory,
    @Nullable Handler eventHandler,
    @Nullable MediaSourceEventListener eventListener) {
  this(
      manifestUri,
      manifestDataSourceFactory,
      chunkSourceFactory,
      DefaultLoadErrorHandlingPolicy.DEFAULT_MIN_LOADABLE_RETRY_COUNT,
      DEFAULT_LIVE_PRESENTATION_DELAY_MS,
      eventHandler,
      eventListener);
}
 
Example 3
Source File: DashMediaSource.java    From Telegram-FOSS with GNU General Public License v2.0 6 votes vote down vote up
/**
 * Constructs an instance to play the manifest at a given {@link Uri}, which may be dynamic or
 * static.
 *
 * @param manifestUri The manifest {@link Uri}.
 * @param manifestDataSourceFactory A factory for {@link DataSource} instances that will be used
 *     to load (and refresh) the manifest.
 * @param chunkSourceFactory A factory for {@link DashChunkSource} instances.
 * @param eventHandler A handler for events. May be null if delivery of events is not required.
 * @param eventListener A listener of events. May be null if delivery of events is not required.
 * @deprecated Use {@link Factory} instead.
 */
@Deprecated
@SuppressWarnings("deprecation")
public DashMediaSource(
    Uri manifestUri,
    DataSource.Factory manifestDataSourceFactory,
    DashChunkSource.Factory chunkSourceFactory,
    Handler eventHandler,
    MediaSourceEventListener eventListener) {
  this(
      manifestUri,
      manifestDataSourceFactory,
      chunkSourceFactory,
      DefaultLoadErrorHandlingPolicy.DEFAULT_MIN_LOADABLE_RETRY_COUNT,
      DEFAULT_LIVE_PRESENTATION_DELAY_PREFER_MANIFEST_MS,
      eventHandler,
      eventListener);
}
 
Example 4
Source File: SsMediaSource.java    From Telegram-FOSS with GNU General Public License v2.0 6 votes vote down vote up
/**
 * Constructs an instance to play the manifest at a given {@link Uri}, which may be live or
 * on-demand.
 *
 * @param manifestUri The manifest {@link Uri}.
 * @param manifestDataSourceFactory A factory for {@link DataSource} instances that will be used
 *     to load (and refresh) the manifest.
 * @param chunkSourceFactory A factory for {@link SsChunkSource} instances.
 * @param eventHandler A handler for events. May be null if delivery of events is not required.
 * @param eventListener A listener of events. May be null if delivery of events is not required.
 * @deprecated Use {@link Factory} instead.
 */
@Deprecated
@SuppressWarnings("deprecation")
public SsMediaSource(
    Uri manifestUri,
    DataSource.Factory manifestDataSourceFactory,
    SsChunkSource.Factory chunkSourceFactory,
    Handler eventHandler,
    MediaSourceEventListener eventListener) {
  this(
      manifestUri,
      manifestDataSourceFactory,
      chunkSourceFactory,
      DefaultLoadErrorHandlingPolicy.DEFAULT_MIN_LOADABLE_RETRY_COUNT,
      DEFAULT_LIVE_PRESENTATION_DELAY_MS,
      eventHandler,
      eventListener);
}
 
Example 5
Source File: DashMediaSource.java    From Telegram with GNU General Public License v2.0 6 votes vote down vote up
/**
 * Constructs an instance to play the manifest at a given {@link Uri}, which may be dynamic or
 * static.
 *
 * @param manifestUri The manifest {@link Uri}.
 * @param manifestDataSourceFactory A factory for {@link DataSource} instances that will be used
 *     to load (and refresh) the manifest.
 * @param chunkSourceFactory A factory for {@link DashChunkSource} instances.
 * @param eventHandler A handler for events. May be null if delivery of events is not required.
 * @param eventListener A listener of events. May be null if delivery of events is not required.
 * @deprecated Use {@link Factory} instead.
 */
@Deprecated
@SuppressWarnings("deprecation")
public DashMediaSource(
    Uri manifestUri,
    DataSource.Factory manifestDataSourceFactory,
    DashChunkSource.Factory chunkSourceFactory,
    Handler eventHandler,
    MediaSourceEventListener eventListener) {
  this(
      manifestUri,
      manifestDataSourceFactory,
      chunkSourceFactory,
      DefaultLoadErrorHandlingPolicy.DEFAULT_MIN_LOADABLE_RETRY_COUNT,
      DEFAULT_LIVE_PRESENTATION_DELAY_PREFER_MANIFEST_MS,
      eventHandler,
      eventListener);
}
 
Example 6
Source File: SsMediaSource.java    From Telegram with GNU General Public License v2.0 6 votes vote down vote up
/**
 * Constructs an instance to play the manifest at a given {@link Uri}, which may be live or
 * on-demand.
 *
 * @param manifestUri The manifest {@link Uri}.
 * @param manifestDataSourceFactory A factory for {@link DataSource} instances that will be used
 *     to load (and refresh) the manifest.
 * @param chunkSourceFactory A factory for {@link SsChunkSource} instances.
 * @param eventHandler A handler for events. May be null if delivery of events is not required.
 * @param eventListener A listener of events. May be null if delivery of events is not required.
 * @deprecated Use {@link Factory} instead.
 */
@Deprecated
@SuppressWarnings("deprecation")
public SsMediaSource(
    Uri manifestUri,
    DataSource.Factory manifestDataSourceFactory,
    SsChunkSource.Factory chunkSourceFactory,
    Handler eventHandler,
    MediaSourceEventListener eventListener) {
  this(
      manifestUri,
      manifestDataSourceFactory,
      chunkSourceFactory,
      DefaultLoadErrorHandlingPolicy.DEFAULT_MIN_LOADABLE_RETRY_COUNT,
      DEFAULT_LIVE_PRESENTATION_DELAY_MS,
      eventHandler,
      eventListener);
}
 
Example 7
Source File: SingleSampleMediaSource.java    From MediaSDK with Apache License 2.0 5 votes vote down vote up
/**
 * @param uri The {@link Uri} of the media stream.
 * @param dataSourceFactory The factory from which the {@link DataSource} to read the media will
 *     be obtained.
 * @param format The {@link Format} associated with the output track.
 * @param durationUs The duration of the media stream in microseconds.
 * @deprecated Use {@link Factory} instead.
 */
@Deprecated
@SuppressWarnings("deprecation")
public SingleSampleMediaSource(
    Uri uri, DataSource.Factory dataSourceFactory, Format format, long durationUs) {
  this(
      uri,
      dataSourceFactory,
      format,
      durationUs,
      DefaultLoadErrorHandlingPolicy.DEFAULT_MIN_LOADABLE_RETRY_COUNT);
}
 
Example 8
Source File: DashMediaSource.java    From MediaSDK with Apache License 2.0 5 votes vote down vote up
/**
 * Constructs an instance to play a given {@link DashManifest}, which must be static.
 *
 * @param manifest The manifest. {@link DashManifest#dynamic} must be false.
 * @param chunkSourceFactory A factory for {@link DashChunkSource} instances.
 * @param eventHandler A handler for events. May be null if delivery of events is not required.
 * @param eventListener A listener of events. May be null if delivery of events is not required.
 * @deprecated Use {@link Factory} instead.
 */
@Deprecated
@SuppressWarnings("deprecation")
public DashMediaSource(
    DashManifest manifest,
    DashChunkSource.Factory chunkSourceFactory,
    @Nullable Handler eventHandler,
    @Nullable MediaSourceEventListener eventListener) {
  this(
      manifest,
      chunkSourceFactory,
      DefaultLoadErrorHandlingPolicy.DEFAULT_MIN_LOADABLE_RETRY_COUNT,
      eventHandler,
      eventListener);
}
 
Example 9
Source File: SsMediaSource.java    From MediaSDK with Apache License 2.0 5 votes vote down vote up
/**
 * Constructs an instance to play a given {@link SsManifest}, which must not be live.
 *
 * @param manifest The manifest. {@link SsManifest#isLive} must be false.
 * @param chunkSourceFactory A factory for {@link SsChunkSource} instances.
 * @param eventHandler A handler for events. May be null if delivery of events is not required.
 * @param eventListener A listener of events. May be null if delivery of events is not required.
 * @deprecated Use {@link Factory} instead.
 */
@Deprecated
@SuppressWarnings("deprecation")
public SsMediaSource(
    SsManifest manifest,
    SsChunkSource.Factory chunkSourceFactory,
    @Nullable Handler eventHandler,
    @Nullable MediaSourceEventListener eventListener) {
  this(
      manifest,
      chunkSourceFactory,
      DefaultLoadErrorHandlingPolicy.DEFAULT_MIN_LOADABLE_RETRY_COUNT,
      eventHandler,
      eventListener);
}
 
Example 10
Source File: SingleSampleMediaSource.java    From Telegram-FOSS with GNU General Public License v2.0 5 votes vote down vote up
/**
 * @param uri The {@link Uri} of the media stream.
 * @param dataSourceFactory The factory from which the {@link DataSource} to read the media will
 *     be obtained.
 * @param format The {@link Format} associated with the output track.
 * @param durationUs The duration of the media stream in microseconds.
 * @deprecated Use {@link Factory} instead.
 */
@Deprecated
@SuppressWarnings("deprecation")
public SingleSampleMediaSource(
    Uri uri, DataSource.Factory dataSourceFactory, Format format, long durationUs) {
  this(
      uri,
      dataSourceFactory,
      format,
      durationUs,
      DefaultLoadErrorHandlingPolicy.DEFAULT_MIN_LOADABLE_RETRY_COUNT);
}
 
Example 11
Source File: DashMediaSource.java    From Telegram-FOSS with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Constructs an instance to play a given {@link DashManifest}, which must be static.
 *
 * @param manifest The manifest. {@link DashManifest#dynamic} must be false.
 * @param chunkSourceFactory A factory for {@link DashChunkSource} instances.
 * @param eventHandler A handler for events. May be null if delivery of events is not required.
 * @param eventListener A listener of events. May be null if delivery of events is not required.
 * @deprecated Use {@link Factory} instead.
 */
@Deprecated
@SuppressWarnings("deprecation")
public DashMediaSource(
    DashManifest manifest,
    DashChunkSource.Factory chunkSourceFactory,
    Handler eventHandler,
    MediaSourceEventListener eventListener) {
  this(
      manifest,
      chunkSourceFactory,
      DefaultLoadErrorHandlingPolicy.DEFAULT_MIN_LOADABLE_RETRY_COUNT,
      eventHandler,
      eventListener);
}
 
Example 12
Source File: SsMediaSource.java    From Telegram-FOSS with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Constructs an instance to play a given {@link SsManifest}, which must not be live.
 *
 * @param manifest The manifest. {@link SsManifest#isLive} must be false.
 * @param chunkSourceFactory A factory for {@link SsChunkSource} instances.
 * @param eventHandler A handler for events. May be null if delivery of events is not required.
 * @param eventListener A listener of events. May be null if delivery of events is not required.
 * @deprecated Use {@link Factory} instead.
 */
@Deprecated
@SuppressWarnings("deprecation")
public SsMediaSource(
    SsManifest manifest,
    SsChunkSource.Factory chunkSourceFactory,
    Handler eventHandler,
    MediaSourceEventListener eventListener) {
  this(
      manifest,
      chunkSourceFactory,
      DefaultLoadErrorHandlingPolicy.DEFAULT_MIN_LOADABLE_RETRY_COUNT,
      eventHandler,
      eventListener);
}
 
Example 13
Source File: SingleSampleMediaSource.java    From Telegram with GNU General Public License v2.0 5 votes vote down vote up
/**
 * @param uri The {@link Uri} of the media stream.
 * @param dataSourceFactory The factory from which the {@link DataSource} to read the media will
 *     be obtained.
 * @param format The {@link Format} associated with the output track.
 * @param durationUs The duration of the media stream in microseconds.
 * @deprecated Use {@link Factory} instead.
 */
@Deprecated
@SuppressWarnings("deprecation")
public SingleSampleMediaSource(
    Uri uri, DataSource.Factory dataSourceFactory, Format format, long durationUs) {
  this(
      uri,
      dataSourceFactory,
      format,
      durationUs,
      DefaultLoadErrorHandlingPolicy.DEFAULT_MIN_LOADABLE_RETRY_COUNT);
}
 
Example 14
Source File: DashMediaSource.java    From Telegram with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Constructs an instance to play a given {@link DashManifest}, which must be static.
 *
 * @param manifest The manifest. {@link DashManifest#dynamic} must be false.
 * @param chunkSourceFactory A factory for {@link DashChunkSource} instances.
 * @param eventHandler A handler for events. May be null if delivery of events is not required.
 * @param eventListener A listener of events. May be null if delivery of events is not required.
 * @deprecated Use {@link Factory} instead.
 */
@Deprecated
@SuppressWarnings("deprecation")
public DashMediaSource(
    DashManifest manifest,
    DashChunkSource.Factory chunkSourceFactory,
    Handler eventHandler,
    MediaSourceEventListener eventListener) {
  this(
      manifest,
      chunkSourceFactory,
      DefaultLoadErrorHandlingPolicy.DEFAULT_MIN_LOADABLE_RETRY_COUNT,
      eventHandler,
      eventListener);
}
 
Example 15
Source File: SsMediaSource.java    From Telegram with GNU General Public License v2.0 5 votes vote down vote up
/**
 * Constructs an instance to play a given {@link SsManifest}, which must not be live.
 *
 * @param manifest The manifest. {@link SsManifest#isLive} must be false.
 * @param chunkSourceFactory A factory for {@link SsChunkSource} instances.
 * @param eventHandler A handler for events. May be null if delivery of events is not required.
 * @param eventListener A listener of events. May be null if delivery of events is not required.
 * @deprecated Use {@link Factory} instead.
 */
@Deprecated
@SuppressWarnings("deprecation")
public SsMediaSource(
    SsManifest manifest,
    SsChunkSource.Factory chunkSourceFactory,
    Handler eventHandler,
    MediaSourceEventListener eventListener) {
  this(
      manifest,
      chunkSourceFactory,
      DefaultLoadErrorHandlingPolicy.DEFAULT_MIN_LOADABLE_RETRY_COUNT,
      eventHandler,
      eventListener);
}