Class OkHttpDataSourceFactory
- java.lang.Object
-
- com.google.android.exoplayer2.upstream.HttpDataSource.BaseFactory
-
- com.google.android.exoplayer2.ext.okhttp.OkHttpDataSourceFactory
-
- All Implemented Interfaces:
DataSource.Factory,HttpDataSource.Factory
@Deprecated public final class OkHttpDataSourceFactory extends HttpDataSource.BaseFactory
Deprecated.UseOkHttpDataSource.Factoryinstead.
-
-
Constructor Summary
Constructors Constructor Description OkHttpDataSourceFactory(okhttp3.Call.Factory callFactory)Deprecated.Creates an instance.OkHttpDataSourceFactory(okhttp3.Call.Factory callFactory, String userAgent)Deprecated.Creates an instance.OkHttpDataSourceFactory(okhttp3.Call.Factory callFactory, String userAgent, TransferListener listener)Deprecated.Creates an instance.OkHttpDataSourceFactory(okhttp3.Call.Factory callFactory, String userAgent, TransferListener listener, okhttp3.CacheControl cacheControl)Deprecated.Creates an instance.OkHttpDataSourceFactory(okhttp3.Call.Factory callFactory, String userAgent, okhttp3.CacheControl cacheControl)Deprecated.Creates an instance.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description protected OkHttpDataSourcecreateDataSourceInternal(HttpDataSource.RequestProperties defaultRequestProperties)Deprecated.Called byHttpDataSource.BaseFactory.createDataSource()to create aHttpDataSourceinstance.-
Methods inherited from class com.google.android.exoplayer2.upstream.HttpDataSource.BaseFactory
createDataSource, setDefaultRequestProperties
-
-
-
-
Constructor Detail
-
OkHttpDataSourceFactory
public OkHttpDataSourceFactory(okhttp3.Call.Factory callFactory)
Deprecated.Creates an instance.- Parameters:
callFactory- ACall.Factory(typically anOkHttpClient) for use by the sources created by the factory.
-
OkHttpDataSourceFactory
public OkHttpDataSourceFactory(okhttp3.Call.Factory callFactory, @Nullable String userAgent)Deprecated.Creates an instance.- Parameters:
callFactory- ACall.Factory(typically anOkHttpClient) for use by the sources created by the factory.userAgent- An optional User-Agent string.
-
OkHttpDataSourceFactory
public OkHttpDataSourceFactory(okhttp3.Call.Factory callFactory, @Nullable String userAgent, @Nullable okhttp3.CacheControl cacheControl)Deprecated.Creates an instance.- Parameters:
callFactory- ACall.Factory(typically anOkHttpClient) for use by the sources created by the factory.userAgent- An optional User-Agent string.cacheControl- An optionalCacheControlfor setting the Cache-Control header.
-
OkHttpDataSourceFactory
public OkHttpDataSourceFactory(okhttp3.Call.Factory callFactory, @Nullable String userAgent, @Nullable TransferListener listener)Deprecated.Creates an instance.- Parameters:
callFactory- ACall.Factory(typically anOkHttpClient) for use by the sources created by the factory.userAgent- An optional User-Agent string.listener- An optional listener.
-
OkHttpDataSourceFactory
public OkHttpDataSourceFactory(okhttp3.Call.Factory callFactory, @Nullable String userAgent, @Nullable TransferListener listener, @Nullable okhttp3.CacheControl cacheControl)Deprecated.Creates an instance.- Parameters:
callFactory- ACall.Factory(typically anOkHttpClient) for use by the sources created by the factory.userAgent- An optional User-Agent string.listener- An optional listener.cacheControl- An optionalCacheControlfor setting the Cache-Control header.
-
-
Method Detail
-
createDataSourceInternal
protected OkHttpDataSource createDataSourceInternal(HttpDataSource.RequestProperties defaultRequestProperties)
Deprecated.Description copied from class:HttpDataSource.BaseFactoryCalled byHttpDataSource.BaseFactory.createDataSource()to create aHttpDataSourceinstance.- Specified by:
createDataSourceInternalin classHttpDataSource.BaseFactory- Parameters:
defaultRequestProperties- The defaultRequestPropertiesto be used by theHttpDataSourceinstance.- Returns:
- A
HttpDataSourceinstance.
-
-