LoadInitialParams

open class LoadInitialParams
kotlin.Any
   ↳ androidx.paging.PositionalDataSource.LoadInitialParams

Holder object for inputs to loadInitial(LoadInitialParams, LoadInitialCallback).

Summary

Public constructors
<init>(requestedStartPosition: Int, requestedLoadSize: Int, pageSize: Int, placeholdersEnabled: Boolean)

Properties
Int

Initial load position requested.

Int

Requested number of items to load.

Int

Defines page size acceptable for return values.

Boolean

Defines whether placeholders are enabled, and whether the total count passed to LoadInitialCallback#onResult(List, int, int) will be ignored.

Public constructors

<init>

LoadInitialParams(requestedStartPosition: Int, requestedLoadSize: Int, pageSize: Int, placeholdersEnabled: Boolean)

Properties

requestedStartPosition

val requestedStartPosition: Int

Initial load position requested.

Note that this may not be within the bounds of your data set, it may need to be adjusted before you execute your load.

requestedLoadSize

val requestedLoadSize: Int

Requested number of items to load.

Note that this may be larger than available data.

pageSize

val pageSize: Int

Defines page size acceptable for return values.

List of items passed to the callback must be an integer multiple of page size.

placeholdersEnabled

val placeholdersEnabled: Boolean

Defines whether placeholders are enabled, and whether the total count passed to LoadInitialCallback#onResult(List, int, int) will be ignored.