PagingData.Companion

object PagingData.Companion


Summary

Public methods

final @NonNull PagingData<@NonNull T>
<T extends Object> empty()

Create a PagingData that immediately displays an empty list of items when submitted to androidx.paging.AsyncPagingDataAdapter.

final @NonNull PagingData<@NonNull T>
<T extends Object> from(@NonNull List<@NonNull T> data)

Create a PagingData that immediately displays a static list of items when submitted to androidx.paging.AsyncPagingDataAdapter.

Public methods

empty

@NonNull
public final PagingData<@NonNull T> <T extends Object> empty()

Create a PagingData that immediately displays an empty list of items when submitted to androidx.paging.AsyncPagingDataAdapter.

from

@NonNull
public final PagingData<@NonNull T> <T extends Object> from(@NonNull List<@NonNull T> data)

Create a PagingData that immediately displays a static list of items when submitted to androidx.paging.AsyncPagingDataAdapter.

Parameters
@NonNull List<@NonNull T> data

Static list of T to display.