protected override void CustomInternalValidate() { base.CustomInternalValidate(); Schema.Utilities.CheckDates(this.StartDate, this.EndDate, new Schema.Utilities.NotifyNeedDefaultDatesDelegate(this.SetDefaultDates), new Schema.Utilities.ValidateDatesDelegate(Schema.Utilities.VerifyDateRange)); GetMailTrafficSummaryReport.Categories categories; if (!Enum.TryParse <GetMailTrafficSummaryReport.Categories>(this.Category, true, out categories)) { throw new InvalidExpressionException(Strings.InvalidCategory); } Tuple <string, GetMailTrafficSummaryReport.AggregateDelegate> tuple; if (!this.mappings.TryGetValue(categories, out tuple)) { throw new InvalidOperationException(Strings.InvalidCategory); } this.CategoryEnum = categories; base.DalObjectTypeName = tuple.Item1; }
private void AddTopTraffic(GetMailTrafficSummaryReport.Categories category, string eventType, params string[] directions) { this.mappings.Add(category, Tuple.Create <string, GetMailTrafficSummaryReport.AggregateDelegate>("Microsoft.Exchange.Hygiene.Data.MessageTrace.Reports.TopTrafficReport, Microsoft.Exchange.Hygiene.Data", () => this.AggregateTopTraffic(eventType, directions))); }