pub struct FilePart {
pub file: FileContent,
pub metadata: BTreeMap<String, Value>,
}Expand description
A file part. Wire form:
{ "file": {...}, "metadata"?: {...} }.
Fields§
§file: FileContentThe file’s content. Either bytes (an
inline base64 string) or uri is set;
the spec does not allow both. The Rust
type does not enforce the rule at the
type level — a builder that wants the
guarantee enforces it before
construction.
metadata: BTreeMap<String, Value>Per-part metadata. Same shape and
rationale as Message::metadata.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for FilePart
impl<'de> Deserialize<'de> for FilePart
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 FilePart
impl StructuralPartialEq for FilePart
Auto Trait Implementations§
impl Freeze for FilePart
impl RefUnwindSafe for FilePart
impl Send for FilePart
impl Sync for FilePart
impl Unpin for FilePart
impl UnsafeUnpin for FilePart
impl UnwindSafe for FilePart
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