org.jasig.portal.portlet.dao.jpa
Class ThreadContextClassLoaderAspect

java.lang.Object
  extended by org.jasig.portal.portlet.dao.jpa.ThreadContextClassLoaderAspect
All Implemented Interfaces:
Ordered

public class ThreadContextClassLoaderAspect
extends Object
implements Ordered

Switches context class loader for Thread.currentThread() to the class loader of this class and switches it back after the method completes

Version:
$Revision$
Author:
Eric Dalquist

Field Summary
 
Fields inherited from interface org.springframework.core.Ordered
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE
 
Constructor Summary
ThreadContextClassLoaderAspect()
           
 
Method Summary
 Object doThreadContextClassLoaderUpdate(org.aspectj.lang.ProceedingJoinPoint pjp)
          Wraps the targeted execution, switching the current thread's context class loader to this classes class loader.
 int getOrder()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ThreadContextClassLoaderAspect

public ThreadContextClassLoaderAspect()
Method Detail

getOrder

public int getOrder()
Specified by:
getOrder in interface Ordered

doThreadContextClassLoaderUpdate

public Object doThreadContextClassLoaderUpdate(org.aspectj.lang.ProceedingJoinPoint pjp)
                                        throws Throwable
Wraps the targeted execution, switching the current thread's context class loader to this classes class loader.

Throws:
Throwable


Copyright © 2010 Jasig. All Rights Reserved.