js/logEventMatcher/lemParser.js
/*
     * Requires that the next token's type is one of the arugments. An error is
     * thrown otherwise This is an infinite-arity function
     * 
     * @param {...TokenType} args
     */
Requires that the next token's type is one of the arugments. An error is
thrown otherwise This is an infinite-arity function


Requires that the next token ' s type is one of the arugments . An error is thrown otherwise This is an infinite - arity function
function require(args) {
        if (context.tokenizer.hasNext()) {
            var currType = peekType();
            for (var i = 0; i < arguments.length; i++) {
                if (currType == arguments[i]) {
                    return;
                }
            }
        }
        var errString = "Expected: ";
        for (var i = 0; i < arguments.length; i++) {
            errString += arguments[i].getPrettyName() + " or ";
        }
        throw new Exception(errString.replace(/or $/, ""));
    }
function require ( args ) { if ( context . tokenizer . hasNext ( ) ) { var currType = peekType ( ) ; for ( var i = 0 ; i < arguments . length ; i ++ ) { if ( currType == arguments [ i ] ) { return ; } } } var errString = "Expected: " ; for ( var i = 0 ; i < arguments . length ; i ++ ) { errString += arguments [ i ] . getPrettyName ( ) + " or " ; } throw new Exception ( errString . replace ( / or $ / , "" ) ) ; }
Requires that the next token's type is one of the arugments.
Requires that the next token ' s type is one of the arugments .