|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.openrdf.repository.sparql.query.SPARQLQuery
public abstract class SPARQLQuery
Provides an execution thread for background result parsing and inlines binding in a SPARQL query.
| Constructor Summary | |
|---|---|
SPARQLQuery(org.apache.commons.httpclient.HttpClient client,
String url,
String base,
String query)
|
|
| Method Summary | |
|---|---|
void |
clearBindings()
Removes all previously set bindings. |
protected void |
execute(Runnable command)
|
protected abstract String |
getAccept()
|
protected Set<String> |
getBindingNames()
|
BindingSet |
getBindings()
Retrieves the bindings that have been set on this operation. |
Dataset |
getDataset()
Gets the dataset that has been set using Operation.setDataset(Dataset), if
any. |
boolean |
getIncludeInferred()
Returns whether or not this operation will return inferred statements (if any are present in the repository). |
int |
getMaxQueryTime()
Returns the maximum query evaluation time. |
protected org.apache.commons.httpclient.HttpMethodBase |
getResponse()
|
String |
getUrl()
|
void |
removeBinding(String name)
Removes a previously set binding on the supplied variable. |
void |
setBinding(String name,
Value value)
Binds the specified variable to the supplied value. |
void |
setDataset(Dataset dataset)
Specifies the dataset against which to execute an operation, overriding any dataset that is specified in the operation itself. |
void |
setIncludeInferred(boolean inf)
Determine whether evaluation results of this operation should include inferred statements (if any inferred statements are present in the repository). |
void |
setMaxQueryTime(int maxQueryTime)
Specifies the maximum time that a query is allowed to run. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public SPARQLQuery(org.apache.commons.httpclient.HttpClient client,
String url,
String base,
String query)
| Method Detail |
|---|
public BindingSet getBindings()
Operation
getBindings in interface OperationOperation.setBinding(String, Value)public Dataset getDataset()
OperationOperation.setDataset(Dataset), if
any.
getDataset in interface Operationpublic boolean getIncludeInferred()
Operation
getIncludeInferred in interface Operationpublic int getMaxQueryTime()
Query
getMaxQueryTime in interface QueryQuery.setMaxQueryTime(int)public void removeBinding(String name)
Operation
removeBinding in interface Operationname - The name of the variable from which the binding is to be removed.
public void setBinding(String name,
Value value)
Operation
setBinding in interface Operationname - The name of the variable that should be bound.value - The (new) value for the specified variable.public void clearBindings()
Operation
clearBindings in interface Operationpublic void setDataset(Dataset dataset)
Operation
setDataset in interface Operationpublic void setIncludeInferred(boolean inf)
Operation
setIncludeInferred in interface Operationinf - indicates whether inferred statements should be included in the
result.public void setMaxQueryTime(int maxQueryTime)
QueryQueryInterruptedExceptions.
setMaxQueryTime in interface QuerymaxQueryTime - The maximum query time, measured in seconds. A negative or zero
value indicates an unlimited query time (which is the default).public String getUrl()
protected org.apache.commons.httpclient.HttpMethodBase getResponse()
throws org.apache.commons.httpclient.HttpException,
IOException,
QueryEvaluationException
org.apache.commons.httpclient.HttpException
IOException
QueryEvaluationExceptionprotected void execute(Runnable command)
protected Set<String> getBindingNames()
protected abstract String getAccept()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||