pub struct User {
pub verified: bool,
pub username: String,
pub mfa_enabled: bool,
pub id: String,
pub global_name: Option<String>,
pub flags: usize,
pub email: Option<String>,
pub discriminator: String,
pub bot: bool,
pub avatar_hash: Option<String>,
pub mention: String,
}Expand description
Represents a user in Discord.
Fields§
§verified: boolWhether the user is verified.
username: StringThe username of the user.
mfa_enabled: boolWhether the user has multi-factor authentication enabled.
id: StringThe unique ID of the user.
global_name: Option<String>The global name of the user.
flags: usizeThe flags of the user.
email: Option<String>The email of the user.
discriminator: StringThe discriminator of the user.
bot: boolWhether the user is a bot.
avatar_hash: Option<String>The hash of the user’s avatar.
mention: StringThe mention string for the user.
Implementations§
Source§impl User
impl User
Sourcepub fn get_avatar_url(
&self,
image_format: ImageFormat,
size: Option<u32>,
) -> Option<String>
pub fn get_avatar_url( &self, image_format: ImageFormat, size: Option<u32>, ) -> Option<String>
Trait Implementations§
Auto Trait Implementations§
impl Freeze for User
impl RefUnwindSafe for User
impl Send for User
impl Sync for User
impl Unpin for User
impl UnsafeUnpin for User
impl UnwindSafe for User
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