Listener

interface Listener

Functions

Link copied to clipboard
open fun onNewTimelineEvents(eventIds: List<String>)

Called when new events come through the sync. Note that the corresponding events may not be available yet in the database. onTimelineUpdated will be called with the event content.

Link copied to clipboard
open fun onStateUpdated(direction: Timeline.Direction, state: Timeline.PaginationState)

Called when the pagination state has changed in one direction.

Link copied to clipboard
open fun onTimelineFailure(throwable: Throwable)

Called whenever an error we can't recover from occurred.

Link copied to clipboard
open fun onTimelineUpdated(snapshot: List<TimelineEvent>)

Call when the timeline has been updated through pagination or sync. The latest event is the first in the list