Declaration
public static HttpResponse EnableAutomatic<TSession>(
this TSession session,
HttpRequest req,
Func<TSession, HttpResponse> handler
)
Summary
Enables the use of sessions in an HTTP request handler. Use this if your session class implements
ISessionEquatable<TSession>.
Generic type parameters
TSession |
The type of session to be used. |
Parameters
this TSession | session |
An already-constructed empty session object. The session object will have Session.NewSession() or
Session.ReadSession() called on it to populate it. |
HttpRequest | req |
The HTTP request for which to enable session support. |
Func<TSession, HttpResponse> | handler |
HTTP request handler code that can make free use of a session variable. |
Remarks
See the remarks section in the
Session documentation for usage guidelines.
See also