Back to Exoplayer

SplitParallelSampleBandwidthEstimator (ExoPlayer library)

docs/doc/reference/com/google/android/exoplayer2/upstream/experimental/SplitParallelSampleBandwidthEstimator.html

latest7.8 KB
Original Source

Package com.google.android.exoplayer2.upstream.experimental

Class SplitParallelSampleBandwidthEstimator

  • java.lang.Object

    • com.google.android.exoplayer2.upstream.experimental.SplitParallelSampleBandwidthEstimator
  • All Implemented Interfaces:BandwidthEstimator


[@Deprecated](https://developer.android.com/reference/java/lang/Deprecated.html "class or interface in java.lang")public classSplitParallelSampleBandwidthEstimatorextends[Object](https://developer.android.com/reference/java/lang/Object.html "class or interface in java.lang")implements[BandwidthEstimator](BandwidthEstimator.html "interface in com.google.android.exoplayer2.upstream.experimental")

Deprecated. com.google.android.exoplayer2 is deprecated. Please migrate to androidx.media3 (which contains the same ExoPlayer code). See the migration guide for more details, including a script to help with the migration.

A BandwidthEstimator that captures a transfer sample each time a transfer ends. When parallel transfers are happening at the same time, the transferred bytes are aggregated in a single sample.

Nested Class Summary

Nested Classes | Modifier and Type | Class | Description | | --- | --- | --- | | static class | SplitParallelSampleBandwidthEstimator.Builder | Deprecated.

A builder to create SplitParallelSampleBandwidthEstimator instances. |

Field Summary

- 

Fields inherited from interface com.google.android.exoplayer2.upstream.experimental.BandwidthEstimator

ESTIMATE_NOT_AVAILABLE

Method Summary

All Methods Instance Methods Concrete Methods Deprecated Methods | Modifier and Type | Method | Description | | --- | --- | --- | | void | addEventListener​(Handler eventHandler, BandwidthMeter.EventListener eventListener) | Deprecated.

Adds an BandwidthMeter.EventListener. | | long | getBandwidthEstimate() | Deprecated.

Returns the bandwidth estimate in bits per second, or BandwidthEstimator.ESTIMATE_NOT_AVAILABLE if there is no estimate available yet. | | void | onBytesTransferred​(DataSource source, int bytesTransferred) | Deprecated.

Called incrementally during a transfer. | | void | onNetworkTypeChange​(long newBandwidthEstimate) | Deprecated.

Notifies this estimator that a network change has been detected. | | void | onTransferEnd​(DataSource source) | Deprecated.

Called when a transfer ends. | | void | onTransferInitializing​(DataSource source) | Deprecated.

Called when a transfer is being initialized. | | void | onTransferStart​(DataSource source) | Deprecated.

Called when a transfer starts. | | void | removeEventListener​(BandwidthMeter.EventListener eventListener) | Deprecated.

Removes an BandwidthMeter.EventListener. |

- 

Methods inherited from class java.lang.Object

clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Method Detail

- 

addEventListener

public void addEventListener​([Handler](https://developer.android.com/reference/android/os/Handler.html "class or interface in android.os")eventHandler,[BandwidthMeter.EventListener](../BandwidthMeter.EventListener.html "interface in com.google.android.exoplayer2.upstream")eventListener)

Deprecated.

Description copied from interface: BandwidthEstimator

Adds an BandwidthMeter.EventListener. Specified by:addEventListener in interface BandwidthEstimatorParameters:eventHandler - A handler for events.eventListener - A listener of events.

- 

removeEventListener

public void removeEventListener​([BandwidthMeter.EventListener](../BandwidthMeter.EventListener.html "interface in com.google.android.exoplayer2.upstream")eventListener)

Deprecated.

Description copied from interface: BandwidthEstimator

Removes an BandwidthMeter.EventListener. Specified by:removeEventListener in interface BandwidthEstimatorParameters:eventListener - The listener to be removed.

- 

onTransferInitializing

public void onTransferInitializing​([DataSource](../DataSource.html "interface in com.google.android.exoplayer2.upstream")source)

Deprecated.

Description copied from interface: BandwidthEstimator

Called when a transfer is being initialized. Specified by:onTransferInitializing in interface BandwidthEstimatorParameters:source - The DataSource performing the transfer.

- 

onTransferStart

public void onTransferStart​([DataSource](../DataSource.html "interface in com.google.android.exoplayer2.upstream")source)

Deprecated.

Description copied from interface: BandwidthEstimator

Called when a transfer starts. Specified by:onTransferStart in interface BandwidthEstimatorParameters:source - The DataSource performing the transfer.

- 

onBytesTransferred

public void onBytesTransferred​([DataSource](../DataSource.html "interface in com.google.android.exoplayer2.upstream")source,
                               int bytesTransferred)

Deprecated.

Description copied from interface: BandwidthEstimator

Called incrementally during a transfer. Specified by:onBytesTransferred in interface BandwidthEstimatorParameters:source - The DataSource performing the transfer.bytesTransferred - The number of bytes transferred since the previous call to this method

- 

onTransferEnd

public void onTransferEnd​([DataSource](../DataSource.html "interface in com.google.android.exoplayer2.upstream")source)

Deprecated.

Description copied from interface: BandwidthEstimator

Called when a transfer ends. Specified by:onTransferEnd in interface BandwidthEstimatorParameters:source - The DataSource performing the transfer.

- 

getBandwidthEstimate

public long getBandwidthEstimate()

Deprecated.

Description copied from interface: BandwidthEstimator

Returns the bandwidth estimate in bits per second, or BandwidthEstimator.ESTIMATE_NOT_AVAILABLE if there is no estimate available yet. Specified by:getBandwidthEstimate in interface BandwidthEstimator

- 

onNetworkTypeChange

public void onNetworkTypeChange​(long newBandwidthEstimate)

Deprecated.

Description copied from interface: BandwidthEstimator

Notifies this estimator that a network change has been detected. Specified by:onNetworkTypeChange in interface BandwidthEstimatorParameters:newBandwidthEstimate - The new initial bandwidth estimate based on network type.