pub struct ClrOutput<'a> { /* private fields */ }
Expand description
Manages output redirection in the CLR by using a StringWriter
.
This struct handles the redirection of standard output and error streams
to a StringWriter
instance, enabling the capture of output produced
by the .NET code.
Implementations§
Source§impl<'a> ClrOutput<'a>
impl<'a> ClrOutput<'a>
Sourcepub fn redirect(&mut self) -> Result<(), ClrError>
pub fn redirect(&mut self) -> Result<(), ClrError>
Redirects standard output and error streams to a StringWriter
.
§Returns
Ok(())
- If the redirection is successful.Err(ClrError)
- If an error occurs while attempting to redirect the streams.
Auto Trait Implementations§
impl<'a> Freeze for ClrOutput<'a>
impl<'a> RefUnwindSafe for ClrOutput<'a>
impl<'a> !Send for ClrOutput<'a>
impl<'a> !Sync for ClrOutput<'a>
impl<'a> Unpin for ClrOutput<'a>
impl<'a> UnwindSafe for ClrOutput<'a>
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