|
2 | 2 | // The .NET Foundation licenses this file to you under the MIT license.
|
3 | 3 |
|
4 | 4 | using System.ComponentModel;
|
| 5 | +using System.Diagnostics.CodeAnalysis; |
5 | 6 | using System.Reflection;
|
6 | 7 | using Microsoft.AspNetCore.Builder;
|
7 | 8 | using Microsoft.AspNetCore.Http;
|
@@ -32,7 +33,7 @@ public static class RouteHandlerServices
|
32 | 33 | /// <returns>The <see cref="RouteHandlerBuilder"/>>.</returns>
|
33 | 34 | public static RouteHandlerBuilder Map(
|
34 | 35 | IEndpointRouteBuilder endpoints,
|
35 |
| - string pattern, |
| 36 | + [StringSyntax("Route")] string pattern, |
36 | 37 | Delegate handler,
|
37 | 38 | IEnumerable<string>? httpMethods,
|
38 | 39 | Func<MethodInfo, RequestDelegateFactoryOptions?, RequestDelegateMetadataResult> populateMetadata,
|
@@ -62,7 +63,7 @@ public static RouteHandlerBuilder Map(
|
62 | 63 | /// <returns>The <see cref="RouteHandlerBuilder"/>>.</returns>
|
63 | 64 | public static RouteHandlerBuilder Map(
|
64 | 65 | IEndpointRouteBuilder endpoints,
|
65 |
| - string pattern, |
| 66 | + [StringSyntax("Route")] string pattern, |
66 | 67 | Delegate handler,
|
67 | 68 | IEnumerable<string>? httpMethods,
|
68 | 69 | Func<MethodInfo, RequestDelegateFactoryOptions?, RequestDelegateMetadataResult> populateMetadata,
|
|
0 commit comments