@Test void java9_version() { assertThat(PmdTemplate.languageVersion("9").getLanguageVersionHandler()).isInstanceOf(JavaLanguageHandler.class); }
static LanguageVersion languageVersion(String javaVersion) { String version = normalize(javaVersion); LanguageVersion languageVersion = new JavaLanguageModule().getVersion(version); if (languageVersion == null) { throw new IllegalArgumentException("Unsupported Java version for PMD: " + version); } LOG.info("Java version: " + version); return languageVersion; }
PmdTemplate { static LanguageVersion languageVersion(String javaVersion) { String version = normalize(javaVersion); LanguageVersion languageVersion = new JavaLanguageModule().getVersion(version); if (languageVersion == null) { throw new IllegalArgumentException("Unsupported Java version for PMD: " + version); } LOG.info("Java version: " + version); return languageVersion; } }
PmdTemplate { static LanguageVersion languageVersion(String javaVersion) { String version = normalize(javaVersion); LanguageVersion languageVersion = new JavaLanguageModule().getVersion(version); if (languageVersion == null) { throw new IllegalArgumentException("Unsupported Java version for PMD: " + version); } LOG.info("Java version: " + version); return languageVersion; } PmdTemplate(PMDConfiguration configuration, SourceCodeProcessor processor); }
PmdTemplate { static LanguageVersion languageVersion(String javaVersion) { String version = normalize(javaVersion); LanguageVersion languageVersion = new JavaLanguageModule().getVersion(version); if (languageVersion == null) { throw new IllegalArgumentException("Unsupported Java version for PMD: " + version); } LOG.info("Java version: " + version); return languageVersion; } PmdTemplate(PMDConfiguration configuration, SourceCodeProcessor processor); static PmdTemplate create(String javaVersion, ClassLoader classloader, Charset charset); void process(InputFile file, RuleSets rulesets, RuleContext ruleContext); }
PmdTemplate { static LanguageVersion languageVersion(String javaVersion) { String version = normalize(javaVersion); LanguageVersion languageVersion = new JavaLanguageModule().getVersion(version); if (languageVersion == null) { throw new IllegalArgumentException("Unsupported Java version for PMD: " + version); } LOG.info("Java version: " + version); return languageVersion; } PmdTemplate(PMDConfiguration configuration, SourceCodeProcessor processor); static PmdTemplate create(String javaVersion, ClassLoader classloader, Charset charset); void process(InputFile file, RuleSets rulesets, RuleContext ruleContext);  }