# Package com.google.android.exoplayer2.source

- Interface Summary
  Interface | Description
  --- | ---
  CompositeSequenceableLoaderFactory | A factory to create composite `SequenceableLoader`s.
  DefaultMediaSourceFactory.AdsLoaderProvider | Deprecated. Use `AdsLoader.Provider` instead.
  MaskingMediaPeriod.PrepareListener | Listener for preparation events.
  MediaPeriod | Loads media corresponding to a `Timeline.Period`, and allows that media to be read.
  MediaPeriod.Callback | A callback to be notified of `MediaPeriod` events.
  MediaSource | Defines and provides media to be played by an `ExoPlayer`.
  MediaSource.Factory | Factory for creating `MediaSources` from `MediaItems`.
  MediaSource.MediaSourceCaller | A caller of media sources, which will be notified of source events.
  MediaSourceEventListener | Interface for callbacks to be notified of `MediaSource` events.
  MediaSourceFactory | Deprecated. Use `MediaSource.Factory`.
  ProgressiveMediaExtractor | Extracts the contents of a container file from a progressive media stream.
  ProgressiveMediaExtractor.Factory | Creates `ProgressiveMediaExtractor` instances.
  SampleQueue.UpstreamFormatChangedListener | A listener for changes to the upstream format.
  SampleStream | A stream of media samples (and associated format information).
  SequenceableLoader | A loader that can proceed in approximate synchronization with other loaders.
  SequenceableLoader.Callback<T extends SequenceableLoader> | A callback to be notified of `SequenceableLoader` events.
  ShuffleOrder | Shuffled order of indices.

- Class Summary
  Class | Description
  --- | ---
  BaseMediaSource | Base `MediaSource` implementation to handle parallel reuse and to keep a list of `MediaSourceEventListener`s.
  BundledExtractorsAdapter | `ProgressiveMediaExtractor` built on top of `Extractor` instances, whose implementation classes are bundled in the app.
  ClippingMediaPeriod | Wraps a `MediaPeriod` and clips its `SampleStream`s to provide a subsequence of their samples.
  ClippingMediaSource | `MediaSource` that wraps a source and clips its timeline based on specified start/end positions.
  CompositeMediaSource<T> | Composite `MediaSource` consisting of multiple child sources.
  CompositeSequenceableLoader | A `SequenceableLoader` that encapsulates multiple other `SequenceableLoader`s.
  ConcatenatingMediaSource | Concatenates multiple `MediaSource`s.
  ConcatenatingMediaSource2 | Concatenates multiple `MediaSources`, combining everything in one single `Timeline.Window`.
  ConcatenatingMediaSource2.Builder | A builder for `ConcatenatingMediaSource2` instances.
  DefaultCompositeSequenceableLoaderFactory | Default implementation of `CompositeSequenceableLoaderFactory`.
  DefaultMediaSourceFactory | The default `MediaSource.Factory` implementation.
  EmptySampleStream | An empty `SampleStream`.
  ForwardingTimeline | An overridable `Timeline` implementation forwarding all methods to another timeline.
  LoadEventInfo | `MediaSource` load event information.
  LoopingMediaSource | Deprecated. To loop a `MediaSource` indefinitely, use `Player.setRepeatMode(int)` instead of this class.
  MaskingMediaPeriod | Media period that defers calling `MediaSource.createPeriod(MediaPeriodId, Allocator, long)` on a given source until `MaskingMediaPeriod.createPeriod(MediaPeriodId)` has been called.
  MaskingMediaSource | A `MediaSource` that masks the `Timeline` with a placeholder until the actual media structure is known.
  MaskingMediaSource.PlaceholderTimeline | A timeline with one dynamic window with a period of indeterminate duration.
  MediaLoadData | Descriptor for data being loaded or selected by a `MediaSource`.
  MediaParserExtractorAdapter | `ProgressiveMediaExtractor` implemented on top of the platform's `MediaParser`.
  MediaPeriodId | Identifies a specific playback of a `Timeline.Period`.
  MediaSource.MediaPeriodId | Identifier for a `MediaPeriod`.
  MediaSourceEventListener.EventDispatcher | Dispatches events to `MediaSourceEventListeners`.
  MergingMediaSource | Merges multiple `MediaSource`s.
  ProgressiveMediaSource | Provides one period that loads data from a `Uri` and extracted using an `Extractor`.
  ProgressiveMediaSource.Factory | Factory for `ProgressiveMediaSource`s.
  SampleQueue | A queue of media samples.
  ShuffleOrder.DefaultShuffleOrder | The default `ShuffleOrder` implementation for random shuffle order.
  ShuffleOrder.UnshuffledShuffleOrder | A `ShuffleOrder` implementation which does not shuffle.
  SilenceMediaSource | Media source with a single period consisting of silent raw audio of a given duration.
  SilenceMediaSource.Factory | Factory for `SilenceMediaSources`.
  SinglePeriodTimeline | A `Timeline` consisting of a single period and static window.
  SingleSampleMediaSource | Loads data at a given `Uri` as a single sample belonging to a single `MediaPeriod`.
  SingleSampleMediaSource.Factory | Factory for `SingleSampleMediaSource`.
  TrackGroup | An immutable group of tracks available within a media stream.
  TrackGroupArray | An immutable array of `TrackGroup`s.
  WrappingMediaSource | An abstract `MediaSource` wrapping a single child `MediaSource`.

- Exception Summary
  Exception | Description
  --- | ---
  BehindLiveWindowException | Thrown when a live playback falls behind the available media window.
  ClippingMediaSource.IllegalClippingException | Thrown when a `ClippingMediaSource` cannot clip its wrapped source.
  MergingMediaSource.IllegalMergeException | Thrown when a `MergingMediaSource` cannot merge its sources.
  UnrecognizedInputFormatException | Thrown if the input format was not recognized.

- Annotation Types Summary
  Annotation Type | Description
  --- | ---
  ClippingMediaSource.IllegalClippingException.Reason | The reason clipping failed.
  MergingMediaSource.IllegalMergeException.Reason | The reason the merge failed.
  SampleStream.ReadDataResult | Return values of `SampleStream.readData(com.google.android.exoplayer2.FormatHolder, com.google.android.exoplayer2.decoder.DecoderInputBuffer, @com.google.android.exoplayer2.source.SampleStream.ReadFlags int)`.
  SampleStream.ReadFlags | Flags that can be specified when calling `SampleStream.readData(com.google.android.exoplayer2.FormatHolder, com.google.android.exoplayer2.decoder.DecoderInputBuffer, @com.google.android.exoplayer2.source.SampleStream.ReadFlags int)`.