public JsonWithNamingPolicyResult(object data, JsonRequestBehavior_t jsonRequestBehavior , System.Text.Json.JsonNamingPolicy namingPolicy = null) { this.Data = data; this.JsonRequestBehavior = jsonRequestBehavior; this.NamingPolicy = namingPolicy; }
// This method gets called by the runtime. Use this method to add services to the container. public void ConfigureServices(IServiceCollection services) { services.AddControllers(); services.AddMvc().SetCompatibilityVersion(CompatibilityVersion.Version_3_0) .AddJsonOptions(options => { // ignore default camel-case formatting applied to JSON response System.Text.Json.JsonNamingPolicy resolver = options.JsonSerializerOptions.PropertyNamingPolicy = null; } ); services.AddDbContext <PaymentDetailContext>(options => options.UseSqlServer(Configuration.GetConnectionString("DevConnection"))); }
public JsonStringEnumConverter(System.Text.Json.JsonNamingPolicy namingPolicy = null, bool allowIntegerValues = true) { }