org.apache.axis2.util
Class ThreadContextMigratorUtil

java.lang.Object
  extended by org.apache.axis2.util.ThreadContextMigratorUtil

public class ThreadContextMigratorUtil
extends java.lang.Object

This is a utility class to make it easier/cleaner for user programming model-level implementations (e.g. the Axis2 JAX-WS code) to invoke the ThreadContextMigrators.


Constructor Summary
ThreadContextMigratorUtil()
           
 
Method Summary
static void addThreadContextMigrator(AxisConfiguration axisConfiguration, java.lang.String threadContextMigratorListID, ThreadContextMigrator migrator)
          Register a new ThreadContextMigrator.
static void addThreadContextMigrator(ConfigurationContext configurationContext, java.lang.String threadContextMigratorListID, ThreadContextMigrator migrator)
          Register a new ThreadContextMigrator.
static void performContextCleanup(java.lang.String threadContextMigratorListID, MessageContext msgContext)
          Activate any registered ThreadContextMigrators to remove information from the context if necessary.
static void performMigrationToContext(java.lang.String threadContextMigratorListID, MessageContext msgContext)
          Activate any registered ThreadContextMigrators to move info from the thread of execution into the context.
static void performMigrationToThread(java.lang.String threadContextMigratorListID, MessageContext msgContext)
          Activate any registered ThreadContextMigrators to move context info to the thread of execution.
static void performThreadCleanup(java.lang.String threadContextMigratorListID, MessageContext msgContext)
          Activate any registered ThreadContextMigrators to remove information from the thread of execution if necessary.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ThreadContextMigratorUtil

public ThreadContextMigratorUtil()
Method Detail

addThreadContextMigrator

public static void addThreadContextMigrator(ConfigurationContext configurationContext,
                                            java.lang.String threadContextMigratorListID,
                                            ThreadContextMigrator migrator)
                                     throws AxisFault
Register a new ThreadContextMigrator.

Parameters:
configurationContext -
threadContextMigratorListID - The name of the parameter in the AxisConfiguration that contains the list of migrators.
migrator -
Throws:
AxisFault

addThreadContextMigrator

public static void addThreadContextMigrator(AxisConfiguration axisConfiguration,
                                            java.lang.String threadContextMigratorListID,
                                            ThreadContextMigrator migrator)
                                     throws AxisFault
Register a new ThreadContextMigrator.

Parameters:
axisConfiguration -
threadContextMigratorListID - The name of the parameter in the AxisConfiguration that contains the list of migrators.
migrator -
Throws:
AxisFault

performMigrationToThread

public static void performMigrationToThread(java.lang.String threadContextMigratorListID,
                                            MessageContext msgContext)
                                     throws AxisFault
Activate any registered ThreadContextMigrators to move context info to the thread of execution.

Parameters:
threadContextMigratorListID - The name of the parameter in the AxisConfiguration that contains the list of migrators.
msgContext -
Throws:
AxisFault

performThreadCleanup

public static void performThreadCleanup(java.lang.String threadContextMigratorListID,
                                        MessageContext msgContext)
Activate any registered ThreadContextMigrators to remove information from the thread of execution if necessary.

Parameters:
threadContextMigratorListID - The name of the parameter in the AxisConfiguration that contains the list of migrators.
msgContext -

performMigrationToContext

public static void performMigrationToContext(java.lang.String threadContextMigratorListID,
                                             MessageContext msgContext)
                                      throws AxisFault
Activate any registered ThreadContextMigrators to move info from the thread of execution into the context.

Parameters:
threadContextMigratorListID - The name of the parameter in the AxisConfiguration that contains the list of migrators.
msgContext -
Throws:
AxisFault

performContextCleanup

public static void performContextCleanup(java.lang.String threadContextMigratorListID,
                                         MessageContext msgContext)
Activate any registered ThreadContextMigrators to remove information from the context if necessary.

Parameters:
threadContextMigratorListID - The name of the parameter in the AxisConfiguration that contains the list of migrators.
msgContext -


Copyright © 2007 Apache Web Services Project. All Rights Reserved.