System.Web.SessionState.SessionStateActions Enumeration

Identifies whether a session item from a data store is for a session that requires initialization.

Syntax

public enum SessionStateActions

Remarks

The System.Web.SessionState.SessionStateActions enumeration is used by the SessionStateStoreProviderBase.GetItem(System.Web.HttpContext, string, Boolean@, TimeSpan@, Object@, SessionStateActions@) and SessionStateStoreProviderBase.GetItemExclusive(System.Web.HttpContext, string, Boolean@, TimeSpan@, Object@, SessionStateActions@) methods of a System.Web.SessionState.SessionStateStoreProviderBase implementation. When a session item is retrieved from the data store, the enumeration value indicates whether the session requires initialization or not based on a value stored with the data. The SessionStateStoreProviderBase.GetItem(System.Web.HttpContext, string, Boolean@, TimeSpan@, Object@, SessionStateActions@) and SessionStateStoreProviderBase.GetItemExclusive(System.Web.HttpContext, string, Boolean@, TimeSpan@, Object@, SessionStateActions@) methods set an actions parameter to a System.Web.SessionState.SessionStateActions enumeration value based on this value retrieved with the session item. If the value of the actions parameter is set to SessionStateActions.InitializeItem, the System.Web.SessionState.SessionStateModule initializes the session and executes the Session_OnStart event defined in the Global.asax file for the ASP.NET application. If the value of the actions parameter is SessionStateActions.None, no additional steps are taken for the current session.

A session item created by the SessionStateStoreProviderBase.CreateUninitializedItem(System.Web.HttpContext, string, int) method is created with a value indicating that the item requires initialization and that the SessionStateStoreProviderBase.GetItem(System.Web.HttpContext, string, Boolean@, TimeSpan@, Object@, SessionStateActions@) and SessionStateStoreProviderBase.GetItemExclusive(System.Web.HttpContext, string, Boolean@, TimeSpan@, Object@, SessionStateActions@) methods should set the actions parameter to SessionStateActions.InitializeItem.

Members

Member NameDescription
InitializeItem

The session item from the data store is for a session that requires initialization.

None

No initialization actions need to be performed by the calling code.

Requirements

Namespace: System.Web.SessionState
Assembly: System.Web (in System.Web.dll)
Assembly Versions: 2.0.0.0
Since: .NET 2.0