# PageKeyedDataSource.LoadInitialParams

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

*** ** * ** ***


```
public class PageKeyedDataSource.LoadInitialParams<Key extends Object>
```

<br />

*** ** * ** ***

> [!CAUTION]
> **This class is deprecated.**   
> PageKeyedDataSource is deprecated and has been replaced by PagingSource, use this instead:
>
> ```
> PagingSource<Key, Value>
> ```

Holder object for inputs to `https://developer.android.com/reference/androidx/paging/PageKeyedDataSource#loadInitial(androidx.paging.PageKeyedDataSource.LoadInitialParams)`.

| Parameters |
|---|---|
| `<Key extends https://developer.android.com/reference/java/lang/Object.html>` | Type of data used to query pages. |

## Summary

| ### Public fields |
|---|---|
| `final boolean` | `https://developer.android.com/reference/androidx/paging/PageKeyedDataSource.LoadInitialParams#placeholdersEnabled()` **This field is deprecated.** PageKeyedDataSource is deprecated and has been replaced by PagingSource |
| `final int` | `https://developer.android.com/reference/androidx/paging/PageKeyedDataSource.LoadInitialParams#requestedLoadSize()` **This field is deprecated.** PageKeyedDataSource is deprecated and has been replaced by PagingSource |

| ### Public constructors |
|---|
| `<Key extends https://developer.android.com/reference/java/lang/Object.html> [LoadInitialParams](https://developer.android.com/reference/androidx/paging/PageKeyedDataSource.LoadInitialParams#LoadInitialParams(kotlin.Int,kotlin.Boolean))( int requestedLoadSize, boolean placeholdersEnabled )` **This method is deprecated.** PageKeyedDataSource is deprecated and has been replaced by PagingSource |

## Public fields

### placeholdersEnabled

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

```
public final boolean placeholdersEnabled
```

> [!CAUTION]
> **This field is deprecated.**   
> PageKeyedDataSource is deprecated and has been replaced by PagingSource, use this instead:
>
> ```
> PagingSource<Key, Value>
> ```

Defines whether placeholders are enabled, and whether the loaded total count will be ignored.

### requestedLoadSize

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

```
public final int requestedLoadSize
```

> [!CAUTION]
> **This field is deprecated.**   
> PageKeyedDataSource is deprecated and has been replaced by PagingSource, use this instead:
>
> ```
> PagingSource<Key, Value>
> ```

Requested number of items to load.

Note that this may be larger than available data.

## Public constructors

### LoadInitialParams

```
public <Key extends Object> [LoadInitialParams](https://developer.android.com/reference/androidx/paging/PageKeyedDataSource.LoadInitialParams#LoadInitialParams(kotlin.Int,kotlin.Boolean))(
    int requestedLoadSize,
    boolean placeholdersEnabled
)
```

> [!CAUTION]
> **This method is deprecated.**   
> PageKeyedDataSource is deprecated and has been replaced by PagingSource, use this instead:
>
> ```
> PagingSource<Key, Value>
> ```

| Parameters |
|---|---|
| `<Key extends https://developer.android.com/reference/java/lang/Object.html>` | Type of data used to query pages. |
| `int requestedLoadSize` | Requested number of items to load. Note that this may be larger than available data. |
| `boolean placeholdersEnabled` | Defines whether placeholders are enabled, and whether the loaded total count will be ignored. |