Package com.brightcove.player.offline
Interface MultiDataSource.ShortTtlHandler
- Enclosing class:
- MultiDataSource
public static interface MultiDataSource.ShortTtlHandler
Interface definition for handling
DataSpec
with an expired manifest URL.-
Method Summary
Modifier and TypeMethodDescriptionboolean
isExpired
(com.google.android.exoplayer2.upstream.DataSpec dataSpec) Returns true if the providedDataSpec
is expired.com.google.android.exoplayer2.upstream.DataSpec
refresh
(com.google.android.exoplayer2.upstream.DataSpec dataSpec) Attempt to refresh an expiredDataSpec
.
-
Method Details
-
isExpired
boolean isExpired(com.google.android.exoplayer2.upstream.DataSpec dataSpec) Returns true if the providedDataSpec
is expired.- Parameters:
dataSpec
- The DataSpec containing an URI.- Returns:
- True if the URI is no longer valid.
-
refresh
@Nullable com.google.android.exoplayer2.upstream.DataSpec refresh(com.google.android.exoplayer2.upstream.DataSpec dataSpec) Attempt to refresh an expiredDataSpec
.- Parameters:
dataSpec
- TheDataSpec
to refresh.- Returns:
- A new
DataSpec
or null if refreshing failed. - See Also:
-
DataSource.open(DataSpec)
-