pub struct Error(/* private fields */);
Expand description
A type wrapping errors produced by GPG libraries.
Implementations§
§impl Error
impl Error
pub const SOURCE_UNKNOWN: ErrorSource = 0u32
pub const SOURCE_GCRYPT: ErrorSource = 1u32
pub const SOURCE_GPG: ErrorSource = 2u32
pub const SOURCE_GPGSM: ErrorSource = 3u32
pub const SOURCE_GPGAGENT: ErrorSource = 4u32
pub const SOURCE_PINENTRY: ErrorSource = 5u32
pub const SOURCE_SCD: ErrorSource = 6u32
pub const SOURCE_GPGME: ErrorSource = 7u32
pub const SOURCE_KEYBOX: ErrorSource = 8u32
pub const SOURCE_KSBA: ErrorSource = 9u32
pub const SOURCE_DIRMNGR: ErrorSource = 10u32
pub const SOURCE_GSTI: ErrorSource = 11u32
pub const SOURCE_GPA: ErrorSource = 12u32
pub const SOURCE_KLEO: ErrorSource = 13u32
pub const SOURCE_G13: ErrorSource = 14u32
pub const SOURCE_ASSUAN: ErrorSource = 15u32
pub const SOURCE_TPM2D: ErrorSource = 16u32
pub const SOURCE_TLS: ErrorSource = 17u32
pub const SOURCE_TKD: ErrorSource = 18u32
pub const SOURCE_ANY: ErrorSource = 31u32
pub const SOURCE_USER_1: ErrorSource = 32u32
pub const SOURCE_USER_2: ErrorSource = 33u32
pub const SOURCE_USER_3: ErrorSource = 34u32
pub const SOURCE_USER_4: ErrorSource = 35u32
pub const NO_ERROR: Self = _
pub const GENERAL: Self = _
pub const UNKNOWN_PACKET: Self = _
pub const UNKNOWN_VERSION: Self = _
pub const PUBKEY_ALGO: Self = _
pub const DIGEST_ALGO: Self = _
pub const BAD_PUBKEY: Self = _
pub const BAD_SECKEY: Self = _
pub const BAD_SIGNATURE: Self = _
pub const NO_PUBKEY: Self = _
pub const CHECKSUM: Self = _
pub const BAD_PASSPHRASE: Self = _
pub const CIPHER_ALGO: Self = _
pub const KEYRING_OPEN: Self = _
pub const INV_PACKET: Self = _
pub const INV_ARMOR: Self = _
pub const NO_USER_ID: Self = _
pub const NO_SECKEY: Self = _
pub const WRONG_SECKEY: Self = _
pub const BAD_KEY: Self = _
pub const COMPR_ALGO: Self = _
pub const NO_PRIME: Self = _
pub const NO_ENCODING_METHOD: Self = _
pub const NO_ENCRYPTION_SCHEME: Self = _
pub const NO_SIGNATURE_SCHEME: Self = _
pub const INV_ATTR: Self = _
pub const NO_VALUE: Self = _
pub const NOT_FOUND: Self = _
pub const VALUE_NOT_FOUND: Self = _
pub const SYNTAX: Self = _
pub const BAD_MPI: Self = _
pub const INV_PASSPHRASE: Self = _
pub const SIG_CLASS: Self = _
pub const RESOURCE_LIMIT: Self = _
pub const INV_KEYRING: Self = _
pub const TRUSTDB: Self = _
pub const BAD_CERT: Self = _
pub const INV_USER_ID: Self = _
pub const UNEXPECTED: Self = _
pub const TIME_CONFLICT: Self = _
pub const KEYSERVER: Self = _
pub const WRONG_PUBKEY_ALGO: Self = _
pub const TRIBUTE_TO_D_A: Self = _
pub const WEAK_KEY: Self = _
pub const INV_KEYLEN: Self = _
pub const INV_ARG: Self = _
pub const BAD_URI: Self = _
pub const INV_URI: Self = _
pub const NETWORK: Self = _
pub const UNKNOWN_HOST: Self = _
pub const SELFTEST_FAILED: Self = _
pub const NOT_ENCRYPTED: Self = _
pub const NOT_PROCESSED: Self = _
pub const UNUSABLE_PUBKEY: Self = _
pub const UNUSABLE_SECKEY: Self = _
pub const INV_VALUE: Self = _
pub const BAD_CERT_CHAIN: Self = _
pub const MISSING_CERT: Self = _
pub const NO_DATA: Self = _
pub const BUG: Self = _
pub const NOT_SUPPORTED: Self = _
pub const INV_OP: Self = _
pub const TIMEOUT: Self = _
pub const INTERNAL: Self = _
pub const EOF_GCRYPT: Self = _
pub const INV_OBJ: Self = _
pub const TOO_SHORT: Self = _
pub const TOO_LARGE: Self = _
pub const NO_OBJ: Self = _
pub const NOT_IMPLEMENTED: Self = _
pub const CONFLICT: Self = _
pub const INV_CIPHER_MODE: Self = _
pub const INV_FLAG: Self = _
pub const INV_HANDLE: Self = _
pub const TRUNCATED: Self = _
pub const INCOMPLETE_LINE: Self = _
pub const INV_RESPONSE: Self = _
pub const NO_AGENT: Self = _
pub const AGENT: Self = _
pub const INV_DATA: Self = _
pub const ASSUAN_SERVER_FAULT: Self = _
pub const ASSUAN: Self = _
pub const INV_SESSION_KEY: Self = _
pub const INV_SEXP: Self = _
pub const UNSUPPORTED_ALGORITHM: Self = _
pub const NO_PIN_ENTRY: Self = _
pub const PIN_ENTRY: Self = _
pub const BAD_PIN: Self = _
pub const INV_NAME: Self = _
pub const BAD_DATA: Self = _
pub const INV_PARAMETER: Self = _
pub const WRONG_CARD: Self = _
pub const NO_DIRMNGR: Self = _
pub const DIRMNGR: Self = _
pub const CERT_REVOKED: Self = _
pub const NO_CRL_KNOWN: Self = _
pub const CRL_TOO_OLD: Self = _
pub const LINE_TOO_LONG: Self = _
pub const NOT_TRUSTED: Self = _
pub const CANCELED: Self = _
pub const BAD_CA_CERT: Self = _
pub const CERT_EXPIRED: Self = _
pub const CERT_TOO_YOUNG: Self = _
pub const UNSUPPORTED_CERT: Self = _
pub const UNKNOWN_SEXP: Self = _
pub const UNSUPPORTED_PROTECTION: Self = _
pub const CORRUPTED_PROTECTION: Self = _
pub const AMBIGUOUS_NAME: Self = _
pub const CARD: Self = _
pub const CARD_RESET: Self = _
pub const CARD_REMOVED: Self = _
pub const INV_CARD: Self = _
pub const CARD_NOT_PRESENT: Self = _
pub const NO_PKCS15_APP: Self = _
pub const NOT_CONFIRMED: Self = _
pub const CONFIGURATION: Self = _
pub const NO_POLICY_MATCH: Self = _
pub const INV_INDEX: Self = _
pub const INV_ID: Self = _
pub const NO_SCDAEMON: Self = _
pub const SCDAEMON: Self = _
pub const UNSUPPORTED_PROTOCOL: Self = _
pub const BAD_PIN_METHOD: Self = _
pub const CARD_NOT_INITIALIZED: Self = _
pub const UNSUPPORTED_OPERATION: Self = _
pub const WRONG_KEY_USAGE: Self = _
pub const NOTHING_FOUND: Self = _
pub const WRONG_BLOB_TYPE: Self = _
pub const MISSING_VALUE: Self = _
pub const HARDWARE: Self = _
pub const PIN_BLOCKED: Self = _
pub const USE_CONDITIONS: Self = _
pub const PIN_NOT_SYNCED: Self = _
pub const INV_CRL: Self = _
pub const BAD_BER: Self = _
pub const INV_BER: Self = _
pub const ELEMENT_NOT_FOUND: Self = _
pub const IDENTIFIER_NOT_FOUND: Self = _
pub const INV_TAG: Self = _
pub const INV_LENGTH: Self = _
pub const INV_KEYINFO: Self = _
pub const UNEXPECTED_TAG: Self = _
pub const NOT_DER_ENCODED: Self = _
pub const NO_CMS_OBJ: Self = _
pub const INV_CMS_OBJ: Self = _
pub const UNKNOWN_CMS_OBJ: Self = _
pub const UNSUPPORTED_CMS_OBJ: Self = _
pub const UNSUPPORTED_ENCODING: Self = _
pub const UNSUPPORTED_CMS_VERSION: Self = _
pub const UNKNOWN_ALGORITHM: Self = _
pub const INV_ENGINE: Self = _
pub const PUBKEY_NOT_TRUSTED: Self = _
pub const DECRYPT_FAILED: Self = _
pub const KEY_EXPIRED: Self = _
pub const SIG_EXPIRED: Self = _
pub const ENCODING_PROBLEM: Self = _
pub const INV_STATE: Self = _
pub const DUP_VALUE: Self = _
pub const MISSING_ACTION: Self = _
pub const MODULE_NOT_FOUND: Self = _
pub const INV_OID_STRING: Self = _
pub const INV_TIME: Self = _
pub const INV_CRL_OBJ: Self = _
pub const UNSUPPORTED_CRL_VERSION: Self = _
pub const INV_CERT_OBJ: Self = _
pub const UNKNOWN_NAME: Self = _
pub const LOCALE_PROBLEM: Self = _
pub const NOT_LOCKED: Self = _
pub const PROTOCOL_VIOLATION: Self = _
pub const INV_MAC: Self = _
pub const INV_REQUEST: Self = _
pub const UNKNOWN_EXTN: Self = _
pub const UNKNOWN_CRIT_EXTN: Self = _
pub const LOCKED: Self = _
pub const UNKNOWN_OPTION: Self = _
pub const UNKNOWN_COMMAND: Self = _
pub const NOT_OPERATIONAL: Self = _
pub const NO_PASSPHRASE: Self = _
pub const NO_PIN: Self = _
pub const NOT_ENABLED: Self = _
pub const NO_ENGINE: Self = _
pub const MISSING_KEY: Self = _
pub const TOO_MANY: Self = _
pub const LIMIT_REACHED: Self = _
pub const NOT_INITIALIZED: Self = _
pub const MISSING_ISSUER_CERT: Self = _
pub const NO_KEYSERVER: Self = _
pub const INV_CURVE: Self = _
pub const UNKNOWN_CURVE: Self = _
pub const DUP_KEY: Self = _
pub const AMBIGUOUS: Self = _
pub const NO_CRYPT_CTX: Self = _
pub const WRONG_CRYPT_CTX: Self = _
pub const BAD_CRYPT_CTX: Self = _
pub const CRYPT_CTX_CONFLICT: Self = _
pub const BROKEN_PUBKEY: Self = _
pub const BROKEN_SECKEY: Self = _
pub const MAC_ALGO: Self = _
pub const FULLY_CANCELED: Self = _
pub const UNFINISHED: Self = _
pub const BUFFER_TOO_SHORT: Self = _
pub const SEXP_INV_LEN_SPEC: Self = _
pub const SEXP_STRING_TOO_LONG: Self = _
pub const SEXP_UNMATCHED_PAREN: Self = _
pub const SEXP_NOT_CANONICAL: Self = _
pub const SEXP_BAD_CHARACTER: Self = _
pub const SEXP_BAD_QUOTATION: Self = _
pub const SEXP_ZERO_PREFIX: Self = _
pub const SEXP_NESTED_DH: Self = _
pub const SEXP_UNMATCHED_DH: Self = _
pub const SEXP_UNEXPECTED_PUNC: Self = _
pub const SEXP_BAD_HEX_CHAR: Self = _
pub const SEXP_ODD_HEX_NUMBERS: Self = _
pub const SEXP_BAD_OCT_CHAR: Self = _
pub const SUBKEYS_EXP_OR_REV: Self = _
pub const DB_CORRUPTED: Self = _
pub const SERVER_FAILED: Self = _
pub const NO_NAME: Self = _
pub const NO_KEY: Self = _
pub const LEGACY_KEY: Self = _
pub const REQUEST_TOO_SHORT: Self = _
pub const REQUEST_TOO_LONG: Self = _
pub const OBJ_TERM_STATE: Self = _
pub const NO_CERT_CHAIN: Self = _
pub const CERT_TOO_LARGE: Self = _
pub const INV_RECORD: Self = _
pub const BAD_MAC: Self = _
pub const UNEXPECTED_MSG: Self = _
pub const COMPR_FAILED: Self = _
pub const WOULD_WRAP: Self = _
pub const FATAL_ALERT: Self = _
pub const NO_CIPHER: Self = _
pub const MISSING_CLIENT_CERT: Self = _
pub const CLOSE_NOTIFY: Self = _
pub const TICKET_EXPIRED: Self = _
pub const BAD_TICKET: Self = _
pub const UNKNOWN_IDENTITY: Self = _
pub const BAD_HS_CERT: Self = _
pub const BAD_HS_CERT_REQ: Self = _
pub const BAD_HS_CERT_VER: Self = _
pub const BAD_HS_CHANGE_CIPHER: Self = _
pub const BAD_HS_CLIENT_HELLO: Self = _
pub const BAD_HS_SERVER_HELLO: Self = _
pub const BAD_HS_SERVER_HELLO_DONE: Self = _
pub const BAD_HS_FINISHED: Self = _
pub const BAD_HS_SERVER_KEX: Self = _
pub const BAD_HS_CLIENT_KEX: Self = _
pub const BOGUS_STRING: Self = _
pub const FORBIDDEN: Self = _
pub const KEY_DISABLED: Self = _
pub const KEY_ON_CARD: Self = _
pub const INV_LOCK_OBJ: Self = _
pub const TRUE: Self = _
pub const FALSE: Self = _
pub const ASS_GENERAL: Self = _
pub const ASS_ACCEPT_FAILED: Self = _
pub const ASS_CONNECT_FAILED: Self = _
pub const ASS_INV_RESPONSE: Self = _
pub const ASS_INV_VALUE: Self = _
pub const ASS_INCOMPLETE_LINE: Self = _
pub const ASS_LINE_TOO_LONG: Self = _
pub const ASS_NESTED_COMMANDS: Self = _
pub const ASS_NO_DATA_CB: Self = _
pub const ASS_NO_INQUIRE_CB: Self = _
pub const ASS_NOT_A_SERVER: Self = _
pub const ASS_NOT_A_CLIENT: Self = _
pub const ASS_SERVER_START: Self = _
pub const ASS_READ_ERROR: Self = _
pub const ASS_WRITE_ERROR: Self = _
pub const ASS_TOO_MUCH_DATA: Self = _
pub const ASS_UNEXPECTED_CMD: Self = _
pub const ASS_UNKNOWN_CMD: Self = _
pub const ASS_SYNTAX: Self = _
pub const ASS_CANCELED: Self = _
pub const ASS_NO_INPUT: Self = _
pub const ASS_NO_OUTPUT: Self = _
pub const ASS_PARAMETER: Self = _
pub const ASS_UNKNOWN_INQUIRE: Self = _
pub const ENGINE_TOO_OLD: Self = _
pub const WINDOW_TOO_SMALL: Self = _
pub const WINDOW_TOO_LARGE: Self = _
pub const MISSING_ENVVAR: Self = _
pub const USER_ID_EXISTS: Self = _
pub const NAME_EXISTS: Self = _
pub const DUP_NAME: Self = _
pub const TOO_YOUNG: Self = _
pub const TOO_OLD: Self = _
pub const UNKNOWN_FLAG: Self = _
pub const INV_ORDER: Self = _
pub const ALREADY_FETCHED: Self = _
pub const TRY_LATER: Self = _
pub const WRONG_NAME: Self = _
pub const NO_AUTH: Self = _
pub const BAD_AUTH: Self = _
pub const NO_KEYBOXD: Self = _
pub const KEYBOXD: Self = _
pub const NO_SERVICE: Self = _
pub const SERVICE: Self = _
pub const BAD_PUK: Self = _
pub const NO_RESET_CODE: Self = _
pub const BAD_RESET_CODE: Self = _
pub const SYSTEM_BUG: Self = _
pub const DNS_UNKNOWN: Self = _
pub const DNS_SECTION: Self = _
pub const DNS_ADDRESS: Self = _
pub const DNS_NO_QUERY: Self = _
pub const DNS_NO_ANSWER: Self = _
pub const DNS_CLOSED: Self = _
pub const DNS_VERIFY: Self = _
pub const DNS_TIMEOUT: Self = _
pub const LDAP_GENERAL: Self = _
pub const LDAP_ATTR_GENERAL: Self = _
pub const LDAP_NAME_GENERAL: Self = _
pub const LDAP_SECURITY_GENERAL: Self = _
pub const LDAP_SERVICE_GENERAL: Self = _
pub const LDAP_UPDATE_GENERAL: Self = _
pub const LDAP_E_GENERAL: Self = _
pub const LDAP_X_GENERAL: Self = _
pub const LDAP_OTHER_GENERAL: Self = _
pub const LDAP_X_CONNECTING: Self = _
pub const LDAP_REFERRAL_LIMIT: Self = _
pub const LDAP_CLIENT_LOOP: Self = _
pub const LDAP_NO_RESULTS: Self = _
pub const LDAP_CONTROL_NOT_FOUND: Self = _
pub const LDAP_NOT_SUPPORTED: Self = _
pub const LDAP_CONNECT: Self = _
pub const LDAP_NO_MEMORY: Self = _
pub const LDAP_PARAM: Self = _
pub const LDAP_USER_CANCELLED: Self = _
pub const LDAP_FILTER: Self = _
pub const LDAP_AUTH_UNKNOWN: Self = _
pub const LDAP_TIMEOUT: Self = _
pub const LDAP_DECODING: Self = _
pub const LDAP_ENCODING: Self = _
pub const LDAP_LOCAL: Self = _
pub const LDAP_SERVER_DOWN: Self = _
pub const LDAP_SUCCESS: Self = _
pub const LDAP_OPERATIONS: Self = _
pub const LDAP_PROTOCOL: Self = _
pub const LDAP_TIMELIMIT: Self = _
pub const LDAP_SIZELIMIT: Self = _
pub const LDAP_COMPARE_FALSE: Self = _
pub const LDAP_COMPARE_TRUE: Self = _
pub const LDAP_UNSUPPORTED_AUTH: Self = _
pub const LDAP_STRONG_AUTH_RQRD: Self = _
pub const LDAP_PARTIAL_RESULTS: Self = _
pub const LDAP_REFERRAL: Self = _
pub const LDAP_ADMINLIMIT: Self = _
pub const LDAP_UNAVAIL_CRIT_EXTN: Self = _
pub const LDAP_CONFIDENT_RQRD: Self = _
pub const LDAP_SASL_BIND_INPROG: Self = _
pub const LDAP_NO_SUCH_ATTRIBUTE: Self = _
pub const LDAP_UNDEFINED_TYPE: Self = _
pub const LDAP_BAD_MATCHING: Self = _
pub const LDAP_CONST_VIOLATION: Self = _
pub const LDAP_TYPE_VALUE_EXISTS: Self = _
pub const LDAP_INV_SYNTAX: Self = _
pub const LDAP_NO_SUCH_OBJ: Self = _
pub const LDAP_ALIAS_PROBLEM: Self = _
pub const LDAP_INV_DN_SYNTAX: Self = _
pub const LDAP_IS_LEAF: Self = _
pub const LDAP_ALIAS_DEREF: Self = _
pub const LDAP_X_PROXY_AUTH_FAIL: Self = _
pub const LDAP_BAD_AUTH: Self = _
pub const LDAP_INV_CREDENTIALS: Self = _
pub const LDAP_INSUFFICIENT_ACC: Self = _
pub const LDAP_BUSY: Self = _
pub const LDAP_UNAVAILABLE: Self = _
pub const LDAP_UNWILL_TO_PERFORM: Self = _
pub const LDAP_LOOP_DETECT: Self = _
pub const LDAP_NAMING_VIOLATION: Self = _
pub const LDAP_OBJ_CLS_VIOLATION: Self = _
pub const LDAP_NOT_ALLOW_NONLEAF: Self = _
pub const LDAP_NOT_ALLOW_ON_RDN: Self = _
pub const LDAP_ALREADY_EXISTS: Self = _
pub const LDAP_NO_OBJ_CLASS_MODS: Self = _
pub const LDAP_RESULTS_TOO_LARGE: Self = _
pub const LDAP_AFFECTS_MULT_DSAS: Self = _
pub const LDAP_VLV: Self = _
pub const LDAP_OTHER: Self = _
pub const LDAP_CUP_RESOURCE_LIMIT: Self = _
pub const LDAP_CUP_SEC_VIOLATION: Self = _
pub const LDAP_CUP_INV_DATA: Self = _
pub const LDAP_CUP_UNSUP_SCHEME: Self = _
pub const LDAP_CUP_RELOAD: Self = _
pub const LDAP_CANCELLED: Self = _
pub const LDAP_NO_SUCH_OPERATION: Self = _
pub const LDAP_TOO_LATE: Self = _
pub const LDAP_CANNOT_CANCEL: Self = _
pub const LDAP_ASSERTION_FAILED: Self = _
pub const LDAP_PROX_AUTH_DENIED: Self = _
pub const USER_1: Self = _
pub const USER_2: Self = _
pub const USER_3: Self = _
pub const USER_4: Self = _
pub const USER_5: Self = _
pub const USER_6: Self = _
pub const USER_7: Self = _
pub const USER_8: Self = _
pub const USER_9: Self = _
pub const USER_10: Self = _
pub const USER_11: Self = _
pub const USER_12: Self = _
pub const USER_13: Self = _
pub const USER_14: Self = _
pub const USER_15: Self = _
pub const USER_16: Self = _
pub const SQL_OK: Self = _
pub const SQL_ERROR: Self = _
pub const SQL_INTERNAL: Self = _
pub const SQL_PERM: Self = _
pub const SQL_ABORT: Self = _
pub const SQL_BUSY: Self = _
pub const SQL_LOCKED: Self = _
pub const SQL_NOMEM: Self = _
pub const SQL_READONLY: Self = _
pub const SQL_INTERRUPT: Self = _
pub const SQL_IOERR: Self = _
pub const SQL_CORRUPT: Self = _
pub const SQL_NOTFOUND: Self = _
pub const SQL_FULL: Self = _
pub const SQL_CANTOPEN: Self = _
pub const SQL_PROTOCOL: Self = _
pub const SQL_EMPTY: Self = _
pub const SQL_SCHEMA: Self = _
pub const SQL_TOOBIG: Self = _
pub const SQL_CONSTRAINT: Self = _
pub const SQL_MISMATCH: Self = _
pub const SQL_MISUSE: Self = _
pub const SQL_NOLFS: Self = _
pub const SQL_AUTH: Self = _
pub const SQL_FORMAT: Self = _
pub const SQL_RANGE: Self = _
pub const SQL_NOTADB: Self = _
pub const SQL_NOTICE: Self = _
pub const SQL_WARNING: Self = _
pub const SQL_ROW: Self = _
pub const SQL_DONE: Self = _
pub const MISSING_ERRNO: Self = _
pub const UNKNOWN_ERRNO: Self = _
pub const EOF: Self = _
pub const E2BIG: Self = _
pub const EACCES: Self = _
pub const EADDRINUSE: Self = _
pub const EADDRNOTAVAIL: Self = _
pub const EADV: Self = _
pub const EAFNOSUPPORT: Self = _
pub const EAGAIN: Self = _
pub const EALREADY: Self = _
pub const EAUTH: Self = _
pub const EBACKGROUND: Self = _
pub const EBADE: Self = _
pub const EBADF: Self = _
pub const EBADFD: Self = _
pub const EBADMSG: Self = _
pub const EBADR: Self = _
pub const EBADRPC: Self = _
pub const EBADRQC: Self = _
pub const EBADSLT: Self = _
pub const EBFONT: Self = _
pub const EBUSY: Self = _
pub const ECANCELED: Self = _
pub const ECHILD: Self = _
pub const ECHRNG: Self = _
pub const ECOMM: Self = _
pub const ECONNABORTED: Self = _
pub const ECONNREFUSED: Self = _
pub const ECONNRESET: Self = _
pub const ED: Self = _
pub const EDEADLK: Self = _
pub const EDEADLOCK: Self = _
pub const EDESTADDRREQ: Self = _
pub const EDIED: Self = _
pub const EDOM: Self = _
pub const EDOTDOT: Self = _
pub const EDQUOT: Self = _
pub const EEXIST: Self = _
pub const EFAULT: Self = _
pub const EFBIG: Self = _
pub const EFTYPE: Self = _
pub const EGRATUITOUS: Self = _
pub const EGREGIOUS: Self = _
pub const EHOSTDOWN: Self = _
pub const EHOSTUNREACH: Self = _
pub const EIDRM: Self = _
pub const EIEIO: Self = _
pub const EILSEQ: Self = _
pub const EINPROGRESS: Self = _
pub const EINTR: Self = _
pub const EINVAL: Self = _
pub const EIO: Self = _
pub const EISCONN: Self = _
pub const EISDIR: Self = _
pub const EISNAM: Self = _
pub const EL2HLT: Self = _
pub const EL2NSYNC: Self = _
pub const EL3HLT: Self = _
pub const EL3RST: Self = _
pub const ELIBACC: Self = _
pub const ELIBBAD: Self = _
pub const ELIBEXEC: Self = _
pub const ELIBMAX: Self = _
pub const ELIBSCN: Self = _
pub const ELNRNG: Self = _
pub const ELOOP: Self = _
pub const EMEDIUMTYPE: Self = _
pub const EMFILE: Self = _
pub const EMLINK: Self = _
pub const EMSGSIZE: Self = _
pub const EMULTIHOP: Self = _
pub const ENAMETOOLONG: Self = _
pub const ENAVAIL: Self = _
pub const ENEEDAUTH: Self = _
pub const ENETDOWN: Self = _
pub const ENETRESET: Self = _
pub const ENETUNREACH: Self = _
pub const ENFILE: Self = _
pub const ENOANO: Self = _
pub const ENOBUFS: Self = _
pub const ENOCSI: Self = _
pub const ENODATA: Self = _
pub const ENODEV: Self = _
pub const ENOENT: Self = _
pub const ENOEXEC: Self = _
pub const ENOLCK: Self = _
pub const ENOLINK: Self = _
pub const ENOMEDIUM: Self = _
pub const ENOMEM: Self = _
pub const ENOMSG: Self = _
pub const ENONET: Self = _
pub const ENOPKG: Self = _
pub const ENOPROTOOPT: Self = _
pub const ENOSPC: Self = _
pub const ENOSR: Self = _
pub const ENOSTR: Self = _
pub const ENOSYS: Self = _
pub const ENOTBLK: Self = _
pub const ENOTCONN: Self = _
pub const ENOTDIR: Self = _
pub const ENOTEMPTY: Self = _
pub const ENOTNAM: Self = _
pub const ENOTSOCK: Self = _
pub const ENOTSUP: Self = _
pub const ENOTTY: Self = _
pub const ENOTUNIQ: Self = _
pub const ENXIO: Self = _
pub const EOPNOTSUPP: Self = _
pub const EOVERFLOW: Self = _
pub const EPERM: Self = _
pub const EPFNOSUPPORT: Self = _
pub const EPIPE: Self = _
pub const EPROCLIM: Self = _
pub const EPROCUNAVAIL: Self = _
pub const EPROGMISMATCH: Self = _
pub const EPROGUNAVAIL: Self = _
pub const EPROTO: Self = _
pub const EPROTONOSUPPORT: Self = _
pub const EPROTOTYPE: Self = _
pub const ERANGE: Self = _
pub const EREMCHG: Self = _
pub const EREMOTE: Self = _
pub const EREMOTEIO: Self = _
pub const ERESTART: Self = _
pub const EROFS: Self = _
pub const ERPCMISMATCH: Self = _
pub const ESHUTDOWN: Self = _
pub const ESOCKTNOSUPPORT: Self = _
pub const ESPIPE: Self = _
pub const ESRCH: Self = _
pub const ESRMNT: Self = _
pub const ESTALE: Self = _
pub const ESTRPIPE: Self = _
pub const ETIME: Self = _
pub const ETIMEDOUT: Self = _
pub const ETOOMANYREFS: Self = _
pub const ETXTBSY: Self = _
pub const EUCLEAN: Self = _
pub const EUNATCH: Self = _
pub const EUSERS: Self = _
pub const EWOULDBLOCK: Self = _
pub const EXDEV: Self = _
pub const EXFULL: Self = _
source§impl Error
impl Error
sourcepub const fn new(err: gpg_error_t) -> Self
pub const fn new(err: gpg_error_t) -> Self
Creates a new error from a raw error value.
sourcepub const fn raw(&self) -> gpg_error_t
pub const fn raw(&self) -> gpg_error_t
Returns the raw error value that this error wraps.
sourcepub fn from_source(source: ErrorSource, code: ErrorCode) -> Self
pub fn from_source(source: ErrorSource, code: ErrorCode) -> Self
Creates a new error from an error source and an error code.
sourcepub fn from_code(code: ErrorCode) -> Self
pub fn from_code(code: ErrorCode) -> Self
Creates a new error from an error code using the default
error source SOURCE_UNKNOWN
.
sourcepub fn last_os_error() -> Self
pub fn last_os_error() -> Self
Returns an error representing the last OS error that occurred.
sourcepub fn from_errno(code: i32) -> Self
pub fn from_errno(code: i32) -> Self
Creates a new error from an OS error code.
sourcepub fn source(&self) -> Option<&'static str>
pub fn source(&self) -> Option<&'static str>
Returns a description of the source of the error as a UTF-8 string.
sourcepub fn with_source(&self, src: ErrorSource) -> Self
pub fn with_source(&self, src: ErrorSource) -> Self
Returns an Error
with the same code from the provided source.
sourcepub fn raw_source(&self) -> Option<&'static [u8]>
pub fn raw_source(&self) -> Option<&'static [u8]>
Returns a description of the source of the error as a slice of bytes.
sourcepub fn description(&self) -> Cow<'static, str>
pub fn description(&self) -> Cow<'static, str>
Returns a printable description of the error.
sourcepub fn raw_description(&self) -> Cow<'static, [u8]>
pub fn raw_description(&self) -> Cow<'static, [u8]>
Returns a description of the error as a slice of bytes.
sourcepub fn write_description<'r>(
&self,
buf: &'r mut [u8]
) -> Result<&'r mut [u8], ()>
pub fn write_description<'r>( &self, buf: &'r mut [u8] ) -> Result<&'r mut [u8], ()>
Writes a description of the error to the provided buffer and returns a slice of the buffer containing the description.
§Errors
Returns an error if the provided buffer is not long enough or if the error is not recognized.