pub enum FsError {
Show 27 variants
BaseNotDirectory,
NotAFile,
InvalidFd,
AlreadyExists,
Lock,
IOError,
AddressInUse,
AddressNotAvailable,
BrokenPipe,
ConnectionAborted,
ConnectionRefused,
ConnectionReset,
Interrupted,
InvalidData,
InvalidInput,
NotConnected,
EntryNotFound,
NoDevice,
PermissionDenied,
TimedOut,
UnexpectedEof,
WouldBlock,
WriteZero,
DirectoryNotEmpty,
StorageFull,
UnknownError,
Unsupported,
}
Expand description
Error type for external users
Variants§
BaseNotDirectory
The fd given as a base was not a directory so the operation was not possible
NotAFile
Expected a file but found not a file
InvalidFd
The fd given was not usable
AlreadyExists
File exists
Lock
The filesystem has failed to lock a resource.
IOError
Something failed when doing IO. These errors can generally not be handled. It may work if tried again.
AddressInUse
The address was in use
AddressNotAvailable
The address could not be found
BrokenPipe
A pipe was closed
ConnectionAborted
The connection was aborted
ConnectionRefused
The connection request was refused
ConnectionReset
The connection was reset
Interrupted
The operation was interrupted before it could finish
InvalidData
Invalid internal data, if the argument data is invalid, use InvalidInput
InvalidInput
The provided data is invalid
NotConnected
Could not perform the operation because there was not an open connection
EntryNotFound
The requested file or directory could not be found
NoDevice
The requested device couldn’t be accessed
PermissionDenied
Caller was not allowed to perform this operation
TimedOut
The operation did not complete within the given amount of time
UnexpectedEof
Found EOF when EOF was not expected
WouldBlock
Operation would block, this error lets the caller know that they can try again
WriteZero
A call to write returned 0
DirectoryNotEmpty
Directory not Empty
StorageFull
UnknownError
Some other unhandled error. If you see this, it’s probably a bug.
Unsupported
Operation is not supported on this filesystem
Trait Implementations§
Source§impl Error for FsError
impl Error for FsError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
Source§impl From<FsError> for WasiStateCreationError
impl From<FsError> for WasiStateCreationError
impl Copy for FsError
impl Eq for FsError
impl StructuralPartialEq for FsError
Auto Trait Implementations§
impl Freeze for FsError
impl RefUnwindSafe for FsError
impl Send for FsError
impl Sync for FsError
impl Unpin for FsError
impl UnwindSafe for FsError
Blanket Implementations§
Source§impl<T> ArchivePointee for T
impl<T> ArchivePointee for T
Source§type ArchivedMetadata = ()
type ArchivedMetadata = ()
Source§fn pointer_metadata(
_: &<T as ArchivePointee>::ArchivedMetadata,
) -> <T as Pointee>::Metadata
fn pointer_metadata( _: &<T as ArchivePointee>::ArchivedMetadata, ) -> <T as Pointee>::Metadata
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key
and return true
if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key
and return true
if they are equal.Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
self
into a Left
variant of Either<Self, Self>
if into_left
is true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
self
into a Left
variant of Either<Self, Self>
if into_left(&self)
returns true
.
Converts self
into a Right
variant of Either<Self, Self>
otherwise. Read more