Class TupleExprs
- java.lang.Object
-
- org.eclipse.rdf4j.query.algebra.helpers.TupleExprs
-
-
Constructor Summary
Constructors Constructor Description TupleExprs()
-
Method Summary
All Methods Static Methods Concrete Methods Deprecated Methods Modifier and Type Method Description static boolean
containsExtension(TupleExpr t)
static boolean
containsProjection(TupleExpr t)
Deprecated.UsecontainsSubquery(TupleExpr)
instead.static boolean
containsSubquery(TupleExpr t)
Verifies if the suppliedTupleExpr
contains aProjection
with the subquery flag set to true (default).static Var
createConstVar(Value value)
Creates an (anonymous) Var representing a constant value.static List<TupleExpr>
getChildren(TupleExpr t)
ReturnsTupleExpr
children of the given node.static String
getConstVarName(Value value)
static boolean
isFilterExistsFunction(TupleExpr expr)
Verifies if the supplied expression is a FILTER (NOT) EXISTS operationstatic boolean
isGraphPatternGroup(TupleExpr expr)
Deprecated.UseisVariableScopeChange(TupleExpr)
instead.static boolean
isVariableScopeChange(TupleExpr expr)
Verifies if the suppliedTupleExpr
represents a variable scope change.
-
-
-
Method Detail
-
containsSubquery
public static boolean containsSubquery(TupleExpr t)
Verifies if the suppliedTupleExpr
contains aProjection
with the subquery flag set to true (default). If the supplied TupleExpr is aJoin
or contains aJoin
, projections inside that Join's arguments will not be taken into account.- Parameters:
t
- a tuple expression.- Returns:
true
if the TupleExpr contains a subquery projection (outside of a Join),false
otherwise.
-
containsExtension
public static boolean containsExtension(TupleExpr t)
Verifies if the suppliedTupleExpr
contains aExtension
. If the supplied TupleExpr is aJoin
or contains aJoin
, aService
clause or a subquery element, extensions inside that element's argument will not be taken into account.- Parameters:
t
- a tuple expression.- Returns:
true
if the TupleExpr contains an Extension (outside of a Join, Service clause, or subquery),false
otherwise.
-
isVariableScopeChange
public static boolean isVariableScopeChange(TupleExpr expr)
Verifies if the suppliedTupleExpr
represents a variable scope change.- Parameters:
expr
- aTupleExpr
- Returns:
true
if theTupleExpr
implementsVariableScopeChange
and has its scope change flag set totrue
,false
otherwise.
-
isGraphPatternGroup
@Deprecated(since="3.2") public static boolean isGraphPatternGroup(TupleExpr expr)
Deprecated.UseisVariableScopeChange(TupleExpr)
instead.Verifies if the suppliedTupleExpr
represents a group graph pattern.- Parameters:
expr
- aTupleExpr
- Returns:
true
if theTupleExpr
isGraphPatternGroupable
and has its graph pattern group flag set totrue
,false
otherwise.
-
containsProjection
@Deprecated(since="2.0") public static boolean containsProjection(TupleExpr t)
Deprecated.UsecontainsSubquery(TupleExpr)
instead.Verifies if the suppliedTupleExpr
contains aProjection
. If the supplied TupleExpr is aJoin
or contains aJoin
, projections inside that Join's arguments will not be taken into account.- Parameters:
t
- a tuple expression.- Returns:
true
if the TupleExpr contains a projection (outside of a Join),false
otherwise.
-
getChildren
public static List<TupleExpr> getChildren(TupleExpr t)
ReturnsTupleExpr
children of the given node.- Parameters:
t
- a tuple expression.- Returns:
- a list of TupleExpr children.
-
createConstVar
public static Var createConstVar(Value value)
Creates an (anonymous) Var representing a constant value. The variable name will be derived from the actual value to guarantee uniqueness.- Parameters:
value
-- Returns:
- an (anonymous) Var representing a constant value.
-
isFilterExistsFunction
public static boolean isFilterExistsFunction(TupleExpr expr)
Verifies if the supplied expression is a FILTER (NOT) EXISTS operation- Parameters:
expr
- a tuple expression- Returns:
- true if the supplied expression is a FILTER (NOT) EXISTS operation, false otherwise.
-
-