library/core/src/main/java/com/google/android/exoplayer2/source/ConcatenatingMediaSource.java
public final synchronized void addMediaSource(
      int index, MediaSource mediaSource, Handler handler, Runnable onCompletionAction) {
    addPublicMediaSources(
        index, Collections.singletonList(mediaSource), handler, onCompletionAction);
  }
/**
   * Adds a {@link MediaSource} to the playlist and executes a custom action on completion.
   *
   * @param index The index at which the new {@link MediaSource} will be inserted. This index must
   *     be in the range of 0 &lt;= index &lt;= {@link #getSize()}.
   * @param mediaSource The {@link MediaSource} to be added to the list.
   * @param handler The {@link Handler} to run {@code onCompletionAction}.
   * @param onCompletionAction A {@link Runnable} which is executed immediately after the media
   *     source has been added to the playlist.
   */
Adds a  MediaSource to the playlist and executes a custom action on completion.
@param index The index at which the new  MediaSource will be inserted. This index must
be in the range of 0 <= index <=  #getSize().
@param mediaSource The  MediaSource to be added to the list.
@param handler The  Handler to run  onCompletionAction.
@param onCompletionAction A  Runnable which is executed immediately after the media
source has been added to the playlist.
Adds a MediaSource to the playlist and executes a custom action on completion . @param index The index at which the new MediaSource will be inserted . This index must be in the range of 0 < = index < = #getSize () . @param mediaSource The MediaSource to be added to the list . @param handler The Handler to run onCompletionAction . @param onCompletionAction A Runnable which is executed immediately after the media source has been added to the playlist .
public final synchronized void addMediaSource(
      int index, MediaSource mediaSource, Handler handler, Runnable onCompletionAction) {
    addPublicMediaSources(
        index, Collections.singletonList(mediaSource), handler, onCompletionAction);
  }
public final synchronized void addMediaSource ( int index , MediaSource mediaSource , Handler handler , Runnable onCompletionAction ) { addPublicMediaSources ( index , Collections . singletonList ( mediaSource ) , handler , onCompletionAction ) ; }
Adds a {@link MediaSource} to the playlist and executes a custom action on completion.
Adds a { @link MediaSource } to the playlist and executes a custom action on completion .