Enum otter_api_tests::shapelib::ErrorKind 1.0.0[−][src]
#[non_exhaustive]
pub enum ErrorKind {
Show 40 variants
NotFound,
PermissionDenied,
ConnectionRefused,
ConnectionReset,
HostUnreachable,
NetworkUnreachable,
ConnectionAborted,
NotConnected,
AddrInUse,
AddrNotAvailable,
NetworkDown,
BrokenPipe,
AlreadyExists,
WouldBlock,
NotADirectory,
IsADirectory,
DirectoryNotEmpty,
ReadOnlyFilesystem,
FilesystemLoop,
StaleNetworkFileHandle,
InvalidInput,
InvalidData,
TimedOut,
WriteZero,
StorageFull,
NotSeekable,
FilesystemQuotaExceeded,
FileTooLarge,
ResourceBusy,
ExecutableFileBusy,
Deadlock,
CrossesDevices,
TooManyLinks,
FilenameTooLong,
ArgumentListTooLong,
Interrupted,
Other,
UnexpectedEof,
Unsupported,
OutOfMemory,
// some variants omitted
}Expand description
A list specifying general categories of I/O error.
This list is intended to grow over time and it is not recommended to exhaustively match against it.
It is used with the io::Error type.
Variants (Non-exhaustive)
This enum is marked as non-exhaustive
An entity was not found, often a file.
The operation lacked the necessary privileges to complete.
The connection was refused by the remote server.
The connection was reset by the remote server.
io_error_more)The remote host is not reachable.
io_error_more)The network containing the remote host is not reachable.
The connection was aborted (terminated) by the remote server.
The network operation failed because it was not connected yet.
A socket address could not be bound because the address is already in use elsewhere.
A nonexistent interface was requested or the requested address was not local.
io_error_more)The system’s networking is down.
The operation failed because a pipe was closed.
An entity already exists, often a file.
The operation needs to block to complete, but the blocking operation was requested to not occur.
io_error_more)A filesystem object is, unexpectedly, not a directory.
For example, a filesystem path was specified where one of the intermediate directory components was, in fact, a plain file.
io_error_more)The filesystem object is, unexpectedly, a directory.
A directory was specified when a non-directory was expected.
io_error_more)A non-empty directory was specified where an empty directory was expected.
io_error_more)The filesystem or storage medium is read-only, but a write operation was attempted.
io_error_more)Loop in the filesystem or IO subsystem; often, too many levels of symbolic links.
There was a loop (or excessively long chain) resolving a filesystem object or file IO object.
On Unix this is usually the result of a symbolic link loop; or, of exceeding the system-specific limit on the depth of symlink traversal.
io_error_more)Stale network file handle.
With some network filesystems, notably NFS, an open file (or directory) can be invalidated by problems with the network or server.
A parameter was incorrect.
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.
The I/O operation’s timeout expired, causing it to be canceled.
An error returned when an operation could not be completed because a
call to write returned Ok(0).
This typically means that an operation could only succeed if it wrote a particular number of bytes but only a smaller number of bytes could be written.
io_error_more)The underlying storage (typically, a filesystem) is full.
This does not include out of quota errors.
io_error_more)Seek on unseekable file.
Seeking was attempted on an open file handle which is not suitable for seeking - for
example, on Unix, a named pipe opened with File::open.
io_error_more)Filesystem quota was exceeded.
io_error_more)File larger than allowed or supported.
This might arise from a hard limit of the underlying filesystem or file access API, or from an administratively imposed resource limitation. Simple disk full, and out of quota, have their own errors.
io_error_more)Resource is busy.
io_error_more)Executable file is busy.
An attempt was made to write to a file which is also in use as a running program. (Not all operating systems detect this situation.)
io_error_more)Deadlock (avoided).
A file locking operation would result in deadlock. This situation is typically detected, if at all, on a best-effort basis.
io_error_more)Cross-device or cross-filesystem (hard) link or rename.
io_error_more)Too many (hard) links to the same filesystem object.
The filesystem does not support making so many hardlinks to the same file.
io_error_more)Filename too long.
The limit might be from the underlying filesystem or API, or an administratively imposed resource limit.
io_error_more)Program argument list too long.
When trying to run an external program, a system or process limit on the size of the arguments would have been exceeded.
This operation was interrupted.
Interrupted operations can typically be retried.
A custom error that does not fall under any other I/O error kind.
This can be used to construct your own Errors that do not match any
ErrorKind.
This ErrorKind is not used by the standard library.
Errors from the standard library that do not fall under any of the I/O
error kinds cannot be matched on, and will only match a wildcard (_) pattern.
New ErrorKinds might be added in the future for some of those.
An error returned when an operation could not be completed because an “end of file” was reached prematurely.
This typically means that an operation could only succeed if it read a particular number of bytes but only a smaller number of bytes could be read.
This operation is unsupported on this platform.
This means that the operation can never succeed.
An operation could not be completed, because it failed to allocate enough memory.
Trait Implementations
Intended for use for errors not exposed to the user, where allocating onto the heap (for normal construction via Error::new) is too costly.
This method returns an ordering between self and other values if one exists. Read more
This method tests less than (for self and other) and is used by the < operator. Read more
This method tests less than or equal to (for self and other) and is used by the <=
operator. Read more
This method tests greater than (for self and other) and is used by the > operator. Read more
Auto Trait Implementations
impl RefUnwindSafe for ErrorKindimpl UnwindSafe for ErrorKindBlanket Implementations
Mutably borrows from an owned value. Read more
pub fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>ⓘNotable traits for Box<R, Global>
impl<R> Read for Box<R, Global> where
R: Read + ?Sized, impl<W> Write for Box<W, Global> where
W: Write + ?Sized, impl<I, A> Iterator for Box<I, A> where
A: Allocator,
I: Iterator + ?Sized, type Item = <I as Iterator>::Item;impl<F, A> Future for Box<F, A> where
A: Allocator + 'static,
F: Future + Unpin + ?Sized, type Output = <F as Future>::Output;
pub fn into_any(self: Box<T, Global>) -> Box<dyn Any + 'static, Global>ⓘNotable traits for Box<R, Global>
impl<R> Read for Box<R, Global> where
R: Read + ?Sized, impl<W> Write for Box<W, Global> where
W: Write + ?Sized, impl<I, A> Iterator for Box<I, A> where
A: Allocator,
I: Iterator + ?Sized, type Item = <I as Iterator>::Item;impl<F, A> Future for Box<F, A> where
A: Allocator + 'static,
F: Future + Unpin + ?Sized, type Output = <F as Future>::Output;Convert Box<dyn Trait> (where Trait: Downcast) to Box<dyn Any>. Box<dyn Any> can
then be further downcast into Box<ConcreteType> where ConcreteType implements Trait. Read more
pub fn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
pub fn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>Convert Rc<Trait> (where Trait: Downcast) to Rc<Any>. Rc<Any> can then be
further downcast into Rc<ConcreteType> where ConcreteType implements Trait. Read more
Convert &Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &Any’s vtable from &Trait’s. Read more
pub fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
pub fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)Convert &mut Trait (where Trait: Downcast) to &Any. This is needed since Rust cannot
generate &mut Any’s vtable from &mut Trait’s. Read more
impl<A> DynCastExt for A
impl<A> DynCastExt for Apub fn dyn_cast<T>(
self
) -> Result<<A as DynCastExtHelper<T>>::Target, <A as DynCastExtHelper<T>>::Source> where
T: ?Sized,
A: DynCastExtHelper<T>,
pub fn dyn_cast<T>(
self
) -> Result<<A as DynCastExtHelper<T>>::Target, <A as DynCastExtHelper<T>>::Source> where
T: ?Sized,
A: DynCastExtHelper<T>, Use this to cast from one trait object type to another. Read more
pub fn dyn_upcast<T>(self) -> <A as DynCastExtAdvHelper<T, T>>::Target where
T: ?Sized,
A: DynCastExtAdvHelper<T, T, Source = <A as DynCastExtAdvHelper<T, T>>::Target>,
pub fn dyn_upcast<T>(self) -> <A as DynCastExtAdvHelper<T, T>>::Target where
T: ?Sized,
A: DynCastExtAdvHelper<T, T, Source = <A as DynCastExtAdvHelper<T, T>>::Target>, Use this to upcast a trait to one of its supertraits. Read more
pub fn dyn_cast_adv<F, T>(
self
) -> Result<<A as DynCastExtAdvHelper<F, T>>::Target, <A as DynCastExtAdvHelper<F, T>>::Source> where
T: ?Sized,
A: DynCastExtAdvHelper<F, T>,
F: ?Sized,
pub fn dyn_cast_adv<F, T>(
self
) -> Result<<A as DynCastExtAdvHelper<F, T>>::Target, <A as DynCastExtAdvHelper<F, T>>::Source> where
T: ?Sized,
A: DynCastExtAdvHelper<F, T>,
F: ?Sized, pub fn dyn_cast_with_config<C>(
self
) -> Result<<A as DynCastExtAdvHelper<<C as DynCastConfig>::Source, <C as DynCastConfig>::Target>>::Target, <A as DynCastExtAdvHelper<<C as DynCastConfig>::Source, <C as DynCastConfig>::Target>>::Source> where
C: DynCastConfig,
A: DynCastExtAdvHelper<<C as DynCastConfig>::Source, <C as DynCastConfig>::Target>,
pub fn dyn_cast_with_config<C>(
self
) -> Result<<A as DynCastExtAdvHelper<<C as DynCastConfig>::Source, <C as DynCastConfig>::Target>>::Target, <A as DynCastExtAdvHelper<<C as DynCastConfig>::Source, <C as DynCastConfig>::Target>>::Source> where
C: DynCastConfig,
A: DynCastExtAdvHelper<<C as DynCastConfig>::Source, <C as DynCastConfig>::Target>, Use this to cast from one trait object type to another. With this method the type parameter is a config type that uniquely specifies which cast should be preformed. Read more
Compare self to key and return true if they are equal.
fn instrument(self, span: Span) -> Instrumented<Self>ⓘNotable traits for Instrumented<T>
impl<T> Future for Instrumented<T> where
T: Future, type Output = <T as Future>::Output;
fn instrument(self, span: Span) -> Instrumented<Self>ⓘNotable traits for Instrumented<T>
impl<T> Future for Instrumented<T> where
T: Future, type Output = <T as Future>::Output;Instruments this type with the provided Span, returning an
Instrumented wrapper. Read more
fn in_current_span(self) -> Instrumented<Self>ⓘNotable traits for Instrumented<T>
impl<T> Future for Instrumented<T> where
T: Future, type Output = <T as Future>::Output;
fn in_current_span(self) -> Instrumented<Self>ⓘNotable traits for Instrumented<T>
impl<T> Future for Instrumented<T> where
T: Future, type Output = <T as Future>::Output;pub fn vzip(self) -> V