# LoadState

# LoadState

Artifact:[androidx.paging:paging-common](https://developer.android.com/jetpack/androidx/releases/paging)  
[View Source](https://cs.android.com/search?q=file:androidx/paging/LoadState.kt+class:androidx.paging.LoadState)  
Added in[3.0.0](https://developer.android.com/jetpack/androidx/releases/paging#3.0.0)

*** ** * ** ***

Kotlin\|[Java](https://developer.android.com/reference/androidx/paging/LoadState "View this page in Java")
Common/AllAndroid/JVMNative/C/iOSJavaScript
  - Cmn  

  ```
  sealed class LoadState
```  
Known direct subclasses  
[LoadState.Error](https://developer.android.com/reference/kotlin/androidx/paging/LoadState.Error),[LoadState.Loading](https://developer.android.com/reference/kotlin/androidx/paging/LoadState.Loading),[LoadState.NotLoading](https://developer.android.com/reference/kotlin/androidx/paging/LoadState.NotLoading)  

|-------------------------------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------|
| [LoadState.Error](https://developer.android.com/reference/kotlin/androidx/paging/LoadState.Error)           | Loading hit an error.                                                                                                                                          |
| [LoadState.Loading](https://developer.android.com/reference/kotlin/androidx/paging/LoadState.Loading)       | Loading is in progress.                                                                                                                                        |
| [LoadState.NotLoading](https://developer.android.com/reference/kotlin/androidx/paging/LoadState.NotLoading) | Indicates the[PagingData](https://developer.android.com/reference/kotlin/androidx/paging/PagingData)is not currently loading, and no error currently observed. |

*** ** * ** ***

LoadState of a PagedList load - associated with a[LoadType](https://developer.android.com/reference/kotlin/androidx/paging/LoadType)

[LoadState](https://developer.android.com/reference/kotlin/androidx/paging/LoadState)of any[LoadType](https://developer.android.com/reference/kotlin/androidx/paging/LoadType)may be observed for UI purposes by registering a listener via androidx.paging.PagingDataAdapter.addLoadStateListener or androidx.paging.AsyncPagingDataDiffer.addLoadStateListener  

|                                      See also                                       |
|-------------------------------------------------------------------------------------|---|
| [LoadType](https://developer.android.com/reference/kotlin/androidx/paging/LoadType) |   |

## Summary

|                                                                                                                                                                               ### Nested types                                                                                                                                                                               |
|------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| `class `[LoadState.Error](https://developer.android.com/reference/kotlin/androidx/paging/LoadState.Error)` : `[LoadState](https://developer.android.com/reference/kotlin/androidx/paging/LoadState) Loading hit an error.                                                                                                                                                    |
| `object `[LoadState.Loading](https://developer.android.com/reference/kotlin/androidx/paging/LoadState.Loading)` : `[LoadState](https://developer.android.com/reference/kotlin/androidx/paging/LoadState) Loading is in progress.                                                                                                                                             |
| `class `[LoadState.NotLoading](https://developer.android.com/reference/kotlin/androidx/paging/LoadState.NotLoading)` : `[LoadState](https://developer.android.com/reference/kotlin/androidx/paging/LoadState) Indicates the[PagingData](https://developer.android.com/reference/kotlin/androidx/paging/PagingData)is not currently loading, and no error currently observed. |

|                                                                                                    ### Protected constructors                                                                                                    |
|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-----|
| [LoadState](https://developer.android.com/reference/kotlin/androidx/paging/LoadState#LoadState(kotlin.Boolean))`(endOfPaginationReached: `[Boolean](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html)`)` | Cmn |

|                                ### Public properties                                |
|-------------------------------------------------------------------------------------|----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|-----|
| [Boolean](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html) | [endOfPaginationReached](https://developer.android.com/reference/kotlin/androidx/paging/LoadState#endOfPaginationReached()) `false`if there is more data to load in the[LoadType](https://developer.android.com/reference/kotlin/androidx/paging/LoadType)this[LoadState](https://developer.android.com/reference/kotlin/androidx/paging/LoadState)is associated with,`true`otherwise. | Cmn |

## Protected constructors

### LoadState

Cmn  

```
protected LoadState(endOfPaginationReached: Boolean)
```  

|                                                  Parameters                                                   |
|---------------------------------------------------------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
| `endOfPaginationReached: `[Boolean](https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-boolean/index.html) | `false`if there is more data to load in the[LoadType](https://developer.android.com/reference/kotlin/androidx/paging/LoadType)this[LoadState](https://developer.android.com/reference/kotlin/androidx/paging/LoadState)is associated with,`true`otherwise. This parameter informs[Pager](https://developer.android.com/reference/kotlin/androidx/paging/Pager)if it should continue to make requests for additional data in this direction or if it should halt as the end of the dataset has been reached. Note: The REFRESH[LoadType.REFRESH](https://developer.android.com/reference/kotlin/androidx/paging/LoadType#REFRESH)always has[LoadState.endOfPaginationReached](https://developer.android.com/reference/kotlin/androidx/paging/LoadState#endOfPaginationReached())set to`false`. |

## Public properties

### endOfPaginationReached

Cmn  
Added in[3.0.0](https://developer.android.com/jetpack/androidx/releases/paging#3.0.0)  

```
val endOfPaginationReached: Boolean
```

`false`if there is more data to load in the[LoadType](https://developer.android.com/reference/kotlin/androidx/paging/LoadType)this[LoadState](https://developer.android.com/reference/kotlin/androidx/paging/LoadState)is associated with,`true`otherwise. This parameter informs[Pager](https://developer.android.com/reference/kotlin/androidx/paging/Pager)if it should continue to make requests for additional data in this direction or if it should halt as the end of the dataset has been reached.

Note: The REFRESH[LoadType.REFRESH](https://developer.android.com/reference/kotlin/androidx/paging/LoadType#REFRESH)always has[LoadState.endOfPaginationReached](https://developer.android.com/reference/kotlin/androidx/paging/LoadState#endOfPaginationReached())set to`false`.