Commit 8dcd1e53 by olly Committed by Oliver Woodman

Remove or suppress warnings where we use our own deprecated APIs

PiperOrigin-RevId: 277928790
parent 07e93c15
...@@ -278,6 +278,7 @@ public final class ExoPlayerFactory { ...@@ -278,6 +278,7 @@ public final class ExoPlayerFactory {
* be passed to {@link SimpleExoPlayer.Builder} and should instead be injected into the {@link * be passed to {@link SimpleExoPlayer.Builder} and should instead be injected into the {@link
* MediaSource} factories. * MediaSource} factories.
*/ */
@SuppressWarnings("deprecation")
@Deprecated @Deprecated
public static SimpleExoPlayer newSimpleInstance( public static SimpleExoPlayer newSimpleInstance(
Context context, Context context,
......
...@@ -253,6 +253,7 @@ public class DefaultDrmSessionManager<T extends ExoMediaCrypto> ...@@ -253,6 +253,7 @@ public class DefaultDrmSessionManager<T extends ExoMediaCrypto>
* to {@link ExoMediaDrm#getKeyRequest(byte[], List, int, HashMap)}. May be null. * to {@link ExoMediaDrm#getKeyRequest(byte[], List, int, HashMap)}. May be null.
* @deprecated Use {@link Builder} instead. * @deprecated Use {@link Builder} instead.
*/ */
@SuppressWarnings("deprecation")
@Deprecated @Deprecated
public DefaultDrmSessionManager( public DefaultDrmSessionManager(
UUID uuid, UUID uuid,
......
...@@ -21,7 +21,6 @@ import com.google.android.exoplayer2.upstream.DataSink; ...@@ -21,7 +21,6 @@ import com.google.android.exoplayer2.upstream.DataSink;
import com.google.android.exoplayer2.upstream.DataSource; import com.google.android.exoplayer2.upstream.DataSource;
import com.google.android.exoplayer2.upstream.DummyDataSource; import com.google.android.exoplayer2.upstream.DummyDataSource;
import com.google.android.exoplayer2.upstream.FileDataSource; import com.google.android.exoplayer2.upstream.FileDataSource;
import com.google.android.exoplayer2.upstream.FileDataSourceFactory;
import com.google.android.exoplayer2.upstream.PriorityDataSourceFactory; import com.google.android.exoplayer2.upstream.PriorityDataSourceFactory;
import com.google.android.exoplayer2.upstream.cache.Cache; import com.google.android.exoplayer2.upstream.cache.Cache;
import com.google.android.exoplayer2.upstream.cache.CacheDataSink; import com.google.android.exoplayer2.upstream.cache.CacheDataSink;
...@@ -60,7 +59,8 @@ public final class DownloaderConstructorHelper { ...@@ -60,7 +59,8 @@ public final class DownloaderConstructorHelper {
* @param upstreamFactory A {@link DataSource.Factory} for creating {@link DataSource}s for * @param upstreamFactory A {@link DataSource.Factory} for creating {@link DataSource}s for
* downloading data. * downloading data.
* @param cacheReadDataSourceFactory A {@link DataSource.Factory} for creating {@link DataSource}s * @param cacheReadDataSourceFactory A {@link DataSource.Factory} for creating {@link DataSource}s
* for reading data from the cache. If null then a {@link FileDataSourceFactory} will be used. * for reading data from the cache. If null then a {@link FileDataSource.Factory} will be
* used.
* @param cacheWriteDataSinkFactory A {@link DataSink.Factory} for creating {@link DataSource}s * @param cacheWriteDataSinkFactory A {@link DataSink.Factory} for creating {@link DataSource}s
* for writing data to the cache. If null then a {@link CacheDataSinkFactory} will be used. * for writing data to the cache. If null then a {@link CacheDataSinkFactory} will be used.
* @param priorityTaskManager A {@link PriorityTaskManager} to use when downloading. If non-null, * @param priorityTaskManager A {@link PriorityTaskManager} to use when downloading. If non-null,
...@@ -87,7 +87,8 @@ public final class DownloaderConstructorHelper { ...@@ -87,7 +87,8 @@ public final class DownloaderConstructorHelper {
* @param upstreamFactory A {@link DataSource.Factory} for creating {@link DataSource}s for * @param upstreamFactory A {@link DataSource.Factory} for creating {@link DataSource}s for
* downloading data. * downloading data.
* @param cacheReadDataSourceFactory A {@link DataSource.Factory} for creating {@link DataSource}s * @param cacheReadDataSourceFactory A {@link DataSource.Factory} for creating {@link DataSource}s
* for reading data from the cache. If null then a {@link FileDataSourceFactory} will be used. * for reading data from the cache. If null then a {@link FileDataSource.Factory} will be
* used.
* @param cacheWriteDataSinkFactory A {@link DataSink.Factory} for creating {@link DataSource}s * @param cacheWriteDataSinkFactory A {@link DataSink.Factory} for creating {@link DataSource}s
* for writing data to the cache. If null then a {@link CacheDataSinkFactory} will be used. * for writing data to the cache. If null then a {@link CacheDataSinkFactory} will be used.
* @param priorityTaskManager A {@link PriorityTaskManager} to use when downloading. If non-null, * @param priorityTaskManager A {@link PriorityTaskManager} to use when downloading. If non-null,
......
...@@ -113,7 +113,6 @@ public final class DefaultDataSource implements DataSource { ...@@ -113,7 +113,6 @@ public final class DefaultDataSource implements DataSource {
context, context,
new DefaultHttpDataSource( new DefaultHttpDataSource(
userAgent, userAgent,
/* contentTypePredicate= */ null,
connectTimeoutMillis, connectTimeoutMillis,
readTimeoutMillis, readTimeoutMillis,
allowCrossProtocolRedirects, allowCrossProtocolRedirects,
......
...@@ -49,8 +49,8 @@ import java.util.zip.GZIPInputStream; ...@@ -49,8 +49,8 @@ import java.util.zip.GZIPInputStream;
* *
* <p>By default this implementation will not follow cross-protocol redirects (i.e. redirects from * <p>By default this implementation will not follow cross-protocol redirects (i.e. redirects from
* HTTP to HTTPS or vice versa). Cross-protocol redirects can be enabled by using the {@link * HTTP to HTTPS or vice versa). Cross-protocol redirects can be enabled by using the {@link
* #DefaultHttpDataSource(String, Predicate, int, int, boolean, RequestProperties)} constructor and * #DefaultHttpDataSource(String, int, int, boolean, RequestProperties)} constructor and passing
* passing {@code true} as the second last argument. * {@code true} for the {@code allowCrossProtocolRedirects} argument.
* *
* <p>Note: HTTP request headers will be set using all parameters passed via (in order of decreasing * <p>Note: HTTP request headers will be set using all parameters passed via (in order of decreasing
* priority) the {@code dataSpec}, {@link #setRequestProperty} and the default parameters used to * priority) the {@code dataSpec}, {@link #setRequestProperty} and the default parameters used to
...@@ -171,6 +171,7 @@ public class DefaultHttpDataSource extends BaseDataSource implements HttpDataSou ...@@ -171,6 +171,7 @@ public class DefaultHttpDataSource extends BaseDataSource implements HttpDataSou
* @deprecated Use {@link #DefaultHttpDataSource(String, int, int)} and {@link * @deprecated Use {@link #DefaultHttpDataSource(String, int, int)} and {@link
* #setContentTypePredicate(Predicate)}. * #setContentTypePredicate(Predicate)}.
*/ */
@SuppressWarnings("deprecation")
@Deprecated @Deprecated
public DefaultHttpDataSource( public DefaultHttpDataSource(
String userAgent, String userAgent,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment