The Android Developer Challenge is back! Submit your idea before December 2.

SortedListAdapterCallback

abstract class SortedListAdapterCallback<T2 : Any!> : SortedList.Callback<T2>
kotlin.Any
   ↳ androidx.recyclerview.widget.SortedList.Callback<T2>
   ↳ androidx.recyclerview.widget.SortedListAdapterCallback

A SortedList.Callback implementation that can bind a SortedList to a RecyclerView.Adapter.

Summary

Public constructors

Creates a SortedList.Callback that will forward data change events to the provided Adapter.

Public methods

open Unit
onChanged(position: Int, count: Int)

open Unit
onChanged(position: Int, count: Int, payload: Any?)

open Unit
onInserted(position: Int, count: Int)

open Unit
onMoved(fromPosition: Int, toPosition: Int)

open Unit
onRemoved(position: Int, count: Int)

Inherited functions

Public constructors

<init>

SortedListAdapterCallback(adapter: RecyclerView.Adapter<RecyclerView.ViewHolder!>!)

Creates a SortedList.Callback that will forward data change events to the provided Adapter.

Parameters
adapter RecyclerView.Adapter<RecyclerView.ViewHolder!>!: The Adapter instance which should receive events from the SortedList.

Public methods

onChanged

open fun onChanged(position: Int, count: Int): Unit

onChanged

open fun onChanged(position: Int, count: Int, payload: Any?): Unit

onInserted

open fun onInserted(position: Int, count: Int): Unit

onMoved

open fun onMoved(fromPosition: Int, toPosition: Int): Unit

onRemoved

open fun onRemoved(position: Int, count: Int): Unit