Struct ruma::api::client::r0::filter::RoomFilter [−][src]
pub struct RoomFilter<'a> {
pub include_leave: bool,
pub account_data: RoomEventFilter<'a>,
pub timeline: RoomEventFilter<'a>,
pub ephemeral: RoomEventFilter<'a>,
pub state: RoomEventFilter<'a>,
pub not_rooms: &'a [RoomId],
pub rooms: Option<&'a [RoomId]>,
}
api
and (crate features client-api
or client-api-c
or client-api-s
) only.Expand description
Filters to be applied to room data.
Fields
include_leave: bool
Include rooms that the user has left in the sync.
Defaults to false
.
account_data: RoomEventFilter<'a>
The per user account data to include for rooms.
timeline: RoomEventFilter<'a>
The message and state update events to include for rooms.
ephemeral: RoomEventFilter<'a>
The events that aren’t recorded in the room history, e.g. typing and receipts, to include for rooms.
state: RoomEventFilter<'a>
The state events to include for rooms.
not_rooms: &'a [RoomId]
A list of room IDs to exclude.
If this list is absent then no rooms are excluded. A matching room will be excluded even if
it is listed in the ‘rooms’ filter. This filter is applied before the filters in
ephemeral
, state
, timeline
or account_data
.
rooms: Option<&'a [RoomId]>
A list of room IDs to include.
If this list is absent then all rooms are included. This filter is applied before the
filters in ephemeral
, state
, timeline
or account_data
.
Implementations
Creates an empty RoomFilter
.
You can also use the Default
implementation.
Creates a new RoomFilter
that can be used to ignore all room events (of any type).
Trait Implementations
Returns the “default value” for a type. Read more
type Incoming = IncomingRoomFilter
type Incoming = IncomingRoomFilter
The ‘Incoming’ variant of Self
.
pub fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error> where
__S: Serializer,
pub fn serialize<__S>(
&self,
__serializer: __S
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error> where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
Auto Trait Implementations
impl<'a> RefUnwindSafe for RoomFilter<'a>
impl<'a> Send for RoomFilter<'a>
impl<'a> Sync for RoomFilter<'a>
impl<'a> Unpin for RoomFilter<'a>
impl<'a> UnwindSafe for RoomFilter<'a>
Blanket Implementations
Mutably borrows from an owned value. Read more
Instruments this type with the provided Span
, returning an
Instrumented
wrapper. Read more
Instruments this type with the provided Span
, returning an
Instrumented
wrapper. Read more
type Output = T
type Output = T
Should always be Self
pub fn vzip(self) -> V
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more