use of org.infernus.idea.checkstyle.VersionListReader in project checkstyle-idea by jshiell.
the class PluginConfigurationBuilder method defaultConfiguration.
public static PluginConfigurationBuilder defaultConfiguration(final Project project) {
final String csDefaultVersion = new VersionListReader().getDefaultVersion();
final SortedSet<ConfigurationLocation> defaultLocations = new TreeSet<>();
defaultLocations.add(configurationLocationFactory(project).create(BundledConfig.SUN_CHECKS, project));
defaultLocations.add(configurationLocationFactory(project).create(BundledConfig.GOOGLE_CHECKS, project));
final boolean copyLibs = OS.isWindows();
return new PluginConfigurationBuilder(csDefaultVersion, ScanScope.getDefaultValue(), false, copyLibs, defaultLocations, Collections.emptyList(), null, false, CheckStylePlugin.version());
}
use of org.infernus.idea.checkstyle.VersionListReader in project checkstyle-idea by jshiell.
the class ProjectConfigurationState method readCheckstyleVersion.
@NotNull
private String readCheckstyleVersion(@NotNull final Map<String, String> pLoadedMap) {
final VersionListReader vlr = new VersionListReader();
String result = pLoadedMap.get(CHECKSTYLE_VERSION_SETTING);
if (result == null) {
result = vlr.getDefaultVersion();
} else {
result = vlr.getReplacementMap().getOrDefault(result, result);
}
return result;
}
Aggregations