Class ReportPlugin

All Implemented Interfaces:
Serializable, InputLocationTracker

The <plugin> element in <reporting><plugins> contains informations required for a report plugin.
See Also:
  • Method Details

    • getGroupId

      public String getGroupId()
      The group ID of the reporting plugin in the repository.
      Returns:
      a String
    • getArtifactId

      public String getArtifactId()
      The artifact ID of the reporting plugin in the repository.
      Returns:
      a String
    • getVersion

      public String getVersion()
      The version of the reporting plugin to be used. Starting with Maven 3, if no version is defined explicitly, version is searched in build/plugins then in build/pluginManagement.
      Returns:
      a String
    • getReportSets

      @Nonnull public List<ReportSet> getReportSets()
      Multiple specifications of a set of reports, each having (possibly) different configuration. This is the reporting parallel to an execution in the build.
      Returns:
      a List<ReportSet>
    • with

      Creates a new builder with this object as the basis.
      Overrides:
      with in class ConfigurationContainer
      Returns:
      a Builder
    • withInherited

      @Nonnull public ReportPlugin withInherited(String inherited)
      Creates a new ReportPlugin instance using the specified inherited.
      Overrides:
      withInherited in class ConfigurationContainer
      Parameters:
      inherited - the new String to use
      Returns:
      a ReportPlugin with the specified inherited
    • withConfiguration

      @Nonnull public ReportPlugin withConfiguration(XmlNode configuration)
      Creates a new ReportPlugin instance using the specified configuration.
      Overrides:
      withConfiguration in class ConfigurationContainer
      Parameters:
      configuration - the new XmlNode to use
      Returns:
      a ReportPlugin with the specified configuration
    • withGroupId

      @Nonnull public ReportPlugin withGroupId(String groupId)
      Creates a new ReportPlugin instance using the specified groupId.
      Parameters:
      groupId - the new String to use
      Returns:
      a ReportPlugin with the specified groupId
    • withArtifactId

      @Nonnull public ReportPlugin withArtifactId(String artifactId)
      Creates a new ReportPlugin instance using the specified artifactId.
      Parameters:
      artifactId - the new String to use
      Returns:
      a ReportPlugin with the specified artifactId
    • withVersion

      @Nonnull public ReportPlugin withVersion(String version)
      Creates a new ReportPlugin instance using the specified version.
      Parameters:
      version - the new String to use
      Returns:
      a ReportPlugin with the specified version
    • withReportSets

      @Nonnull public ReportPlugin withReportSets(Collection<ReportSet> reportSets)
      Creates a new ReportPlugin instance using the specified reportSets.
      Parameters:
      reportSets - the new Collection<ReportSet> to use
      Returns:
      a ReportPlugin with the specified reportSets
    • newInstance

      @Nonnull public static ReportPlugin newInstance()
      Creates a new ReportPlugin instance. Equivalent to newInstance(true).
      Returns:
      a new ReportPlugin
      See Also:
    • newInstance

      @Nonnull public static ReportPlugin newInstance(boolean withDefaults)
      Creates a new ReportPlugin instance using default values or not. Equivalent to newBuilder(withDefaults).build().
      Parameters:
      withDefaults - the boolean indicating whether default values should be used
      Returns:
      a new ReportPlugin
    • newBuilder

      @Nonnull public static ReportPlugin.Builder newBuilder()
      Creates a new ReportPlugin builder instance. Equivalent to newBuilder(true).
      Returns:
      a new Builder
      See Also:
    • newBuilder

      @Nonnull public static ReportPlugin.Builder newBuilder(boolean withDefaults)
      Creates a new ReportPlugin builder instance using default values or not.
      Parameters:
      withDefaults - the boolean indicating whether default values should be used
      Returns:
      a new Builder
    • newBuilder

      @Nonnull public static ReportPlugin.Builder newBuilder(ReportPlugin from)
      Creates a new ReportPlugin builder instance using the specified object as a basis. Equivalent to newBuilder(from, false).
      Parameters:
      from - the ReportPlugin instance to use as a basis
      Returns:
      a new Builder
    • newBuilder

      @Nonnull public static ReportPlugin.Builder newBuilder(ReportPlugin from, boolean forceCopy)
      Creates a new ReportPlugin builder instance using the specified object as a basis.
      Parameters:
      from - the ReportPlugin instance to use as a basis
      forceCopy - the boolean indicating if a copy should be forced
      Returns:
      a new Builder
    • flushReportSetMap

      public void flushReportSetMap()
      Reset the reportSetMap field to null
    • getReportSetsAsMap

      public Map<String,ReportSet> getReportSetsAsMap()
      Returns:
      a Map of reportSets field with ReportSet#getId() as key
      See Also:
    • getKey

      public String getKey()
      Returns:
      the key of the report plugin, ie groupId:artifactId
    • constructKey

      public static String constructKey(String groupId, String artifactId)
      Parameters:
      groupId - The group ID of the plugin in the repository
      artifactId - The artifact ID of the reporting plugin in the repository
      Returns:
      the key of the report plugin, ie groupId:artifactId