diff --git a/kernel-d-scanner/scanner-api/src/main/java/cn/stylefeng/roses/kernel/scanner/api/util/ClassReflectUtil.java b/kernel-d-scanner/scanner-api/src/main/java/cn/stylefeng/roses/kernel/scanner/api/util/ClassReflectUtil.java index cdd9ebcaf..05d7f5ad3 100644 --- a/kernel-d-scanner/scanner-api/src/main/java/cn/stylefeng/roses/kernel/scanner/api/util/ClassReflectUtil.java +++ b/kernel-d-scanner/scanner-api/src/main/java/cn/stylefeng/roses/kernel/scanner/api/util/ClassReflectUtil.java @@ -50,60 +50,6 @@ public class ClassReflectUtil { */ private final static Map RUN_MAP = new HashMap<>(2); - /** - * 获取ResponseData类型的字段描述,参数clazz是ResponseData的data属性的类型 - * - * @author fengshuonan - * @date 2022/1/7 15:37 - */ - public static Set getResponseDataClassFieldDescription(Class clazz) { - - HashSet responseDataFieldMetadata = new HashSet<>(); - - // 创建ResponseData几个固定的属性描述 - FieldMetadata success = new FieldMetadata(); - success.setMetadataId(IdUtil.fastSimpleUUID()); - success.setChineseName("请求是否成功"); - success.setFieldClassType("Boolean"); - success.setFieldClassPath("java.lang.Boolean"); - success.setFieldName("success"); - responseDataFieldMetadata.add(success); - - // 创建ResponseData几个固定的属性描述 - FieldMetadata code = new FieldMetadata(); - code.setMetadataId(IdUtil.fastSimpleUUID()); - code.setChineseName("响应状态码"); - code.setFieldClassType("String"); - code.setFieldClassPath("java.lang.String"); - code.setFieldName("code"); - responseDataFieldMetadata.add(code); - - // 创建ResponseData几个固定的属性描述 - FieldMetadata message = new FieldMetadata(); - message.setMetadataId(IdUtil.fastSimpleUUID()); - message.setChineseName("响应信息"); - message.setFieldClassType("String"); - message.setFieldClassPath("java.lang.String"); - message.setFieldName("message"); - responseDataFieldMetadata.add(message); - - // 创建ResponseData几个固定的属性描述 - FieldMetadata data = new FieldMetadata(); - data.setMetadataId(IdUtil.fastSimpleUUID()); - data.setChineseName("响应对象"); - data.setFieldClassType(clazz.getSimpleName()); - data.setFieldClassPath(clazz.getName()); - data.setFieldName("data"); - - // 设置data属性类型具体的元数据 - Set dataFieldMetadata = getClassFieldDescription(clazz); - data.setGenericFieldMetadata(dataFieldMetadata); - - responseDataFieldMetadata.add(data); - - return responseDataFieldMetadata; - } - /** * 获取一个类的所有字段描述 *