diff options
author | Simon Brandhof <simon.brandhof@sonarsource.com> | 2016-03-31 12:23:32 +0200 |
---|---|---|
committer | Simon Brandhof <simon.brandhof@sonarsource.com> | 2016-03-31 12:31:20 +0200 |
commit | 491644917a5ebb44429ef45ee1885ed9728daf56 (patch) | |
tree | 6fad2c888a1f59e65b05e15270cd1c3ad99c4fbd | |
parent | eee6027f6146f4a529a6f3cd14637592a70cf3f2 (diff) | |
download | sonarqube-491644917a5ebb44429ef45ee1885ed9728daf56.tar.gz sonarqube-491644917a5ebb44429ef45ee1885ed9728daf56.zip |
Fix quality flaws
-rw-r--r-- | sonar-plugin-api/src/main/java/org/sonar/api/internal/package-info.java | 24 | ||||
-rw-r--r-- | sonar-plugin-api/src/main/java/org/sonar/api/utils/DateUtils.java | 2 |
2 files changed, 25 insertions, 1 deletions
diff --git a/sonar-plugin-api/src/main/java/org/sonar/api/internal/package-info.java b/sonar-plugin-api/src/main/java/org/sonar/api/internal/package-info.java new file mode 100644 index 00000000000..24caa2cc413 --- /dev/null +++ b/sonar-plugin-api/src/main/java/org/sonar/api/internal/package-info.java @@ -0,0 +1,24 @@ +/* + * SonarQube + * Copyright (C) 2009-2016 SonarSource SA + * mailto:contact AT sonarsource DOT com + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License as published by the Free Software Foundation; either + * version 3 of the License, or (at your option) any later version. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public License + * along with this program; if not, write to the Free Software Foundation, + * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. + */ +@ParametersAreNonnullByDefault +package org.sonar.api.internal; + +import javax.annotation.ParametersAreNonnullByDefault; + diff --git a/sonar-plugin-api/src/main/java/org/sonar/api/utils/DateUtils.java b/sonar-plugin-api/src/main/java/org/sonar/api/utils/DateUtils.java index 2f31b3f506b..ab8c90fbb52 100644 --- a/sonar-plugin-api/src/main/java/org/sonar/api/utils/DateUtils.java +++ b/sonar-plugin-api/src/main/java/org/sonar/api/utils/DateUtils.java @@ -175,7 +175,7 @@ public final class DateUtils { } private DateFormat getDateFormat() { - return (DateFormat) ((Reference) cache.get()).get(); + return cache.get().get(); } @Override |