#[non_exhaustive]pub struct SortOptions {
pub pretty: bool,
pub sort_scripts: bool,
}Expand description
Options for controlling JSON formatting when sorting.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.pretty: boolWhether to pretty-print the output JSON.
sort_scripts: boolWhether to sort the scripts field alphabetically.
Implementations§
Source§impl SortOptions
impl SortOptions
Sourcepub const fn with_pretty(self, pretty: bool) -> Self
pub const fn with_pretty(self, pretty: bool) -> Self
Sets whether the output is pretty-printed.
Sourcepub const fn with_sort_scripts(self, sort_scripts: bool) -> Self
pub const fn with_sort_scripts(self, sort_scripts: bool) -> Self
Sets whether the scripts, betterScripts, and wireit fields are sorted.
Trait Implementations§
Source§impl Clone for SortOptions
impl Clone for SortOptions
impl Copy for SortOptions
Source§impl Debug for SortOptions
impl Debug for SortOptions
Source§impl Default for SortOptions
impl Default for SortOptions
impl Eq for SortOptions
Source§impl PartialEq for SortOptions
impl PartialEq for SortOptions
impl StructuralPartialEq for SortOptions
Auto Trait Implementations§
impl Freeze for SortOptions
impl RefUnwindSafe for SortOptions
impl Send for SortOptions
impl Sync for SortOptions
impl Unpin for SortOptions
impl UnsafeUnpin for SortOptions
impl UnwindSafe for SortOptions
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