Package 

Class ThreadListViewModel

    • Field Summary

      Fields 
      Modifier and Type Field Description
      private final StateFlow<ThreadListState> state
    • Constructor Summary

      Constructors 
      Constructor Description
      ThreadListViewModel(ThreadListController controller)
    • Method Summary

      Modifier and Type Method Description
      final StateFlow<ThreadListState> getState() The current thread list state.
      final Unit load() Loads the initial data when requested.
      final Unit loadNextPage() Loads more data when requested.
      • Methods inherited from class io.getstream.chat.android.compose.viewmodel.threads.ThreadListViewModel

        addCloseable, addCloseable, addCloseable, getCloseable
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • ThreadListViewModel

        ThreadListViewModel(ThreadListController controller)
        Parameters:
        controller - The ThreadListController handling the business logic and the state management for the threads list.
    • Method Detail

      • getState

         final StateFlow<ThreadListState> getState()

        The current thread list state.

      • load

         final Unit load()

        Loads the initial data when requested. Overrides all previously retrieved data.

      • loadNextPage

         final Unit loadNextPage()

        Loads more data when requested.

        Does nothing if the end of the list has already been reached or loading is already in progress.