pub struct CommandConfig<'a> { /* private fields */ }Expand description
A resolved config for formatting a specific command, with per-command overrides already applied.
Implementations§
Source§impl CommandConfig<'_>
impl CommandConfig<'_>
Sourcepub fn space_before_paren(&self) -> bool
pub fn space_before_paren(&self) -> bool
Whether this command should render a space before (.
Sourcepub fn line_width(&self) -> usize
pub fn line_width(&self) -> usize
Effective line width for the current command.
Sourcepub fn dangle_parens(&self) -> bool
pub fn dangle_parens(&self) -> bool
Effective dangling-paren setting for the current command.
Sourcepub fn dangle_align(&self) -> DangleAlign
pub fn dangle_align(&self) -> DangleAlign
Effective dangling-paren alignment for the current command.
Sourcepub fn command_case(&self) -> CaseStyle
pub fn command_case(&self) -> CaseStyle
Effective command casing rule for the current command.
Sourcepub fn keyword_case(&self) -> CaseStyle
pub fn keyword_case(&self) -> CaseStyle
Effective keyword casing rule for the current command.
Sourcepub fn max_pargs_hwrap(&self) -> usize
pub fn max_pargs_hwrap(&self) -> usize
Effective hanging-wrap positional argument threshold for the current command.
Sourcepub fn max_subgroups_hwrap(&self) -> usize
pub fn max_subgroups_hwrap(&self) -> usize
Effective hanging-wrap subgroup threshold for the current command.
Sourcepub fn wrap_after_first_arg(&self, spec_value: Option<bool>) -> bool
pub fn wrap_after_first_arg(&self, spec_value: Option<bool>) -> bool
Effective wrap_after_first_arg for the current command.
Resolution order: per-command user override > spec_value (from
the command spec’s layout overrides) > global config default.
Sourcepub fn indent_str(&self) -> String
pub fn indent_str(&self) -> String
Effective indentation unit for the current command.