<commit_before>package hudson.plugins.warnings.parser;

import java.util.regex.Matcher;

import org.apache.commons.lang.StringUtils;

/**
 * A parser for the Acu Cobol compile.
 *
 * @author jerryshea
 */
public class AcuCobolParser extends RegexpLineParser {
    /** Warning type of this parser. */
    static final String WARNING_TYPE = "AcuCobol Compiler";
    /** Pattern of cobol compiler warnings. */
    private static final String ACUCOBOL_WARNING_PATTERN = "\\s*(\\[.*\\])?\\s*?(.*), line ([0-9]*): Warning: (.*)";

    /**
     * Creates a new instance of {@link AcuCobolParser}.
     */
    public AcuCobolParser() {
        super(ACUCOBOL_WARNING_PATTERN, WARNING_TYPE);
    }

    /**
     * Creates a new annotation for the specified pattern.
     *
     * @param matcher
     *            the regular expression matcher<commit_msg>[HUDSON-5185] Added a string matcher before a line is parsed by regular expression.<commit_after>package hudson.plugins.warnings.parser;

import java.util.regex.Matcher;

import org.apache.commons.lang.StringUtils;

/**
 * A parser for the Acu Cobol compile.
 *
 * @author jerryshea
 */
public class AcuCobolParser extends RegexpLineParser {
    /** Warning type of this parser. */
    static final String WARNING_TYPE = "AcuCobol Compiler";
    /** Pattern of cobol compiler warnings. */
    private static final String ACUCOBOL_WARNING_PATTERN = "\\s*(\\[.*\\])?\\s*?(.*), line ([0-9]*): Warning: (.*)";

    /**
     * Creates a new instance of {@link AcuCobolParser}.
     */
    public AcuCobolParser() {
        super(ACUCOBOL_WARNING_PATTERN, WARNING_TYPE, true);
    }

    /** {@inheritDoc} */
    @Override
    protected boolean isLineInteresting(final String line) {
        return line.contains("Warning");
    }

    /**
     * Creates a new annotation for the specified pattern.
     *
     * @param matcher
     *            the regular expression matcher
{'fraction_non_alphanumeric': 0.12630480167014613, 'fraction_numerical': 0.0041753653444676405, 'mean_word_length': 2.8884381338742395, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1217724', 'n_tokens_mistral': 612, 'n_tokens_neox': 585, 'n_words': 161}