From a0311c5362b897dbb3cf71c4921468a0042f17ea Mon Sep 17 00:00:00 2001 From: oppofind <836575280@qq.com> Date: Tue, 12 Jan 2021 23:56:04 +0800 Subject: [PATCH] fix gitee #I2C6N1 --- src/main/java/com/power/doc/utils/DocClassUtil.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/main/java/com/power/doc/utils/DocClassUtil.java b/src/main/java/com/power/doc/utils/DocClassUtil.java index fb63942..d65819f 100644 --- a/src/main/java/com/power/doc/utils/DocClassUtil.java +++ b/src/main/java/com/power/doc/utils/DocClassUtil.java @@ -46,9 +46,13 @@ public class DocClassUtil { * @return array of string */ public static String[] getSimpleGicName(String returnType) { - if (JavaClassValidateUtil.isArray(returnType)) { + if (JavaClassValidateUtil.isCollection(returnType)) { + returnType = returnType + ""; + } else if (JavaClassValidateUtil.isArray(returnType)) { returnType = returnType.substring(0, returnType.lastIndexOf("[")); returnType = "java.util.List<" + returnType + ">"; + } else if (JavaClassValidateUtil.isMap(returnType)) { + returnType = returnType + ""; } if (returnType.contains("<")) { String pre = returnType.substring(0, returnType.indexOf("<"));