Struct dts_core::ser::SerializeOptions
source · [−]pub struct SerializeOptions {
pub compact: bool,
pub newline: bool,
pub keys_as_csv_headers: bool,
pub csv_delimiter: Option<u8>,
pub text_join_separator: Option<String>,
}Expand description
Options for the Serializer. The options are context specific and may only be honored when
serializing into a certain Encoding.
Fields
compact: boolEmit output data in a compact format. This will disable pretty printing for encodings that support it.
newline: boolAppend a trailing newline to the serialized data.
keys_as_csv_headers: boolWhen the input is an array of objects and the output encoding is CSV, the field names of the first object will be used as CSV headers. Field values of all following objects will be matched to the right CSV column based on their key. Missing fields produce empty columns while excess fields are ignored.
csv_delimiter: Option<u8>Optional custom delimiter for CSV output.
text_join_separator: Option<String>Optional seprator to join text output with.
Implementations
Trait Implementations
sourceimpl Clone for SerializeOptions
impl Clone for SerializeOptions
sourcefn clone(&self) -> SerializeOptions
fn clone(&self) -> SerializeOptions
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source. Read more
sourceimpl Debug for SerializeOptions
impl Debug for SerializeOptions
sourceimpl Default for SerializeOptions
impl Default for SerializeOptions
sourcefn default() -> SerializeOptions
fn default() -> SerializeOptions
Returns the “default value” for a type. Read more
sourceimpl PartialEq<SerializeOptions> for SerializeOptions
impl PartialEq<SerializeOptions> for SerializeOptions
sourcefn eq(&self, other: &SerializeOptions) -> bool
fn eq(&self, other: &SerializeOptions) -> bool
This method tests for self and other values to be equal, and is used
by ==. Read more
sourcefn ne(&self, other: &SerializeOptions) -> bool
fn ne(&self, other: &SerializeOptions) -> bool
This method tests for !=.
impl StructuralPartialEq for SerializeOptions
Auto Trait Implementations
impl RefUnwindSafe for SerializeOptions
impl Send for SerializeOptions
impl Sync for SerializeOptions
impl Unpin for SerializeOptions
impl UnwindSafe for SerializeOptions
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<T> Pointable for T
impl<T> Pointable for T
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into)Uses borrowed data to replace owned data, usually by cloning. Read more