com.googlecode.mycontainer.kernel.reflect.proxy
Class ProxyEngine<T>

java.lang.Object
  extended by com.googlecode.mycontainer.kernel.reflect.proxy.ProxyEngine<T>
All Implemented Interfaces:
java.io.Serializable, java.lang.reflect.InvocationHandler

public class ProxyEngine<T>
extends java.lang.Object
implements java.lang.reflect.InvocationHandler, java.io.Serializable

See Also:
Serialized Form

Constructor Summary
ProxyEngine(java.lang.Class<T> api, T impl)
           
ProxyEngine(java.lang.Class<T> api, T impl, java.lang.Object info)
           
 
Method Summary
 void addInterceptor(ProxyInterceptor interceptor)
           
 void addInterface(java.lang.Class<?> clazz)
           
 T create()
           
 T getImpl()
           
static
<T> T
getImpl(T proxy)
           
 T getProxy()
           
 java.lang.Object invoke(java.lang.Object proxy, java.lang.reflect.Method method, java.lang.Object[] args)
           
 void setProxy(T proxy)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ProxyEngine

public ProxyEngine(java.lang.Class<T> api,
                   T impl)

ProxyEngine

public ProxyEngine(java.lang.Class<T> api,
                   T impl,
                   java.lang.Object info)
Method Detail

addInterceptor

public void addInterceptor(ProxyInterceptor interceptor)

getProxy

public T getProxy()

setProxy

public void setProxy(T proxy)

create

public T create()

invoke

public java.lang.Object invoke(java.lang.Object proxy,
                               java.lang.reflect.Method method,
                               java.lang.Object[] args)
                        throws java.lang.Throwable
Specified by:
invoke in interface java.lang.reflect.InvocationHandler
Throws:
java.lang.Throwable

getImpl

public T getImpl()

getImpl

public static <T> T getImpl(T proxy)

addInterface

public void addInterface(java.lang.Class<?> clazz)


Copyright © 2008-2013 Mycontainer Team. All Rights Reserved.