lib/bemlint.js
function validate (input, source, line, column, bemlintId) {

        for (var rule_id in currentRules) {
            var messageOptions = lodash.assign({}, {
                    input:  input,
                    source: source,
                    bemlintId: bemlintId,
                    elem:   options.elem,
                    mod:    options.mod,
                    wordPattern: options.wordPattern
                }),
                message = new Message(cheerio.load(modifiedText), rule_id, messageOptions);

            if ( message.text ) {
                messages.push({
                    message: message.text,
                    line: line,
                    column: column,
                    ruleId: rule_id
                });
            }
        }

    }
function validate (input, source, line, column, bemlintId) {

        for (var rule_id in currentRules) {
            var messageOptions = lodash.assign({}, {
                    input:  input,
                    source: source,
                    bemlintId: bemlintId,
                    elem:   options.elem,
                    mod:    options.mod,
                    wordPattern: options.wordPattern
                }),
                message = new Message(cheerio.load(modifiedText), rule_id, messageOptions);

            if ( message.text ) {
                messages.push({
                    message: message.text,
                    line: line,
                    column: column,
                    ruleId: rule_id
                });
            }
        }

    }
function validate ( input , source , line , column , bemlintId ) { for ( var rule_id in currentRules ) { var messageOptions = lodash . assign ( { } , { input : input , source : source , bemlintId : bemlintId , elem : options . elem , mod : options . mod , wordPattern : options . wordPattern } ) , message = new Message ( cheerio . load ( modifiedText ) , rule_id , messageOptions ) ; if ( message . text ) { messages . push ( { message : message . text , line : line , column : column , ruleId : rule_id } ) ; } } }
Generates messages for given classname in source
@method validate
@param  {String} input          classname
@param  {Array}  source         Array of classnames from html attribute
@param  {Integer} line          line number
@param  {Integer} column        column
@param  {String} bemlintId       Id for each node matched
Generates messages for given classname in source