@Override public boolean equals(Object other) { if (other instanceof Bound) { Bound o = (Bound)other; return arg.equals(o.getArg()); } return false; }
/** * @inheritDoc */ @Override public void meet(Bound theOp) throws Exception { mBuffer.append(" bound("); theOp.getArg().visit(this); mBuffer.append(")"); }
/** * @inheritDoc */ @Override public void meet(Bound theOp) throws Exception { mBuffer.append(" bound("); theOp.getArg().visit(this); mBuffer.append(")"); }
@Override public boolean equals(Object other) { if (other instanceof Bound) { Bound o = (Bound)other; return arg.equals(o.getArg()); } return false; }
/** * @inheritDoc */ @Override public void meet(Bound theOp) throws Exception { mBuffer.append(" bound("); theOp.getArg().visit(this); mBuffer.append(")"); }
/** * @inheritDoc */ @Override public void meet(Bound theOp) throws Exception { mBuffer.append(" bound("); theOp.getArg().visit(this); mBuffer.append(")"); }
/** * @inheritDoc */ @Override public void meet(Bound theOp) throws Exception { mBuffer.append(" bound("); theOp.getArg().visit(this); mBuffer.append(")"); }
/** * @inheritDoc */ @Override public void meet(Bound theOp) throws Exception { mBuffer.append(" bound("); theOp.getArg().visit(this); mBuffer.append(")"); }
/** * Evaluate a {@link Bound} node * @param node the node to evaluate * @param bindings the set of named value bindings * @return {@link BooleanLiteral#TRUE} if the node can be evaluated or {@link BooleanLiteral#FALSE} if an exception occurs * @throws QueryEvaluationException */ private Value evaluate(Bound node, BindingSet bindings) throws QueryEvaluationException { try { evaluate(node.getArg(), bindings); return BooleanLiteral.TRUE; } catch (ValueExprEvaluationException e) { return BooleanLiteral.FALSE; } }
public Value evaluate(Bound node, BindingSet bindings) throws QueryEvaluationException { try { Value argValue = evaluate(node.getArg(), bindings); return BooleanLiteral.valueOf(argValue != null); } catch (ValueExprEvaluationException e) { return BooleanLiteral.FALSE; } }
public Value evaluate(Bound node, BindingSet bindings) throws QueryEvaluationException { try { Value argValue = evaluate(node.getArg(), bindings); return BooleanLiteral.valueOf(argValue != null); } catch (ValueExprEvaluationException e) { return BooleanLiteral.FALSE; } }
@Override public Bound clone() { Bound clone = (Bound)super.clone(); clone.setArg(getArg().clone()); return clone; } }
@Override public Bound clone() { Bound clone = (Bound)super.clone(); clone.setArg(getArg().clone()); return clone; } }
@Override public void meet(Bound bound) { super.meet(bound); if (bound.getArg().hasValue()) { // variable is always bound bound.replaceWith(new ValueConstant(BooleanLiteral.TRUE)); } }
@Override public void meet(Bound node) throws RDFHandlerException { Resource currentSubj = subject; flushPendingStatement(); handler.handleStatement(valueFactory.createStatement(subject, RDF.TYPE, SP.BOUND)); predicate = SP.ARG1_PROPERTY; node.getArg().visit(this); subject = currentSubj; predicate = null; }
@Override public void meet(Bound bound) { super.meet(bound); if (bound.getArg().hasValue()) { // variable is always bound bound.replaceWith(new ValueConstant(BooleanLiteral.TRUE)); } }
Var v = ((Bound) expr).getArg(); Variable var = termFactory.getVariable(v.getName()); return variables.contains(var) ? termFactory.getFunctionIsNotNull(var) : termFactory.getBooleanConstant(false);