22 references to Throw
Microsoft.Extensions.Diagnostics.Testing (22)
Logging\FakeLogCollector.cs (3)
28
_options =
Throw
.IfNullOrMemberNull(options, options?.Value);
46
return new FakeLogCollector(Options.Options.Create(
Throw
.IfNull(options)));
96
Throw
.InvalidOperationException("No records logged.");
Logging\FakeLogCollectorDebugView.cs (1)
18
_collector =
Throw
.IfNull(collector);
Logging\FakeLogger.cs (1)
65
_ =
Throw
.IfNull(formatter);
Logging\FakeLoggerBuilderExtensions.cs (4)
27
_ =
Throw
.IfNull(builder);
28
_ =
Throw
.IfNull(section);
45
_ =
Throw
.IfNull(builder);
46
_ =
Throw
.IfNull(configure);
Logging\FakeLoggerProvider.cs (1)
49
_scopeProvider =
Throw
.IfNull(scopeProvider);
Logging\FakeLogRecord.cs (2)
36
Message =
Throw
.IfNull(message);
37
Scopes =
Throw
.IfNull(scopes);
Metrics\CollectedMeasurement.cs (3)
61
foreach (var kvp in
Throw
.IfNull(tags))
84
foreach (var key in
Throw
.IfNull(tags))
107
public bool MatchesTags(params string[] tags) => ContainsTags(
Throw
.IfNull(tags)) && (Tags.Count == tags.Length);
Metrics\MetricCollector.cs (7)
51
_instrument =
Throw
.IfNull(instrument);
65
_instrument =
Throw
.IfNull(instrument);
87
_ =
Throw
.IfNullOrEmpty(meterName);
88
_ =
Throw
.IfNullOrEmpty(instrumentName);
102
_ =
Throw
.IfNull(meter);
103
_ =
Throw
.IfNullOrEmpty(instrumentName);
211
_ =
Throw
.IfLessThan(minCount, 1);