pub trait UsernameReader: Send + Sync {
// Required methods
fn get_username_by_wallet<'life0, 'life1, 'async_trait>(
&'life0 self,
wallet: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<UsernameRecord>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn get_username_by_name<'life0, 'life1, 'async_trait>(
&'life0 self,
username: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<UsernameRecord>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
}Expand description
Read-only username queries.
Required Methods§
Sourcefn get_username_by_wallet<'life0, 'life1, 'async_trait>(
&'life0 self,
wallet: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<UsernameRecord>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_username_by_wallet<'life0, 'life1, 'async_trait>(
&'life0 self,
wallet: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<UsernameRecord>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Look up the username for a wallet (case-insensitive wallet match).
Sourcefn get_username_by_name<'life0, 'life1, 'async_trait>(
&'life0 self,
username: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<UsernameRecord>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn get_username_by_name<'life0, 'life1, 'async_trait>(
&'life0 self,
username: &'life1 str,
) -> Pin<Box<dyn Future<Output = Result<Option<UsernameRecord>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Reverse lookup: find the wallet that owns a username (case-insensitive).