public class ReflectTools extends Object
| Constructor and Description |
|---|
ReflectTools() |
| Modifier and Type | Method and Description |
|---|---|
static List<Field> |
getDeclaredFields(Class<?> clazz)
获取所有声明字段,且非static修饰
|
static List<Method> |
getDeclaredMethods(Class<?> clazz) |
static Method |
getGetMethod(Class<?> clazz,
String fieldName) |
static Method |
getSetMethod(Class<?> clazz,
String fieldName) |
static Object |
invokeMethod(Method method,
Object obj,
Object... args) |
static <T> T |
newInstance(Class<?> clazz)
初始化
|
Copyright © 2022. All rights reserved.