public static < Item extends IItem > void bind ( RecyclerView . ViewHolder viewHolder , @ Nullable final List < EventHook < Item > > eventHooks ) { if ( eventHooks == null ) { return ; } for ( final EventHook < Item > event : eventHooks ) { View view = event . onBind ( viewHolder ) ; if ( view != null ) { attachToView ( event , viewHolder , view ) ; } List < ? extends View > views = event . onBindMany ( viewHolder ) ; if ( views != null ) { for ( View v : views ) { attachToView ( event , viewHolder , v ) ; } } } }
binds the hooks to the viewHolder