protected override SoftDeleteMailboxRemovalCheckRemoval CheckRemoval() { SoftDeletedMoveHistory softDeletedMoveHistory = this.context.RetrieveSoftDeletedMailboxMoveHistory(base.Data.MailboxIdentity.Guid, base.Data.TargetDatabase.Guid, base.Data.SourceDatabase.Guid); if (softDeletedMoveHistory == null) { string reasonMessage = "Cannot remove soft deleted mailbox {0} because its Movehistory for source database '{1}' and target database '{2}' could not be found"; return(SoftDeleteMailboxRemovalCheckRemoval.DisallowRemoval(reasonMessage, new object[] { base.Data.MailboxIdentity.Guid, base.Data.SourceDatabase.Name, base.Data.TargetDatabase.Name })); } if (softDeletedMoveHistory.BadItemsEncountered > 0 || softDeletedMoveHistory.LargeItemsEncountered > 0 || softDeletedMoveHistory.MissingItemsEncountered > 0) { string reasonMessage2 = "Cannot remove soft deleted mailbox {0} because its MoveHistory from '{1}' to '{2}' has BadItemCount: {3} LargeItemCount: {4} MissingItemCount: {5}."; return(SoftDeleteMailboxRemovalCheckRemoval.DisallowRemoval(reasonMessage2, new object[] { base.Data.MailboxIdentity.Guid, base.Data.SourceDatabase.Name, base.Data.TargetDatabase.Name, softDeletedMoveHistory.BadItemsEncountered, softDeletedMoveHistory.LargeItemsEncountered, softDeletedMoveHistory.MissingItemsEncountered })); } return(null); }
protected bool Equals(SoftDeletedMoveHistory other) { return(this.BadItemsEncountered == other.BadItemsEncountered && this.LargeItemsEncountered == other.LargeItemsEncountered && this.MissingItemsEncountered == other.MissingItemsEncountered); }