TreeState

class TreeState

Constructors

Link copied to clipboard
constructor(fromState: TreeState?)
constructor(initialResolveState: InitialState, initialLayoutState: InitialState)
constructor()

Types

Link copied to clipboard
object Companion
Link copied to clipboard

This class represents whether this Litho tree has been mounted before. The usage is a bit convoluted and will need to be cleaned out properly in the future.

Properties

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Functions

Link copied to clipboard
fun addState(key: String, state: ComponentState<*>, isLayoutState: Boolean)
Link copied to clipboard
fun applyStateUpdatesEarly(context: ComponentContext, component: Component?, prevTreeRootNode: LithoNode?, isLayoutState: Boolean)
Link copied to clipboard
fun bindEventAndTriggerHandlers(createdEventHandlers: List<Pair<String, EventHandler<*>>>?, componentScopes: List<ScopedComponentInfo>?)
Link copied to clipboard
fun <T> canSkipStateUpdate(stateId: StateId, newValue: T, isLayoutState: Boolean): Boolean
fun <T> canSkipStateUpdate(updater: (T) -> T, stateId: StateId, isLayoutState: Boolean): Boolean
Link copied to clipboard
fun commit()
Link copied to clipboard
fun commitLayoutState(localTreeState: TreeState)
Link copied to clipboard
fun commitResolveState(localTreeState: TreeState)
Link copied to clipboard
fun <T> createOrGetInitialHookState(key: String, kStateIndex: Int, deps: Array<*>, initializer: HookInitializer<T>, isLayoutState: Boolean, componentName: String): ComponentState<KStateContainer>
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun getCachedValue(globalKey: String, index: Int, cachedValueInputs: Any, isLayoutState: Boolean): Any?
Link copied to clipboard
fun getEventTrigger(triggerKey: String): EventTrigger<*>?
fun getEventTrigger(handle: Handle, methodId: Int): EventTrigger<*>?
Link copied to clipboard
fun getState(key: String, isLayoutState: Boolean): ComponentState<out StateContainer>?
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun markStateInUse(key: String, isLayoutState: Boolean)
Link copied to clipboard
fun putCachedValue(globalKey: String, index: Int, cachedValueInputs: Any, cachedValue: Any?, isLayoutState: Boolean)
Link copied to clipboard
fun queueHookStateUpdate(stateId: StateId, updater: HookUpdater, isLayoutState: Boolean)
Link copied to clipboard
fun queueStateUpdate(key: String, stateUpdate: StateContainer.StateUpdate, isLazyStateUpdate: Boolean, isLayoutState: Boolean)
Link copied to clipboard
fun recordRenderData(layoutState: LayoutState)
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun removePendingStateUpdate(key: String, isLayoutState: Boolean)
Link copied to clipboard