Interface GuiVirtualRowRenderer<K,V>

Type Parameters:
K - stable row key
V - application value

public interface GuiVirtualRowRenderer<K,V>
Creates and binds retained virtual rows. A component belongs to one stable key for its whole cache lifetime; the library never silently rebinds an edited or captured control to a different key. Callbacks run on the client thread.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    bind(GuiComponent<?> row, GuiVirtualListSnapshot.Entry<K,V> entry, boolean selected)
    Updates application content after its immutable entry or selection changes.
    create(K key)
    Creates an unattached row for this key.
    default void
    release(GuiComponent<?> row, K key)
    Releases row-owned subscriptions/resources after cache eviction or list close.
  • Method Details

    • create

      GuiComponent<?> create(K key)
      Creates an unattached row for this key. The list owns its position, width and height.
    • bind

      void bind(GuiComponent<?> row, GuiVirtualListSnapshot.Entry<K,V> entry, boolean selected)
      Updates application content after its immutable entry or selection changes. This is not called for an unchanged frame or a scroll that preserves the same entry. Store durable edit state in the application model if it must outlive the bounded retained cache. Row margins/transforms do not contribute to the indexed scroll extent.
    • release

      default void release(GuiComponent<?> row, K key)
      Releases row-owned subscriptions/resources after cache eviction or list close. The row is already detached.