pub struct DebugDoc {
pub inner: Doc<'static, BoxDoc<'static, ShellAnnotation>, ShellAnnotation>,
}
Fields§
§inner: Doc<'static, BoxDoc<'static, ShellAnnotation>, ShellAnnotation>
Implementations§
Source§impl DebugDoc
impl DebugDoc
Sourcepub fn new(
inner: Doc<'static, BoxDoc<'static, ShellAnnotation>, ShellAnnotation>,
) -> Self
pub fn new( inner: Doc<'static, BoxDoc<'static, ShellAnnotation>, ShellAnnotation>, ) -> Self
Constructs a new DebugDoc
.
Methods from Deref<Target = Doc<'static, BoxDoc<'static, ShellAnnotation>, ShellAnnotation>>§
Sourcepub fn render<'b, W>(&'b self, width: usize, out: &mut W) -> Result<(), Error>
pub fn render<'b, W>(&'b self, width: usize, out: &mut W) -> Result<(), Error>
Writes a rendered document to a std::io::Write
object.
Sourcepub fn render_fmt<'b, W>(
&'b self,
width: usize,
out: &mut W,
) -> Result<(), Error>
pub fn render_fmt<'b, W>( &'b self, width: usize, out: &mut W, ) -> Result<(), Error>
Writes a rendered document to a std::fmt::Write
object.
Sourcepub fn render_raw<'b, W>(
&'b self,
width: usize,
out: &mut W,
) -> Result<(), <W as Render>::Error>
pub fn render_raw<'b, W>( &'b self, width: usize, out: &mut W, ) -> Result<(), <W as Render>::Error>
Writes a rendered document to a RenderAnnotated<A>
object.
Trait Implementations§
Source§impl From<DebugDoc> for Doc<'static, BoxDoc<'static, ShellAnnotation>, ShellAnnotation>
impl From<DebugDoc> for Doc<'static, BoxDoc<'static, ShellAnnotation>, ShellAnnotation>
Source§fn from(
input: DebugDoc,
) -> Doc<'static, BoxDoc<'static, ShellAnnotation>, ShellAnnotation>
fn from( input: DebugDoc, ) -> Doc<'static, BoxDoc<'static, ShellAnnotation>, ShellAnnotation>
Converts to this type from the input type.
Source§impl Ord for DebugDoc
impl Ord for DebugDoc
Source§impl PartialOrd for DebugDoc
impl PartialOrd for DebugDoc
Source§impl PrettyDebug for DebugDoc
impl PrettyDebug for DebugDoc
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>
Source§fn display(&self) -> String
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
impl Eq for DebugDoc
impl StructuralPartialEq for DebugDoc
Auto Trait Implementations§
impl Freeze for DebugDoc
impl RefUnwindSafe for DebugDoc
impl Send for DebugDoc
impl Sync for DebugDoc
impl Unpin for DebugDoc
impl UnwindSafe for DebugDoc
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