private PsiClass @NotNull [] getCachedClassesByName(@NotNull String name, GlobalSearchScope scope) {
    DumbService dumbService = DumbService.getInstance(getProject());
    if (dumbService.isAlternativeResolveEnabled()) {
      return getCachedClassesInDumbMode(name, scope);
    }

    Map<String, PsiClass[]> map = dereference(myClassCache);
    if (map == null) {
      myClassCache = new SoftReference<>(map = ContainerUtil.createConcurrentSoftValueMap());
    }
    PsiClass[] classes = map.get(name);
    if (classes != null) {
      return classes;
    }

    RecursionGuard.StackStamp stamp = RecursionManager.markStack();
    classes = findAllClasses(name, GlobalSearchScope.everythingScope(getProject()));
    if (stamp.mayCacheNow()) {
      map.put(name, classes);
    }
    return classes;
  }
private PsiClass @NotNull [] getCachedClassesByName(@NotNull String name, GlobalSearchScope scope)