private static boolean suggestTagCalls(CompletionParameters parameters, CompletionResultSet result, PsiElement position) {
    if (!Registry.is("java.completion.methods.use.tags")) {
      return false;
    }
    if (!(JavaKeywordCompletion.AFTER_DOT.accepts(position))) {
      return false;
    }
    if (!(position.getParent() instanceof PsiReferenceExpression psiReferenceExpression)) {
      return false;
    }
    PsiExpression qualifierExpression = psiReferenceExpression.getQualifierExpression();
    if (!(qualifierExpression != null && PsiUtil.resolveClassInClassTypeOnly(qualifierExpression.getType()) != null)) {
      return false;
    }
    PrefixMatcher prefixMatcher = result.getPrefixMatcher();
    if (!(prefixMatcher instanceof CamelHumpMatcher camelHumpMatcher) || camelHumpMatcher.isTypoTolerant()) {
      //there is no reason to check it one more time
      return false;
    }
    Ref<Boolean> added = new Ref<>();
    added.set(false);
    MethodTags.TagMatcher tagMatcher = new MethodTags.TagMatcher(prefixMatcher);
    CompletionResultSet tagResultSet = result.withPrefixMatcher(tagMatcher);
    tagResultSet.runRemainingContributors(parameters, downstream -> {
      LookupElement element = downstream.getLookupElement();
      if (element != null && !prefixMatcher.prefixMatches(element) && tagMatcher.prefixMatches(element)) {
        LookupElement lookupElement = MethodTags.wrapLookupWithTags(element, prefixMatcher::prefixMatches, prefixMatcher.getPrefix(),
                                                                    parameters.getCompletionType());
        if (lookupElement != null) {
          CompletionResult wrapped = CompletionResult.wrap(lookupElement, downstream.getPrefixMatcher(),
                                                           downstream.getSorter());
          if (wrapped != null) {
            added.set(true);
            tagResultSet.passResult(wrapped);
          }
        }
      }
    });
    return added.get();
  }
private static boolean suggestTagCalls(CompletionParameters parameters, CompletionResultSet result, PsiElement position)