O'Reilly logo

Pro ASP.NET MVC 5 Platform by Adam Freeman

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

CHAPTER 5

image

Handlers

Handlers are responsible for generating the response content for an HTTP request. In this chapter, I explain how handlers generate content, demonstrate how to create custom handlers, and show you how modules can provide services to handlers. Table 5-1 summarizes this chapter.

Table 5-1. Chapter Summary

Problem

Solution

Listing

Create a handler.

Implement the IHttpHandler interface.

13

Register a handler using a URL route.

Create an implementation of the IRouteHandler interface that returns the handler from its GetHttpHandler method and use it as an argument to the RouteCollection.Add method.

4

Register a handler using ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required