public AutoWrapperMembers(AutoWrapperOptions options, ILogger <AutoWrapperMiddleware> logger, JsonSerializerSettings jsonSettings, Dictionary <string, string> propertyMappings = null, bool hasSchemaForMappping = false) { _options = options; _logger = logger; _jsonSettings = jsonSettings; _propertyMappings = propertyMappings; _hasSchemaForMappping = hasSchemaForMappping; }
public AutoWrapperMembers(AutoWrapperOptions options, ILogger <AutoWrapperMiddleware> logger, JsonSerializerSettings jsonSettings, Dictionary <string, string> propertyMappings = null, bool isCustomObjectUsed = false) { _options = options; _logger = logger; _jsonSettings = jsonSettings; _propertyMappings = propertyMappings; _isCustomObjectUsed = isCustomObjectUsed; }
public AutoWrapperMiddleware(RequestDelegate next, AutoWrapperOptions options, ILogger <AutoWrapperMiddleware> logger, IActionResultExecutor <ObjectResult> executor) : base(next, options, logger, executor) { var jsonSettings = Helpers.JSONHelper.GetJSONSettings(options.IgnoreNullValue, options.ReferenceLoopHandling, options.UseCamelCaseNamingStrategy); _awm = new AutoWrapperMembers(options, logger, jsonSettings); }
public static IApplicationBuilder UseApiResponseAndExceptionWrapper(this IApplicationBuilder builder, AutoWrapperOptions options = default) { options = options ?? new AutoWrapperOptions(); return(builder.UseMiddleware <AutoWrapperMiddleware>(options)); }
public AutoWrapperMiddleware(RequestDelegate next, AutoWrapperOptions options, ILogger <AutoWrapperMiddleware> logger) : base(next, options, logger) { var jsonSettings = Helpers.JSONHelper.GetJSONSettings(options.IgnoreNullValue, options.UseCamelCaseNamingStrategy); _awm = new AutoWrapperMembers(options, logger, jsonSettings); }