pub struct AttachmentFile {
pub filename: String,
pub data: Vec<u8>,
pub content_type: Option<String>,
}Expand description
A file to attach when sending a message. Pass one or more of these to
[Http::send_files] or [Http::send_message_with_files].
Fields§
§filename: StringFilename shown in the client, e.g. "image.png".
data: Vec<u8>§content_type: Option<String>MIME type, e.g. "image/png". If None, defaults to "application/octet-stream".
Auto Trait Implementations§
impl Freeze for AttachmentFile
impl RefUnwindSafe for AttachmentFile
impl Send for AttachmentFile
impl Sync for AttachmentFile
impl Unpin for AttachmentFile
impl UnsafeUnpin for AttachmentFile
impl UnwindSafe for AttachmentFile
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