All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.joo.libra.sql.node.EmptyExpressionNode Maven / Gradle / Ivy

There is a newer version: 2.1.2
Show newest version
package org.joo.libra.sql.node;

import org.joo.libra.Predicate;
import org.joo.libra.common.HasValue;
import org.joo.libra.logic.NotPredicate;
import org.joo.libra.sql.antlr.SqlLexer;
import org.joo.libra.text.IsEmptyPredicate;

import lombok.Getter;
import lombok.Setter;

public class EmptyExpressionNode extends UnaryExpressionNode {

	private @Getter @Setter int op;

	@Override
	public Predicate buildPredicate() {
		if (op == SqlLexer.IS_NOT_EMPTY)
			return new NotPredicate(new IsEmptyPredicate((HasValue) getInnerNode()));
		return new IsEmptyPredicate((HasValue) getInnerNode());
	}
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy