Export (0) Print
Expand All

HttpSessionStateContainer Class

Contains session-state values as well as session-level settings for the current request.

Namespace:  System.Web.SessionState
Assembly:  System.Web (in System.Web.dll)

[AspNetHostingPermissionAttribute(SecurityAction.InheritanceDemand, Level = AspNetHostingPermissionLevel.Minimal)]
[AspNetHostingPermissionAttribute(SecurityAction.LinkDemand, Level = AspNetHostingPermissionLevel.Minimal)]
public class HttpSessionStateContainer : IHttpSessionState

ASP.NET provides session-state management to enable you to store information associated with a unique browser session across multiple requests. You can store a collection of values referenced by a key name or by numerical index. Access to session values and functionality is available using the HttpSessionState class, which is accessible through the Session property of the current HttpContext or the Session property of the Page. The HttpSessionState class accesses session-state values and session-level settings by referencing a session-state container, which is an implementation of the IHttpSessionState interface that has been populated with session-state data and added to the HttpContext of the current request by the session-state module for the HttpApplication.

The HttpSessionState class calls the HttpSessionStateContainer class, which manages session settings and values in memory.

The HttpSessionStateContainer class is the ASP.NET implementation of the IHttpSessionState interface. The HttpSessionStateContainer class is not intended to be called from application code. If you replace the SessionStateModule with a custom session-state module, you can use the HttpSessionStateContainer class, or supply your own implementation of the IHttpSessionState interface.

For an example of a custom session-state module that uses the HttpSessionStateContainer class as the session-state container for the current request, see the SessionStateUtility class overview.

System.Object
  System.Web.SessionState.HttpSessionStateContainer

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Windows 7, Windows Vista, Windows XP SP2, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP Starter Edition, Windows Server 2008 R2, Windows Server 2008, Windows Server 2003, Windows Server 2000 SP4, Windows Millennium Edition, Windows 98

The .NET Framework and .NET Compact Framework do not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

.NET Framework

Supported in: 3.5, 3.0, 2.0

Community Additions

ADD
Show:
© 2014 Microsoft