ReactiveRecyclerViewAdapter.GetItemViewType(int) method¶
Defined in
Type: ReactiveRecyclerViewAdapterReactiveUI.AndroidX
Assembly: ReactiveUI.AndroidX.dll
Applies to
net10.0-android36.0
Overloads¶
-
public override int GetItemViewType(int position) -
public virtual int GetItemViewType(int position, TViewModel? viewModel)
1. Overload¶
public override int GetItemViewType(int position)
View source (opens in a new tab)
Inherited documentation
These docs were inherited from Adapter. The member doesn't override them on this type.
Parameters
| Name | Type | Description |
|---|---|---|
position | int (opens in a new tab) | -- |
Returns: int (opens in a new tab)
2. Overload¶
public virtual int GetItemViewType(int position, TViewModel? viewModel)
View source (opens in a new tab)
Summary: Determine the View that will be used/re-used in lists where the list contains different cell designs.
Parameters
| Name | Type | Description |
|---|---|---|
position | int (opens in a new tab) | The position of the current view in the list. |
viewModel | TViewModel? | The ViewModel associated with the current View. |
Returns: int (opens in a new tab) -- An ID to be used in OnCreateViewHolder.