private void matches(boolean own) {
        tq.consume(own ? ":matchesOwn" : ":matches");
        String regex = tq.chompBalanced('(', ')'); // don't unescape, as regex bits will be escaped
        Validate.notEmpty(regex, ":matches(regex) query must not be empty");

        if (own)
            evals.add(new Evaluator.MatchesOwn(Pattern.compile(regex)));
        else
            evals.add(new Evaluator.Matches(Pattern.compile(regex)));
    }
private void matches ( boolean own ) { tq . consume ( own ? ":matchesOwn" : ":matches" ) ; String regex = tq . chompBalanced ( '(' , ')' ) ; Validate . notEmpty ( regex , ":matches(regex) query must not be empty" ) ; if ( own ) evals . add ( new Evaluator . MatchesOwn ( Pattern . compile ( regex ) ) ) ; else evals . add ( new Evaluator . Matches ( Pattern . compile ( regex ) ) ) ; }
:matches(regex), matchesOwn(regex)