pub enum FSError {
Show 43 variants
DeviceError(String),
FormatError(&'static str),
NoSuchVolume,
TooManyOpenVolumes,
TooManyOpenDirs,
TooManyOpenFiles,
BadHandle,
NotFound,
FileAlreadyOpen,
DirAlreadyOpen,
OpenedDirAsFile,
OpenedFileAsDir,
DeleteDirAsFile,
VolumeStillInUse,
VolumeAlreadyOpen,
Unsupported,
EndOfFile,
BadCluster,
ConversionError,
NotEnoughSpace,
AllocationError,
UnterminatedFatChain,
ReadOnly,
FileAlreadyExists,
BadBlockSize(u16),
InvalidOffset,
DiskFull,
DirAlreadyExists,
Deadlock,
PermissionDenied,
ConnectionRefused,
ConnectionReset,
ConnectionAborted,
NotConnected,
AddrInUse,
AddrNotAvailable,
BrokenPipe,
InvalidInput,
InvalidData,
TimedOut,
Interrupted,
WriteZero,
Other,
}Variants§
DeviceError(String)
The underlying block device threw an error.
FormatError(&'static str)
The filesystem is badly formatted (or this code is buggy).
NoSuchVolume
The given VolumeIdx was bad,
TooManyOpenVolumes
Out of memory opening volumes
TooManyOpenDirs
Out of memory opening directories
TooManyOpenFiles
Out of memory opening files
BadHandle
Bad handle given
NotFound
That file or directory doesn’t exist
FileAlreadyOpen
You can’t open a file twice or delete an open file
DirAlreadyOpen
You can’t open a directory twice
OpenedDirAsFile
You can’t open a directory as a file
OpenedFileAsDir
You can’t open a file as a directory
DeleteDirAsFile
You can’t delete a directory as a file
VolumeStillInUse
You can’t close a volume with open files or directories
VolumeAlreadyOpen
You can’t open a volume twice
Unsupported
We can’t do that yet
EndOfFile
Tried to read beyond end of file
BadCluster
Found a bad cluster
ConversionError
Error while converting types
NotEnoughSpace
The device does not have enough space for the operation
AllocationError
Cluster was not properly allocated by the library
UnterminatedFatChain
Jumped to free space during FAT traversing
ReadOnly
Tried to open Read-Only file with write mode
FileAlreadyExists
Tried to create an existing file
BadBlockSize(u16)
Bad block size - only 512 byte blocks supported
InvalidOffset
Bad offset given when seeking
DiskFull
Disk is full
DirAlreadyExists
A directory with that name already exists
Deadlock
PermissionDenied
The operation lacked the necessary privileges to complete.
ConnectionRefused
The connection was refused by the remote server.
ConnectionReset
The connection was reset by the remote server.
ConnectionAborted
The connection was aborted (terminated) by the remote server.
NotConnected
The network operation failed because it was not connected yet.
AddrInUse
A socket address could not be bound because the address is already in use elsewhere.
AddrNotAvailable
A nonexistent interface was requested or the requested address was not local.
BrokenPipe
The operation failed because a pipe was closed.
InvalidInput
A parameter was incorrect.
InvalidData
Data not valid for the operation were encountered.
Unlike InvalidInput, this typically means that the operation
parameters were valid, however the error was caused by malformed
input data.
For example, a function that reads a file into a string will error with
InvalidData if the file’s contents are not valid UTF-8.
TimedOut
The I/O operation’s timeout expired, causing it to be canceled.
Interrupted
This operation was interrupted.
Interrupted operations can typically be retried.
WriteZero
An attempted write could not write any data.
Other
Something else.