In this article you will learn about ASP.NET Core Middleware in a nutshell.
Obviously, first it will hit ConfigureServices to check if any component has been requested, later on it will go to the pipeline section and execute the same in linear ordering.
NoteOrdering of Midlleware is very important. We will explore this in the coming section.
After above execution, it simply produced Hello World text in browser.Now, if you look closely at this Run method, it accepts RequestDelegate as a parameter whose signature accepts one parameter as a HTTP Context and return type is Task as shown below.Now, what this middleware component is doing is it's handling all the requests made to the app and sending back the response. Run method adds as a RequestDelegate which is terminal to the request pipeline. This means any middleware comes after this; it won’t be reached. At the moment, we don’t have much in the middleware section. Let’s go ahead and add one. Below is the structure for that.
Let’s start with Map. Map has two parameters. Below is the concrete structure for the same.
Pro WPF: Windows Presentation Foundation in .NET 3.0