Class DetailsTableModel

java.lang.Object
io.jenkins.plugins.datatables.TableModel
io.jenkins.plugins.analysis.core.model.DetailsTableModel
Direct Known Subclasses:
BlamesModel, DuplicateCodeScanner.DryModel, ForensicsModel, IssuesModel, RevApi.RevApiModel

public abstract class DetailsTableModel extends io.jenkins.plugins.datatables.TableModel
Provides the model for the issues details table. The model consists of the following parts:
  • header name for each column
  • width for each column
  • content for each row
  • content for whole table
Author:
Ullrich Hafner
  • Constructor Details

    • DetailsTableModel

      protected DetailsTableModel(edu.hm.hafner.analysis.Report report, FileNameRenderer fileNameRenderer, StaticAnalysisLabelProvider.AgeBuilder ageBuilder, DescriptionProvider descriptionProvider, io.jenkins.plugins.util.JenkinsFacade jenkinsFacade)
      Creates a new instance of DetailsTableModel.
      Parameters:
      report - the report to render
      fileNameRenderer - renders the file name column
      ageBuilder - renders the age column
      descriptionProvider - renders the description text
      jenkinsFacade - Jenkins facade to replaced with a stub during unit tests
  • Method Details

    • getTableConfiguration

      public io.jenkins.plugins.datatables.TableConfiguration getTableConfiguration()
      Overrides:
      getTableConfiguration in class io.jenkins.plugins.datatables.TableModel
    • getJenkinsFacade

      protected io.jenkins.plugins.util.JenkinsFacade getJenkinsFacade()
    • getReport

      protected edu.hm.hafner.analysis.Report getReport()
    • getFileNameRenderer

      protected FileNameRenderer getFileNameRenderer()
    • getAgeBuilder

      protected StaticAnalysisLabelProvider.AgeBuilder getAgeBuilder()
    • getDescriptionProvider

      protected DescriptionProvider getDescriptionProvider()
    • getRows

      public List<Object> getRows()
      Converts the specified set of issues into a table.
      Specified by:
      getRows in class io.jenkins.plugins.datatables.TableModel
      Returns:
      the table as String
    • createDetailsColumn

      protected io.jenkins.plugins.datatables.TableColumn createDetailsColumn()
    • createHiddenDetailsColumn

      protected io.jenkins.plugins.datatables.TableColumn createHiddenDetailsColumn()
    • createFileColumn

      protected io.jenkins.plugins.datatables.TableColumn createFileColumn()
    • createAgeColumn

      protected io.jenkins.plugins.datatables.TableColumn createAgeColumn()
    • createSeverityColumn

      protected io.jenkins.plugins.datatables.TableColumn createSeverityColumn()
    • createPackageColumn

      protected io.jenkins.plugins.datatables.TableColumn createPackageColumn()
    • getRow

      protected abstract DetailsTableModel.TableRow getRow(edu.hm.hafner.analysis.Issue issue)
      Returns a table row for the specified issue.
      Parameters:
      issue - the issue to show in the row
      Returns:
      a table row for the issue