DataCacheSessionStoreProvider.GetItemExclusive Method (HttpContext, String, Boolean, TimeSpan, Object, SessionStateActions)

 

Returns and locks the read-only session-state data from the cache.

Namespace:   Microsoft.ApplicationServer.Caching
Assembly:  Microsoft.ApplicationServer.Caching.Client (in Microsoft.ApplicationServer.Caching.Client.dll)

Syntax

public override SessionStateStoreData GetItemExclusive(
    HttpContext context,
    string id,
    out bool locked,
    out TimeSpan lockAge,
    out object lockId,
    out SessionStateActions actions
)
public:
virtual SessionStateStoreData^ GetItemExclusive(
    HttpContext^ context,
    String^ id,
    [OutAttribute] bool% locked,
    [OutAttribute] TimeSpan% lockAge,
    [OutAttribute] Object^% lockId,
    [OutAttribute] SessionStateActions% actions
) override
override GetItemExclusive : 
        context:HttpContext *
        id:string *
        locked:bool byref *
        lockAge:TimeSpan byref *
        lockId:Object byref *
        actions:SessionStateActions byref -> SessionStateStoreData
Public Overrides Function GetItemExclusive (
    context As HttpContext,
    id As String,
    <OutAttribute> ByRef locked As Boolean,
    <OutAttribute> ByRef lockAge As TimeSpan,
    <OutAttribute> ByRef lockId As Object,
    <OutAttribute> ByRef actions As SessionStateActions
) As SessionStateStoreData

Parameters

  • id
    Type: System.String

    The session identifier for the current request.

  • locked
    Type: System.Boolean

    When this method returns, contains a Boolean value that is set to true if a lock in the cache is successfully obtained; otherwise, false.

  • lockAge
    Type: System.TimeSpan

    When this method returns, contains a TimeSpan object that is set to the period of time that an item in the cache has been locked.

  • lockId
    Type: System.Object

    When this method returns, contains an object that is set to the lock identifier for the current request.

  • actions
    Type: System.Web.SessionState.SessionStateActions

    When this method returns, contains one of the SessionStateActions values. This indicates whether the current session is an uninitialized, cookieless session.

Return Value

Type: System.Web.SessionState.SessionStateStoreData

A SessionStateStoreData object populated with session values and information from the cache.

Remarks

For more information, see the documentation for the base class SessionStateStoreProviderBase.

See Also

DataCacheSessionStoreProvider Class
Microsoft.ApplicationServer.Caching Namespace

Return to top