pub struct SerializerOptions {
pub indent_step: usize,
pub anchor_generator: Option<fn(usize) -> String>,
}
Fields§
§indent_step: usize
Number of spaces to indent per nesting level when emitting block-style collections.
anchor_generator: Option<fn(usize) -> String>
Optional custom anchor-name generator.
Receives a monotonically increasing usize
id (starting at 1) and returns the
anchor name to emit. If None
, the built-in generator yields names like a1
, a2
, …
Trait Implementations§
Source§impl Clone for SerializerOptions
impl Clone for SerializerOptions
Source§fn clone(&self) -> SerializerOptions
fn clone(&self) -> SerializerOptions
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Default for SerializerOptions
impl Default for SerializerOptions
impl Copy for SerializerOptions
Auto Trait Implementations§
impl Freeze for SerializerOptions
impl RefUnwindSafe for SerializerOptions
impl Send for SerializerOptions
impl Sync for SerializerOptions
impl Unpin for SerializerOptions
impl UnwindSafe for SerializerOptions
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