// and_op -> AND and_term and_op
// and_op -> EPSILON
private ExpressionNode andOperation(ExpressionNode expression) {
// and_op -> AND and_term and_op
if (lookahead.tokenType == TokenTypes.AND) {
AndExpressionNode conjunction;
// This means we are actually dealing with an AND
// If expr is not already an AND, we have to create one
if (expression.getType() == TokenTypes.AND) {
conjunction = (AndExpressionNode) expression;
} else {
conjunction = new AndExpressionNode(expression);
}
nextToken();
ExpressionNode term = andTerm();
conjunction.add(term);
return andOperation(conjunction);
}
// and_op -> EPSILON