pub struct MessageAttachment {
pub id: Snowflake,
pub filename: String,
pub size: i32,
pub url: String,
pub proxy_url: String,
pub height: Option<i32>,
pub width: Option<i32>,
}
Expand description
Represents an attachment sent by a user.
Fields§
§id: Snowflake
The attachment ID.
filename: String
The name of the file attached.
size: i32
The size of the file in bytes.
url: String
The source URL of the file.
proxy_url: String
A proxied URL of the file.
height: Option<i32>
The height of the file, if it is an image.
width: Option<i32>
The width of the file, if it is an image.
Trait Implementations§
Source§impl Clone for MessageAttachment
impl Clone for MessageAttachment
Source§fn clone(&self) -> MessageAttachment
fn clone(&self) -> MessageAttachment
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for MessageAttachment
impl Debug for MessageAttachment
Source§impl<'de> Deserialize<'de> for MessageAttachment
impl<'de> Deserialize<'de> for MessageAttachment
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for MessageAttachment
impl RefUnwindSafe for MessageAttachment
impl Send for MessageAttachment
impl Sync for MessageAttachment
impl Unpin for MessageAttachment
impl UnwindSafe for MessageAttachment
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