001/*
002 * SonarQube, open source software quality management tool.
003 * Copyright (C) 2008-2014 SonarSource
004 * mailto:contact AT sonarsource DOT com
005 *
006 * SonarQube is free software; you can redistribute it and/or
007 * modify it under the terms of the GNU Lesser General Public
008 * License as published by the Free Software Foundation; either
009 * version 3 of the License, or (at your option) any later version.
010 *
011 * SonarQube is distributed in the hope that it will be useful,
012 * but WITHOUT ANY WARRANTY; without even the implied warranty of
013 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
014 * Lesser General Public License for more details.
015 *
016 * You should have received a copy of the GNU Lesser General Public License
017 * along with this program; if not, write to the Free Software Foundation,
018 * Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
019 */
020package org.sonar.api.batch.maven;
021
022import org.sonar.api.BatchExtension;
023import org.sonar.api.resources.Project;
024
025import javax.annotation.Nonnull;
026import javax.annotation.Nullable;
027
028/**
029 * @since 1.10
030 * @deprecated since 4.5 we don't want any dependency on Maven anymore
031 */
032@Deprecated
033public interface MavenPluginHandler extends BatchExtension {
034
035  /**
036   * The plugin group id
037   *
038   * @return the group id
039   */
040  @Nonnull
041  String getGroupId();
042
043  /**
044   * The plugin artifact id
045   *
046   * @return artifact id
047   */
048  @Nonnull
049  String getArtifactId();
050
051  /**
052   * The fixed plugin version to execute
053   *
054   * @return the plugin version
055   */
056  @Nullable
057  String getVersion();
058
059  /**
060   * Indicates if the plugin version should be fixed or not, it means that if your pom defines another version
061   * than the one defined by getVersion(), this version will be used
062   *
063   * @return true if the version should be fixed
064   */
065  boolean isFixedVersion();
066
067  /**
068   * The maven goals to execute
069   *
070   * @return an array of goals
071   */
072  @Nonnull
073  String[] getGoals();
074
075  /**
076   * Configures the pom being executed, add or remove plugin properties.
077   * This method is automatically executed by Sonar. Plugins do NOT have to execute it.
078   */
079  void configure(Project project, MavenPlugin plugin);
080
081}