org.jboss.test.naming.interceptors
public class: ProxyFactoryInterceptor [javadoc |
source]
java.lang.Object
org.jboss.mx.interceptor.AbstractInterceptor
org.jboss.test.naming.interceptors.ProxyFactoryInterceptor
All Implemented Interfaces:
Interceptor
An interceptor that replaces any NamingContext values returned with the
proxy found under the JNDI binding given by the proxyName.
- author:
Scott.Stark - @jboss.org
- version:
$ - Revision: 1.1.2.1 $
| Method from org.jboss.test.naming.interceptors.ProxyFactoryInterceptor Summary: |
|---|
|
invoke, setProxyName |
| Methods from java.lang.Object: |
|---|
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Method from org.jboss.test.naming.interceptors.ProxyFactoryInterceptor Detail: |
public Object invoke(Invocation invocation) throws InvocationException {
String opName = invocation.getName();
log.info("invoke, opName="+opName);
Object value = getNext().invoke(invocation);
if( value instanceof NamingContext )
{
initNamingProxy();
NamingContext ctx = (NamingContext) value;
ctx.setNaming(proxy);
}
return value;
}
|
public void setProxyName(String proxyName) {
this.proxyName = proxyName;
}
|