{% setvar book_path %}/reference/kotlin/androidx/_book.yaml{% endsetvar %} {% include "_shared/_reference-head-tags.html" %}

LazyLayoutPrefetchState


State for lazy items prefetching, used by lazy layouts to instruct the prefetcher.

Summary

Nested types

Public constructors

Cmn

Public functions

LazyLayoutPrefetchState.PrefetchHandle
schedulePrefetch(index: Int, constraints: Constraints)

Schedules precomposition and premeasure for the new item.

Cmn

Public constructors

LazyLayoutPrefetchState

LazyLayoutPrefetchState()

Public functions

schedulePrefetch

fun schedulePrefetch(index: Int, constraints: Constraints): LazyLayoutPrefetchState.PrefetchHandle

Schedules precomposition and premeasure for the new item.

Parameters
index: Int

item index to prefetch.

constraints: Constraints

Constraints to use for premeasuring.