public static @NotNull Collection<Module> getModulesOfType(@NotNull Project project, @NotNull ModuleType<?> moduleType) {
    return CachedValuesManager.getManager(project)
      .getParameterizedCachedValue(project, MODULES_BY_TYPE_KEY, MODULE_BY_TYPE_VALUE_PROVIDER, false, project)
      .get(moduleType);
  }
public static @NotNull Collection<Module> getModulesOfType(@NotNull Project project, @NotNull ModuleType<?> moduleType)