public class ProxyFactory extends Object
Constructor and Description |
---|
ProxyFactory() |
Modifier and Type | Method and Description |
---|---|
static Object |
newProxyInstance(ClassLoader loader,
Class<?>[] interfaces,
ProxyInvocationHandler handler,
boolean allowCache)
Returns an instance of a class for the specified interfaces that dispatches method
invocations to the specified invocation handler.
|
public static Object newProxyInstance(ClassLoader loader, Class<?>[] interfaces, ProxyInvocationHandler handler, boolean allowCache) throws IllegalArgumentException
handler
- the invocation handler to dispatch method invocations toloader
- the class loader to define the proxy classinterfaces
- the list of interfaces for the proxy class to implementIllegalArgumentException
- if any of the restrictions on the parameters that may be
passed to getProxyClass
are violatedNullPointerException
- if the interfaces
array argument or any of its
elements are null
, or if the invocation
handler, h
, is null
Copyright © GigaSpaces.