Enum clio::Output [−][src]
Expand description
An enum that represents a command line output stream, either std out or a file
Variants
Stdout(Stdout)
Implementations
impl Output
[src]
impl Output
[src]pub fn new<S: AsRef<OsStr>>(path: S) -> Result<Self>
[src]
pub fn new<S: AsRef<OsStr>>(path: S) -> Result<Self>
[src]Contructs a new output either by opening/creating the file or for ‘-’ returning stdout
pub fn try_from_os_str(path: &OsStr) -> Result<Self, OsString>
[src]
pub fn try_from_os_str(path: &OsStr) -> Result<Self, OsString>
[src]Contructs a new output either by opening/creating the file or for ‘-’ returning stdout The error is converted to a OsString so that stuctopt can show it to the user
Trait Implementations
impl Write for Output
[src]
impl Write for Output
[src]fn flush(&mut self) -> IoResult<()>
[src]
fn flush(&mut self) -> IoResult<()>
[src]Flush this output stream, ensuring that all intermediately buffered contents reach their destination. Read more
fn write(&mut self, buf: &[u8]) -> IoResult<usize>
[src]
fn write(&mut self, buf: &[u8]) -> IoResult<usize>
[src]Write a buffer into this writer, returning how many bytes were written. Read more
fn is_write_vectored(&self) -> bool
[src]
fn is_write_vectored(&self) -> bool
[src]can_vector
)Determines if this Write
r has an efficient write_vectored
implementation. Read more
fn write_all(&mut self, buf: &[u8]) -> Result<(), Error>
1.0.0[src]
fn write_all(&mut self, buf: &[u8]) -> Result<(), Error>
1.0.0[src]Attempts to write an entire buffer into this writer. Read more
fn write_all_vectored(&mut self, bufs: &mut [IoSlice<'_>]) -> Result<(), Error>
[src]
fn write_all_vectored(&mut self, bufs: &mut [IoSlice<'_>]) -> Result<(), Error>
[src]write_all_vectored
)Attempts to write multiple buffers into this writer. Read more
Auto Trait Implementations
impl RefUnwindSafe for Output
impl Send for Output
impl Sync for Output
impl Unpin for Output
impl UnwindSafe for Output
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more