Struct linux_stat::Errno
#[repr(transparent)]pub struct Errno(_);
Expand description
Error number representation.
Implementations§
§impl Errno
impl Errno
pub fn name(&self) -> Option<&'static str>
pub fn name(&self) -> Option<&'static str>
Returns the name of the error if it’s known. Generally the name of the constant.
pub fn description(&self) -> Option<&'static str>
pub fn description(&self) -> Option<&'static str>
Returns a description of the error if it’s known.
pub fn from_io_error(err: Error) -> Option<Errno>
pub fn from_io_error(err: Error) -> Option<Errno>
Returns a new Errno
if the given error is generated from a system error.
None otherwise.
pub fn last_os_error() -> Errno
pub fn last_os_error() -> Errno
Returns a new Errno
from last OS error.
§impl Errno
impl Errno
pub const ENAMETOOLONG: Errno = Self(36)
pub const ENAMETOOLONG: Errno = Self(36)
File name too long
pub const EDESTADDRREQ: Errno = Self(89)
pub const EDESTADDRREQ: Errno = Self(89)
Destination address required
pub const EPROTOTYPE: Errno = Self(91)
pub const EPROTOTYPE: Errno = Self(91)
Protocol wrong type for socket
pub const ENOPROTOOPT: Errno = Self(92)
pub const ENOPROTOOPT: Errno = Self(92)
Protocol not available
pub const EPROTONOSUPPORT: Errno = Self(93)
pub const EPROTONOSUPPORT: Errno = Self(93)
Protocol not supported
pub const ESOCKTNOSUPPORT: Errno = Self(94)
pub const ESOCKTNOSUPPORT: Errno = Self(94)
Socket type not supported
pub const EOPNOTSUPP: Errno = Self(95)
pub const EOPNOTSUPP: Errno = Self(95)
Operation not supported on transport endpoint
pub const EPFNOSUPPORT: Errno = Self(96)
pub const EPFNOSUPPORT: Errno = Self(96)
Protocol family not supported
pub const EAFNOSUPPORT: Errno = Self(97)
pub const EAFNOSUPPORT: Errno = Self(97)
Address family not supported by protocol
pub const EADDRINUSE: Errno = Self(98)
pub const EADDRINUSE: Errno = Self(98)
Address already in use
pub const EADDRNOTAVAIL: Errno = Self(99)
pub const EADDRNOTAVAIL: Errno = Self(99)
Cannot assign requested address
pub const ENETUNREACH: Errno = Self(101)
pub const ENETUNREACH: Errno = Self(101)
Network is unreachable
pub const ECONNABORTED: Errno = Self(103)
pub const ECONNABORTED: Errno = Self(103)
Software caused connection abort
pub const ECONNRESET: Errno = Self(104)
pub const ECONNRESET: Errno = Self(104)
Connection reset by peer
pub const ETOOMANYREFS: Errno = Self(109)
pub const ETOOMANYREFS: Errno = Self(109)
Too many references: cannot splice
pub const ECONNREFUSED: Errno = Self(111)
pub const ECONNREFUSED: Errno = Self(111)
Connection refused
pub const EHOSTUNREACH: Errno = Self(113)
pub const EHOSTUNREACH: Errno = Self(113)
No route to host
pub const EINPROGRESS: Errno = Self(115)
pub const EINPROGRESS: Errno = Self(115)
Operation now in progress
pub const EMEDIUMTYPE: Errno = Self(124)
pub const EMEDIUMTYPE: Errno = Self(124)
Wrong medium type
pub const EKEYEXPIRED: Errno = Self(127)
pub const EKEYEXPIRED: Errno = Self(127)
Key has expired
pub const EKEYREVOKED: Errno = Self(128)
pub const EKEYREVOKED: Errno = Self(128)
Key has been revoked
pub const EKEYREJECTED: Errno = Self(129)
pub const EKEYREJECTED: Errno = Self(129)
Key was rejected by service
pub const EOWNERDEAD: Errno = Self(130)
pub const EOWNERDEAD: Errno = Self(130)
Owner died
pub const ENOTRECOVERABLE: Errno = Self(131)
pub const ENOTRECOVERABLE: Errno = Self(131)
State not recoverable
pub const ERESTARTSYS: Errno = Self(512)
pub const ERESTARTSYS: Errno = Self(512)
Restart syscall
pub const ERESTARTNOINTR: Errno = Self(513)
pub const ERESTARTNOINTR: Errno = Self(513)
Restart if no interrupt
pub const ERESTARTNOHAND: Errno = Self(514)
pub const ERESTARTNOHAND: Errno = Self(514)
restart if no handler..
pub const ENOIOCTLCMD: Errno = Self(515)
pub const ENOIOCTLCMD: Errno = Self(515)
No ioctl command
pub const ERESTART_RESTARTBLOCK: Errno = Self(516)
pub const ERESTART_RESTARTBLOCK: Errno = Self(516)
restart by calling sys_restart_syscall
pub const EPROBE_DEFER: Errno = Self(517)
pub const EPROBE_DEFER: Errno = Self(517)
Driver requests probe retry
pub const EOPENSTALE: Errno = Self(518)
pub const EOPENSTALE: Errno = Self(518)
open found a stale dentry
pub const EBADHANDLE: Errno = Self(521)
pub const EBADHANDLE: Errno = Self(521)
Illegal NFS file handle
pub const EBADCOOKIE: Errno = Self(523)
pub const EBADCOOKIE: Errno = Self(523)
Cookie is stale
pub const ESERVERFAULT: Errno = Self(526)
pub const ESERVERFAULT: Errno = Self(526)
An untranslatable error occurred
pub const EIOCBQUEUED: Errno = Self(529)
pub const EIOCBQUEUED: Errno = Self(529)
iocb queued, will get completion event
pub const ERECALLCONFLICT: Errno = Self(530)
pub const ERECALLCONFLICT: Errno = Self(530)
conflict with recalled state
pub const EDEADLOCK: Errno = Self::EDEADLK
pub const EDEADLOCK: Errno = Self::EDEADLK
Alias for Self::EDEADLK
pub const EWOULDBLOCK: Errno = Self::EAGAIN
pub const EWOULDBLOCK: Errno = Self::EAGAIN
Alias for Self::EAGAIN
pub const MIN: i32 = 1i32
pub const MAX: i32 = 531i32
Trait Implementations§
§impl Error for Errno
impl Error for Errno
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
§impl Ord for Errno
impl Ord for Errno
§impl PartialOrd<Errno> for Errno
impl PartialOrd<Errno> for Errno
§fn partial_cmp(&self, other: &Errno) -> Option<Ordering>
fn partial_cmp(&self, other: &Errno) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
self
and other
) and is used by the <=
operator. Read more