OptionsAdapter

class OptionsAdapter(optionTextLimit: Int?, onOptionChange: (id: Int, text: String) -> Unit) : ListAdapter<PollAnswer, OptionsAdapter.OptionViewHolder>

Constructors

Link copied to clipboard
constructor(optionTextLimit: Int?, onOptionChange: (id: Int, text: String) -> Unit)
constructor(onOptionChange: (id: Int, text: String) -> Unit)

Builds an OptionsAdapter instance without providing option text limit.

Types

Link copied to clipboard
class OptionViewHolder(parent: ViewGroup, binding: ERROR CLASS: Symbol not found for StreamUiPollOptionBinding = StreamUiPollOptionBinding.inflate( parent.streamThemeInflater, parent, false, ), optionTextLimit: Int?, onOptionChange: (id: Int, text: String) -> Unit) : RecyclerView.ViewHolder

Properties

Link copied to clipboard
@get:NonNull
open override val currentList: List<PollAnswer?>
Link copied to clipboard
open override val itemCount: Int

Functions

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open override fun getItemId(position: Int): Long
Link copied to clipboard
open fun getItemViewType(position: Int): Int
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun notifyItemChanged(position: Int)
fun notifyItemChanged(position: Int, @Nullable payload: Any?)
Link copied to clipboard
fun notifyItemInserted(position: Int)
Link copied to clipboard
fun notifyItemMoved(fromPosition: Int, toPosition: Int)
Link copied to clipboard
fun notifyItemRangeChanged(positionStart: Int, itemCount: Int)
fun notifyItemRangeChanged(positionStart: Int, itemCount: Int, @Nullable payload: Any?)
Link copied to clipboard
fun notifyItemRangeInserted(positionStart: Int, itemCount: Int)
Link copied to clipboard
fun notifyItemRangeRemoved(positionStart: Int, itemCount: Int)
Link copied to clipboard
fun notifyItemRemoved(position: Int)
Link copied to clipboard
Link copied to clipboard
open fun onBindViewHolder(@NonNull holder: OptionsAdapter.OptionViewHolder, position: Int, @NonNull payloads: List<Any?>)
open override fun onBindViewHolder(holder: OptionsAdapter.OptionViewHolder, position: Int)
Link copied to clipboard
open override fun onCreateViewHolder(parent: ViewGroup, viewType: Int): OptionsAdapter.OptionViewHolder
Link copied to clipboard
open fun onCurrentListChanged(@NonNull previousList: List<PollAnswer?>, @NonNull currentList: List<PollAnswer?>)
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
open fun setHasStableIds(hasStableIds: Boolean)
Link copied to clipboard
open fun submitList(@Nullable list: List<PollAnswer?>??)
open fun submitList(@Nullable list: List<PollAnswer?>??, @Nullable commitCallback: Runnable?)