<PackageReference Include="System.Text.Json" Version="10.0.0-rc.1.25451.107" />

AppContextSwitchHelper

static class AppContextSwitchHelper
namespace System.Text.Json { internal static class AppContextSwitchHelper { public static bool IsSourceGenReflectionFallbackEnabled { get; } = AppContext.TryGetSwitch("System.Text.Json.Serialization.EnableSourceGenReflectionFallback", out bool isEnabled) && isEnabled; public static bool RespectNullableAnnotationsDefault { get; } = AppContext.TryGetSwitch("System.Text.Json.Serialization.RespectNullableAnnotationsDefault", out bool isEnabled2) && isEnabled2; public static bool RespectRequiredConstructorParametersDefault { get; } = AppContext.TryGetSwitch("System.Text.Json.Serialization.RespectRequiredConstructorParametersDefault", out bool isEnabled3) && isEnabled3; } }