public IDictionary <string, ISampler <T> > Instantiate(IFailureReportProfile profile) { return(new Dictionary <string, ISampler <T> >() { { "expected", SelectSampler(profile.ExpectedSet, profile.ThresholdSampleItem, profile.MaxSampleItem) }, { "actual", SelectSampler(profile.ActualSet, profile.ThresholdSampleItem, profile.MaxSampleItem) }, { "analysis", SelectSampler(profile.AnalysisSet, profile.ThresholdSampleItem, profile.MaxSampleItem) }, }); }
public IScoreMessageFormatter Instantiate(IFailureReportProfile profile) { switch (profile.Format) { case FailureReportFormat.Markdown: return(new ScoreMessageMarkdown()); case FailureReportFormat.Json: return(new ScoreMessageJson()); default: throw new ArgumentOutOfRangeException(); } }
public IDataRowsMessageFormatter Instantiate(IFailureReportProfile profile, Core.ResultSet.EngineStyle style) { var factory = new SamplersFactory <DataRow>(); var samplers = factory.Instantiate(profile); switch (profile.Format) { case FailureReportFormat.Markdown: return(new DataRowsMessageMarkdown(style, samplers)); case FailureReportFormat.Json: return(new DataRowsMessageJson(style, samplers)); default: throw new ArgumentOutOfRangeException(); } }
public IItemsMessageFormatter Instantiate(IFailureReportProfile profile) { var factory = new SamplersFactory <string>(); var samplers = factory.Instantiate(profile); switch (profile.Format) { case FailureReportFormat.Markdown: return(new ItemsMessageMarkdown(samplers)); case FailureReportFormat.Json: return(new ItemsMessageJson(samplers)); default: throw new ArgumentOutOfRangeException(); } }
public ILookupViolationsMessageFormatter Instantiate(IFailureReportProfile profile) { var dataRowsFactory = new SamplersFactory <DataRow>(); var dataRowsSamplers = dataRowsFactory.Instantiate(profile); var keysCollectionFactory = new SamplersFactory <KeyCollection>(); var keysCollectionSamplers = keysCollectionFactory.Instantiate(profile); switch (profile.Format) { case FailureReportFormat.Markdown: return(new LookupViolationsMessageMarkdown(keysCollectionSamplers, dataRowsSamplers)); case FailureReportFormat.Json: return(new ReferenceViolationsMessageJson(dataRowsSamplers)); default: throw new ArgumentOutOfRangeException(); } }
public DataRowsMessage(ComparisonStyle style, IFailureReportProfile profile) : base(profile) { this.style = style; }
public DataRowsMessage(IFailureReportProfile profile) : base(profile) { }
public TestConfiguration(IFailureReportProfile profile) { failureReportProfile = profile; }
public void LoadFailureReportProfile(IFailureReportProfile profile) { FailureReportProfile = profile; }
public SampledFailureMessage(IFailureReportProfile profile) : base() { this.profile = profile; }
public ItemsMessage(IFailureReportProfile profile) : base(profile) { }