arch-android

//Android/br.com.arch.toolkit.android.recyclerAdapter/DefaultItemDiffer

DefaultItemDiffer

class DefaultItemDiffer<MODEL : Any> : DiffUtil.ItemCallback<MODEL>

A default implementation of DiffUtil.ItemCallback that uses the equality operator (==) for both item and content comparison.

Parameters

android

   
MODEL The type of data items being compared.

Constructors

   
DefaultItemDiffer [android]
constructor()

Functions

Name Summary
areContentsTheSame [android]
open override fun areContentsTheSame(oldItem: MODEL, newItem: MODEL): Boolean
Checks if two items have the same content using equality (==).
areItemsTheSame [android]
open override fun areItemsTheSame(oldItem: MODEL, newItem: MODEL): Boolean
Checks if two items represent the same object using equality (==).
getChangePayload [android]
@Nullable
open fun getChangePayload(@NonNulloldItem: MODEL & Any, @NonNullnewItem: MODEL & Any): Any?