public final class Proxy extends Object
| 构造器和说明 |
|---|
Proxy() |
| 限定符和类型 | 方法和说明 |
|---|---|
static Class<?> |
buildInstanceClass(ClassLoader loader,
DynamicConfig config)
对象增强类型
|
static Class<?> |
buildProxyClass(ClassLoader loader,
DynamicConfig config)
类型增强类型
|
static Class<?> |
getPrototypeType(Class<?> targetType) |
static Class<?> |
getPrototypeType(Object instance) |
static boolean |
isDynamicClass(Class<?> targetType) |
static boolean |
isDynamicObject(Object instance) |
static boolean |
isProxyClass(Class<?> targetType) |
static boolean |
isProxyObject(Object instance) |
static Class<?> |
newProxyClass(ClassLoader loader,
Class<?> superType)
增强一个类型,使用对象身上的 @Aop 注解
|
static Class<?> |
newProxyClass(ClassLoader loader,
Class<?>[] interfaces,
InvocationHandler handler)
兼容 jdk Proxy 用法,interfaces 中可以含有(一个类或抽象类)作为父类
|
static Class<?> |
newProxyClass(ClassLoader loader,
Class<?> superType,
Class<?>[] interfaces,
MethodInterceptor... interceptors)
对类型已经实现的某个接口做增强,返回一个增强类型
|
static Class<?> |
newProxyClass(ClassLoader loader,
Class<?> superType,
Predicate<Method> methodMatcher,
MethodInterceptor... interceptors)
对类型的方法做增强,返回一个增强类型
|
static <T> ProxyFactory<T> |
newProxyFactory(ClassLoader loader,
DynamicConfig config)
创建一个工厂,创建增强的代理类对象
|
static Object |
newProxyInstance(ClassLoader loader,
Class<?>[] interfaces,
InvocationHandler handler)
兼容 jdk Proxy 用法,interfaces 中可以含有(一个类或抽象类)作为父类
|
static <T> T |
newProxyInstance(ClassLoader loader,
T instance)
增强一个对象,无论它是否实现任何一个接口。
|
static <T> T |
newProxyInstance(ClassLoader loader,
T instance,
Class<?>[] interfaces,
MethodInterceptor... interceptors)
对象已经实现的某个接口做增强
|
static <T> T |
newProxyInstance(ClassLoader loader,
T instance,
Predicate<Method> matchers,
MethodInterceptor... interceptors)
增强一个对象,无论它是否实现任何一个接口
|
static <T> T |
newProxyInstance(T instance)
增强一个对象,无论它是否实现任何一个接口。
|
static <T> T |
newProxyInstance(T instance,
Class<?>[] interfaces,
MethodInterceptor... interceptors)
对象已经实现的某个接口做增强
|
static <T> T |
newProxyInstance(T instance,
Predicate<Method> matchers,
MethodInterceptor... interceptors)
增强一个对象,无论它是否实现任何一个接口
|
public static Object newProxyInstance(ClassLoader loader, Class<?>[] interfaces, InvocationHandler handler)
public static Class<?> newProxyClass(ClassLoader loader, Class<?>[] interfaces, InvocationHandler handler)
public static <T> T newProxyInstance(ClassLoader loader, T instance, Class<?>[] interfaces, MethodInterceptor... interceptors)
public static <T> T newProxyInstance(ClassLoader loader, T instance, Predicate<Method> matchers, MethodInterceptor... interceptors)
public static <T> T newProxyInstance(ClassLoader loader, T instance)
public static <T> T newProxyInstance(T instance,
Class<?>[] interfaces,
MethodInterceptor... interceptors)
public static <T> T newProxyInstance(T instance,
Predicate<Method> matchers,
MethodInterceptor... interceptors)
public static <T> T newProxyInstance(T instance)
public static Class<?> newProxyClass(ClassLoader loader, Class<?> superType, Class<?>[] interfaces, MethodInterceptor... interceptors)
public static Class<?> newProxyClass(ClassLoader loader, Class<?> superType, Predicate<Method> methodMatcher, MethodInterceptor... interceptors)
public static Class<?> newProxyClass(ClassLoader loader, Class<?> superType)
public static <T> ProxyFactory<T> newProxyFactory(ClassLoader loader, DynamicConfig config)
public static Class<?> buildInstanceClass(ClassLoader loader, DynamicConfig config)
public static Class<?> buildProxyClass(ClassLoader loader, DynamicConfig config)
public static boolean isProxyObject(Object instance)
public static boolean isDynamicObject(Object instance)
public static boolean isProxyClass(Class<?> targetType)
public static boolean isDynamicClass(Class<?> targetType)
[Web Site]