1 22 package org.jboss.ejb3; 23 24 import org.jboss.aop.advice.Interceptor; 25 import org.jboss.aop.joinpoint.Invocation; 26 27 33 public class ENCPropagationInterceptor implements Interceptor 34 { 35 public String getName() 36 { 37 return this.getClass().getName(); 38 } 39 40 public Object invoke(Invocation invocation) throws Throwable  41 { 42 try 43 { 44 Container container = (Container) invocation.getAdvisor(); 45 ThreadLocalENCFactory.push(container.getEnc()); 46 47 return invocation.invokeNext(); 48 } 49 finally 50 { 51 ThreadLocalENCFactory.pop(); 52 } 53 } 54 } 55 | Popular Tags |