private static <F> ReportXmlFormatter createInternal(final LintReport<F> lintReport,
      final FormatterType formatterType, final Function<F, LintItem> adapter) {
    """
	Creates a report which handles the adaptation of type <F> to {@link LintItem}.
	
	@param lintReport
	{@link LintReport} containing all lints.
	@param formatterType
	the type of formatter to use.
	@param adapter
	a {@link Function} responsible for adapting a type <F> into {@link LintItem}
    """
    Validate.notNull(lintReport);
    final LintReport<LintItem> report = new LintReport<LintItem>();
    for (final ResourceLintReport<F> reportItem : lintReport.getReports()) {
      final Collection<LintItem> lintItems = new ArrayList<LintItem>();
      for (final F lint : reportItem.getLints()) {
        try {
          LOG.debug("Adding lint: {}", lint);
          lintItems.add(adapter.apply(lint));
        } catch (final Exception e) {
          throw WroRuntimeException.wrap(e, "Problem while adapting lint item");
        }
      }
      report.addReport(ResourceLintReport.create(reportItem.getResourcePath(), lintItems));
    }
    return new ReportXmlFormatter(report, formatterType);
  }
private static <F> ReportXmlFormatter createInternal(final LintReport<F> lintReport,
      final FormatterType formatterType, final Function<F, LintItem> adapter) {
    Validate.notNull(lintReport);
    final LintReport<LintItem> report = new LintReport<LintItem>();
    for (final ResourceLintReport<F> reportItem : lintReport.getReports()) {
      final Collection<LintItem> lintItems = new ArrayList<LintItem>();
      for (final F lint : reportItem.getLints()) {
        try {
          LOG.debug("Adding lint: {}", lint);
          lintItems.add(adapter.apply(lint));
        } catch (final Exception e) {
          throw WroRuntimeException.wrap(e, "Problem while adapting lint item");
        }
      }
      report.addReport(ResourceLintReport.create(reportItem.getResourcePath(), lintItems));
    }
    return new ReportXmlFormatter(report, formatterType);
  }
private static < F > ReportXmlFormatter createInternal ( final LintReport < F > lintReport , final FormatterType formatterType , final Function < F , LintItem > adapter ) { Validate . notNull ( lintReport ) ; final LintReport < LintItem > report = new LintReport < LintItem > ( ) ; for ( final ResourceLintReport < F > reportItem : lintReport . getReports ( ) ) { final Collection < LintItem > lintItems = new ArrayList < LintItem > ( ) ; for ( final F lint : reportItem . getLints ( ) ) { try { LOG . debug ( "Adding lint: {}" , lint ) ; lintItems . add ( adapter . apply ( lint ) ) ; } catch ( final Exception e ) { throw WroRuntimeException . wrap ( e , "Problem while adapting lint item" ) ; } } report . addReport ( ResourceLintReport . create ( reportItem . getResourcePath ( ) , lintItems ) ) ; } return new ReportXmlFormatter ( report , formatterType ) ; }
Creates a report which handles the adaptation of type <F> to {@link LintItem}.

@param lintReport
{@link LintReport} containing all lints.
@param formatterType
the type of formatter to use.
@param adapter
a {@link Function} responsible for adapting a type <F> into {@link LintItem}
Creates a report which handles the adaptation of type <F > to { @link LintItem } .