SubcomposeLayoutState.PrecomposedSlotHandle


Instance of this interface is returned by precompose function.

Summary

Public functions

Unit

This function allows to dispose the content for the slot which was precomposed previously via precompose.

Cmn
open Unit
premeasure(index: Int, constraints: Constraints)

Performs synchronous measure of the placeable at the given index.

Cmn

Public properties

open Int

The amount of placeables composed into this slot.

Cmn

Public functions

dispose

fun dispose(): Unit

This function allows to dispose the content for the slot which was precomposed previously via precompose.

If this slot was already used during the regular measure pass via SubcomposeMeasureScope.subcompose this function will do nothing.

This could be useful if after the future calculations this item is not anymore expected to be used during the measure pass anytime soon.

premeasure

open fun premeasure(index: Int, constraints: Constraints): Unit

Performs synchronous measure of the placeable at the given index.

Parameters
index: Int

the placeable index. Should be smaller than placeablesCount.

constraints: Constraints

Constraints to measure this placeable with.

Public properties

placeablesCount

open val placeablesCountInt

The amount of placeables composed into this slot.