Class QueryContext
- java.lang.Object
-
- org.eclipse.rdf4j.query.algebra.evaluation.QueryContext
-
public class QueryContext extends Object
AQueryContext
provides a means to pass arbitrary local state to aFunction
orTupleFunction
. The implementation oforg.eclipse.rdf4j.sail.SailConnection#evaluate()
is responsible for initialising a QueryContext and making it available during evaluation viaQueryContextIteration
. A QueryContext is commonly used to provide aQueryPreparer
for the current SailConnection. This allows, for example, Functions to be written that conveniently express more complex queries.
-
-
Constructor Summary
Constructors Constructor Description QueryContext()
QueryContext(QueryPreparer qp)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description void
begin()
void
end()
<T> T
getAttribute(String name)
static QueryContext
getQueryContext()
QueryPreparer
getQueryPreparer()
void
setAttribute(String name, Object value)
-
-
-
Constructor Detail
-
QueryContext
public QueryContext()
-
QueryContext
public QueryContext(QueryPreparer qp)
-
-
Method Detail
-
getQueryContext
public static QueryContext getQueryContext()
-
begin
public void begin()
-
getQueryPreparer
public QueryPreparer getQueryPreparer()
-
getAttribute
public <T> T getAttribute(String name)
-
end
public void end()
-
-