Trait matrix_sdk_ui::timeline::RoomExt

source ·
pub trait RoomExt {
    // Required methods
    fn timeline<'life0, 'async_trait>(
        &'life0 self,
    ) -> Pin<Box<dyn Future<Output = Result<Timeline, Error>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait;
    fn timeline_builder(&self) -> TimelineBuilder;
}

Required Methods§

source

fn timeline<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<Timeline, Error>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

Get a Timeline for this room.

This offers a higher-level API than event handlers, in treating things like edits and reactions as updates of existing items rather than new independent events.

This is the same as using room.timeline_builder().build().

source

fn timeline_builder(&self) -> TimelineBuilder

Get a TimelineBuilder for this room.

Timeline offers a higher-level API than event handlers, in treating things like edits and reactions as updates of existing items rather than new independent events.

This allows to customize settings of the Timeline before constructing it.

Implementations on Foreign Types§

source§

impl RoomExt for Room

source§

fn timeline<'life0, 'async_trait>( &'life0 self, ) -> Pin<Box<dyn Future<Output = Result<Timeline, Error>> + Send + 'async_trait>>
where Self: 'async_trait, 'life0: 'async_trait,

source§

fn timeline_builder(&self) -> TimelineBuilder

Implementors§