public class ViewCompatComponent<V extends View> extends ComponentLifecycle
ViewBinder
class to bind the view
and a ViewCreator
to create the mount contents.
This component will have a different recycle pool per ViewCreator
.Modifier and Type | Class and Description |
---|---|
static class |
ViewCompatComponent.Builder<V extends View> |
ComponentLifecycle.MountType, ComponentLifecycle.RenderData, ComponentLifecycle.StateContainer, ComponentLifecycle.StateUpdate
Modifier and Type | Method and Description |
---|---|
protected boolean |
canMeasure()
Whether this
ComponentLifecycle is able to measure itself according
to specific size constraints. |
ViewCompatComponent.Builder<V> |
create(ComponentContext componentContext) |
static <V extends View> |
get(ViewCreator<V> viewCreator,
String componentName) |
ComponentLifecycle.MountType |
getMountType()
This indicates the type of the
Object that will be returned by
ComponentLifecycle.mount(com.facebook.litho.ComponentContext, java.lang.Object, com.facebook.litho.Component<?>) . |
protected void |
onMeasure(ComponentContext c,
ComponentLayout layout,
int widthSpec,
int heightSpec,
Size size,
Component<?> component) |
protected void |
onPrepare(ComponentContext c,
Component<?> component) |
acceptTriggerEvent, acquireDiff, acquireOutput, applyPreviousRenderData, callsShouldUpdateOnMount, canAcceptTrigger, canMountIncrementally, canPreallocate, createInitialState, dispatchOnEvent, getEventTrigger, getExtraAccessibilityNodeAt, getExtraAccessibilityNodesCount, getTreePropsForChildren, hasState, implementsAccessibility, implementsExtraAccessibilityNodes, isMountSizeDependent, isPureRender, needsPreviousRenderData, newEventHandler, newEventHandler, newEventTrigger, onBind, onBoundsDefined, onCreateLayout, onCreateLayoutWithSizeSpec, onCreateMountContent, onCreateTransition, onLoadStyle, onMeasureBaseline, onMount, onPopulateAccessibilityNode, onPopulateExtraAccessibilityNode, onUnbind, onUnmount, poolSize, populateTreeProps, recordRenderData, releaseDiff, releaseOutput, shouldUpdate, shouldUseDisplayList, transferState
public static <V extends View> ViewCompatComponent<V> get(ViewCreator<V> viewCreator, String componentName)
public ViewCompatComponent.Builder<V> create(ComponentContext componentContext)
protected boolean canMeasure()
ComponentLifecycle
ComponentLifecycle
is able to measure itself according
to specific size constraints.canMeasure
in class ComponentLifecycle
protected void onMeasure(ComponentContext c, ComponentLayout layout, int widthSpec, int heightSpec, Size size, Component<?> component)
onMeasure
in class ComponentLifecycle
protected void onPrepare(ComponentContext c, Component<?> component)
onPrepare
in class ComponentLifecycle
public ComponentLifecycle.MountType getMountType()
ComponentLifecycle
Object
that will be returned by
ComponentLifecycle.mount(com.facebook.litho.ComponentContext, java.lang.Object, com.facebook.litho.Component<?>)
.getMountType
in class ComponentLifecycle
ComponentLifecycle.MountType