Online Book Reader

Home Category

Programming Microsoft ASP.NET 4 - Dino Esposito [601]

By Root 5810 0
Forms and the MVC Pattern

The MVP Pattern

Generalities of the MVP Pattern

Role of the Model

Role of the View

Role of the Presenter

Web Forms and the MVP Pattern

The MVVM Pattern

Generalities of the MVVM Pattern

Web Forms and MVVM

Implementing Model View Presenter

Abstracting the View

From Use-Cases to the View

Implementing the Interface

Creating the Presenter

Getting a Presenter’s Instance

Using the Presenter

How Does the Presenter Retrieve Data?

Connecting the Presenter to the Service Layer

Presenter in Action

Sharing the Presenter with a Windows Application

Navigation

The Application Controller Pattern

Defining the Navigation Workflow

Navigating Within a Web Forms Site

Testability in Web Forms with MVP

Writing Testable Code

Aspects of Testable Code

Unit Testing

Test-Driven Development

Testing a Presenter Class

Creating a Unit Test

Testing Presenters in Isolation

Summary

IV. Infrastructure of the Application

16. The HTTP Request Context

Initialization of the Application

Properties of the HttpApplication Class

Application Modules

Methods of the HttpApplication Class

Events of the HttpApplication Class

The global.asax File

Compiling global.asax

Syntax of global.asax

Application Directives

Code Declaration Blocks

Server-Side Tags

Static Properties

The HttpContext Class

Properties of the HttpContext Class

Methods of the HttpContext Class

URL Rewriting

Loading Resources Programmatically

The Server Object

Properties of the HttpServerUtility Class

Methods of the HttpServerUtility Class

Embedding Another Page’s Results

Server-Side Redirection

The HttpResponse Object

Properties of the HttpResponse Class

Setting the Response Cache Policy

Setting an Output Filter

Methods of the HttpResponse Class

Output Caching Features

Large File Transmission

The HttpRequest Object

Properties of the HttpRequest Class

Information About the Request

Information from the Client

Information About the Connection

Methods of the HttpRequest Class

Saving the Request to Disk

Validating Client Input

Summary

17. ASP.NET State Management

The Application’s State

Properties of the HttpApplicationState Class

Methods of the HttpApplicationState Class

State Synchronization

Tradeoffs of Application State

The Session’s State

The Session-State HTTP Module

State Client Managers

Creating the HttpSessionState Object

Synchronizing Access to the Session State

Properties of the HttpSessionState Class

Methods of the HttpSessionState Class

Working with a Session’s State

Identifying a Session

Generating the Session ID

Session Cookies

Cookieless Sessions

Issues with Cookieless Sessions

Cookieless Sessions and Security

Cookieless Sessions and SEO

Configuring the Session State

Lifetime of a Session

The Session_Start Event

The Session_End Event

Why Does My Session State Sometimes Get Lost?

Persist Session Data to Remote Servers

State Serialization and Deserialization

Storing Session Data

Configuring the StateServer Provider

Persist Session Data to SQL Server

Performance and Robustness

Configuring Session State for SQL Server Support

Creating the SQL Server Data Store

Reverting to the Hosting Identity

Customizing Session State Management

Building a Custom Session State Provider

Defining the Session State Store

Locking and Expiration

Replacing the Session Data Dictionary

Registering a Custom Session State Provider

Generating a Custom Session ID

The Default Behavior

A Homemade Session ID Manager

The View State of a Page

The StateBag Class

View State Properties

View State Methods


®Online Book Reader