List<GrLightMethodBuilder> (@NotNull GrTypeDefinition typeDefinition, String originInfo, @NotNull TransformationContext context) { if (GroovyConfigUtils.isAtLeastGroovy25(typeDefinition)) { PsiAnnotation mapConstructorAnno = typeDefinition.getAnnotation(GroovyCommonClassNames.GROOVY_TRANSFORM_MAP_CONSTRUCTOR); if (mapConstructorAnno == null) { return Collections.emptyList(); } GrLightMethodBuilder mapConstructor = new GrLightMethodBuilder(typeDefinition); checkContainingClass(context, mapConstructor); mapConstructor.setOriginInfo(originInfo); Visibility visibility = getVisibility(mapConstructorAnno, mapConstructor, Visibility.PUBLIC); mapConstructor.addModifier(visibility.toString()); var specialParamHandling = GrAnnotationUtil.inferBooleanAttribute(mapConstructorAnno, "specialNamedArgHandling"); String parameterRepresentation; if (Boolean.TRUE.equals(specialParamHandling)) { parameterRepresentation = computeMapParameterPresentation(typeDefinition); } else { parameterRepresentation = CommonClassNames.JAVA_UTIL_MAP; } mapConstructor.addParameter("args", parameterRepresentation); var noArg = GrAnnotationUtil.inferBooleanAttribute(mapConstructorAnno, "noArg"); if (Boolean.TRUE.equals(noArg)) { var noArgConstructor = new GrLightMethodBuilder(typeDefinition); checkContainingClass(context, noArgConstructor); noArgConstructor.setOriginInfo(originInfo); return List.of(mapConstructor, noArgConstructor); } else { return List.of(mapConstructor); } } else { final GrLightMethodBuilder mapConstructor = new GrLightMethodBuilder(typeDefinition); checkContainingClass(context, mapConstructor); mapConstructor.addParameter("args", CommonClassNames.JAVA_UTIL_HASH_MAP); mapConstructor.setOriginInfo(originInfo); return List.of(mapConstructor); } }