Struct io_impl::RealIo

source ·
pub struct RealIo();

Trait Implementations§

source§

impl Default for RealIo

source§

fn default() -> RealIo

Returns the “default value” for a type. Read more
source§

impl Io for RealIo

§

type Args = Args

§

type Stdout = Stdout

§

type File = File

§

type Metadata = Metadata

§

type DirEntry = DirEntry

§

type Instant = Instant

source§

fn args(&self) -> Self::Args

source§

fn create(&self, path: &str) -> Result<Self::File>

source§

fn open(&self, path: &str) -> Result<Self::File>

source§

fn metadata(&self, path: &str) -> Result<Metadata>

source§

fn read_dir(&self, path: &str) -> Result<Vec<Self::DirEntry>>

source§

fn create_dir(&self, path: &str) -> Result<()>

source§

fn stdout(&self) -> Self::Stdout

source§

fn now(&self) -> Instant

source§

fn current_dir(&self) -> Result<String>

source§

fn set_current_dir(&self, path: &str) -> Result<()>

source§

fn read(&self, path: &str) -> Result<Vec<u8>, Error>

source§

fn read_to_string(&self, path: &str) -> Result<String, Error>

source§

fn write(&self, path: &str, data: &[u8]) -> Result<(), Error>

source§

fn create_dir_recursively(&self, path: &str) -> Result<(), Error>

source§

fn write_recursively(&self, path: &str, data: &[u8]) -> Result<(), Error>

source§

fn read_dir_type( &self, path: &str, is_dir: bool ) -> Result<Vec<Self::DirEntry>, Error>

Auto Trait Implementations§

§

impl Freeze for RealIo

§

impl RefUnwindSafe for RealIo

§

impl Send for RealIo

§

impl Sync for RealIo

§

impl Unpin for RealIo

§

impl UnwindSafe for RealIo

Blanket Implementations§

source§

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

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

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

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

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

source§

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

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

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

source§

fn into(self) -> U

Calls U::from(self).

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

source§

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

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

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

Performs the conversion.
source§

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

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

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

Performs the conversion.