pub struct Upload {
pub name: String,
pub size: u64,
pub mime: String,
pub sha3_256: Vec<u8>,
}Expand description
attachment.upload: declares a file the member is about to send.
Fields§
§name: StringThe file name shown to readers: 1–255 scalars, no path separator or control character.
size: u64Exact size in bytes, 1 to the host’s limit (at most 1 GiB).
mime: StringThe media type, such as image/png (type/subtype, ASCII, at most 127 bytes).
sha3_256: Vec<u8>SHA3-256 of the bytes, base64url. The host refuses a file that does not match.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Upload
impl<'de> Deserialize<'de> for Upload
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
impl Eq for Upload
impl StructuralPartialEq for Upload
Auto Trait Implementations§
impl Freeze for Upload
impl RefUnwindSafe for Upload
impl Send for Upload
impl Sync for Upload
impl Unpin for Upload
impl UnsafeUnpin for Upload
impl UnwindSafe for Upload
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