pub struct SystemMessages(/* private fields */);Available on crate feature
system-messages only.Expand description
Collection of system messages for an account.
Implementations§
Source§impl SystemMessages
impl SystemMessages
Sourcepub fn new(target: BackendTarget, account_id: &AccountId) -> Self
pub fn new(target: BackendTarget, account_id: &AccountId) -> Self
Create new system messages.
Trait Implementations§
Source§impl SystemMessageManager for SystemMessages
impl SystemMessageManager for SystemMessages
Source§fn load_system_messages<'life0, 'async_trait>(
&'life0 mut self,
) -> Pin<Box<dyn Future<Output = Result<(), Self::Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn load_system_messages<'life0, 'async_trait>(
&'life0 mut self,
) -> Pin<Box<dyn Future<Output = Result<(), Self::Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Load system messages for an account into memory.
Source§fn subscribe(&self) -> Receiver<SysMessageCount>
fn subscribe(&self) -> Receiver<SysMessageCount>
Subscribe to the broadcast channel.
Source§fn counts(&self) -> SysMessageCount
fn counts(&self) -> SysMessageCount
Message counts.
Source§fn sorted_list(&self) -> Vec<(&Urn, &SysMessage)>
fn sorted_list(&self) -> Vec<(&Urn, &SysMessage)>
Sorted list of system messages.
Source§impl SystemMessageStorage for SystemMessages
impl SystemMessageStorage for SystemMessages
Source§fn list_system_messages<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<SystemMessageMap, Self::Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn list_system_messages<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<SystemMessageMap, Self::Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
List system messages for an account.
Source§fn insert_system_message<'life0, 'async_trait>(
&'life0 mut self,
key: Urn,
message: SysMessage,
) -> Pin<Box<dyn Future<Output = Result<(), Self::Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn insert_system_message<'life0, 'async_trait>(
&'life0 mut self,
key: Urn,
message: SysMessage,
) -> Pin<Box<dyn Future<Output = Result<(), Self::Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Add a system message to an account.
Source§fn remove_system_message<'life0, 'life1, 'async_trait>(
&'life0 mut self,
key: &'life1 Urn,
) -> Pin<Box<dyn Future<Output = Result<(), Self::Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn remove_system_message<'life0, 'life1, 'async_trait>(
&'life0 mut self,
key: &'life1 Urn,
) -> Pin<Box<dyn Future<Output = Result<(), Self::Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Remove a system message from an account.
Source§fn mark_system_message<'life0, 'life1, 'async_trait>(
&'life0 mut self,
key: &'life1 Urn,
is_read: bool,
) -> Pin<Box<dyn Future<Output = Result<(), Self::Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn mark_system_message<'life0, 'life1, 'async_trait>(
&'life0 mut self,
key: &'life1 Urn,
is_read: bool,
) -> Pin<Box<dyn Future<Output = Result<(), Self::Error>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Mark a system message as read or unread.
Auto Trait Implementations§
impl Freeze for SystemMessages
impl !RefUnwindSafe for SystemMessages
impl Send for SystemMessages
impl Sync for SystemMessages
impl Unpin for SystemMessages
impl !UnwindSafe for SystemMessages
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
Mutably borrows from an owned value. Read more