flex.messaging
Class FlexContext

java.lang.Object
  extended by flex.messaging.FlexContext

public class FlexContext
extends Object

The FlexContext class is a utility class that holds the FlexSession, HttpServletRequest, HttpServletResponse and ServletConfig for the current thread (request).


Method Summary
static FlexClient getFlexClient()
          The FlexClient for the current request.
static FlexSession getFlexSession()
          The FlexSession for the current request.
static javax.servlet.http.HttpServletRequest getHttpRequest()
          The HttpServletResponse for the current request if the request is via HTTP.
static javax.servlet.http.HttpServletResponse getHttpResponse()
          The HttpServletResponse for the current request if the request is via HTTP.
static javax.servlet.ServletConfig getServletConfig()
          The ServletConfig for the current request, uses the last known ServletConfig when the request is not via HTTP.
static javax.servlet.ServletContext getServletContext()
          The ServletContext for the current web application.
static javax.servlet.http.HttpServletRequest getTunnelHttpRequest()
          The HttpServletRequest for the current request if it is transporting a tunneled protocol.
static Principal getUserPrincipal()
          Returns the principal associated with the session or client depending on whether perClientauthentication is being used.
static boolean isMessageFromPeer()
          Indicates whether the current message being processed came from a server peer in a cluster.
static void setUserPrincipal(Principal userPrincipal)
           
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getHttpRequest

public static javax.servlet.http.HttpServletRequest getHttpRequest()
The HttpRequest for the current request if the request is via HTTP. Returns null if the client is using a non-HTTP channel. Available for users.


getHttpResponse

public static javax.servlet.http.HttpServletResponse getHttpResponse()
The HttpServletResponse for the current request if the request is via HTTP. Returns null if the using an non-HTTP channel. Available for users.


getTunnelHttpRequest

public static javax.servlet.http.HttpServletRequest getTunnelHttpRequest()
The HttpServletRequest for the current request if it is transporting a tunneled protocol. Returns null if the current request protocol it not tunneled. Available for users.


getServletConfig

public static javax.servlet.ServletConfig getServletConfig()
The ServletConfig for the current request, uses the last known ServletConfig when the request is not via HTTP. Available for users.


getServletContext

public static javax.servlet.ServletContext getServletContext()
The ServletContext for the current web application.


getFlexClient

public static FlexClient getFlexClient()
The FlexClient for the current request. Available for users.


getFlexSession

public static FlexSession getFlexSession()
The FlexSession for the current request. Available for users.


isMessageFromPeer

public static boolean isMessageFromPeer()
Indicates whether the current message being processed came from a server peer in a cluster.


getUserPrincipal

public static Principal getUserPrincipal()
Returns the principal associated with the session or client depending on whether perClientauthentication is being used. If the client has not authenticated the principal will be null.

Returns:
The principal associated with the session.

setUserPrincipal

public static void setUserPrincipal(Principal userPrincipal)
Parameters:
userPrincipal - The principal to associate with the session or client depending on whether perClientauthentication is being used.


Copyright © 2007 Adobe Systems Inc. All Rights Reserved.

 

Send me an e-mail when comments are added to this page | Comment Report

Current page: http://livedocs.adobe.com/livecycle/es/sdkHelp/programmer/lcdsjavadoc/flex/messaging/FlexContext.html