diff options
author | Evgeny Mandrikov <mandrikov@gmail.com> | 2011-01-27 21:20:09 +0300 |
---|---|---|
committer | Evgeny Mandrikov <mandrikov@gmail.com> | 2011-01-28 11:27:41 +0300 |
commit | 5c05c7d812a97fd6ab07b5ae7449f5e95d0f6546 (patch) | |
tree | 2d088123a1faaa64179822d14ccc0fa807a12763 /sonar-plugin-api | |
parent | c2f90c84e3fef821bfdee686351375a2732ac06e (diff) | |
download | sonarqube-5c05c7d812a97fd6ab07b5ae7449f5e95d0f6546.tar.gz sonarqube-5c05c7d812a97fd6ab07b5ae7449f5e95d0f6546.zip |
SONAR-2148: Add new properties to manage level of Java language
* Use sonar-java-api in sonar-pmd-plugin and sonar-clover-plugin
Diffstat (limited to 'sonar-plugin-api')
-rw-r--r-- | sonar-plugin-api/src/main/java/org/sonar/api/resources/ProjectUtils.java | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/sonar-plugin-api/src/main/java/org/sonar/api/resources/ProjectUtils.java b/sonar-plugin-api/src/main/java/org/sonar/api/resources/ProjectUtils.java index 1998fbbdaf1..b81c3dc7b46 100644 --- a/sonar-plugin-api/src/main/java/org/sonar/api/resources/ProjectUtils.java +++ b/sonar-plugin-api/src/main/java/org/sonar/api/resources/ProjectUtils.java @@ -20,9 +20,8 @@ package org.sonar.api.resources; /** - * FIXME - * Actually this class incorrectly named, because provides information not about project, but about Java project. - * And seems that only core plugins use this class. + * @TODO Actually this class incorrectly named, because provides information not about project, but about Java project. + * And seems that only core plugins use this class. * * @since 1.10 */ @@ -33,22 +32,23 @@ public final class ProjectUtils { } /** - * Java version as defined in maven-compiler-plugin + * @deprecated since 2.6 use JavaUtils.getTargetVersion() instead. */ + @Deprecated public static String getJavaVersion(Project project) { - // target version - // TODO was return MavenUtils.getJavaVersion(project.getPom()); if (project.getConfiguration() != null) { - return project.getConfiguration().getString("sonar.java.targetVersion"); + return project.getConfiguration().getString("sonar.java.target"); } return null; } + /** + * @deprecated since 2.6 use JavaUtils.getSourceVersion() instead. + */ + @Deprecated public static String getJavaSourceVersion(Project project) { - // source version - // TODO was return MavenUtils.getJavaSourceVersion(project.getPom()); if (project.getConfiguration() != null) { - return project.getConfiguration().getString("sonar.java.sourceVersion"); + return project.getConfiguration().getString("sonar.java.source"); } return null; } |