Overview | Package | Class | Tree | Deprecated | Index | Help
| Spring Web Flow
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.springframework.webflow.execution
Class RequestContextHolder

    java.lang.Object
      org.springframework.webflow.execution.RequestContextHolder

    public class RequestContextHolder

extends java.lang.Object

Simple holder class that associates a `RequestContext` instance with the current thread. The RequestContext will not be inherited by any child threads spawned by the current thread.

Used as a central holder for the current RequestContext in Spring Web Flow, wherever necessary. Often used by integration artifacts needing access to the current flow execution.

Author:
  Jeremy Grelle
See Also:
  `RequestContext`

Method Summary
`static RequestContext` | `getRequestContext()` Return the RequestContext associated with the current thread, if any.
`static void` | `setRequestContext(RequestContext requestContext)` Associate the given RequestContext with the current thread.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Method Detail

### setRequestContext

    public static void setRequestContext(RequestContext requestContext)

  Associate the given RequestContext with the current thread.

  Parameters:
    `requestContext` - the current RequestContext, or `null` to reset the thread-bound context

### getRequestContext

    public static RequestContext getRequestContext()

  Return the RequestContext associated with the current thread, if any.

  Returns:
    the current RequestContext
  Throws:
    `java.lang.IllegalStateException` - if no RequestContext is bound to this thread

Overview | Package | Class | Tree | Deprecated | Index | Help
| Spring Web Flow
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD