org.openrdf.repository.sparql.query
Class SPARQLQuery

java.lang.Object
  extended by org.openrdf.repository.sparql.query.SPARQLQuery
All Implemented Interfaces:
Query
Direct Known Subclasses:
SPARQLBooleanQuery, SPARQLGraphQuery, SPARQLTupleQuery

public abstract class SPARQLQuery
extends Object
implements Query

Provides an execution thread for background result parsing and inlines binding in a SPARQL query.

Author:
James Leigh

Constructor Summary
SPARQLQuery(org.apache.commons.httpclient.HttpClient client, String url, String query)
           
 
Method Summary
protected  void execute(Runnable command)
           
protected abstract  String getAccept()
           
protected  Set<String> getBindingNames()
           
 BindingSet getBindings()
           
 Dataset getDataset()
           
 boolean getIncludeInferred()
           
 int getMaxQueryTime()
           
protected  org.apache.commons.httpclient.HttpMethodBase getResponse()
           
 String getUrl()
           
 void removeBinding(String name)
           
 void setBinding(String name, Value value)
           
 void setDataset(Dataset dataset)
           
 void setIncludeInferred(boolean inf)
           
 void setMaxQueryTime(int maxQueryTime)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

SPARQLQuery

public SPARQLQuery(org.apache.commons.httpclient.HttpClient client,
                   String url,
                   String query)
Method Detail

getBindings

public BindingSet getBindings()
Specified by:
getBindings in interface Query

getDataset

public Dataset getDataset()
Specified by:
getDataset in interface Query

getIncludeInferred

public boolean getIncludeInferred()
Specified by:
getIncludeInferred in interface Query

getMaxQueryTime

public int getMaxQueryTime()
Specified by:
getMaxQueryTime in interface Query

removeBinding

public void removeBinding(String name)
Specified by:
removeBinding in interface Query

setBinding

public void setBinding(String name,
                       Value value)
Specified by:
setBinding in interface Query

setDataset

public void setDataset(Dataset dataset)
Specified by:
setDataset in interface Query

setIncludeInferred

public void setIncludeInferred(boolean inf)
Specified by:
setIncludeInferred in interface Query

setMaxQueryTime

public void setMaxQueryTime(int maxQueryTime)
Specified by:
setMaxQueryTime in interface Query

getUrl

public String getUrl()

getResponse

protected org.apache.commons.httpclient.HttpMethodBase getResponse()
                                                            throws org.apache.commons.httpclient.HttpException,
                                                                   IOException,
                                                                   QueryEvaluationException
Throws:
org.apache.commons.httpclient.HttpException
IOException
QueryEvaluationException

execute

protected void execute(Runnable command)

getBindingNames

protected Set<String> getBindingNames()

getAccept

protected abstract String getAccept()


Copyright © 2004-2009 James Leigh Services Inc.. All Rights Reserved.