Beispiel #1
0
 public override SoftDeleteMailboxRemovalCheckRemoval CheckSoftDeletedMailboxRemoval(SoftDeletedRemovalData data)
 {
     return(SoftDeleteMailboxRemovalCheckRemoval.DisallowRemoval("The target server '{0}' does not have the SoftDeletedRemoval capability so removal is not valid", new object[]
     {
         base.TargetServer.Name
     }));
 }
Beispiel #2
0
        public SoftDeleteMailboxRemovalCheckRemoval CheckSoftDeletedMailboxRemoval(SoftDeletedRemovalData data)
        {
            if (!this.Settings.SoftDeletedCleanupEnabled)
            {
                return(SoftDeleteMailboxRemovalCheckRemoval.DisallowRemoval("SoftDeletedRemoval is disabled on the target database '{0}', so no removal check can be performed.", new object[]
                {
                    data.TargetDatabase.Name
                }));
            }
            DateTime removalCutoffDate = DateTime.UtcNow.Add(TimeSpan.Zero - this.Settings.MinimumSoftDeletedMailboxCleanupAge);
            SoftDeletedMailboxRemovalCheck softDeletedMailboxRemovalCheck  = new DisconnectDateCheck(data, this.Directory, removalCutoffDate);
            SoftDeletedMailboxRemovalCheck softDeletedMailboxRemovalCheck2 = new ItemCountCheck(data, this.Directory);
            SoftDeletedMailboxRemovalCheck next = new MoveHistoryCheck(data, this);

            softDeletedMailboxRemovalCheck.SetNext(softDeletedMailboxRemovalCheck2);
            softDeletedMailboxRemovalCheck2.SetNext(next);
            return(softDeletedMailboxRemovalCheck.GetRemovalResult());
        }