# CompositeSequenceableLoader

# CompositeSequenceableLoader

Artifact:[androidx.media3:media3-exoplayer](https://developer.android.com/jetpack/androidx/releases/media3)  
[View Source](https://cs.android.com/search?q=file:androidx/media3/exoplayer/source/CompositeSequenceableLoader.java+class:androidx.media3.exoplayer.source.CompositeSequenceableLoader)

*** ** * ** ***

Kotlin\|[Java](https://developer.android.com/reference/androidx/media3/exoplayer/source/CompositeSequenceableLoader "View this page in Java")

<br />

```
@UnstableApi
class CompositeSequenceableLoader : SequenceableLoader
```

<br />

*** ** * ** ***

A[SequenceableLoader](https://developer.android.com/reference/kotlin/androidx/media3/exoplayer/source/SequenceableLoader)that encapsulates multiple other[SequenceableLoader](https://developer.android.com/reference/kotlin/androidx/media3/exoplayer/source/SequenceableLoader)s.

## Summary

|                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              ### Public constructors                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                              |
|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| ~~[CompositeSequenceableLoader](https://developer.android.com/reference/kotlin/androidx/media3/exoplayer/source/CompositeSequenceableLoader#CompositeSequenceableLoader(androidx.media3.exoplayer.source.SequenceableLoader[]))~~`(loaders: `[Array](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-array/index.html)`<`[SequenceableLoader](https://developer.android.com/reference/kotlin/androidx/media3/exoplayer/source/SequenceableLoader)`!>!)` **This function is deprecated.** Use[CompositeSequenceableLoader](https://developer.android.com/reference/kotlin/androidx/media3/exoplayer/source/CompositeSequenceableLoader#CompositeSequenceableLoader(java.util.List<? extends androidx.media3.exoplayer.source.SequenceableLoader>,java.util.List<java.util.List<java.lang.Integer>>))instead. <br />                                                                                                                                                                                                                                                                                                                                                                                                                                                          |
| [CompositeSequenceableLoader](https://developer.android.com/reference/kotlin/androidx/media3/exoplayer/source/CompositeSequenceableLoader#CompositeSequenceableLoader(java.util.List<? extends androidx.media3.exoplayer.source.SequenceableLoader>,java.util.List<java.util.List<java.lang.Integer>>))`(` ` loaders: (`[Mutable](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-mutable-list/index.html)`)`[List](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-list/index.html)`<`[SequenceableLoader](https://developer.android.com/reference/kotlin/androidx/media3/exoplayer/source/SequenceableLoader)`!>!,` ` loaderTrackTypes: (`[Mutable](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-mutable-list/index.html)`)`[List](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-list/index.html)`<(`[Mutable](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-mutable-list/index.html)`)`[List](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-list/index.html)`<@`[C.TrackType](https://developer.android.com/reference/kotlin/androidx/media3/common/C.TrackType)` `[Int](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-int/index.html)`!>!>!` `)` |

|                                ### Public functions                                 |
|-------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [Boolean](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html) | [continueLoading](https://developer.android.com/reference/kotlin/androidx/media3/exoplayer/source/CompositeSequenceableLoader#continueLoading(androidx.media3.exoplayer.LoadingInfo))`(loadingInfo: `[LoadingInfo](https://developer.android.com/reference/kotlin/androidx/media3/exoplayer/LoadingInfo)`!)` Attempts to continue loading. |
| [Long](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long/index.html)       | [getBufferedPositionUs](https://developer.android.com/reference/kotlin/androidx/media3/exoplayer/source/CompositeSequenceableLoader#getBufferedPositionUs())`()` Returns an estimate of the position up to which data is buffered.                                                                                                         |
| [Long](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long/index.html)       | [getNextLoadPositionUs](https://developer.android.com/reference/kotlin/androidx/media3/exoplayer/source/CompositeSequenceableLoader#getNextLoadPositionUs())`()` Returns the next load time, or[TIME_END_OF_SOURCE](https://developer.android.com/reference/kotlin/androidx/media3/common/C#TIME_END_OF_SOURCE())if loading has finished.  |
| [Boolean](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html) | [isLoading](https://developer.android.com/reference/kotlin/androidx/media3/exoplayer/source/CompositeSequenceableLoader#isLoading())`()` Returns whether the loader is currently loading.                                                                                                                                                  |
| [Unit](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html)       | [reevaluateBuffer](https://developer.android.com/reference/kotlin/androidx/media3/exoplayer/source/CompositeSequenceableLoader#reevaluateBuffer(long))`(positionUs: `[Long](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long/index.html)`)` Re-evaluates the buffer given the playback position.                                 |

## Public constructors

### CompositeSequenceableLoader

```
[CompositeSequenceableLoader](https://developer.android.com/reference/kotlin/androidx/media3/exoplayer/source/CompositeSequenceableLoader#CompositeSequenceableLoader(androidx.media3.exoplayer.source.SequenceableLoader[]))(loaders: Array<SequenceableLoader!>!)
```
| **This function is deprecated.**   
|
Use[CompositeSequenceableLoader](https://developer.android.com/reference/kotlin/androidx/media3/exoplayer/source/CompositeSequenceableLoader#CompositeSequenceableLoader(java.util.List<? extends androidx.media3.exoplayer.source.SequenceableLoader>,java.util.List<java.util.List<java.lang.Integer>>))instead.  

### CompositeSequenceableLoader

```
CompositeSequenceableLoader(
    loaders: (Mutable)List<SequenceableLoader!>!,
    loaderTrackTypes: (Mutable)List<(Mutable)List<@C.TrackType Int!>!>!
)
```  

## Public functions

### continueLoading

```
fun continueLoading(loadingInfo: LoadingInfo!): Boolean
```

Attempts to continue loading.  

|                                                      Parameters                                                       |
|-----------------------------------------------------------------------------------------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------|
| `loadingInfo: `[LoadingInfo](https://developer.android.com/reference/kotlin/androidx/media3/exoplayer/LoadingInfo)`!` | The[LoadingInfo](https://developer.android.com/reference/kotlin/androidx/media3/exoplayer/LoadingInfo)when attempting to continue loading. |

|                                       Returns                                       |
|-------------------------------------------------------------------------------------|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [Boolean](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html) | True if progress was made, meaning that[getNextLoadPositionUs](https://developer.android.com/reference/kotlin/androidx/media3/exoplayer/source/SequenceableLoader#getNextLoadPositionUs())will return a different value than prior to the call. False otherwise. |

### getBufferedPositionUs

```
fun getBufferedPositionUs(): Long
```

Returns an estimate of the position up to which data is buffered.  

|                                    Returns                                    |
|-------------------------------------------------------------------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [Long](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long/index.html) | An estimate of the absolute position in microseconds up to which data is buffered, or[TIME_END_OF_SOURCE](https://developer.android.com/reference/kotlin/androidx/media3/common/C#TIME_END_OF_SOURCE())if the data is fully buffered. |

### getNextLoadPositionUs

```
fun getNextLoadPositionUs(): Long
```

Returns the next load time, or[TIME_END_OF_SOURCE](https://developer.android.com/reference/kotlin/androidx/media3/common/C#TIME_END_OF_SOURCE())if loading has finished.  

### isLoading

```
fun isLoading(): Boolean
```

Returns whether the loader is currently loading.  

### reevaluateBuffer

```
fun reevaluateBuffer(positionUs: Long): Unit
```

Re-evaluates the buffer given the playback position.

Re-evaluation may discard buffered media or cancel ongoing loads so that media can be re-buffered in a different quality.  

|                                         Parameters                                          |
|---------------------------------------------------------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| `positionUs: `[Long](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-long/index.html) | The current playback position in microseconds. If playback of this period has not yet started, the value will be the starting position in this period minus the duration of any media in previous periods still to be played. |