public ValueExpressionEvaluator(ValueExpr expr, SQLBuilder parent, ValueType optype) { this.parent = parent; optypes.push(optype); if (log.isTraceEnabled()) { long start = System.currentTimeMillis(); expr.visit(this); log.trace("expression evaluated in {} ms", (System.currentTimeMillis() - start)); } else { expr.visit(this); } }
@Override public void meet(Bound node) throws RuntimeException { ValueExpr arg = node.getArg(); if (arg instanceof ValueConstant) { builder.append(Boolean.toString(true)); } else if (arg instanceof Var) { builder.append("("); optypes.push(ValueType.NODE); arg.visit(this); optypes.pop(); builder.append(" IS NOT NULL)"); } }