Skip to content

Instantly share code, notes, and snippets.

@justinyoo
Created November 24, 2016 01:09
Show Gist options
  • Save justinyoo/3933357763c8e19b755e4bac17650a5f to your computer and use it in GitHub Desktop.
Save justinyoo/3933357763c8e19b755e4bac17650a5f to your computer and use it in GitHub Desktop.
Implementing HTTP Request Handler on ASP.NET Core Applications
public class HttpRequestHeaderHandlerMiddleware
{
private readonly RequestDelegate _next;
private readonly HttpRequestHeaderHandlerMiddlewareOptions _options;
public HttpRequestHeaderHandlerMiddleware(RequestDelegate next, IOptions<HttpRequestHeaderHandlerMiddlewareOptions> options)
{
this._next = next;
this._options = options.Value;
}
...
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment