Class AbstractStandardEnforcerRule

    • Field Summary

      Fields 
      Modifier and Type Field Description
      private java.lang.String message  
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      protected static java.lang.String formatLocation​(org.apache.maven.project.MavenProject project, org.apache.maven.model.InputLocation location)
      Creates a string with line/column information for problems originating directly from this POM.
      java.lang.String getMessage()  
      private static java.lang.String getProjectId​(org.apache.maven.project.MavenProject project)
      Returns an identifier of a given project.
      void setMessage​(java.lang.String message)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • message

        private java.lang.String message
    • Constructor Detail

      • AbstractStandardEnforcerRule

        public AbstractStandardEnforcerRule()
    • Method Detail

      • getMessage

        public java.lang.String getMessage()
      • setMessage

        public void setMessage​(java.lang.String message)
      • getProjectId

        private static java.lang.String getProjectId​(org.apache.maven.project.MavenProject project)
        Returns an identifier of a given project.
        Parameters:
        project - the project
        Returns:
        the identifier of the project in the format <groupId>:<artifactId>:<version>
      • formatLocation

        protected static java.lang.String formatLocation​(org.apache.maven.project.MavenProject project,
                                                         org.apache.maven.model.InputLocation location)
        Creates a string with line/column information for problems originating directly from this POM. Inspired by o.a.m.model.building.ModelProblemUtils.formatLocation(...).
        Parameters:
        project - the current project.
        location - The location which should be formatted, must not be null.
        Returns:
        The formatted problem location or an empty string if unknown, never null.