#[non_exhaustive]pub enum ResponseCode {
Show 61 variants
Alert,
BadCharset(Vec<String>),
Capability(Vec<Capability>),
Parse,
PermanentFlags(Vec<Flag>),
ReadOnly,
ReadWrite,
TryCreate,
UidNext(u32),
UidValidity(u32),
Unseen(u32),
AppendUid {
uid_validity: u32,
uids: Vec<UidRange>,
},
CopyUid {
uid_validity: u32,
source_uids: Vec<UidRange>,
dest_uids: Vec<UidRange>,
},
HighestModSeq(u64),
Modified(Vec<UidRange>),
NoModSeq,
Closed,
MailboxId(String),
Unavailable,
AuthenticationFailed,
AuthorizationFailed,
Expired,
PrivacyRequired,
ContactAdmin,
NoPerm,
InUse,
ExpungeIssued,
Corruption,
ServerBug,
ClientBug,
Cannot,
Limit,
OverQuota,
AlreadyExists,
NonExistent,
NewName(Option<String>),
Referral(Option<String>),
UrlMech(Option<String>),
BadUrl(Option<String>),
BadComparator(Option<String>),
Annotate(Option<String>),
Annotations(Option<String>),
TempFail(Option<String>),
MaxConvertMessages(Option<String>),
MaxConvertParts(Option<String>),
NoUpdate(Option<String>),
NotificationOverflow(Option<String>),
BadEvent(Option<String>),
UndefinedFilter(Option<String>),
UidNotSticky,
NotSaved,
HasChildren,
UnknownCte,
TooBig,
CompressionActive,
UseAttr,
MetadataLongEntries(u64),
MetadataMaxSize(u64),
MetadataTooMany,
MetadataNoPrivate,
Other {
name: String,
value: Option<String>,
},
}Expand description
Response code in square brackets (e.g. [UIDVALIDITY 12345])
(RFC 3501 Section 7.1 / RFC 9051 Section 7.1).
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Alert
[ALERT] — must be presented to the user (RFC 3501 Section 7.1).
BadCharset(Vec<String>)
[BADCHARSET (charsets)] — search charset not supported (RFC 3501 Section 7.1).
Capability(Vec<Capability>)
[CAPABILITY ...] — capability list (RFC 3501 Section 7.1).
Parse
[PARSE] — message headers could not be parsed (RFC 3501 Section 7.1).
PermanentFlags(Vec<Flag>)
[PERMANENTFLAGS (flags)] — flags the client can change permanently (RFC 3501 Section 7.1).
ReadOnly
[READ-ONLY] — mailbox is read-only (RFC 3501 Section 7.1).
ReadWrite
[READ-WRITE] — mailbox is read-write (RFC 3501 Section 7.1).
TryCreate
[TRYCREATE] — attempt to CREATE the target mailbox (RFC 3501 Section 7.1).
UidNext(u32)
[UIDNEXT n] — predicted next UID (RFC 3501 Section 7.1).
UidValidity(u32)
[UIDVALIDITY n] — UID validity value (RFC 3501 Section 7.1).
Unseen(u32)
[UNSEEN n] — first unseen message sequence number (RFC 3501 Section 7.1).
AppendUid
[APPENDUID uidvalidity uid-set] (RFC 4315 UIDPLUS Section 3).
For a single APPEND, uids contains one range. For MULTIAPPEND
(RFC 3502), uids may contain multiple ranges.
CopyUid
[COPYUID uidvalidity source-uids dest-uids] (RFC 4315 UIDPLUS).
HighestModSeq(u64)
[HIGHESTMODSEQ n] (RFC 7162 CONDSTORE).
Modified(Vec<UidRange>)
[MODIFIED sequence-set] (RFC 7162 Section 3.1.3 / Section 7).
For STORE, the set contains message sequence numbers. For UID STORE,
it contains UIDs.
NoModSeq
[NOMODSEQ] — mailbox does not support mod-sequences (RFC 7162 Section 3.1.2).
Closed
[CLOSED] — previously selected mailbox is now closed (RFC 7162 QRESYNC).
MailboxId(String)
[MAILBOXID (objectid)] — unique mailbox identifier (RFC 8474 Section 5.1).
[UNAVAILABLE] — server temporarily unavailable (RFC 5530 Section 3).
AuthenticationFailed
[AUTHENTICATIONFAILED] — authentication credentials invalid (RFC 5530 Section 3).
AuthorizationFailed
[AUTHORIZATIONFAILED] — authorization identity not permitted (RFC 5530 Section 3).
Expired
[EXPIRED] — credentials have expired (RFC 5530 Section 3).
PrivacyRequired
[PRIVACYREQUIRED] — operation requires encryption (RFC 5530 Section 3).
ContactAdmin
[CONTACTADMIN] — contact server administrator (RFC 5530 Section 3).
NoPerm
[NOPERM] — no permission to perform the operation (RFC 5530 Section 3).
InUse
[INUSE] — resource is in use by another session (RFC 5530 Section 3).
ExpungeIssued
[EXPUNGEISSUED] — expunge occurred during operation (RFC 5530 Section 3).
Corruption
[CORRUPTION] — server detected data corruption (RFC 5530 Section 3).
ServerBug
[SERVERBUG] — server encountered an internal bug (RFC 5530 Section 3).
ClientBug
[CLIENTBUG] — client sent malformed or nonsensical data (RFC 5530 Section 3).
Cannot
[CANNOT] — operation is not supported on this mailbox/server (RFC 5530 Section 3).
Limit
[LIMIT] — operation exceeds a server-imposed limit (RFC 5530 Section 3).
OverQuota
[OVERQUOTA] — user has exceeded their storage quota (RFC 5530 Section 3).
AlreadyExists
[ALREADYEXISTS] — mailbox already exists (e.g. on CREATE) (RFC 5530 Section 3).
NonExistent
[NONEXISTENT] — mailbox does not exist (e.g. on SELECT/DELETE) (RFC 5530 Section 3).
NewName(Option<String>)
[NEWNAME ...] — registered response code, obsolete but still standardized;
trailing data is preserved verbatim (RFC 5530 Section 6).
Referral(Option<String>)
[REFERRAL ...] — registered response code; trailing data is preserved
verbatim for consumers (RFC 5530 Section 6).
UrlMech(Option<String>)
[URLMECH ...] — registered response code; trailing data is preserved
verbatim for consumers (RFC 5530 Section 6).
BadUrl(Option<String>)
[BADURL ...] — registered response code; trailing data is preserved
verbatim for consumers (RFC 5530 Section 6).
BadComparator(Option<String>)
[BADCOMPARATOR ...] — registered response code; trailing data is
preserved verbatim for consumers (RFC 5530 Section 6).
Annotate(Option<String>)
[ANNOTATE ...] — registered response code; trailing data is preserved
verbatim for consumers (RFC 5530 Section 6).
Annotations(Option<String>)
[ANNOTATIONS ...] — registered response code; trailing data is preserved
verbatim for consumers (RFC 5530 Section 6).
TempFail(Option<String>)
[TEMPFAIL ...] — registered response code; trailing data is preserved
verbatim for consumers (RFC 5530 Section 6).
MaxConvertMessages(Option<String>)
[MAXCONVERTMESSAGES ...] — registered response code; trailing data is
preserved verbatim for consumers (RFC 5530 Section 6).
MaxConvertParts(Option<String>)
[MAXCONVERTPARTS ...] — registered response code; trailing data is
preserved verbatim for consumers (RFC 5530 Section 6).
NoUpdate(Option<String>)
[NOUPDATE ...] — registered response code; trailing data is preserved
verbatim for consumers (RFC 5530 Section 6).
NotificationOverflow(Option<String>)
[NOTIFICATIONOVERFLOW ...] — registered response code; trailing data
is preserved verbatim for consumers (RFC 5465 Section 5.8 / RFC 5530 Section 6).
BadEvent(Option<String>)
[BADEVENT ...] — registered response code; trailing data is preserved
verbatim for consumers (RFC 5465 Section 5 / RFC 5530 Section 6).
UndefinedFilter(Option<String>)
[UNDEFINED-FILTER ...] — registered response code; trailing data is
preserved verbatim for consumers (RFC 5465 Section 8 / RFC 5530 Section 6).
UidNotSticky
[UIDNOTSTICKY] — assigned UIDs are not persistent (RFC 4315 Section 2 / RFC 9051 Section 7.1).
NotSaved
[NOTSAVED] — search result variable $ is empty (RFC 5182 Section 2.1).
HasChildren
[HASCHILDREN] — mailbox has child mailboxes (RFC 9051 Section 7.1).
UnknownCte
[UNKNOWN-CTE] — BINARY fetch failed due to unknown CTE (RFC 3516 Section 4.3).
TooBig
[TOOBIG] — message too large for APPEND (RFC 7889 Section 4).
CompressionActive
[COMPRESSIONACTIVE] — compression layer already active (RFC 4978 Section 3).
UseAttr
[USEATTR] — special-use attribute not supported (RFC 6154 Section 6).
MetadataLongEntries(u64)
[METADATA LONGENTRIES n] — entry values were truncated at n bytes
(RFC 5464 Section 4.2.1).
MetadataMaxSize(u64)
[METADATA MAXSIZE n] — server’s maximum annotation size
(RFC 5464 Section 4.3).
MetadataTooMany
[METADATA TOOMANY] — too many annotations on this mailbox
(RFC 5464 Section 4.3).
MetadataNoPrivate
[METADATA NOPRIVATE] — server does not support private annotations
(RFC 5464 Section 4.3).
Other
Unrecognized response code — preserved for forward compatibility.
Trait Implementations§
Source§impl Clone for ResponseCode
impl Clone for ResponseCode
Source§fn clone(&self) -> ResponseCode
fn clone(&self) -> ResponseCode
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more