Expressions { public static Expression<?> bnode() { return function(BNODE); } private  Expressions(); static Expression<?> abs(Number operand); static Expression<?> abs(Operand operand); static Expression<?> bnode(); static Expression<?> bnode(RdfLiteral<?> literal); static Expression<?> bnode(String literal); static Expression<?> bound(Variable var); static Expression<?> ceil(Operand operand); static Expression<?> coalesce(Operand... operands); static Expression<?> concat(Operand... operands); static Expression<?> regex(Operand testString, String pattern); static Expression<?> regex(Operand testString, String pattern, String flags); static Expression<?> regex(Operand testString, Operand pattern); static Expression<?> regex(Operand testString, Operand pattern, Operand flags); static Expression<?> str(Operand operand); static Expression<?> custom(Iri functionIri, Operand... operands); static Expression<?> function(SparqlFunction function, Operand... operands); static Expression<?> not(Operand operand); static Expression<?> plus(Operand operand); static Expression<?> minus(Operand operand); static Expression<?> equals(Operand left, Operand right); static Expression<?> notEquals(Operand left, Operand right); static Expression<?> gt(Number left, Number right); static Expression<?> gt(Number left, Operand right); static Expression<?> gt(Operand left, Number right); static Expression<?> gt(Operand left, Operand right); static Expression<?> gte(Operand left, Operand right); static Expression<?> lt(Number left, Number right); static Expression<?> lt(Number left, Operand right); static Expression<?> lt(Operand left, Number right); static Expression<?> lt(Operand left, Operand right); static Expression<?> lte(Operand left, Operand right); static Expression<?> and(Operand... operands); static Expression<?> or(Operand... operands); static Expression<?> add(Operand... operands); static Expression<?> subtract(Operand... operands); static Expression<?> multiply(Operand... operands); static Expression<?> divide(Operand... operands); static Aggregate avg(Operand operand); static Aggregate count(Operand operand); static Aggregate countAll(); static Aggregate group_concat(Operand... operands); static Aggregate group_concat(String separator, Operand... operands); static Aggregate max(Operand operand); static Aggregate min(Operand operand); static Aggregate sample(Operand operand); static Aggregate sum(Operand operand);  }
@Test public void bnodeProducesProperQueryString() { Expression<?> expression = Expressions.bnode("name"); assertEquals("BNODE( \"name\" )", expression.getQueryString()); }
@Test public void bnodeNoArgumentProducesProperQueryString() { Expression<?> expression = Expressions.bnode(); assertEquals("BNODE()", expression.getQueryString()); }