Package com.google.android.exoplayer2.testutil

## Class Action.ThrowPlaybackException

- java.lang.Object
- - com.google.android.exoplayer2.testutil.Action
  - - com.google.android.exoplayer2.testutil.Action.ThrowPlaybackException

- Enclosing class:
    Action

      public static final class Action.ThrowPlaybackException
      extends Action

  Throws a playback exception on the playback thread.

- - ### Nested Class Summary

    - ### Nested classes/interfaces inherited from class com.google.android.exoplayer2.testutil.Action

      `Action.AddMediaItems, Action.ClearMediaItems, Action.ClearVideoSurface, Action.ExecuteRunnable, Action.MoveMediaItem, Action.PlayUntilPosition, Action.Prepare, Action.RemoveMediaItem, Action.RemoveMediaItems, Action.Seek, Action.SendMessages, Action.SetAudioAttributes, Action.SetMediaItems, Action.SetMediaItemsResetPosition, Action.SetPlaybackParameters, Action.SetPlayWhenReady, Action.SetRendererDisabled, Action.SetRepeatMode, Action.SetShuffleModeEnabled, Action.SetShuffleOrder, Action.SetVideoSurface, Action.Stop, Action.ThrowPlaybackException, Action.WaitForIsLoading, Action.WaitForMessage, Action.WaitForPendingPlayerCommands, Action.WaitForPlaybackState, Action.WaitForPlayWhenReady, Action.WaitForPositionDiscontinuity, Action.WaitForTimelineChanged`

  - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `ThrowPlaybackException​(String tag, ExoPlaybackException exception)` |

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `protected void` | `doActionImpl​(SimpleExoPlayer player, DefaultTrackSelector trackSelector, Surface surface)` | Called by `Action.doActionAndScheduleNextImpl(SimpleExoPlayer, DefaultTrackSelector, Surface, HandlerWrapper, ActionNode)` to perform the action.

    - ### Methods inherited from class com.google.android.exoplayer2.testutil.Action

      `doActionAndScheduleNext, doActionAndScheduleNextImpl`

    - ### Methods inherited from class java.lang.Object

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

- - ### Constructor Detail

    - #### ThrowPlaybackException

          public ThrowPlaybackException​(String tag,
                                        ExoPlaybackException exception)

      Parameters:
        `tag` - A tag to use for logging.
        `exception` - The exception to throw.

  - ### Method Detail

    - #### doActionImpl

          protected void doActionImpl​(SimpleExoPlayer player,
                                      DefaultTrackSelector trackSelector,
                                      @Nullable
                                      Surface surface)

      Description copied from class: `Action`
      Called by `Action.doActionAndScheduleNextImpl(SimpleExoPlayer, DefaultTrackSelector, Surface, HandlerWrapper, ActionNode)` to perform the action.
      Specified by:
        `doActionImpl` in class `Action`
      Parameters:
        `player` - The player to which the action should be applied.
        `trackSelector` - The track selector to which the action should be applied.
        `surface` - The surface to use when applying actions, or `null` if no surface is needed.