-
public abstract class BaseMessageItemViewHolder<T extends MessageListItem> extends RecyclerView.ViewHolder
Base ViewHolder used for displaying messages in io.getstream.chat.android.ui.feature.messages.list.adapter.internal.MessageListItemAdapter.
-
-
Field Summary
Fields Modifier and Type Field Description private Tdataprivate final ViewitemViewprivate final WeakReference<RecyclerView>mNestedRecyclerViewprivate final IntegermPositionprivate final IntegermOldPositionprivate final LongmItemIdprivate final IntegermItemViewTypeprivate final IntegermPreLayoutPositionprivate final RecyclerView.ViewHoldermShadowedHolderprivate final RecyclerView.ViewHoldermShadowingHolderprivate final IntegermFlagsprivate final List<Object>mPayloadsprivate final List<Object>mUnmodifiedPayloadsprivate final RecyclerView.RecyclermScrapContainerprivate final BooleanmInChangeScrapprivate final IntegermPendingAccessibilityStateprivate final RecyclerViewmOwnerRecyclerViewprivate final RecyclerView.Adapter<out RecyclerView.ViewHolder>mBindingAdapter
-
Constructor Summary
Constructors Constructor Description BaseMessageItemViewHolder(View itemView)
-
Method Summary
Modifier and Type Method Description final TgetData()The data that was last bound to this ViewHolder via bindData. final UnitsetData(T data)ViewmessageContainerView()Returns the Message container that we can use to anchor UI based on its size and position. abstract UnitbindData(T data, MessageListItemPayloadDiff diff)Unitunbind()UnitonDetachedFromWindow()Called when this view holder and its' view were detached from window. UnitonAttachedToWindow()Called when this view holder and its' view were attached to window. -
Methods inherited from class io.getstream.chat.android.ui.feature.messages.list.adapter.BaseMessageItemViewHolder
addChangePayload, addFlags, clearOldPosition, clearPayload, clearReturnedFromScrapFlag, clearTmpDetachFlag, doesTransientStatePreventRecycling, flagRemovedAndOffsetPosition, getAbsoluteAdapterPosition, getAdapterPosition, getBindingAdapter, getBindingAdapterPosition, getItemId, getItemViewType, getLayoutPosition, getOldPosition, getPosition, getUnmodifiedPayloads, hasAnyOfTheFlags, isAdapterPositionUnknown, isAttachedToTransitionOverlay, isBound, isInvalid, isRecyclable, isRemoved, isScrap, isTmpDetached, isUpdated, needsUpdate, offsetPosition, onEnteredHiddenState, onLeftHiddenState, resetInternal, saveOldPosition, setFlags, setIsRecyclable, setScrapContainer, shouldBeKeptAsChild, shouldIgnore, stopIgnoring, toString, unScrap, wasReturnedFromScrap -
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
-
Constructor Detail
-
BaseMessageItemViewHolder
BaseMessageItemViewHolder(View itemView)
-
-
Method Detail
-
getData
final T getData()
The data that was last bound to this ViewHolder via bindData. Can be used for listeners that need to pass along the currently bound data as a parameter.
-
messageContainerView
View messageContainerView()
Returns the Message container that we can use to anchor UI based on its size and position.
-
bindData
abstract Unit bindData(T data, MessageListItemPayloadDiff diff)
-
onDetachedFromWindow
Unit onDetachedFromWindow()
Called when this view holder and its' view were detached from window.
-
onAttachedToWindow
Unit onAttachedToWindow()
Called when this view holder and its' view were attached to window.
-
-
-
-