// Token: 0x0600071D RID: 1821 RVA: 0x00037CBC File Offset: 0x00035EBC
        private void DownloadAllAttachments(Item item, HttpContext httpContext, UserContext userContext)
        {
            BlockStatus itemBlockStatus      = AttachmentUtility.GetItemBlockStatus(item);
            string      subject              = this.GetSubject(item);
            ArrayList   attachmentListForZip = AttachmentUtility.GetAttachmentListForZip(item, true, userContext);

            if (attachmentListForZip == null || attachmentListForZip.Count == 0)
            {
                ExTraceGlobals.AttachmentHandlingTracer.TraceDebug((long)this.GetHashCode(), "AttachmentHandler.DownloadAllAttachments: No attachments returned for item");
                return;
            }
            ZipFileAttachments zipFileAttachments = new ZipFileAttachments(itemBlockStatus, subject);

            foreach (object obj in attachmentListForZip)
            {
                AttachmentWellInfo attachmentWellInfo = (AttachmentWellInfo)obj;
                zipFileAttachments.AddAttachmentToZip(attachmentWellInfo, userContext, httpContext);
            }
            zipFileAttachments.WriteArchive(httpContext);
        }
        // Token: 0x0600071B RID: 1819 RVA: 0x00037B10 File Offset: 0x00035D10
        private void DownloadOneAttachment(Item item, UserContext userContext, HttpContext httpContext, bool isVoiceMailAttachment)
        {
            Attachment attachment = null;

            try
            {
                if (!isVoiceMailAttachment)
                {
                    attachment = Utilities.GetAttachment(item, httpContext.Request, userContext);
                }
                else
                {
                    if (!userContext.IsFeatureEnabled(Feature.UMIntegration))
                    {
                        throw new OwaSegmentationException("Access to Voice mail is disabled");
                    }
                    attachment = Utilities.GetLatestVoiceMailAttachment(item, userContext);
                }
                if (attachment == null)
                {
                    ExTraceGlobals.AttachmentHandlingTracer.TraceError((long)this.GetHashCode(), "AttachmentHandler.DownloadOneAttachment: Unable to retrieve attachment from store");
                }
                else
                {
                    BlockStatus itemBlockStatus = AttachmentUtility.GetItemBlockStatus(item);
                    this.ProcessAttachment(attachment, httpContext, itemBlockStatus);
                }
            }
            finally
            {
                if (attachment != null)
                {
                    attachment.Dispose();
                }
            }
        }