2 writes to InlineConstraints
Microsoft.AspNetCore.Routing (2)
Template\TemplatePart.cs (2)
44
InlineConstraints
= parameter.ParameterPolicies?.Select(p => new InlineConstraint(p)) ?? Enumerable.Empty<InlineConstraint>();
97
InlineConstraints
= inlineConstraints ?? Enumerable.Empty<InlineConstraint>(),
82 references to InlineConstraints
Microsoft.AspNetCore.Mvc.ApiExplorer (2)
DefaultApiDescriptionProvider.cs (2)
347
if (routeParameter.
InlineConstraints
!= null)
349
foreach (var constraint in routeParameter.
InlineConstraints
)
Microsoft.AspNetCore.Routing (12)
RouteBase.cs (1)
226
foreach (var inlineConstraint in parameter.
InlineConstraints
)
Template\RoutePrecedence.cs (4)
166
if (part.
InlineConstraints
!= null && part.
InlineConstraints
.Any())
236
if (part.
InlineConstraints
!= null && part.
InlineConstraints
.Any())
Template\TemplatePart.cs (1)
173
var constraints =
InlineConstraints
.Select(c => new RoutePatternParameterPolicyReference(c.Constraint));
Tree\TreeRouteBuilder.cs (4)
118
if (parameter.
InlineConstraints
!= null)
124
foreach (var constraint in parameter.
InlineConstraints
)
203
if (parameter.
InlineConstraints
!= null)
210
foreach (var constraint in parameter.
InlineConstraints
)
Tree\UrlMatchingTree.cs (2)
139
if (part.IsParameter && part.
InlineConstraints
.Any() && !part.IsCatchAll)
161
if (part.IsParameter && part.
InlineConstraints
.Any() && part.IsCatchAll)
Microsoft.AspNetCore.Routing.Tests (68)
InlineRouteParameterParserTests.cs (58)
24
Assert.Empty(templatePart.
InlineConstraints
);
36
Assert.Empty(templatePart.
InlineConstraints
);
48
var constraint = Assert.Single(templatePart.
InlineConstraints
);
61
var constraint = Assert.Single(templatePart.
InlineConstraints
);
74
Assert.Empty(templatePart.
InlineConstraints
);
87
var constraint = Assert.Single(templatePart.
InlineConstraints
);
101
var constraint = Assert.Single(templatePart.
InlineConstraints
);
115
var constraint = Assert.Single(templatePart.
InlineConstraints
);
130
var constraint = Assert.Single(templatePart.
InlineConstraints
);
145
var constraint = Assert.Single(templatePart.
InlineConstraints
);
159
var constraint = Assert.Single(templatePart.
InlineConstraints
);
175
var constraint = Assert.Single(templatePart.
InlineConstraints
);
188
Assert.Collection(templatePart.
InlineConstraints
,
202
Assert.Collection(templatePart.
InlineConstraints
,
218
Assert.Collection(templatePart.
InlineConstraints
,
234
Assert.Collection(templatePart.
InlineConstraints
,
250
Assert.Collection(templatePart.
InlineConstraints
,
269
var constraint = Assert.Single(templatePart.
InlineConstraints
);
287
Assert.Collection(param1.
InlineConstraints
,
332
var constraint = Assert.Single(templatePart.
InlineConstraints
);
347
var constraint = Assert.Single(templatePart.
InlineConstraints
);
360
var constraint = Assert.Single(templatePart.
InlineConstraints
);
375
var constraint = Assert.Single(templatePart.
InlineConstraints
);
388
var constraint = Assert.Single(templatePart.
InlineConstraints
);
403
var constraint = Assert.Single(templatePart.
InlineConstraints
);
416
var constraint = Assert.Single(templatePart.
InlineConstraints
);
431
var constraint = Assert.Single(templatePart.
InlineConstraints
);
446
Assert.Collection(templatePart.
InlineConstraints
,
460
Assert.Collection(templatePart.
InlineConstraints
,
474
var constraint = Assert.Single(templatePart.
InlineConstraints
);
487
var constraint = Assert.Single(templatePart.
InlineConstraints
);
502
var constraint = Assert.Single(templatePart.
InlineConstraints
);
518
var constraint = Assert.Single(templatePart.
InlineConstraints
);
532
var constraint = Assert.Single(templatePart.
InlineConstraints
);
557
var constraint = Assert.Single(templatePart.
InlineConstraints
);
571
var constraint = Assert.Single(templatePart.
InlineConstraints
);
629
var constraint = Assert.Single(templatePart.
InlineConstraints
);
642
var constraint = Assert.Single(templatePart.
InlineConstraints
);
655
var constraint = Assert.Single(templatePart.
InlineConstraints
);
670
var constraint = Assert.Single(templatePart.
InlineConstraints
);
683
var constraint = Assert.Single(templatePart.
InlineConstraints
);
696
var constraint = Assert.Single(templatePart.
InlineConstraints
);
709
var constraint = Assert.Single(templatePart.
InlineConstraints
);
722
Assert.Collection(templatePart.
InlineConstraints
,
737
Assert.Collection(templatePart.
InlineConstraints
,
753
var constraint = Assert.Single(templatePart.
InlineConstraints
);
768
var constraint = Assert.Single(templatePart.
InlineConstraints
);
783
var constraint = Assert.Single(templatePart.
InlineConstraints
);
798
var constraint = Assert.Single(templatePart.
InlineConstraints
);
813
var constraint = Assert.Single(templatePart.
InlineConstraints
);
828
var constraint = Assert.Single(templatePart.
InlineConstraints
);
843
var constraint = Assert.Single(templatePart.
InlineConstraints
);
858
Assert.Collection(templatePart.
InlineConstraints
,
874
var constraint = Assert.Single(templatePart.
InlineConstraints
);
889
var constraint = Assert.Single(templatePart.
InlineConstraints
);
904
var constraint = Assert.Single(templatePart.
InlineConstraints
);
919
var constraint = Assert.Single(templatePart.
InlineConstraints
);
940
Assert.Empty(templatePart.
InlineConstraints
);
Template\TemplateParserTests.cs (10)
874
(x.
InlineConstraints
== null && y.
InlineConstraints
!= null) ||
875
(x.
InlineConstraints
!= null && y.
InlineConstraints
== null))
880
if (x.
InlineConstraints
== null && y.
InlineConstraints
== null)
885
if (x.
InlineConstraints
.Count() != y.
InlineConstraints
.Count())
890
foreach (var xconstraint in x.
InlineConstraints
)
892
if (!y.
InlineConstraints
.Any<InlineConstraint>(