Package com.google.android.exoplayer2.trackselection

## Class TrackSelectionArray

- java.lang.Object
- - com.google.android.exoplayer2.trackselection.TrackSelectionArray

-     public final class TrackSelectionArray
      extends Object

  An array of `TrackSelection`s.

- - ### Field Summary

    Fields
    Modifier and Type | Field | Description
    --- | --- | ---
    `int` | `length` | The length of this array.

  - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `TrackSelectionArray​(@NullableType TrackSelection... trackSelections)` |

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `boolean` | `equals​(Object obj)` |
    `TrackSelection` | `get​(int index)` | Returns the selection at a given index.
    `@NullableType TrackSelection[]` | `getAll()` | Returns the selections in a newly allocated array.
    `int` | `hashCode()` |

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

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

- - ### Field Detail

    - #### length

          public final int length

      The length of this array.

  - ### Constructor Detail

    - #### TrackSelectionArray

          public TrackSelectionArray​(@NullableType TrackSelection... trackSelections)

      Parameters:
        `trackSelections` - The selections. Must not be null, but may contain null elements.

  - ### Method Detail

    - #### get

          @Nullable
          public TrackSelection get​(int index)

      Returns the selection at a given index.
      Parameters:
        `index` - The index of the selection.
      Returns:
        The selection.

    - #### getAll

          public @NullableType TrackSelection[] getAll()

      Returns the selections in a newly allocated array.

    - #### hashCode

          public int hashCode()

      Overrides:
        `hashCode` in class `Object`

    - #### equals

          public boolean equals​(@Nullable
                                Object obj)

      Overrides:
        `equals` in class `Object`