Klasse CommitDecorator

java.lang.Object
io.jenkins.plugins.forensics.util.CommitDecorator
Bekannte direkte Unterklassen:
CommitDecorator.NullDecorator

public abstract class CommitDecorator extends Object
A RepositoryBrowser for commits. Since a RepositoryBrowser has no API to generate links to simple commits, this decorator adds such a functionality. Note that this API does not only obtain such links, it also renders these links as HTML a tags.
Autor:
Ullrich Hafner
  • Konstruktordetails

    • CommitDecorator

      public CommitDecorator()
  • Methodendetails

    • asLink

      public abstract String asLink(String id)
      Obtains a link for the specified commit ID.
      Parameter:
      id - the ID of the commit
      Gibt zurück:
      an HTML a tag that contains a link to the commit
    • getRawLink

      public String getRawLink(String id)
      Returns the raw link for the specified commit ID.
      Parameter:
      id - the ID of the commit
      Gibt zurück:
      a raw link to the commit, e.g. https://github.com/jenkinsci/analysis-model/commit/9f5eb8b28e422d6249e6c29dc65173a59f2d9f6f
    • asText

      public String asText(String id)
      Renders the commit ID as a human-readable text.
      Parameter:
      id - the ID of the commit
      Gibt zurück:
      a commit ID as human-readable text