@Override
  public void processDynamicElements(@NotNull PsiType qualifierType,
                                     @Nullable PsiClass aClass,
                                     @NotNull PsiScopeProcessor processor,
                                     @NotNull PsiElement place,
                                     @NotNull ResolveState state) {
    if (!(aClass instanceof GroovyScriptClass)) {
      return;
    }

    PsiFile file = aClass.getContainingFile();
    if (!"pom.groovy".equals(file.getName())) return;

    List<String> methodCallInfo = MavenGroovyPomUtil.getGroovyMethodCalls(place);

    MultiMap<String, String> multiMap = MultiMap.createLinked();
    MultiMap<String, String> leafMap = MultiMap.createLinked();

    String key = StringUtil.join(methodCallInfo, "->");
    for (Contributor contributor : contributors.getValue()) {
      contributor.populate(place.getProject(), multiMap, leafMap);
    }

    for (String classSource : multiMap.get(key)) {
      DynamicMemberUtils.process(processor, false, place, classSource);
    }

    for (String classSource : leafMap.get(key)) {
      if (!(place.getParent() instanceof GrClosableBlock)) {
        DynamicMemberUtils.process(processor, false, place, classSource);
      }
    }

    if (!methodCallInfo.isEmpty() &&
        StringUtil.endsWithIgnoreCase(ContainerUtil.getLastItem(methodCallInfo), CompletionUtilCore.DUMMY_IDENTIFIER_TRIMMED)) {
      key = StringUtil.join(methodCallInfo.subList(0, methodCallInfo.size() - 1), "->");
      for (String classSource : multiMap.get(key)) {
        DynamicMemberUtils.process(processor, false, place, classSource);
      }
    }
  }
@Override
  public void processDynamicElements(@NotNull PsiType qualifierType,
                                     @Nullable PsiClass aClass,
                                     @NotNull PsiScopeProcessor processor,
                                     @NotNull PsiElement place,
                                     @NotNull ResolveState state)