Exemplo n.º 1
0
        // Token: 0x060003BC RID: 956 RVA: 0x0001A6EC File Offset: 0x000188EC
        private void InvokeInternal(MailboxSession mailboxSession, MailboxDataForTags mailboxDataForTags)
        {
            if (mailboxSession.MailboxOwner.RecipientType == RecipientType.MailUser && !this.FaiExists(mailboxSession))
            {
                ElcSubAssistant.Tracer.TraceDebug <ElcTagSubAssistant, string>((long)this.GetHashCode(), "{0}: FAI doesn't exist for archive mailbox: {1}. Skip it.", this, mailboxSession.MailboxOwner.MailboxInfo.DisplayName);
                return;
            }
            if (!this.CheckForPolicy(mailboxDataForTags))
            {
                if (mailboxDataForTags.LitigationHoldEnabled || mailboxDataForTags.SuspendExpiration)
                {
                    ElcUserTagInformation elcUserTagInformation = (ElcUserTagInformation)mailboxDataForTags.ElcUserInformation;
                    elcUserTagInformation.EnsureUserConfigurationIsValid();
                    elcUserTagInformation.SaveConfigItem(mailboxDataForTags.ArchiveProcessor);
                }
                return;
            }
            bool flag = this.tagProvisioner.Invoke(mailboxDataForTags);

            if (flag)
            {
                this.MapPolicyForArchive(mailboxDataForTags);
                this.tagEnforcerManager.Invoke(mailboxDataForTags);
            }
            this.TrainForAutoTagging(mailboxDataForTags);
        }
        // Token: 0x060003F6 RID: 1014 RVA: 0x0001C798 File Offset: 0x0001A998
        private bool InvokeInternal(MailboxDataForTags mailboxDataForTags)
        {
            TagProvisioner.Tracer.TraceDebug <TagProvisioner, IExchangePrincipal>((long)this.GetHashCode(), "{0}: TagProvisioner invoked for for mailbox '{1}'.", this, mailboxDataForTags.MailboxSession.MailboxOwner);
            ElcUserTagInformation elcUserTagInformation = (ElcUserTagInformation)mailboxDataForTags.ElcUserInformation;
            bool      flag      = false;
            TagChange tagChange = new TagChange();

            if (mailboxDataForTags.MailboxSession.MailboxOwner.RecipientType != RecipientType.MailUser)
            {
                MailboxUpgrader  mailboxUpgrader  = new MailboxUpgrader(elcUserTagInformation);
                UpgradeStatus    upgradeStatus    = mailboxUpgrader.UpgradeIfNecessary();
                ADChangeDetector adchangeDetector = new ADChangeDetector(mailboxDataForTags);
                tagChange = adchangeDetector.Detect();
                if (tagChange.ChangeType != ChangeType.None || (upgradeStatus & UpgradeStatus.AppliedFolderTag) != UpgradeStatus.None)
                {
                    flag = true;
                    elcUserTagInformation.FullCrawlRequired = true;
                }
            }
            else if (elcUserTagInformation.FullCrawlRequired)
            {
                flag = true;
            }
            mailboxDataForTags.StatisticsLogEntry.IsFullCrawlNeeded = flag;
            Synchronizer synchronizer = new Synchronizer(mailboxDataForTags, this.elcAssistant, flag);

            synchronizer.Invoke();
            return(elcUserTagInformation.SaveConfigItem(mailboxDataForTags.ArchiveProcessor));
        }
        // Token: 0x06000399 RID: 921 RVA: 0x00019714 File Offset: 0x00017914
        public void Init(MailboxSession mailboxSession)
        {
            bool flag = false;
            ElcUserTagInformation elcUserTagInformation = null;

            try
            {
                elcUserTagInformation = new ElcUserTagInformation(mailboxSession);
                base.Init(elcUserTagInformation);
                flag = true;
            }
            finally
            {
                if (!flag && elcUserTagInformation != null)
                {
                    elcUserTagInformation.Dispose();
                    elcUserTagInformation = null;
                }
            }
        }
 // Token: 0x060003DA RID: 986 RVA: 0x0001BE31 File Offset: 0x0001A031
 internal MailboxUpgrader(ElcUserTagInformation dataForTags)
 {
     this.dataForTags = dataForTags;
 }