pub struct MultipartFormDataWriter<W>where
W: Write,{
pub boundary: String,
/* private fields */
}
Fields§
§boundary: String
Implementations§
Source§impl<W> MultipartFormDataWriter<W>where
W: Write,
impl<W> MultipartFormDataWriter<W>where
W: Write,
pub fn new(writer: W) -> Self
pub fn with_boundary(writer: W, boundary: impl AsRef<str>) -> Self
pub fn write_text_field( &mut self, name: impl AsRef<str>, value: impl AsRef<str>, ) -> Result<(), IoError>
pub fn write_field<'a>( &mut self, name: impl AsRef<str>, value: impl AsRef<[u8]>, filename: impl Into<Option<&'a str>>, content_type: impl Into<Option<&'a str>>, headers: impl Into<Option<Vec<(&'a str, &'a str)>>>, ) -> Result<(), IoError>
pub fn finish(self) -> Result<W, IoError>
Trait Implementations§
Auto Trait Implementations§
impl<W> Freeze for MultipartFormDataWriter<W>where
W: Freeze,
impl<W> RefUnwindSafe for MultipartFormDataWriter<W>where
W: RefUnwindSafe,
impl<W> Send for MultipartFormDataWriter<W>where
W: Send,
impl<W> Sync for MultipartFormDataWriter<W>where
W: Sync,
impl<W> Unpin for MultipartFormDataWriter<W>where
W: Unpin,
impl<W> UnwindSafe for MultipartFormDataWriter<W>where
W: UnwindSafe,
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