[][src]Trait nu_source::PrettyDebug

pub trait PrettyDebug {
    fn pretty(&self) -> DebugDocBuilder;

    fn to_doc(&self) -> DebugDoc { ... }
fn pretty_doc(
        &self
    ) -> Doc<'static, BoxDoc<'static, ShellAnnotation>, ShellAnnotation> { ... }
fn pretty_builder(
        &self
    ) -> DocBuilder<'static, BoxAllocator, ShellAnnotation> { ... }
fn display(&self) -> String { ... }
fn plain_string(&self, width: usize) -> String { ... }
fn colored_string(&self, width: usize) -> String { ... } }

Required methods

fn pretty(&self) -> DebugDocBuilder

Loading content...

Provided methods

fn to_doc(&self) -> DebugDoc

fn pretty_doc(
    &self
) -> Doc<'static, BoxDoc<'static, ShellAnnotation>, ShellAnnotation>

fn pretty_builder(&self) -> DocBuilder<'static, BoxAllocator, ShellAnnotation>

fn display(&self) -> String

A convenience method that prints out the document without colors in 70 columns. Generally, you should use plain_string or colored_string if possible, but display() can be useful for trace lines and things like that, where you don't have control over the terminal.

fn plain_string(&self, width: usize) -> String

fn colored_string(&self, width: usize) -> String

Loading content...

Implementations on Foreign Types

impl PrettyDebug for bool[src]

impl PrettyDebug for ()[src]

Loading content...

Implementors

impl PrettyDebug for DebugDoc[src]

impl PrettyDebug for DebugDocBuilder[src]

impl<T: PrettyDebug> PrettyDebug for Spanned<T>[src]

Loading content...