|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
Allows us to implement different versions of Proxies
Method Summary | |
InvocationHandler |
getInvocationHandler(Object proxy)
Returns the invocation handler for the specified proxy instance. |
Class |
getProxyClass(Class interfce)
Returns the java.lang.Class object for a proxy class given a class loader and an array of interfaces. |
Class |
getProxyClass(Class[] interfaces)
Returns the java.lang.Class object for a proxy class given a class loader and an array of interfaces. |
void |
init(Properties props)
Prepares the ProxyFactory for use. |
boolean |
isProxyClass(Class cl)
Returns true if and only if the specified class was dynamically generated to be a proxy class using the getProxyClass method or the newProxyInstance method. |
Object |
newProxyInstance(Class proxyClass)
Returns a new proxy instance from the specified proxy class. |
Object |
newProxyInstance(Class[] interfaces,
InvocationHandler h)
Returns an instance of a proxy class for the specified interface that dispatches method invocations to the specified invocation handler. |
Object |
newProxyInstance(Class interfce,
InvocationHandler h)
Returns an instance of a proxy class for the specified interface that dispatches method invocations to the specified invocation handler. |
Object |
setInvocationHandler(Object proxy,
InvocationHandler handler)
Sets the invocation handler for the specified proxy instance. |
Method Detail |
public void init(Properties props)
props
- public InvocationHandler getInvocationHandler(Object proxy) throws IllegalArgumentException
IllegalArgumentException
public Object setInvocationHandler(Object proxy, InvocationHandler handler) throws IllegalArgumentException
IllegalArgumentException
public Class getProxyClass(Class interfce) throws IllegalArgumentException
interfce
-
IllegalArgumentException
public Class getProxyClass(Class[] interfaces) throws IllegalArgumentException
interfaces
-
IllegalArgumentException
public boolean isProxyClass(Class cl)
cl
-
public Object newProxyInstance(Class interfce, InvocationHandler h) throws IllegalArgumentException
interfce
- h
-
IllegalArgumentException
public Object newProxyInstance(Class[] interfaces, InvocationHandler h) throws IllegalArgumentException
interfaces
- h
-
IllegalArgumentException
public Object newProxyInstance(Class proxyClass) throws IllegalArgumentException
proxyClass
-
IllegalArgumentException
- Occurs when the specified class is not a proxy class.
IllegalArgumentException
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |