// // FetchFlags.cs // // Author: Jeffrey Stedfast // // Copyright (c) 2013-2020 .NET Foundation and Contributors // // Permission is hereby granted, free of charge, to any person obtaining a copy // of this software and associated documentation files (the "Software"), to deal // in the Software without restriction, including without limitation the rights // to use, copy, modify, merge, publish, distribute, sublicense, and/or sell // copies of the Software, and to permit persons to whom the Software is // furnished to do so, subject to the following conditions: // // The above copyright notice and this permission notice shall be included in // all copies or substantial portions of the Software. // // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN // THE SOFTWARE. // using System; namespace MailKit { /// /// A bitfield of fields. /// /// /// are used to specify which properties /// of should be populated by calls to /// , /// , or /// . /// [Flags] public enum MessageSummaryItems { /// /// Don't fetch any summary items. /// None = 0, /// /// Fetch the . /// Fetches all ANNOATION values as defined in /// rfc5257. /// Annotations = 1 << 0, /// /// Fetch the . /// Fetches the BODY value as defined in /// rfc3501. /// Unlike , Body will not populate the /// parameters nor will it populate the /// , /// or properties of each /// body part. This makes Body far less useful than BodyStructure especially when /// it is desirable to determine whether or not a body part is an attachment. /// Body = 1 << 1, /// /// Fetch the (but with more details than ). /// Fetches the BODYSTRUCTURE value as defined in /// rfc3501. /// Unlike , BodyStructure will also populate the /// parameters as well as the /// , /// and properties of each /// body part. The Content-Disposition information is especially important when trying to /// determine whether or not a body part is an attachment, for example. /// BodyStructure = 1 << 2, /// /// Fetch the . /// Fetches the ENVELOPE value as defined in /// rfc3501. /// Envelope = 1 << 3, /// /// Fetch the . /// Fetches the FLAGS value as defined in /// rfc3501. /// Flags = 1 << 4, /// /// Fetch the . /// Fetches the INTERNALDATE value as defined in /// rfc3501. /// InternalDate = 1 << 5, /// /// Fetch the . /// Fetches the RFC822.SIZE value as defined in /// rfc3501. /// Size = 1 << 6, /// /// Fetch the . /// Fetches the MODSEQ value as defined in /// rfc4551. /// ModSeq = 1 << 7, /// /// Fetch the . /// References = 1 << 8, /// /// Fetch the . /// Fetches the UID value as defined in /// rfc3501. /// UniqueId = 1 << 9, /// /// Fetch the . /// Fetches the EMAILID value as defined in /// rfc8474. /// EmailId = 1 << 10, /// /// Fetch the . /// Fetches the EMAILID value as defined in /// rfc8474. /// [Obsolete ("Use EmailId instead.")] Id = EmailId, /// /// Fetch the . /// Fetches the THREADID value as defined in /// rfc8474. /// ThreadId = 1 << 11, #region GMail extension items /// /// Fetch the . /// Fetches the X-GM-MSGID value as defined in Google's /// IMAP extensions /// documentation. /// GMailMessageId = 1 << 12, /// /// Fetch the . /// Fetches the X-GM-THRID value as defined in Google's /// IMAP extensions /// documentation. /// GMailThreadId = 1 << 13, /// /// Fetch the . /// Fetches the X-GM-LABELS value as defined in Google's /// IMAP extensions /// documentation. /// GMailLabels = 1 << 14, #endregion /// /// Fetch the the complete list of for each message. /// Headers = 1 << 15, /// /// Fetch the . /// This property is quite expensive to calculate because it is not an /// item that is cached on the IMAP server. Instead, MailKit must download a hunk of the /// message body so that it can decode and parse it in order to generate a meaningful /// text snippet. This usually involves downloading the first 512 bytes for text/plain /// message bodies and the first 16 kilobytes for text/html message bodies. If a /// message contains both a text/plain body and a text/html body, then the /// text/plain content is used in order to reduce network traffic. /// PreviewText = 1 << 16, #region Macros /// /// A macro for fetching the , , /// , and values. /// This macro maps to the equivalent ALL macro as defined in /// rfc3501. /// All = Envelope | Flags | InternalDate | Size, /// /// A macro for fetching the , , and /// values. /// This macro maps to the equivalent FAST macro as defined in /// rfc3501. /// Fast = Flags | InternalDate | Size, /// /// A macro for fetching the , , /// , , and values. /// This macro maps to the equivalent FULL macro as defined in /// rfc3501. /// Full = Body | Envelope | Flags| InternalDate | Size, #endregion } }