1 write to Default
Microsoft.AspNetCore.Routing (1)
Patterns\RoutePatternParameterPart.cs (1)
40
Default
= @default;
94 references to Default
Microsoft.AspNetCore.App.Analyzers.Test (1)
RouteEmbeddedLanguage\RoutePatternParserTests.cs (1)
212
Assert.True(Equals(routeParameter.DefaultValue, parsedRoutePattern.
Default
), "DefaultValue");
Microsoft.AspNetCore.Mvc.Core (2)
Routing\RoutePatternWriter.cs (2)
51
if (parameterPart.
Default
!= null)
54
sb.Append(parameterPart.
Default
);
Microsoft.AspNetCore.Routing (13)
Matching\DfaMatcherBuilder.cs (3)
780
var hasDefaultValue = parameterPart.
Default
!= null || parameterPart.IsCatchAll;
781
_slots.Add(hasDefaultValue ? new KeyValuePair<string, object>(parameterPart.Name, parameterPart.
Default
) : default);
868
parameterPart.
Default
== null)
Patterns\RoutePatternFactory.cs (6)
579
var @default = parameter.
Default
;
583
if (parameter.
Default
!= null && !Equals(newDefault, parameter.
Default
))
598
if (parameter.
Default
!= null)
605
updatedDefaults[parameter.Name] = parameter.
Default
;
626
if (Equals(parameter.
Default
, @default)
Patterns\RoutePatternParameterPart.cs (2)
105
if (
Default
!= null)
108
builder.Append(
Default
);
Patterns\RoutePatternParser.cs (1)
223
if (templatePart.IsOptional && templatePart.
Default
!= null)
Template\TemplatePart.cs (1)
43
DefaultValue = parameter.
Default
;
Microsoft.AspNetCore.Routing.Microbenchmarks (2)
src\Http\Routing\test\UnitTests\Matching\RouteMatcherBuilder.cs (1)
56
if (parameter.
Default
!= null)
src\Http\Routing\test\UnitTests\Matching\TreeRouterMatcherBuilder.cs (1)
60
if (parameter.
Default
!= null)
Microsoft.AspNetCore.Routing.Tests (76)
Matching\RouteMatcherBuilder.cs (1)
56
if (parameter.
Default
!= null)
Matching\TreeRouterMatcherBuilder.cs (1)
60
if (parameter.
Default
!= null)
Patterns\DefaultRoutePatternTransformerTest.cs (2)
204
Assert.Null(actual.GetParameter("controller").
Default
);
206
Assert.Null(actual.GetParameter("action").
Default
);
Patterns\InlineRouteParameterParserTest.cs (55)
18
Assert.Null(templatePart.
Default
);
30
Assert.Equal("", templatePart.
Default
);
42
Assert.Null(templatePart.
Default
);
54
Assert.Equal("", templatePart.
Default
);
66
Assert.Equal(":", templatePart.
Default
);
78
Assert.Equal("111111", templatePart.
Default
);
92
Assert.Equal("111111", templatePart.
Default
);
120
Assert.Equal("12", templatePart.
Default
);
135
Assert.Equal("12?", templatePart.
Default
);
166
Assert.Equal("abc", templatePart.
Default
);
224
Assert.Equal("qwer", templatePart.
Default
);
240
Assert.Equal("=qwer", templatePart.
Default
);
259
Assert.Equal(defaultValue, templatePart.
Default
);
276
Assert.Equal("hello", param1.
Default
);
286
Assert.Equal("abc", param2.
Default
);
312
Assert.Equal("world", templatePart.
Default
);
337
Assert.Equal("wer", templatePart.
Default
);
365
Assert.Equal("fsd", templatePart.
Default
);
393
Assert.Equal("mnf", templatePart.
Default
);
421
Assert.Equal("12", templatePart.
Default
);
436
Assert.Equal("12", templatePart.
Default
);
492
Assert.Equal("jsd", templatePart.
Default
);
506
Assert.Equal("", templatePart.
Default
);
522
Assert.Null(templatePart.
Default
);
536
Assert.Equal("test=bar", templatePart.
Default
);
547
Assert.Null(templatePart.
Default
);
561
Assert.Equal("dvds", templatePart.
Default
);
575
Assert.Equal("=am:test=dvds", templatePart.
Default
);
586
Assert.Equal("=dvds", templatePart.
Default
);
597
Assert.Equal("am:test(asd)", templatePart.
Default
);
608
Assert.Equal("test(am):est=asd", templatePart.
Default
);
619
Assert.Equal("sds", templatePart.
Default
);
660
Assert.Equal("xvc", templatePart.
Default
);
727
Assert.Equal("default-value", templatePart.
Default
);
743
Assert.Equal("test1", templatePart.
Default
);
758
Assert.Equal("djk", templatePart.
Default
);
772
Assert.Null(templatePart.
Default
);
787
Assert.Null(templatePart.
Default
);
802
Assert.Equal("sdf", templatePart.
Default
);
817
Assert.Equal("sdf", templatePart.
Default
);
832
Assert.Null(templatePart.
Default
);
847
Assert.Null(templatePart.
Default
);
863
Assert.Null(templatePart.
Default
);
878
Assert.Null(templatePart.
Default
);
893
Assert.Null(templatePart.
Default
);
908
Assert.Equal("123-456-7890", templatePart.
Default
);
934
Assert.Null(templatePart.
Default
);
959
Assert.NotNull(parameterPart.
Default
);
960
Assert.Equal("a/b/c", parameterPart.
Default
.ToString());
998
Assert.NotNull(parameterPart.
Default
);
999
Assert.Equal("a/b/c", parameterPart.
Default
.ToString());
1024
Assert.NotNull(parameterPart.
Default
);
1025
Assert.Equal("a/b/c", parameterPart.
Default
.ToString());
1061
Assert.NotNull(parameterPart.
Default
);
1062
Assert.Equal("a/b/c", parameterPart.
Default
.ToString());
Patterns\RoutePatternFactoryTest.cs (15)
30
Assert.Equal("15", actual.GetParameter("a").
Default
);
31
Assert.Equal(17, actual.GetParameter("b").
Default
);
32
Assert.Equal("19", actual.GetParameter("c").
Default
);
485
Assert.Equal(12, actual.Parameters[0].
Default
);
486
Assert.Null(paramPartB.
Default
);
489
Assert.Equal(4, actual.Parameters[1].
Default
);
491
Assert.Null(paramPartC.
Default
);
493
Assert.Null(actual.Parameters[2].
Default
);
495
Assert.Null(paramPartD.
Default
);
525
Assert.Equal(12, actual.Parameters[0].
Default
);
526
Assert.Null(paramPartB.
Default
);
529
Assert.Equal(4, actual.Parameters[1].
Default
);
531
Assert.Null(paramPartC.
Default
);
533
Assert.Null(actual.Parameters[2].
Default
);
535
Assert.Null(paramPartD.
Default
);
Patterns\RoutePatternParserTest.cs (2)
730
x.
Default
== y.
Default
&&