Trait clap_builder::error::ErrorFormatter

source ·
pub trait ErrorFormatter: Sized {
    // Required method
    fn format_error(error: &Error<Self>) -> StyledStr;
}
Expand description

Defines how to format an error for displaying to the user

Required Methods§

source

fn format_error(error: &Error<Self>) -> StyledStr

Stylize the error for the terminal

Object Safety§

This trait is not object safe.

Implementors§

source§

impl ErrorFormatter for KindFormatter

source§

impl ErrorFormatter for RichFormatter

Available on crate feature error-context only.