if (pred.getLhsOperand() instanceof LOConst) {
leftIsConst = true;
leftConst = ((LOConst) (pred.getLhsOperand())).getValue();
} else {
LogicalOperator lhs = pred.getLhsOperand();
if (lhs instanceof LOCast)
lhs = ((LOCast) lhs).getExpression();
// if (!(pred.getLhsOperand() instanceof LOProject && ((LOProject)
// pred
// .getLhsOperand()).getProjection().size() == 1))
// return; // too hard
if (!(lhs instanceof LOProject && ((LOProject) lhs).getProjection()
.size() == 1))
return;
leftCol = ((LOProject) lhs).getCol();
leftDataType = ((LOProject) lhs).getType();
Object d = t.get(leftCol);
if (d != null) {
leftIsConst = true;
leftConst = d;
}
}
if (pred.getRhsOperand() instanceof LOConst) {
rightIsConst = true;
rightConst = ((LOConst) (pred.getRhsOperand())).getValue();
} else {
LogicalOperator rhs = pred.getRhsOperand();
if (rhs instanceof LOCast)
rhs = ((LOCast) rhs).getExpression();
// if (!(pred.getRhsOperand() instanceof LOProject && ((LOProject)
// pred
// .getRhsOperand()).getProjection().size() == 1))