CollectionPreparationManager
This class is responsible for preparing the items in the collection. It will prepare the items that are in the viewport and the items that are in the range of the viewport.
Properties
Functions
Estimates the number of items that can fit in the viewport based on measuring a sample item. This calculation is performed only once when estimatedItemsInViewPort is unset and helps determine how many items should be prepared for rendering to optimize performance.
Attempts to update the viewport and compute the range of items that should be prepared. This method checks if the viewport needs updating and posts a runnable to handle the update. It also triggers computation of which items should enter or exit the preparation range.
Prepares items currently visible in the viewport by measuring them and filling the viewport. This method uses a ViewportFiller to determine which items should be measured and prepared for rendering based on the available space in the collection's viewport.