use of org.apache.jena.sparql.expr.Expr in project jena by apache.
the class ExprFactoryTest method callTest_dynamic.
@Test
public void callTest_dynamic() {
Expr e = factory.call(factory.none(), factory.list());
assertTrue(e instanceof E_FunctionDynamic);
}
use of org.apache.jena.sparql.expr.Expr in project jena by apache.
the class ExprFactoryTest method langMatchesTest.
@Test
public void langMatchesTest() {
Expr e = factory.langMatches(factory.none(), factory.none());
assertTrue(e instanceof E_LangMatches);
}
use of org.apache.jena.sparql.expr.Expr in project jena by apache.
the class ExprFactoryTest method coalesceTest.
@Test
public void coalesceTest() {
Expr e = factory.coalesce(factory.list());
assertTrue(e instanceof E_Coalesce);
}
use of org.apache.jena.sparql.expr.Expr in project jena by apache.
the class QueryTransformOps method transformExprList.
// ** Mutates the List
private static void transformExprList(List<Expr> exprList, ExprTransform exprTransform) {
for (int i = 0; i < exprList.size(); i++) {
Expr e1 = exprList.get(0);
Expr e2 = ExprTransformer.transform(exprTransform, e1);
if (e2 == null || e2 == e1)
continue;
exprList.set(i, e2);
}
}
use of org.apache.jena.sparql.expr.Expr in project jena by apache.
the class QueryTransformOps method transformSortConditions.
private static void transformSortConditions(List<SortCondition> conditions, ExprTransform exprTransform) {
for (int i = 0; i < conditions.size(); i++) {
SortCondition s1 = conditions.get(i);
Expr e = ExprTransformer.transform(exprTransform, s1.expression);
if (e == null || s1.expression.equals(e))
continue;
conditions.set(i, new SortCondition(e, s1.direction));
}
}
Aggregations