pub struct IdentityStatusChanges { /* private fields */ }
e2e-encryption
and non-WebAssembly only.Expand description
Support for creating a stream of batches of IdentityStatusChange
.
Internally, this subscribes to all identity changes, and to room events that change the membership, and provides a stream of all changes to the identity status of all room members.
This struct does not represent the actual stream, but the state that is used to produce the values of the stream.
It does provide a method to create the stream:
IdentityStatusChanges::create_stream
.
Implementations§
Source§impl IdentityStatusChanges
impl IdentityStatusChanges
Sourcepub async fn create_stream(
room: Room,
) -> Result<impl Stream<Item = Vec<IdentityStatusChange>>>
pub async fn create_stream( room: Room, ) -> Result<impl Stream<Item = Vec<IdentityStatusChange>>>
Create a new stream of changes to the identity status of members of a room.
The “status” of an identity changes when our level of trust in it changes.
For example, if an identity is “pinned” i.e. not manually verified, but known, and it becomes a “unpinned” i.e. unknown, because the encryption keys are different and the user has not acknowledged this, then this constitutes a status change. Also, if an identity is “unpinned” and becomes “pinned”, this is also a status change.
The supplied stream is intended to provide enough information for a client to display a list of room members whose identities have changed, and allow the user to acknowledge this or act upon it.
Note: when an unpinned user leaves a room, an update is generated stating that they have become pinned, even though they may not necessarily have become pinned, but we don’t care any more because they left the room.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for IdentityStatusChanges
impl !RefUnwindSafe for IdentityStatusChanges
impl Send for IdentityStatusChanges
impl Sync for IdentityStatusChanges
impl Unpin for IdentityStatusChanges
impl !UnwindSafe for IdentityStatusChanges
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T, W> HasTypeWitness<W> for Twhere
W: MakeTypeWitness<Arg = T>,
T: ?Sized,
impl<T, W> HasTypeWitness<W> for Twhere
W: MakeTypeWitness<Arg = T>,
T: ?Sized,
Source§impl<T> Identity for Twhere
T: ?Sized,
impl<T> Identity for Twhere
T: ?Sized,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more