Class AbstractDryParser<T>

    • Constructor Detail

      • AbstractDryParser

        protected AbstractDryParser​(int highThreshold,
                                    int normalThreshold)
        Creates a new instance of AbstractDryParser.
        Parameters:
        highThreshold - minimum number of duplicate lines for high priority warnings
        normalThreshold - minimum number of duplicate lines for normal priority warnings
    • Method Detail

      • getPriority

        protected Severity getPriority​(int lines)
        Returns the priority of the warning.
        Parameters:
        lines - number of duplicate lines
        Returns:
        the priority of the warning
      • configureParser

        protected abstract void configureParser​(org.apache.commons.digester3.Digester digester)
        Configures the Digester parser. Register all rules that are required to parse the file.
        Parameters:
        digester - the parser to configure
      • convertDuplicationsToIssues

        protected abstract Report convertDuplicationsToIssues​(List<T> duplications,
                                                              IssueBuilder issueBuilder)
        Converts the parsed duplications from the original format to an Report instance.
        Parameters:
        duplications - the parsed warnings
        issueBuilder - the issue builder to use
        Returns:
        the converted warnings