summaryrefslogtreecommitdiffstats
path: root/sonar-deprecated
diff options
context:
space:
mode:
authorSimon Brandhof <simon.brandhof@gmail.com>2014-03-25 15:50:29 +0100
committerSimon Brandhof <simon.brandhof@gmail.com>2014-03-25 16:45:32 +0100
commite2b033fccc4e306a11b77b3632b388f556385815 (patch)
treeb54ffc40f007fa512b8c14fb77ff106ca813a9c5 /sonar-deprecated
parent767869e7fdcd15e3cf290a247b60b34b1bde6958 (diff)
downloadsonarqube-e2b033fccc4e306a11b77b3632b388f556385815.tar.gz
sonarqube-e2b033fccc4e306a11b77b3632b388f556385815.zip
SONAR-4908 refactor RulesDefinition API (debt functions, XML)
Diffstat (limited to 'sonar-deprecated')
-rw-r--r--sonar-deprecated/src/main/java/org/sonar/api/i18n/RuleI18n.java152
1 files changed, 0 insertions, 152 deletions
diff --git a/sonar-deprecated/src/main/java/org/sonar/api/i18n/RuleI18n.java b/sonar-deprecated/src/main/java/org/sonar/api/i18n/RuleI18n.java
deleted file mode 100644
index 0dbcee23cc7..00000000000
--- a/sonar-deprecated/src/main/java/org/sonar/api/i18n/RuleI18n.java
+++ /dev/null
@@ -1,152 +0,0 @@
-/*
- * SonarQube, open source software quality management tool.
- * Copyright (C) 2008-2014 SonarSource
- * mailto:contact AT sonarsource DOT com
- *
- * SonarQube 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.
- *
- * SonarQube 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.
- */
-package org.sonar.api.i18n;
-
-import org.sonar.api.BatchComponent;
-import org.sonar.api.ServerComponent;
-import org.sonar.api.rules.Rule;
-
-import javax.annotation.CheckForNull;
-
-import java.util.Locale;
-
-/**
- * {@link I18n}-companion component that provides translation facilities for rule names, descriptions and parameter names.
- *
- * @since 3.2
- * @deprecated in 4.1. Rules are not localized anymore. See http://jira.codehaus.org/browse/SONAR-4885
- */
-@Deprecated
-public interface RuleI18n extends ServerComponent, BatchComponent {
-
- /**
- * Returns the localized name of the rule identified by its repository key and rule key.
- * <br>
- * If the name is not found in the given locale, then the default name is returned (the English one).
- * This method could return null if no default name found. This is the cause for instance the copies rules.
- *
- * @param repositoryKey the repository key
- * @param ruleKey the rule key
- * @param locale not used
- * @return the translated name of the rule, or the default English one if the given locale is not supported, or null
- * @deprecated since 4.1. Rules are not localized anymore. See http://jira.codehaus.org/browse/SONAR-4885
- */
- @Deprecated
- @CheckForNull
- String getName(String repositoryKey, String ruleKey, Locale locale);
-
- /**
- * Returns the name of the rule identified by its repository key and rule key.
- * <br>
- * This method could return null if no default name found. This is the cause for instance the copies rules.
- *
- * @param repositoryKey the repository key
- * @param ruleKey the rule key
- * @return the nullable name of the rule
- * @since 4.1
- */
- @CheckForNull
- String getName(String repositoryKey, String ruleKey);
-
- /**
- * Returns the localized name or the name of the rule.
- * <br>
- * If the name is not found in the given locale, then the default name is returned (the English one).
- * It the default name is not found, then the rule name is returned.
- *
- * @param rule the rule
- * @param locale the locale to translate into
- * @return the translated name of the rule, or the default English one if the given locale is not supported, or the rule name.
- * @deprecated since 4.1. Rules are not localized anymore. See http://jira.codehaus.org/browse/SONAR-4885
- */
- @Deprecated
- @CheckForNull
- String getName(Rule rule, Locale locale);
-
- /**
- * Returns the name of the rule.
- * <br>
- * It the default name is not found, then the rule name is returned.
- *
- * @param rule the rule
- * @return the nullable name of the rule
- * @since 4.1
- */
- @CheckForNull
- String getName(Rule rule);
-
- /**
- * Returns the localized description of the rule identified by its repository key and rule key.
- * <br>
- * If the description is not found in the given locale, then the default description is returned (the English one).
- * As a rule must have a description (this is a constraint in Sonar), this method never returns null.
- *
- * @param repositoryKey the repository key
- * @param ruleKey the rule key
- * @param locale the locale to translate into
- * @return the translated description of the rule, or the default English one if the given locale is not supported
- * @deprecated since 4.1. Rules are not localized anymore. See http://jira.codehaus.org/browse/SONAR-4885
- */
- @Deprecated
- String getDescription(String repositoryKey, String ruleKey, Locale locale);
-
- /**
- * Returns the description of the rule identified by its repository key and rule key.
- * <br>
- * As a rule must have a description (this is a constraint in SonarQube), this method never returns null.
- *
- * @param repositoryKey the repository key
- * @param ruleKey the rule key
- * @return the description of the rule
- * @since 4.1
- */
- String getDescription(String repositoryKey, String ruleKey);
-
- /**
- * Returns the localized name of the rule parameter identified by the rules's key and repository key, and by the parameter key.
- * <br>
- * If the name is not found in the given locale, then the English translation is searched and return if found. Otherwise,
- * this method returns null (= if no translation can be found).
- *
- * @param repositoryKey the repository key
- * @param ruleKey the rule key
- * @param paramKey the parameter key
- * @param locale the locale to translate into
- * @return the translated name of the rule parameter, or the default English one if the given locale is not supported, or null if
- * no translation can be found.
- * @deprecated since 4.1. Rules are not localized anymore. See http://jira.codehaus.org/browse/SONAR-4885
- */
- @Deprecated
- @CheckForNull
- String getParamDescription(String repositoryKey, String ruleKey, String paramKey, Locale locale);
-
- /**
- * Returns the name of the rule parameter identified by the rules's key and repository key, and by the parameter key.
- *
- * @param repositoryKey the repository key
- * @param ruleKey the rule key
- * @param paramKey the parameter key
- * @return the nullable name of the rule parameter
- * @since 4.1
- */
- @CheckForNull
- String getParamDescription(String repositoryKey, String ruleKey, String paramKey);
-
-}