23 instantiations of RouteTemplate
Microsoft.AspNetCore.Routing (2)
RouteValuesAddressScheme.cs (1)
157
RouteTemplate = new
RouteTemplate
(endpoint.RoutePattern),
Template\TemplateParser.cs (1)
25
return new
RouteTemplate
(inner);
Microsoft.AspNetCore.Routing.Microbenchmarks (2)
EndpointRoutingBenchmarkBase.cs (1)
139
new
RouteTemplate
(RoutePatternFactory.Parse(
src\Http\Routing\test\UnitTests\Matching\TreeRouterMatcherBuilder.cs (1)
68
new
RouteTemplate
(endpoint.RoutePattern),
Microsoft.AspNetCore.Routing.Tests (19)
Matching\TreeRouterMatcherBuilder.cs (1)
68
new
RouteTemplate
(endpoint.RoutePattern),
Template\TemplateParserTests.cs (17)
16
var expected = new
RouteTemplate
(template, new List<TemplateSegment>());
33
var expected = new
RouteTemplate
(template, new List<TemplateSegment>());
52
var expected = new
RouteTemplate
(template, new List<TemplateSegment>());
71
var expected = new
RouteTemplate
(template, new List<TemplateSegment>());
92
var expected = new
RouteTemplate
(template, new List<TemplateSegment>());
131
var expected = new
RouteTemplate
(template, new List<TemplateSegment>());
154
var expected = new
RouteTemplate
(template, new List<TemplateSegment>());
177
var expected = new
RouteTemplate
(template, new List<TemplateSegment>());
206
var expected = new
RouteTemplate
(template, new List<TemplateSegment>());
230
var expected = new
RouteTemplate
(template, new List<TemplateSegment>());
260
var expected = new
RouteTemplate
(template, new List<TemplateSegment>());
290
var expected = new
RouteTemplate
(template, new List<TemplateSegment>());
328
var expected = new
RouteTemplate
(template, new List<TemplateSegment>());
366
var expected = new
RouteTemplate
(template, new List<TemplateSegment>());
403
var expected = new
RouteTemplate
(template, new List<TemplateSegment>());
440
var expected = new
RouteTemplate
(template, new List<TemplateSegment>());
474
var expected = new
RouteTemplate
(template, new List<TemplateSegment>());
Tree\LinkGenerationDecisionTreeTest.cs (1)
749
match.Entry.RouteTemplate = new
RouteTemplate
(RoutePatternFactory.Parse(routeTemplate));
102 references to RouteTemplate
Microsoft.AspNetCore.Mvc.ApiExplorer (3)
DefaultApiDescriptionProvider.cs (3)
99
var
parsedTemplate = ParseTemplate(action);
375
private static
RouteTemplate
? ParseTemplate(ControllerActionDescriptor action)
385
private string? GetRelativePath(
RouteTemplate
? parsedTemplate)
Microsoft.AspNetCore.Mvc.Core (5)
ApplicationModels\InferParameterBindingInfoConvention.cs (1)
162
var
parsedTemplate = TemplateParser.Parse(selector.AttributeRouteModel.Template!);
Routing\AttributeRoute.cs (4)
145
var templateCache = new Dictionary<string,
RouteTemplate
>(StringComparer.OrdinalIgnoreCase);
179
Dictionary<string,
RouteTemplate
> templateCache,
190
if (!templateCache.TryGetValue(template, out
var
parsedTemplate))
239
public
RouteTemplate
? RouteTemplate { get; set; }
Microsoft.AspNetCore.Routing (31)
RouteBase.cs (7)
88
/// Gets the <see cref="
RouteTemplate
"/> associated with the route.
90
public virtual
RouteTemplate
ParsedTemplate { get; protected set; }
199
/// Extracts constatins from a given <see cref="
RouteTemplate
"/>.
202
/// <param name="parsedTemplate">A <see cref="
RouteTemplate
"/> instance.</param>
206
RouteTemplate
parsedTemplate,
238
/// <param name="parsedTemplate">A <see cref="
RouteTemplate
"/> instance.</param>
241
RouteTemplate
parsedTemplate,
Template\DefaultTemplateBinderFactory.cs (1)
26
public override TemplateBinder Create(
RouteTemplate
template, RouteValueDictionary defaults)
Template\RoutePrecedence.cs (4)
33
/// <param name="template">The <see cref="
RouteTemplate
"/> to compute precedence for.</param>
35
public static decimal ComputeInbound(
RouteTemplate
template)
87
/// <param name="template">The <see cref="
RouteTemplate
"/> to compute precedence for.</param>
89
public static decimal ComputeOutbound(
RouteTemplate
template)
Template\RouteTemplate.cs (3)
21
/// Constructs a new <see cref="
RouteTemplate
"/> instance given <paramref name="other"/>.
54
/// Constructs a a new <see cref="
RouteTemplate
" /> instance given the <paramref name="template"/> string
133
/// Converts the <see cref="
RouteTemplate
"/> to the equivalent
Template\TemplateBinder.cs (2)
41
/// <param name="template">The <see cref="
RouteTemplate
"/> to bind values to.</param>
46
RouteTemplate
template,
Template\TemplateBinderFactory.cs (1)
20
public abstract TemplateBinder Create(
RouteTemplate
template, RouteValueDictionary defaults);
Template\TemplateMatcher.cs (4)
24
/// <param name="template">The <see cref="
RouteTemplate
"/> to compare against.</param>
27
RouteTemplate
template,
70
/// Gets the <see cref="
RouteTemplate
"/> to match against.
72
public
RouteTemplate
Template { get; }
Template\TemplateParser.cs (3)
14
/// Creates a <see cref="
RouteTemplate
"/> for a given <paramref name="routeTemplate"/> string.
17
/// <returns>A <see cref="
RouteTemplate
"/> instance.</returns>
18
public static
RouteTemplate
Parse(string routeTemplate)
Tree\InboundRouteEntry.cs (1)
72
public
RouteTemplate
RouteTemplate { get; set; }
Tree\OutboundRouteEntry.cs (1)
61
public
RouteTemplate
RouteTemplate { get; set; }
Tree\TreeRouteBuilder.cs (4)
74
/// <param name="routeTemplate">The <see cref="
RouteTemplate
"/> of the route.</param>
82
RouteTemplate
routeTemplate,
174
/// <param name="routeTemplate">The <see cref="
RouteTemplate
"/> of the route.</param>
181
RouteTemplate
routeTemplate,
Microsoft.AspNetCore.Routing.Tests (60)
InlineRouteParameterParserTests.cs (2)
277
var
template = ParseRouteTemplate(@"some/url-{p1:int:test(3)=hello}/{p2=abc}/{p3?}");
951
private static
RouteTemplate
ParseRouteTemplate(string template)
Template\RouteTemplatePrecedenceTests.cs (2)
18
private static decimal ComputeRouteTemplate(string template, Func<
RouteTemplate
, decimal> func)
20
var
parsed = TemplateParser.Parse(template);
Template\TemplateParserTests.cs (56)
16
var
expected = new RouteTemplate(template, new List<TemplateSegment>());
21
var
actual = TemplateParser.Parse(template);
24
Assert.Equal<
RouteTemplate
>(expected, actual, new TemplateEqualityComparer());
33
var
expected = new RouteTemplate(template, new List<TemplateSegment>());
40
var
actual = TemplateParser.Parse(template);
43
Assert.Equal<
RouteTemplate
>(expected, actual, new TemplateEqualityComparer());
52
var
expected = new RouteTemplate(template, new List<TemplateSegment>());
59
var
actual = TemplateParser.Parse(template);
62
Assert.Equal<
RouteTemplate
>(expected, actual, new TemplateEqualityComparer());
71
var
expected = new RouteTemplate(template, new List<TemplateSegment>());
80
var
actual = TemplateParser.Parse(template);
83
Assert.Equal<
RouteTemplate
>(expected, actual, new TemplateEqualityComparer());
92
var
expected = new RouteTemplate(template, new List<TemplateSegment>());
119
var
actual = TemplateParser.Parse(template);
122
Assert.Equal<
RouteTemplate
>(expected, actual, new TemplateEqualityComparer());
131
var
expected = new RouteTemplate(template, new List<TemplateSegment>());
142
var
actual = TemplateParser.Parse(template);
145
Assert.Equal<
RouteTemplate
>(expected, actual, new TemplateEqualityComparer());
154
var
expected = new RouteTemplate(template, new List<TemplateSegment>());
165
var
actual = TemplateParser.Parse(template);
168
Assert.Equal<
RouteTemplate
>(expected, actual, new TemplateEqualityComparer());
177
var
expected = new RouteTemplate(template, new List<TemplateSegment>());
194
var
actual = TemplateParser.Parse(template);
197
Assert.Equal<
RouteTemplate
>(expected, actual, new TemplateEqualityComparer());
206
var
expected = new RouteTemplate(template, new List<TemplateSegment>());
218
var
actual = TemplateParser.Parse(template);
221
Assert.Equal<
RouteTemplate
>(expected, actual, new TemplateEqualityComparer());
230
var
expected = new RouteTemplate(template, new List<TemplateSegment>());
248
var
actual = TemplateParser.Parse(template);
251
Assert.Equal<
RouteTemplate
>(expected, actual, new TemplateEqualityComparer());
260
var
expected = new RouteTemplate(template, new List<TemplateSegment>());
278
var
actual = TemplateParser.Parse(template);
281
Assert.Equal<
RouteTemplate
>(expected, actual, new TemplateEqualityComparer());
290
var
expected = new RouteTemplate(template, new List<TemplateSegment>());
316
var
actual = TemplateParser.Parse(template);
319
Assert.Equal<
RouteTemplate
>(expected, actual, new TemplateEqualityComparer());
328
var
expected = new RouteTemplate(template, new List<TemplateSegment>());
354
var
actual = TemplateParser.Parse(template);
357
Assert.Equal<
RouteTemplate
>(expected, actual, new TemplateEqualityComparer());
366
var
expected = new RouteTemplate(template, new List<TemplateSegment>());
391
var
actual = TemplateParser.Parse(template);
394
Assert.Equal<
RouteTemplate
>(expected, actual, new TemplateEqualityComparer());
403
var
expected = new RouteTemplate(template, new List<TemplateSegment>());
428
var
actual = TemplateParser.Parse(template);
431
Assert.Equal<
RouteTemplate
>(expected, actual, new TemplateEqualityComparer());
440
var
expected = new RouteTemplate(template, new List<TemplateSegment>());
459
var
actual = TemplateParser.Parse(template);
462
Assert.Equal<
RouteTemplate
>(expected, actual, new TemplateEqualityComparer());
474
var
expected = new RouteTemplate(template, new List<TemplateSegment>());
486
var
actual = TemplateParser.Parse(template);
489
Assert.Equal<
RouteTemplate
>(expected, actual, new TemplateEqualityComparer());
764
var
pattern = TemplateParser.Parse(routeTemplate);
809
private class TemplateEqualityComparer : IEqualityComparer<
RouteTemplate
>
811
public bool Equals(
RouteTemplate
x,
RouteTemplate
y)
902
public int GetHashCode(
RouteTemplate
obj)
Swaggatherer (3)
RouteEntry.cs (1)
10
public
RouteTemplate
Template { get; set; }
SwaggathererApplication.cs (2)
157
var
parsed = TemplateParser.Parse(template);
234
private static string GenerateRequestUrl(
RouteTemplate
template)