// Token: 0x06000F5E RID: 3934 RVA: 0x0005B7C4 File Offset: 0x000599C4
        private void SyncPublicFolderMailbox(Guid mailboxGuid)
        {
            if (PublicFolderSplitHelper.IsPrimaryHierarchy(mailboxGuid, base.CurrentPublicFolderSession.OrganizationId))
            {
                this.logger.LogEvent(LogEventType.Verbose, string.Format("The target mailbox, {0}, is the primary hierarchy. Skipping PrepareTargetMailboxOperation.", this.splitState.TargetMailboxGuid.ToString()));
                return;
            }
            bool flag  = false;
            bool flag2 = PublicFolderSplitHelper.IsSyncRequired(mailboxGuid, base.CurrentPublicFolderSession.OrganizationId, out flag, this.xsoFactory, this.logger);

            if (flag2)
            {
                if (flag)
                {
                    this.SyncAndReturn(mailboxGuid);
                }
                else
                {
                    PublicFolderSplitHelper.SyncAndWaitForCompletion(mailboxGuid, base.CurrentPublicFolderSession.OrganizationId, this.xsoFactory, this.logger, this.splitOperationState);
                }
            }
            this.logger.LogEvent(LogEventType.Statistics, string.Format("PrepareTargetMailboxOperation::SyncPublicFolderMailbox - SR={0},IPS={1},PSC={2},RC={3}", new object[]
            {
                flag2,
                this.splitOperationState.PartialStep,
                this.splitOperationState.PartialStepCount,
                this.splitOperationState.RetryCount
            }));
        }
        // Token: 0x06000EC7 RID: 3783 RVA: 0x00057A38 File Offset: 0x00055C38
        protected override void InvokeInternal()
        {
            if (!this.AreSplitPlanFoldersValid())
            {
                this.splitOperationState.Error = new SplitPlanFoldersInvalidException();
                return;
            }
            PublicFolderMoveRequest publicFolderMoveRequest = this.GetPublicFolderMoveRequest();

            if (this.splitOperationState.Error == null && this.TryHandleExistingRequest(publicFolderMoveRequest))
            {
                Unlimited <ByteQuantifiedSize> totalItemSize = PublicFolderSplitHelper.GetTotalItemSize(this.logger, this.powershellFactory, this.splitState.TargetMailboxGuid, base.CurrentPublicFolderSession.OrganizationId, this.splitOperationState);
                if (this.splitOperationState.Error != null)
                {
                    return;
                }
                Unlimited <ByteQuantifiedSize> mailboxQuota = PublicFolderSplitHelper.GetMailboxQuota(this.logger, this.powershellFactory, this.splitState.TargetMailboxGuid, base.CurrentPublicFolderSession.OrganizationId, this.splitOperationState);
                if (this.splitOperationState.Error != null)
                {
                    return;
                }
                if (totalItemSize.Value.ToBytes() + this.splitState.SplitPlan.TotalSizeToSplit >= mailboxQuota.Value.ToBytes() * PublicFolderSplitConfig.Instance.SplitThreshold / 100UL)
                {
                    this.splitOperationState.Error = new TargetMailboxOutofQuotaException(base.CurrentPublicFolderSession.OrganizationId.OrganizationalUnit.Name, this.splitState.TargetMailboxGuid.ToString());
                    return;
                }
                try
                {
                    if (!PublicFolderSplitHelper.IsPrimaryHierarchy(this.splitState.TargetMailboxGuid, base.CurrentPublicFolderSession.OrganizationId))
                    {
                        bool flag  = false;
                        bool flag2 = PublicFolderSplitHelper.IsSyncRequired(this.splitState.TargetMailboxGuid, base.CurrentPublicFolderSession.OrganizationId, out flag, this.xsoFactory, this.logger);
                        if (flag2)
                        {
                            PublicFolderSplitHelper.SyncAndWaitForCompletion(this.splitState.TargetMailboxGuid, base.CurrentPublicFolderSession.OrganizationId, this.xsoFactory, this.logger, this.splitOperationState);
                        }
                    }
                    else
                    {
                        this.logger.LogEvent(LogEventType.Verbose, string.Format("The target mailbox, {0}, is the primary hierarchy. Skipped sync.", this.splitState.TargetMailboxGuid.ToString()));
                    }
                }
                catch (StorageTransientException error)
                {
                    this.splitOperationState.Error = error;
                    return;
                }
                catch (StoragePermanentException error2)
                {
                    this.splitOperationState.Error = error2;
                    return;
                }
                this.IssueMoveRequest();
                if (this.splitOperationState.Error == null)
                {
                    this.splitOperationState.PartialStep = true;
                    this.logger.LogEvent(LogEventType.Verbose, "MoveContentOperation::InvokeInternal - Successfully issued a new public folder move request.");
                }
            }
        }