public class ClickListenerHelper<Item extends IItem>
extends java.lang.Object
| Constructor and Description |
|---|
ClickListenerHelper(FastAdapter<Item> fastAdapter)
ctor
|
ClickListenerHelper(FastAdapter<Item> fastAdapter,
java.util.List<EventHook> eventHooks) |
| Modifier and Type | Method and Description |
|---|---|
ClickListenerHelper<Item> |
addEventHook(EventHook eventHook)
adds a new eventHook
note this will not add new event hooks for existing viewHolders after it was created
|
void |
bind(android.support.v7.widget.RecyclerView.ViewHolder viewHolder)
binds the hooks to the viewHolder
|
java.util.List<EventHook> |
getEventHooks() |
ClickListenerHelper<Item> |
setEventHooks(java.util.List<EventHook> eventHooks)
adds a new list of eventHook
note this will not add new event hooks for existing viewHolders after it was created
|
public ClickListenerHelper(FastAdapter<Item> fastAdapter)
fastAdapter - the fastAdapter which manages these itemspublic ClickListenerHelper(FastAdapter<Item> fastAdapter, java.util.List<EventHook> eventHooks)
fastAdapter - the fastAdapter which manages these itemseventHooks - the event hooks we want to use for this itempublic java.util.List<EventHook> getEventHooks()
public ClickListenerHelper<Item> setEventHooks(java.util.List<EventHook> eventHooks)
eventHooks - a new list of eventHookpublic ClickListenerHelper<Item> addEventHook(EventHook eventHook)
eventHook - a new eventHookpublic void bind(@NonNull
android.support.v7.widget.RecyclerView.ViewHolder viewHolder)
viewHolder - the viewHolder of the item