ExpressionParser { static Parser<Expression> notInRelation(Parser<Expression> expr, Parser<Relation> relation) { return Parsers.sequence( expr, Parsers.between(phrase("not in ("), relation, term(")")), (e, r) -> new BinaryRelationalExpression(e, Op.NOT_IN, r)); }    }
@Test public void testNotInRelation() { TerminalParserTest.assertParser(ExpressionParser.notInRelation(NUMBER, RelationParser.TABLE), "1 not in (table)", new BinaryRelationalExpression(number(1), Op.NOT_IN, table("table"))); }