public final class HideableDataDiffSection<T> extends SectionLifecycle
HideableDataDiffSectionSpec
that wraps a DataDiffSectionSpec
.
It provides the ability to remove an item from the DataDiffSection via the
HideItemEvent
.
This Section
emits the following events:
RenderWithHideItemHandlerEvent
whenever it needs a Component
to render a model T from
the list of data. A HideItemEvent
handler is a param of this event.
Providing an handler for this OnEvent
is mandatory.
GetUniqueIdentifierEvent
is fired when a single unique identifier is needed for a
model object.
Modifier and Type | Class and Description |
---|---|
static class |
HideableDataDiffSection.Builder<T> |
SectionLifecycle.StateContainer, SectionLifecycle.StateUpdate
acquireDiff, acquireOutput, bindService, createService, dataBound, dispatchLoadingEvent, generateChangeSet, getLoadingEventHandler, getService, getTreePropsForChildren, isDiffSectionSpec, newEventHandler, newEventHandler, populateTreeProps, refresh, releaseDiff, releaseOutput, requestFocus, requestFocus, requestFocus, requestFocusWithOffset, requestFocusWithOffset, shouldUpdate, transferService, unbindService, viewportChanged
public static <T> HideableDataDiffSection.Builder<T> create(SectionContext context)
protected void transferState(SectionContext context, SectionLifecycle.StateContainer prevStateContainer, Section component)
SectionLifecycle
transferState
in class SectionLifecycle
protected static void onBlacklistUpdateAsync(SectionContext c, Object modelObject, EventHandler<GetUniqueIdentifierEvent> getUniqueIdentifierHandlerParam)
protected static void onBlacklistUpdate(SectionContext c, Object modelObject, EventHandler<GetUniqueIdentifierEvent> getUniqueIdentifierHandlerParam)
public static EventHandler getRenderWithHideItemHandlerEventHandler(SectionContext context)
public static EventHandler getGetUniqueIdentifierEventHandler(SectionContext context)
public static EventHandler<RenderEvent> onRenderEvent(SectionContext c)
public static EventHandler<HideItemEvent> onHideItem(SectionContext c)
public Object dispatchOnEvent(EventHandler eventHandler, Object eventState)
dispatchOnEvent
in interface EventDispatcher
dispatchOnEvent
in class SectionLifecycle
protected void createInitialState(SectionContext c, Section _abstractImpl)
createInitialState
in class SectionLifecycle
protected Children createChildren(SectionContext c, Section _abstractImpl)
SectionLifecycle
GroupSectionSpec
method annotated with com.facebook.litho.sections.annotations.OnCreateChildren
createChildren
in class SectionLifecycle