docs/doc/reference/com/google/android/exoplayer2/analytics/PlaybackStats.html
Package com.google.android.exoplayer2.analytics
[@Deprecated](https://developer.android.com/reference/java/lang/Deprecated.html "class or interface in java.lang")public final classPlaybackStatsextends[Object](https://developer.android.com/reference/java/lang/Object.html "class or interface in java.lang")
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.
Statistics about playbacks.
Nested Classes | Modifier and Type | Class | Description |
| --- | --- | --- |
| static class | PlaybackStats.EventTimeAndException |
Deprecated.
Stores an exception with the event time at which it occurred.
|
| static class | PlaybackStats.EventTimeAndFormat |
Deprecated.
Stores a format with the event time at which it started being used, or null to indicate that no format was used.
|
| static class | PlaybackStats.EventTimeAndPlaybackState |
Deprecated.
Stores a playback state with the event time at which it became active. |
Fields | Modifier and Type | Field | Description |
| --- | --- | --- |
| int | abandonedBeforeReadyCount |
Deprecated.
The number of playbacks which were abandoned before they were ready to play.
|
| int | adPlaybackCount |
Deprecated.
The number of ad playbacks.
|
| List<PlaybackStats.EventTimeAndFormat> | audioFormatHistory |
Deprecated.
The audio format history as EventTimeAndFormats ordered by EventTime.realTimeMs.
|
| int | backgroundJoiningCount |
Deprecated.
The number of playbacks which were pre-buffered in the background.
|
| static PlaybackStats | EMPTY |
Deprecated.
Empty playback stats.
|
| int | endedCount |
Deprecated.
The number of playbacks which reached the ended state at least once.
|
| int | fatalErrorCount |
Deprecated.
The total number of fatal errors.
|
| List<PlaybackStats.EventTimeAndException> | fatalErrorHistory |
Deprecated.
The history of fatal errors as EventTimeAndExceptions ordered by EventTime.realTimeMs.
|
| int | fatalErrorPlaybackCount |
Deprecated.
The total number of playback with at least one fatal error.
|
| long | firstReportedTimeMs |
Deprecated.
The elapsed real-time as returned by SystemClock.elapsedRealtime() of the first reported playback event, or C.TIME_UNSET if no event has been reported.
|
| int | foregroundPlaybackCount |
Deprecated.
The number of playbacks which were the active foreground playback at some point.
|
| int | initialAudioFormatBitrateCount |
Deprecated.
The number of playbacks with initial audio format bitrate data.
|
| int | initialVideoFormatBitrateCount |
Deprecated.
The number of playbacks with initial video format bitrate data.
|
| int | initialVideoFormatHeightCount |
Deprecated.
The number of playbacks with initial video format height data.
|
| long | maxRebufferTimeMs |
Deprecated.
The maximum time spent during a single rebuffer, in milliseconds, or C.TIME_UNSET if no rebuffer occurred.
|
| List<long[]> | mediaTimeHistory |
Deprecated.
The media time history as an ordered list of long[2] arrays with [0] being the realtime as returned by SystemClock.elapsedRealtime() and [1] being the media time at this realtime, in milliseconds.
|
| int | nonFatalErrorCount |
Deprecated.
The total number of non-fatal errors.
|
| List<PlaybackStats.EventTimeAndException> | nonFatalErrorHistory |
Deprecated.
The history of non-fatal errors as EventTimeAndExceptions ordered by EventTime.realTimeMs.
|
| static int | PLAYBACK_STATE_ABANDONED |
Deprecated.
Playback is abandoned before reaching the end of the media.
|
| static int | PLAYBACK_STATE_BUFFERING |
Deprecated.
Playback is buffering to resume active playback.
|
| static int | PLAYBACK_STATE_ENDED |
Deprecated.
Playback has reached the end of the media.
|
| static int | PLAYBACK_STATE_FAILED |
Deprecated.
Playback is stopped due a fatal error and can be retried.
|
| static int | PLAYBACK_STATE_INTERRUPTED_BY_AD |
Deprecated.
Playback is interrupted by an ad.
|
| static int | PLAYBACK_STATE_JOINING_BACKGROUND |
Deprecated.
Playback is buffering in the background for initial playback start.
|
| static int | PLAYBACK_STATE_JOINING_FOREGROUND |
Deprecated.
Playback is buffering in the foreground for initial playback start.
|
| static int | PLAYBACK_STATE_NOT_STARTED |
Deprecated.
Playback has not started (initial state).
|
| static int | PLAYBACK_STATE_PAUSED |
Deprecated.
Playback is paused but ready to play.
|
| static int | PLAYBACK_STATE_PAUSED_BUFFERING |
Deprecated.
Playback is buffering while paused.
|
| static int | PLAYBACK_STATE_PLAYING |
Deprecated.
Playback is actively playing.
|
| static int | PLAYBACK_STATE_SEEKING |
Deprecated.
Playback is handling a seek.
|
| static int | PLAYBACK_STATE_STOPPED |
Deprecated.
Playback is stopped and can be restarted.
|
| static int | PLAYBACK_STATE_SUPPRESSED |
Deprecated.
Playback is suppressed (e.g.
|
| static int | PLAYBACK_STATE_SUPPRESSED_BUFFERING |
Deprecated.
Playback is suppressed (e.g.
|
| int | playbackCount |
Deprecated.
The number of individual playbacks for which these stats were collected.
|
| List<PlaybackStats.EventTimeAndPlaybackState> | playbackStateHistory |
Deprecated.
The playback state history as EventTimeAndPlaybackStates ordered by EventTime.realTimeMs.
|
| long | totalAudioFormatBitrateTimeProduct |
Deprecated.
The accumulated sum of all audio format bitrates, in bits per second, times the time the format was used for playback, in milliseconds.
|
| long | totalAudioFormatTimeMs |
Deprecated.
The total media time for which audio format data is available, in milliseconds.
|
| long | totalAudioUnderruns |
Deprecated.
The total number of audio underruns.
|
| long | totalBandwidthBytes |
Deprecated.
The total bytes transferred during totalBandwidthTimeMs.
|
| long | totalBandwidthTimeMs |
Deprecated.
The total time for which bandwidth measurement data is available, in milliseconds.
|
| long | totalDroppedFrames |
Deprecated.
The total number of dropped video frames.
|
| long | totalInitialAudioFormatBitrate |
Deprecated.
The total initial audio format bitrate for all playbacks, in bits per second, or C.LENGTH_UNSET if no initial audio format data is available.
|
| long | totalInitialVideoFormatBitrate |
Deprecated.
The total initial video format bitrate for all playbacks, in bits per second, or C.LENGTH_UNSET if no initial video format data is available.
|
| int | totalInitialVideoFormatHeight |
Deprecated.
The total initial video format height for all playbacks, in pixels, or C.LENGTH_UNSET if no initial video format data is available.
|
| int | totalPauseBufferCount |
Deprecated.
The total number of times a playback has been paused while rebuffering.
|
| int | totalPauseCount |
Deprecated.
The total number of times a playback has been paused.
|
| int | totalRebufferCount |
Deprecated.
The total number of times a rebuffer occurred.
|
| int | totalSeekCount |
Deprecated.
The total number of times a seek occurred.
|
| long | totalValidJoinTimeMs |
Deprecated.
The total time spent joining the playback, in milliseconds, or C.TIME_UNSET if no valid join time could be determined.
|
| long | totalVideoFormatBitrateTimeMs |
Deprecated.
The total media time for which video format bitrate data is available, in milliseconds.
|
| long | totalVideoFormatBitrateTimeProduct |
Deprecated.
The accumulated sum of all video format bitrates, in bits per second, times the time the format was used for playback, in milliseconds.
|
| long | totalVideoFormatHeightTimeMs |
Deprecated.
The total media time for which video format height data is available, in milliseconds.
|
| long | totalVideoFormatHeightTimeProduct |
Deprecated.
The accumulated sum of all video format heights, in pixels, times the time the format was used for playback, in milliseconds.
|
| int | validJoinTimeCount |
Deprecated.
The number of playbacks with a valid join time as documented in totalValidJoinTimeMs.
|
| List<PlaybackStats.EventTimeAndFormat> | videoFormatHistory |
Deprecated.
The video format history as EventTimeAndFormats ordered by EventTime.realTimeMs.
|
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods | Modifier and Type | Method | Description |
| --- | --- | --- |
| float | getAbandonedBeforeReadyRatio() |
Deprecated.
Returns the ratio of foreground playbacks which were abandoned before they were ready to play, or 0.0 if no playback has been in foreground.
|
| float | getAudioUnderrunRate() |
Deprecated.
Returns the mean rate at which audio underruns occurred, in underruns per play time second, or 0.0 if no time was spent playing.
|
| float | getDroppedFramesRate() |
Deprecated.
Returns the mean rate at which video frames are dropped, in dropped frames per play time second, or 0.0 if no time was spent playing.
|
| float | getEndedRatio() |
Deprecated.
Returns the ratio of foreground playbacks which reached the ended state at least once, or 0.0 if no playback has been in foreground.
|
| float | getFatalErrorRate() |
Deprecated.
Returns the rate of fatal errors, in errors per play time second, or 0.0 if no time was spend playing.
|
| float | getFatalErrorRatio() |
Deprecated.
Returns the ratio of foreground playbacks which experienced fatal errors, or 0.0 if no playback has been in foreground.
|
| float | getJoinTimeRatio() |
Deprecated.
Returns the ratio of foreground join time to the total time spent playing and waiting, or 0.0 if no time was spend playing or waiting.
|
| int | getMeanAudioFormatBitrate() |
Deprecated.
Returns the mean audio format bitrate, in bits per second, or C.LENGTH_UNSET if no audio format data is available.
|
| int | getMeanBandwidth() |
Deprecated.
Returns the mean network bandwidth based on transfer measurements, in bits per second, or C.LENGTH_UNSET if no transfer data is available.
|
| long | getMeanElapsedTimeMs() |
Deprecated.
Returns the mean time covered by any playback state per playback, in milliseconds, or C.TIME_UNSET if no playback was recorded.
|
| int | getMeanInitialAudioFormatBitrate() |
Deprecated.
Returns the mean initial audio format bitrate, in bits per second, or C.LENGTH_UNSET if no audio format data is available.
|
| int | getMeanInitialVideoFormatBitrate() |
Deprecated.
Returns the mean initial video format bitrate, in bits per second, or C.LENGTH_UNSET if no video format data is available.
|
| int | getMeanInitialVideoFormatHeight() |
Deprecated.
Returns the mean initial video format height, in pixels, or C.LENGTH_UNSET if no video format data is available.
|
| long | getMeanJoinTimeMs() |
Deprecated.
Returns the mean time spent joining the playback, in milliseconds, or C.TIME_UNSET if no valid join time is available.
|
| float | getMeanNonFatalErrorCount() |
Deprecated.
Returns the mean number of non-fatal errors per foreground playback, or 0.0 if no playback has been in foreground.
|
| float | getMeanPauseBufferCount() |
Deprecated.
Returns the mean number of times a playback has been paused while rebuffering per foreground playback, or 0.0 if no playback has been in foreground.
|
| float | getMeanPauseCount() |
Deprecated.
Returns the mean number of times a playback has been paused per foreground playback, or 0.0 if no playback has been in foreground.
|
| long | getMeanPausedTimeMs() |
Deprecated.
Returns the mean time spent in a paused state per foreground playback, in milliseconds, or C.TIME_UNSET if no playback has been in foreground.
|
| long | getMeanPlayAndWaitTimeMs() |
Deprecated.
Returns the mean time spent playing or actively waiting for playback per foreground playback, in milliseconds, or C.TIME_UNSET if no playback has been in foreground.
|
| long | getMeanPlayTimeMs() |
Deprecated.
Returns the mean time spent actively playing per foreground playback, in milliseconds, or C.TIME_UNSET if no playback has been in foreground.
|
| float | getMeanRebufferCount() |
Deprecated.
Returns the mean number of times a rebuffer occurred per foreground playback, or 0.0 if no playback has been in foreground.
|
| long | getMeanRebufferTimeMs() |
Deprecated.
Returns the mean time spent rebuffering per foreground playback, in milliseconds, or C.TIME_UNSET if no playback has been in foreground.
|
| float | getMeanSeekCount() |
Deprecated.
Returns the mean number of times a seek occurred per foreground playback, or 0.0 if no playback has been in foreground.
|
| long | getMeanSeekTimeMs() |
Deprecated.
Returns the mean time spent per foreground playback from the start of a seek until playback is ready again, in milliseconds, or C.TIME_UNSET if no playback has been in foreground.
|
| long | getMeanSingleRebufferTimeMs() |
Deprecated.
Returns the mean time spent during a single rebuffer, in milliseconds, or C.TIME_UNSET if no rebuffer was recorded.
|
| long | getMeanSingleSeekTimeMs() |
Deprecated.
Returns the mean time spent from the start of a single seek until playback is ready again, in milliseconds, or C.TIME_UNSET if no seek occurred.
|
| float | getMeanTimeBetweenFatalErrors() |
Deprecated.
Returns the mean play time between fatal errors, in seconds.
|
| float | getMeanTimeBetweenNonFatalErrors() |
Deprecated.
Returns the mean play time between non-fatal errors, in seconds.
|
| float | getMeanTimeBetweenRebuffers() |
Deprecated.
Returns the mean play time between rebuffer events, in seconds.
|
| int | getMeanVideoFormatBitrate() |
Deprecated.
Returns the mean video format bitrate, in bits per second, or C.LENGTH_UNSET if no video format data is available.
|
| int | getMeanVideoFormatHeight() |
Deprecated.
Returns the mean video format height, in pixels, or C.LENGTH_UNSET if no video format data is available.
|
| long | getMeanWaitTimeMs() |
Deprecated.
Returns the mean time spent actively waiting for playback per foreground playback, in milliseconds, or C.TIME_UNSET if no playback has been in foreground.
|
| long | getMediaTimeMsAtRealtimeMs(long realtimeMs) |
Deprecated.
Returns the estimated media time at the given realtime, in milliseconds, or C.TIME_UNSET if the media time history is unknown.
|
| float | getNonFatalErrorRate() |
Deprecated.
Returns the rate of non-fatal errors, in errors per play time second, or 0.0 if no time was spend playing.
|
| @com.google.android.exoplayer2.analytics.PlaybackStats.PlaybackState int | getPlaybackStateAtTime(long realtimeMs) |
Deprecated.
Returns the PlaybackStats.PlaybackState at the given time.
|
| long | getPlaybackStateDurationMs(@com.google.android.exoplayer2.analytics.PlaybackStats.PlaybackState int playbackState) |
Deprecated.
Returns the total time spent in a given PlaybackStats.PlaybackState, in milliseconds.
|
| float | getRebufferRate() |
Deprecated.
Returns the rate of rebuffer events, in rebuffers per play time second, or 0.0 if no time was spend playing.
|
| float | getRebufferTimeRatio() |
Deprecated.
Returns the ratio of rebuffer time to the total time spent playing and waiting, or 0.0 if no time was spend playing or waiting.
|
| float | getSeekTimeRatio() |
Deprecated.
Returns the ratio of seek time to the total time spent playing and waiting, or 0.0 if no time was spend playing or waiting.
|
| long | getTotalElapsedTimeMs() |
Deprecated.
Returns the total time covered by any playback state, in milliseconds.
|
| long | getTotalJoinTimeMs() |
Deprecated.
Returns the total time spent joining the playback in foreground, in milliseconds.
|
| long | getTotalPausedTimeMs() |
Deprecated.
Returns the total time spent in a paused state, in milliseconds.
|
| long | getTotalPlayAndWaitTimeMs() |
Deprecated.
Returns the total time spent playing or actively waiting for playback, in milliseconds.
|
| long | getTotalPlayTimeMs() |
Deprecated.
Returns the total time spent actively playing, in milliseconds.
|
| long | getTotalRebufferTimeMs() |
Deprecated.
Returns the total time spent rebuffering, in milliseconds.
|
| long | getTotalSeekTimeMs() |
Deprecated.
Returns the total time spent from the start of a seek until playback is ready again, in milliseconds.
|
| long | getTotalWaitTimeMs() |
Deprecated.
Returns the total time spent actively waiting for playback, in milliseconds.
|
| float | getWaitTimeRatio() |
Deprecated.
Returns the ratio of wait times to the total time spent playing and waiting, or 0.0 if no time was spend playing or waiting.
|
| static PlaybackStats | merge(PlaybackStats... playbackStats) |
Deprecated.
Returns the combined PlaybackStats for all input PlaybackStats.
|
-
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
public static final int PLAYBACK_STATE_NOT_STARTED
Deprecated.
Playback has not started (initial state). See Also:Constant Field Values
-
public static final int PLAYBACK_STATE_JOINING_BACKGROUND
Deprecated.
Playback is buffering in the background for initial playback start. See Also:Constant Field Values
-
public static final int PLAYBACK_STATE_JOINING_FOREGROUND
Deprecated.
Playback is buffering in the foreground for initial playback start. See Also:Constant Field Values
-
public static final int PLAYBACK_STATE_PLAYING
Deprecated.
Playback is actively playing. See Also:Constant Field Values
-
public static final int PLAYBACK_STATE_PAUSED
Deprecated.
Playback is paused but ready to play. See Also:Constant Field Values
-
public static final int PLAYBACK_STATE_SEEKING
Deprecated.
Playback is handling a seek. See Also:Constant Field Values
-
public static final int PLAYBACK_STATE_BUFFERING
Deprecated.
Playback is buffering to resume active playback. See Also:Constant Field Values
-
public static final int PLAYBACK_STATE_PAUSED_BUFFERING
Deprecated.
Playback is buffering while paused. See Also:Constant Field Values
-
public static final int PLAYBACK_STATE_SUPPRESSED
Deprecated.
Playback is suppressed (e.g. due to audio focus loss). See Also:Constant Field Values
-
public static final int PLAYBACK_STATE_SUPPRESSED_BUFFERING
Deprecated.
Playback is suppressed (e.g. due to audio focus loss) while buffering to resume a playback. See Also:Constant Field Values
-
public static final int PLAYBACK_STATE_ENDED
Deprecated.
Playback has reached the end of the media. See Also:Constant Field Values
-
public static final int PLAYBACK_STATE_STOPPED
Deprecated.
Playback is stopped and can be restarted. See Also:Constant Field Values
-
public static final int PLAYBACK_STATE_FAILED
Deprecated.
Playback is stopped due a fatal error and can be retried. See Also:Constant Field Values
-
public static final int PLAYBACK_STATE_INTERRUPTED_BY_AD
Deprecated.
Playback is interrupted by an ad. See Also:Constant Field Values
-
public static final int PLAYBACK_STATE_ABANDONED
Deprecated.
Playback is abandoned before reaching the end of the media. See Also:Constant Field Values
-
public static final[PlaybackStats](PlaybackStats.html "class in com.google.android.exoplayer2.analytics")EMPTY
Deprecated.
Empty playback stats.
-
public final int playbackCount
Deprecated.
The number of individual playbacks for which these stats were collected.
-
public final[List](https://developer.android.com/reference/java/util/List.html "class or interface in java.util")<[PlaybackStats.EventTimeAndPlaybackState](PlaybackStats.EventTimeAndPlaybackState.html "class in com.google.android.exoplayer2.analytics")> playbackStateHistory
Deprecated.
The playback state history as EventTimeAndPlaybackStates ordered by EventTime.realTimeMs.
-
public final[List](https://developer.android.com/reference/java/util/List.html "class or interface in java.util")<long[]> mediaTimeHistory
Deprecated.
The media time history as an ordered list of long[2] arrays with [0] being the realtime as returned by SystemClock.elapsedRealtime() and [1] being the media time at this realtime, in milliseconds.
-
public final long firstReportedTimeMs
Deprecated.
The elapsed real-time as returned by SystemClock.elapsedRealtime() of the first reported playback event, or C.TIME_UNSET if no event has been reported.
-
public final int foregroundPlaybackCount
Deprecated.
The number of playbacks which were the active foreground playback at some point.
-
public final int abandonedBeforeReadyCount
Deprecated.
The number of playbacks which were abandoned before they were ready to play.
-
public final int endedCount
Deprecated.
The number of playbacks which reached the ended state at least once.
-
public final int backgroundJoiningCount
Deprecated.
The number of playbacks which were pre-buffered in the background.
-
public final long totalValidJoinTimeMs
Deprecated.
The total time spent joining the playback, in milliseconds, or C.TIME_UNSET if no valid join time could be determined.
Note that this does not include background joining time. A join time may be invalid if the playback never reached PLAYBACK_STATE_PLAYING or PLAYBACK_STATE_PAUSED, or joining was interrupted by a seek, stop, or error state.
-
public final int validJoinTimeCount
Deprecated.
The number of playbacks with a valid join time as documented in totalValidJoinTimeMs.
-
public final int totalPauseCount
Deprecated.
The total number of times a playback has been paused.
-
public final int totalPauseBufferCount
Deprecated.
The total number of times a playback has been paused while rebuffering.
-
public final int totalSeekCount
Deprecated.
The total number of times a seek occurred. This includes seeks happening before playback resumed after another seek.
-
public final int totalRebufferCount
Deprecated.
The total number of times a rebuffer occurred. This excludes initial joining and buffering after seek.
-
public final long maxRebufferTimeMs
Deprecated.
The maximum time spent during a single rebuffer, in milliseconds, or C.TIME_UNSET if no rebuffer occurred.
-
public final int adPlaybackCount
Deprecated.
The number of ad playbacks.
-
public final[List](https://developer.android.com/reference/java/util/List.html "class or interface in java.util")<[PlaybackStats.EventTimeAndFormat](PlaybackStats.EventTimeAndFormat.html "class in com.google.android.exoplayer2.analytics")> videoFormatHistory
Deprecated.
The video format history as EventTimeAndFormats ordered by EventTime.realTimeMs. The Format may be null if no video format was used.
-
public final[List](https://developer.android.com/reference/java/util/List.html "class or interface in java.util")<[PlaybackStats.EventTimeAndFormat](PlaybackStats.EventTimeAndFormat.html "class in com.google.android.exoplayer2.analytics")> audioFormatHistory
Deprecated.
The audio format history as EventTimeAndFormats ordered by EventTime.realTimeMs. The Format may be null if no audio format was used.
-
public final long totalVideoFormatHeightTimeMs
Deprecated.
The total media time for which video format height data is available, in milliseconds.
-
public final long totalVideoFormatHeightTimeProduct
Deprecated.
The accumulated sum of all video format heights, in pixels, times the time the format was used for playback, in milliseconds.
-
public final long totalVideoFormatBitrateTimeMs
Deprecated.
The total media time for which video format bitrate data is available, in milliseconds.
-
public final long totalVideoFormatBitrateTimeProduct
Deprecated.
The accumulated sum of all video format bitrates, in bits per second, times the time the format was used for playback, in milliseconds.
-
public final long totalAudioFormatTimeMs
Deprecated.
The total media time for which audio format data is available, in milliseconds.
-
public final long totalAudioFormatBitrateTimeProduct
Deprecated.
The accumulated sum of all audio format bitrates, in bits per second, times the time the format was used for playback, in milliseconds.
-
public final int initialVideoFormatHeightCount
Deprecated.
The number of playbacks with initial video format height data.
-
public final int initialVideoFormatBitrateCount
Deprecated.
The number of playbacks with initial video format bitrate data.
-
public final int totalInitialVideoFormatHeight
Deprecated.
The total initial video format height for all playbacks, in pixels, or C.LENGTH_UNSET if no initial video format data is available.
-
public final long totalInitialVideoFormatBitrate
Deprecated.
The total initial video format bitrate for all playbacks, in bits per second, or C.LENGTH_UNSET if no initial video format data is available.
-
public final int initialAudioFormatBitrateCount
Deprecated.
The number of playbacks with initial audio format bitrate data.
-
public final long totalInitialAudioFormatBitrate
Deprecated.
The total initial audio format bitrate for all playbacks, in bits per second, or C.LENGTH_UNSET if no initial audio format data is available.
-
public final long totalBandwidthTimeMs
Deprecated.
The total time for which bandwidth measurement data is available, in milliseconds.
-
public final long totalBandwidthBytes
Deprecated.
The total bytes transferred during totalBandwidthTimeMs.
-
public final long totalDroppedFrames
Deprecated.
The total number of dropped video frames.
-
public final long totalAudioUnderruns
Deprecated.
The total number of audio underruns.
-
public final int fatalErrorPlaybackCount
Deprecated.
The total number of playback with at least one fatal error. Errors are fatal if playback stopped due to this error.
-
public final int fatalErrorCount
Deprecated.
The total number of fatal errors. Errors are fatal if playback stopped due to this error.
-
public final int nonFatalErrorCount
Deprecated.
The total number of non-fatal errors. Error are non-fatal if playback can recover from the error without stopping.
-
public final[List](https://developer.android.com/reference/java/util/List.html "class or interface in java.util")<[PlaybackStats.EventTimeAndException](PlaybackStats.EventTimeAndException.html "class in com.google.android.exoplayer2.analytics")> fatalErrorHistory
Deprecated.
The history of fatal errors as EventTimeAndExceptions ordered by EventTime.realTimeMs. Errors are fatal if playback stopped due to this error.
-
public final[List](https://developer.android.com/reference/java/util/List.html "class or interface in java.util")<[PlaybackStats.EventTimeAndException](PlaybackStats.EventTimeAndException.html "class in com.google.android.exoplayer2.analytics")> nonFatalErrorHistory
Deprecated.
The history of non-fatal errors as EventTimeAndExceptions ordered by EventTime.realTimeMs. Errors are non-fatal if playback can recover from the error without stopping.
-
public static[PlaybackStats](PlaybackStats.html "class in com.google.android.exoplayer2.analytics")merge([PlaybackStats](PlaybackStats.html "class in com.google.android.exoplayer2.analytics")... playbackStats)
Deprecated.
Returns the combined PlaybackStats for all input PlaybackStats.
Note that the full history of events is not kept as the history only makes sense in the context of a single playback.
Parameters:playbackStats - Array of PlaybackStats to combine.Returns:The combined PlaybackStats.
-
public long getPlaybackStateDurationMs(@com.google.android.exoplayer2.analytics.PlaybackStats.PlaybackState int playbackState)
Deprecated.
Returns the total time spent in a given PlaybackStats.PlaybackState, in milliseconds.
Parameters:playbackState - A PlaybackStats.PlaybackState.Returns:Total spent in the given playback state, in milliseconds
-
public @com.google.android.exoplayer2.analytics.PlaybackStats.PlaybackState int getPlaybackStateAtTime(long realtimeMs)
Deprecated.
Returns the PlaybackStats.PlaybackState at the given time.
Parameters:realtimeMs - The time as returned by SystemClock.elapsedRealtime().Returns:The PlaybackStats.PlaybackState at that time, or PLAYBACK_STATE_NOT_STARTED if the given time is before the first known playback state in the history.
-
public long getMediaTimeMsAtRealtimeMs(long realtimeMs)
Deprecated.
Returns the estimated media time at the given realtime, in milliseconds, or C.TIME_UNSET if the media time history is unknown.
Parameters:realtimeMs - The realtime as returned by SystemClock.elapsedRealtime().Returns:The estimated media time in milliseconds at this realtime, C.TIME_UNSET if no estimate can be given.
-
public long getMeanJoinTimeMs()
Deprecated.
Returns the mean time spent joining the playback, in milliseconds, or C.TIME_UNSET if no valid join time is available. Only includes playbacks with valid join times as documented in totalValidJoinTimeMs.
-
public long getTotalJoinTimeMs()
Deprecated.
Returns the total time spent joining the playback in foreground, in milliseconds. This does include invalid join times where the playback never reached PLAYBACK_STATE_PLAYING or PLAYBACK_STATE_PAUSED, or joining was interrupted by a seek, stop, or error state.
-
public long getTotalPlayTimeMs()
Deprecated.
Returns the total time spent actively playing, in milliseconds.
-
public long getMeanPlayTimeMs()
Deprecated.
Returns the mean time spent actively playing per foreground playback, in milliseconds, or C.TIME_UNSET if no playback has been in foreground.
-
public long getTotalPausedTimeMs()
Deprecated.
Returns the total time spent in a paused state, in milliseconds.
-
public long getMeanPausedTimeMs()
Deprecated.
Returns the mean time spent in a paused state per foreground playback, in milliseconds, or C.TIME_UNSET if no playback has been in foreground.
-
public long getTotalRebufferTimeMs()
Deprecated.
Returns the total time spent rebuffering, in milliseconds. This excludes initial join times, buffer times after a seek and buffering while paused.
-
public long getMeanRebufferTimeMs()
Deprecated.
Returns the mean time spent rebuffering per foreground playback, in milliseconds, or C.TIME_UNSET if no playback has been in foreground. This excludes initial join times, buffer times after a seek and buffering while paused.
-
public long getMeanSingleRebufferTimeMs()
Deprecated.
Returns the mean time spent during a single rebuffer, in milliseconds, or C.TIME_UNSET if no rebuffer was recorded. This excludes initial join times and buffer times after a seek.
-
public long getTotalSeekTimeMs()
Deprecated.
Returns the total time spent from the start of a seek until playback is ready again, in milliseconds.
-
public long getMeanSeekTimeMs()
Deprecated.
Returns the mean time spent per foreground playback from the start of a seek until playback is ready again, in milliseconds, or C.TIME_UNSET if no playback has been in foreground.
-
public long getMeanSingleSeekTimeMs()
Deprecated.
Returns the mean time spent from the start of a single seek until playback is ready again, in milliseconds, or C.TIME_UNSET if no seek occurred.
-
public long getTotalWaitTimeMs()
Deprecated.
Returns the total time spent actively waiting for playback, in milliseconds. This includes all join times, rebuffer times and seek times, but excludes times without user intention to play, e.g. all paused states.
-
public long getMeanWaitTimeMs()
Deprecated.
Returns the mean time spent actively waiting for playback per foreground playback, in milliseconds, or C.TIME_UNSET if no playback has been in foreground. This includes all join times, rebuffer times and seek times, but excludes times without user intention to play, e.g. all paused states.
-
public long getTotalPlayAndWaitTimeMs()
Deprecated.
Returns the total time spent playing or actively waiting for playback, in milliseconds.
-
public long getMeanPlayAndWaitTimeMs()
Deprecated.
Returns the mean time spent playing or actively waiting for playback per foreground playback, in milliseconds, or C.TIME_UNSET if no playback has been in foreground.
-
public long getTotalElapsedTimeMs()
Deprecated.
Returns the total time covered by any playback state, in milliseconds.
-
public long getMeanElapsedTimeMs()
Deprecated.
Returns the mean time covered by any playback state per playback, in milliseconds, or C.TIME_UNSET if no playback was recorded.
-
public float getAbandonedBeforeReadyRatio()
Deprecated.
Returns the ratio of foreground playbacks which were abandoned before they were ready to play, or 0.0 if no playback has been in foreground.
-
public float getEndedRatio()
Deprecated.
Returns the ratio of foreground playbacks which reached the ended state at least once, or 0.0 if no playback has been in foreground.
-
public float getMeanPauseCount()
Deprecated.
Returns the mean number of times a playback has been paused per foreground playback, or 0.0 if no playback has been in foreground.
-
public float getMeanPauseBufferCount()
Deprecated.
Returns the mean number of times a playback has been paused while rebuffering per foreground playback, or 0.0 if no playback has been in foreground.
-
public float getMeanSeekCount()
Deprecated.
Returns the mean number of times a seek occurred per foreground playback, or 0.0 if no playback has been in foreground. This includes seeks happening before playback resumed after another seek.
-
public float getMeanRebufferCount()
Deprecated.
Returns the mean number of times a rebuffer occurred per foreground playback, or 0.0 if no playback has been in foreground. This excludes initial joining and buffering after seek.
-
public float getWaitTimeRatio()
Deprecated.
Returns the ratio of wait times to the total time spent playing and waiting, or 0.0 if no time was spend playing or waiting. This is equivalent to getTotalWaitTimeMs() / getTotalPlayAndWaitTimeMs() and also to getJoinTimeRatio() + getRebufferTimeRatio() + getSeekTimeRatio().
-
public float getJoinTimeRatio()
Deprecated.
Returns the ratio of foreground join time to the total time spent playing and waiting, or 0.0 if no time was spend playing or waiting. This is equivalent to getTotalJoinTimeMs() / getTotalPlayAndWaitTimeMs().
-
public float getRebufferTimeRatio()
Deprecated.
Returns the ratio of rebuffer time to the total time spent playing and waiting, or 0.0 if no time was spend playing or waiting. This is equivalent to getTotalRebufferTimeMs() / getTotalPlayAndWaitTimeMs().
-
public float getSeekTimeRatio()
Deprecated.
Returns the ratio of seek time to the total time spent playing and waiting, or 0.0 if no time was spend playing or waiting. This is equivalent to getTotalSeekTimeMs() / getTotalPlayAndWaitTimeMs().
-
public float getRebufferRate()
Deprecated.
Returns the rate of rebuffer events, in rebuffers per play time second, or 0.0 if no time was spend playing. This is equivalent to 1.0 / getMeanTimeBetweenRebuffers().
-
public float getMeanTimeBetweenRebuffers()
Deprecated.
Returns the mean play time between rebuffer events, in seconds. This is equivalent to 1.0 / getRebufferRate(). Note that this may return Float.POSITIVE_INFINITY.
-
public int getMeanInitialVideoFormatHeight()
Deprecated.
Returns the mean initial video format height, in pixels, or C.LENGTH_UNSET if no video format data is available.
-
public int getMeanInitialVideoFormatBitrate()
Deprecated.
Returns the mean initial video format bitrate, in bits per second, or C.LENGTH_UNSET if no video format data is available.
-
public int getMeanInitialAudioFormatBitrate()
Deprecated.
Returns the mean initial audio format bitrate, in bits per second, or C.LENGTH_UNSET if no audio format data is available.
-
public int getMeanVideoFormatHeight()
Deprecated.
Returns the mean video format height, in pixels, or C.LENGTH_UNSET if no video format data is available. This is a weighted average taking the time the format was used for playback into account.
-
public int getMeanVideoFormatBitrate()
Deprecated.
Returns the mean video format bitrate, in bits per second, or C.LENGTH_UNSET if no video format data is available. This is a weighted average taking the time the format was used for playback into account.
-
public int getMeanAudioFormatBitrate()
Deprecated.
Returns the mean audio format bitrate, in bits per second, or C.LENGTH_UNSET if no audio format data is available. This is a weighted average taking the time the format was used for playback into account.
-
public int getMeanBandwidth()
Deprecated.
Returns the mean network bandwidth based on transfer measurements, in bits per second, or C.LENGTH_UNSET if no transfer data is available.
-
public float getDroppedFramesRate()
Deprecated.
Returns the mean rate at which video frames are dropped, in dropped frames per play time second, or 0.0 if no time was spent playing.
-
public float getAudioUnderrunRate()
Deprecated.
Returns the mean rate at which audio underruns occurred, in underruns per play time second, or 0.0 if no time was spent playing.
-
public float getFatalErrorRatio()
Deprecated.
Returns the ratio of foreground playbacks which experienced fatal errors, or 0.0 if no playback has been in foreground.
-
public float getFatalErrorRate()
Deprecated.
Returns the rate of fatal errors, in errors per play time second, or 0.0 if no time was spend playing. This is equivalent to 1.0 / getMeanTimeBetweenFatalErrors().
-
public float getMeanTimeBetweenFatalErrors()
Deprecated.
Returns the mean play time between fatal errors, in seconds. This is equivalent to 1.0 / getFatalErrorRate(). Note that this may return Float.POSITIVE_INFINITY.
-
public float getMeanNonFatalErrorCount()
Deprecated.
Returns the mean number of non-fatal errors per foreground playback, or 0.0 if no playback has been in foreground.
-
public float getNonFatalErrorRate()
Deprecated.
Returns the rate of non-fatal errors, in errors per play time second, or 0.0 if no time was spend playing. This is equivalent to 1.0 / getMeanTimeBetweenNonFatalErrors().
-
public float getMeanTimeBetweenNonFatalErrors()
Deprecated.
Returns the mean play time between non-fatal errors, in seconds. This is equivalent to 1.0 / getNonFatalErrorRate(). Note that this may return Float.POSITIVE_INFINITY.