3 instantiations of Created
Microsoft.AspNetCore.Http.Results (3)
TypedResults.cs (3)
888return new(default(string)); 898return new(uri); 920return new(uri);
38 references to Created
Microsoft.AspNetCore.Http.Results (10)
Created.cs (2)
19/// Initializes a new instance of the <see cref="Created"/> class with the values 29/// Initializes a new instance of the <see cref="Created"/> class with the values
CreatedOfT.cs (2)
20/// Initializes a new instance of the <see cref="Created"/> class with the values 33/// Initializes a new instance of the <see cref="Created"/> class with the values
TypedResults.cs (6)
885/// <returns>The created <see cref="HttpResults.Created"/> for the response.</returns> 886public static Created Created() 895/// <returns>The created <see cref="HttpResults.Created"/> for the response.</returns> 896public static Created Created(string? uri) 917/// <returns>The created <see cref="HttpResults.Created"/> for the response.</returns> 918public static Created Created(Uri? uri)
Microsoft.AspNetCore.Http.Results.Tests (28)
CreatedResultTests.cs (8)
24var result = new Created(location); 36var result = new Created(location); 53var result = new Created(location); 67Created MyApi() { throw new NotImplementedException(); } 72PopulateMetadata<Created>(((Delegate)MyApi).GetMethodInfo(), builder); 84var result = new Created("location"); 95Assert.Throws<ArgumentNullException>("method", () => PopulateMetadata<Created>(null, new RouteEndpointBuilder(requestDelegate: null, RoutePatternFactory.Parse("/"), order: 0))); 96Assert.Throws<ArgumentNullException>("builder", () => PopulateMetadata<Created>(((Delegate)PopulateMetadata_ThrowsArgumentNullException_WhenMethodOrBuilderAreNull).GetMethodInfo(), null));
ResultsTests.cs (14)
574var result = Results.Created() as Created; 619var result = Results.Created(uri, null) as Created; 665var result = Results.Created(uri, null) as Created; 676var result = Results.Created(default(string), null) as Created; 686var result = Results.Created(string.Empty, null) as Created; 696var result = Results.Created(default(Uri), null) as Created; 1744(() => Results.Created("/path", null), typeof(Created)), 1745(() => Results.Created(), typeof(Created)),
TypedResultsTests.cs (6)
570var result = TypedResults.Created(); 600var result = TypedResults.Created(uri); 630var result = TypedResults.Created(uri); 641var result = TypedResults.Created(default(string)); 650var result = TypedResults.Created(string.Empty); 658var result = TypedResults.Created(default(Uri));