コード例 #1
0
  public static File getReport(Project project, MavenProject mavenProject, String file) {
    File report = getReportFromPluginConfiguration(project, mavenProject, file);
    if (report == null) {
      report = getReportFromDefaultPath(project, file);
    }

    if (report == null || !report.exists() || !report.isFile()) {
      Logs.INFO.warn("PomQuality report not found at {}", report);
      report = null;
    }
    return report;
  }
コード例 #2
0
ファイル: PmdSensor.java プロジェクト: jerr/sonar
  public void analyse(Project project, SensorContext context) {
    if (project.getReuseExistingRulesConfig()) {
      Logs.INFO.warn("Reusing existing PMD configuration is not supported any more.");
    }
    try {
      File xmlReport = executor.execute();
      getStaxParser(project, context).parse(xmlReport);

    } catch (Exception e) {
      // TOFIX
      throw new XmlParserException(e);
    }
  }