Struct Sink

#[non_exhaustive]
pub struct Sink;

A writer which will move data into the void.

This struct is generally created by calling [sink()]. Please see the documentation of [sink()] for more details.

Trait Implementations

impl Clone for Sink

fn clone(&self) -> Sink

impl Copy for Sink

impl Debug for Sink

fn fmt(&self, f: &mut Formatter<'_>) -> Result

impl Default for Sink

fn default() -> Sink

impl TrivialClone for Sink

impl Write for Sink

fn write(&mut self, buf: &[u8]) -> Result<usize>
fn write_vectored(&mut self, bufs: &[IoSlice<'_>]) -> Result<usize>
fn is_write_vectored(&self) -> bool
fn write_all(&mut self, _buf: &[u8]) -> Result<()>
fn write_all_vectored(&mut self, _bufs: &mut [IoSlice<'_>]) -> Result<()>
fn write_fmt(&mut self, _args: Arguments<'_>) -> Result<()>
fn flush(&mut self) -> Result<()>

Auto Trait Implementations

impl Freeze for Sink

impl RefUnwindSafe for Sink

impl Send for Sink

impl Sync for Sink

impl Unpin for Sink

impl UnsafeUnpin for Sink

impl UnwindSafe for Sink

Blanket Implementations

impl<T> Any for Sink where T: 'static + ?Sized,

fn type_id(&self) -> TypeId

impl<T> Borrow<T> for Sink where T: ?Sized,

fn borrow(&self) -> &T

impl<T> BorrowMut<T> for Sink where T: ?Sized,

fn borrow_mut(&mut self) -> &mut T

impl<T> CloneToUninit for Sink where T: Clone,

unsafe fn clone_to_uninit(&self, dest: *mut u8)

impl<T> From<T> for Sink

fn from(t: T) -> T

Returns the argument unchanged.

impl<T> Printable for Sink where T: Copy + Debug,

impl<T> SizeHint for Sink where T: ?Sized,

fn lower_bound(&self) -> usize
fn upper_bound(&self) -> Option<usize>

impl<T> SizedTypeProperties for Sink

impl<T, U> Into<U> for Sink where U: From<T>,

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of [From]<T> for U chooses to do.

impl<T, U> TryFrom<U> for Sink where U: Into<T>,

type Error = Infallible;
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

impl<T, U> TryInto<U> for Sink where U: TryFrom<T>,

type Error = <U as TryFrom<T>>::Error;
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>