Enum gix_transport::client::WriteMode
source · pub enum WriteMode {
Binary,
OneLfTerminatedLinePerWriteCall,
}
Expand description
Configure how the RequestWriter
behaves when writing bytes.
Variants§
Binary
Each write() call writes the bytes verbatim as one or more packet lines.
This mode also indicates to the transport that it should try to stream data as it is unbounded. This mode is typically used for sending packs whose exact size is not necessarily known in advance.
OneLfTerminatedLinePerWriteCall
Each write() call assumes text in the input, assures a trailing newline and writes it as single packet line.
This mode also indicates that the lines written fit into memory, hence the transport may chose to not stream it but to buffer it instead. This is relevant for some transports, like the one for HTTP.
Trait Implementations§
source§impl<'de> Deserialize<'de> for WriteMode
impl<'de> Deserialize<'de> for WriteMode
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
source§impl From<WriteMode> for PostBodyDataKind
Available on crate features http-client
and blocking-client
only.
impl From<WriteMode> for PostBodyDataKind
Available on crate features
http-client
and blocking-client
only.source§impl Ord for WriteMode
impl Ord for WriteMode
source§impl PartialEq for WriteMode
impl PartialEq for WriteMode
source§impl PartialOrd for WriteMode
impl PartialOrd for WriteMode
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moreimpl Copy for WriteMode
impl Eq for WriteMode
impl StructuralPartialEq for WriteMode
Auto Trait Implementations§
impl Freeze for WriteMode
impl RefUnwindSafe for WriteMode
impl Send for WriteMode
impl Sync for WriteMode
impl Unpin for WriteMode
impl UnwindSafe for WriteMode
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