pub trait CsvStreamRequest {
// Required methods
fn csv_stream_body<S, T>(
self,
stream: S,
with_csv_header: bool,
delimiter: u8,
) -> RequestBuilder
where T: Serialize + Send + 'static,
S: Stream<Item = T> + Send + 'static;
fn try_csv_stream_body<S, T, E>(
self,
stream: S,
with_csv_header: bool,
delimiter: u8,
) -> RequestBuilder
where T: Serialize + Send + 'static,
S: Stream<Item = Result<T, E>> + Send + 'static,
E: Into<Box<dyn Error + Send + Sync>> + Send + 'static;
}Available on crate feature
csv only.Expand description
Extension trait for reqwest::RequestBuilder that streams a CSV request body.
See ReqwestStreamBody for the HTTP caveats that apply to every streamed request body.
Required Methods§
Sourcefn csv_stream_body<S, T>(
self,
stream: S,
with_csv_header: bool,
delimiter: u8,
) -> RequestBuilder
fn csv_stream_body<S, T>( self, stream: S, with_csv_header: bool, delimiter: u8, ) -> RequestBuilder
Streams stream as CSV, setting Content-Type: text/csv.
with_csv_header writes a header row from the field names before the first record.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".