private static GrImportStatement createTemplateImport(Project project,
                                                        PsiMember resolved,
                                                        GroovyFileBase file) {
    final PsiClass aClass = resolved.getContainingClass();
    assert aClass != null;
    String qname = aClass.getQualifiedName();
    final String name = resolved.getName();

    GrImportStatement template = GroovyPsiElementFactory.getInstance(project)
      .createImportStatementFromText("import static " + qname + "." + name + " as aliased");
    return file.addImport(template);
  }
private static GrImportStatement createTemplateImport(Project project,
                                                        PsiMember resolved,
                                                        GroovyFileBase file)