이제 두 번째 Android 11 개발자 프리뷰를 사용할 수 있습니다. 테스트해 보고 의견을 공유하세요.

ListItem.ViewHolder

public static abstract class ListItem.ViewHolder
extends RecyclerView.ViewHolder implements OnUxRestrictionsChangedListener

java.lang.Object
   ↳ androidx.recyclerview.widget.RecyclerView.ViewHolder
     ↳ androidx.car.widget.ListItem.ViewHolder


ViewHolder that supports ListItem.ViewBinder.

Summary

Inherited fields

Public constructors

ListItem.ViewHolder(View itemView)

Public methods

final void addCleanUp(ViewBinder<ListItem.ViewHolder> cleanUp)

Stores clean up ViewBinders that will be called in cleanUp().

final void cleanUp()

Removes customization from previous ListItem.

Inherited methods

Public constructors

ListItem.ViewHolder

public ListItem.ViewHolder (View itemView)

Parameters
itemView View

Public methods

addCleanUp

public final void addCleanUp (ViewBinder<ListItem.ViewHolder> cleanUp)

Stores clean up ViewBinders that will be called in cleanUp().

Parameters
cleanUp ViewBinder

cleanUp

public final void cleanUp ()

Removes customization from previous ListItem. Intended to be used when this ViewHolder is bound to a ListItem.