public class QueryInfo extends Object
Modifier and Type | Field and Description |
---|---|
protected boolean |
done |
protected static AtomicInteger |
NEXT_QUERY_ID |
protected Set<ParallelTask<?>> |
scheduledSubtasks |
Constructor and Description |
---|
QueryInfo(Resource subj,
IRI pred,
Value obj,
boolean includeInferred,
FederationContext federationContext,
Dataset dataset) |
QueryInfo(String query,
QueryType queryType,
boolean incluedInferred,
FederationContext federationContext,
Dataset dataset) |
QueryInfo(String query,
String baseURI,
QueryType queryType,
int maxExecutionTime,
boolean includeInferred,
FederationContext federationContext,
Dataset dataset) |
Modifier and Type | Method and Description |
---|---|
void |
abort()
Mark the query as aborted and abort all scheduled (future) tasks known at this point in time.
|
protected void |
abortScheduledTasks()
Abort any scheduled future tasks
|
void |
close()
Close this query.
|
boolean |
equals(Object obj) |
String |
getBaseURI() |
Dataset |
getDataset() |
FederationContext |
getFederationContext() |
boolean |
getIncludeInferred() |
long |
getMaxRemainingTimeMS() |
String |
getQuery() |
BigInteger |
getQueryID() |
QueryType |
getQueryType() |
Optional<TupleQueryResultHandler> |
getResultHandler()
Returns a
TupleQueryResultHandler if this query is executed using. |
int |
hashCode() |
void |
registerScheduledTask(ParallelTask<?> task)
Register a new scheduled task for this query.
|
void |
setResultHandler(TupleQueryResultHandler resultHandler)
Set the
TupleQueryResultHandler if the query is executed using
TupleQuery.evaluate(TupleQueryResultHandler) allowing for passing through results to the handler. |
protected static final AtomicInteger NEXT_QUERY_ID
protected boolean done
protected Set<ParallelTask<?>> scheduledSubtasks
public QueryInfo(String query, QueryType queryType, boolean incluedInferred, FederationContext federationContext, Dataset dataset)
public QueryInfo(String query, String baseURI, QueryType queryType, int maxExecutionTime, boolean includeInferred, FederationContext federationContext, Dataset dataset)
query
- queryType
- maxExecutionTime
- the maximum explicit query time in seconds, if 0 use
FedXConfig.getEnforceMaxQueryTime()
includeInferred
- whether to include inferred statementsfederationContext
- the FederationContext
dataset
- the Dataset
public QueryInfo(Resource subj, IRI pred, Value obj, boolean includeInferred, FederationContext federationContext, Dataset dataset)
public BigInteger getQueryID()
public String getQuery()
public QueryType getQueryType()
public boolean getIncludeInferred()
public Dataset getDataset()
public String getBaseURI()
public FederationContext getFederationContext()
FederationContext
in which this query is executedpublic long getMaxRemainingTimeMS()
public void registerScheduledTask(ParallelTask<?> task) throws QueryEvaluationException
task
- QueryEvaluationException
- if the query has been aborted or closedpublic Optional<TupleQueryResultHandler> getResultHandler()
TupleQueryResultHandler
if this query is executed using.
TupleQuery.evaluate(TupleQueryResultHandler)
.TupleQueryResultHandler
that can be used for pass throughPassThroughTupleExpr
public void setResultHandler(TupleQueryResultHandler resultHandler)
TupleQueryResultHandler
if the query is executed using
TupleQuery.evaluate(TupleQueryResultHandler)
allowing for passing through results to the handler.resultHandler
- the TupleQueryResultHandler
public void abort()
public void close()
protected void abortScheduledTasks()
Copyright © 2015-2022 Eclipse Foundation. All Rights Reserved.