update - REQ-2516-处理生成接口参数注解丢失问题
This commit is contained in:
parent
66e2b475c9
commit
d4e784901c
@ -55,7 +55,16 @@ public class GenServiceProcessor extends BaseCodeGenProcessor {
|
||||
if (add) {
|
||||
List<ParameterSpec> parameterSpecs = new ArrayList<>();
|
||||
for (VariableElement variableElement : executableElement.getParameters()) {
|
||||
parameterSpecs.add(ParameterSpec.get(variableElement));
|
||||
ParameterSpec parameterSpec = ParameterSpec.get(variableElement);
|
||||
List<? extends AnnotationMirror> paramAnnotations = variableElement.getAnnotationMirrors();
|
||||
if (paramAnnotations != null && !paramAnnotations.isEmpty()) {
|
||||
List<AnnotationSpec> annotationSpecs = new ArrayList<>();
|
||||
for (AnnotationMirror annotation : paramAnnotations) {
|
||||
annotationSpecs.add(AnnotationSpec.get(annotation));
|
||||
}
|
||||
parameterSpec = parameterSpec.toBuilder().addAnnotations(annotationSpecs).build();
|
||||
}
|
||||
parameterSpecs.add(parameterSpec);
|
||||
}
|
||||
List<AnnotationSpec> annotationSpecs = new ArrayList<>();
|
||||
for (AnnotationMirror annotationMirror : annotationMirrors) {
|
||||
|
||||
@ -15,7 +15,7 @@ public @interface GenService {
|
||||
|
||||
String genSourcePath() default "workflow-engine-spring-boot-starter/src/main/java";
|
||||
|
||||
String genClassName() default "WorkflowCoreService";
|
||||
String genClassName() default "WorkflowCoreService_Gen";
|
||||
|
||||
boolean overrideSource() default false;
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user