Move the type to its own file
This commit is contained in:
parent
d71fc7df9e
commit
d50cc3ed4c
|
|
@ -0,0 +1,11 @@
|
||||||
|
using AS1024.NetworkQuality.Server;
|
||||||
|
using System.Text.Json.Serialization;
|
||||||
|
|
||||||
|
[JsonSerializable(typeof(ConfigResponse))]
|
||||||
|
[JsonSerializable(typeof(Microsoft.AspNetCore.Mvc.ProblemDetails))]
|
||||||
|
[JsonSourceGenerationOptions(GenerationMode = JsonSourceGenerationMode.Default,
|
||||||
|
PropertyNamingPolicy = JsonKnownNamingPolicy.SnakeCaseLower)]
|
||||||
|
internal partial class AppJsonSerializerContext : JsonSerializerContext
|
||||||
|
{
|
||||||
|
|
||||||
|
}
|
||||||
|
|
@ -1,6 +1,5 @@
|
||||||
using AS1024.NetworkQuality.Server;
|
using AS1024.NetworkQuality.Server;
|
||||||
using System.Text.Json;
|
using System.Text.Json;
|
||||||
using System.Text.Json.Serialization;
|
|
||||||
const string schemeNetQuality = "https";
|
const string schemeNetQuality = "https";
|
||||||
var builder = WebApplication.CreateSlimBuilder(args);
|
var builder = WebApplication.CreateSlimBuilder(args);
|
||||||
|
|
||||||
|
|
@ -101,13 +100,4 @@ app.MapPost("/api/v1/upload", (HttpRequest request, ILogger<Program> logger) =>
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
app.Run();
|
app.Run();
|
||||||
|
|
||||||
[JsonSerializable(typeof(ConfigResponse))]
|
|
||||||
[JsonSerializable(typeof(Microsoft.AspNetCore.Mvc.ProblemDetails))]
|
|
||||||
[JsonSourceGenerationOptions(GenerationMode = JsonSourceGenerationMode.Default,
|
|
||||||
PropertyNamingPolicy = JsonKnownNamingPolicy.SnakeCaseLower)]
|
|
||||||
internal partial class AppJsonSerializerContext : JsonSerializerContext
|
|
||||||
{
|
|
||||||
|
|
||||||
}
|
|
||||||
Loading…
Reference in New Issue