GeoPubby  Version 0.1.0.0
RemoteSPARQLDataSource Class Reference

A data source backed by a SPARQL endpoint accessed through the SPARQL protocol. More...

Inheritance diagram for RemoteSPARQLDataSource:
Collaboration diagram for RemoteSPARQLDataSource:

Public Member Functions

 RemoteSPARQLDataSource (String endpointURL, String defaultGraphURI)
 
 RemoteSPARQLDataSource (String endpointURL, String defaultGraphURI, boolean supportsSPARQL11, Set< String > resourceQueries, Set< String > propertyQueries, Set< String > inversePropertyQueries, Set< String > anonPropertyQueries, Set< String > anonInversePropertyQueries, CachedPropertyCollection highIndegreeProperties, CachedPropertyCollection highOutdegreeProperties)
 
void setGraphContentType (String mediaType)
 Sets the content type to ask for in graph requests (CONSTRUCT and DESCRIBE) to the remote SPARQL endpoint. More...
 
void addGraphQueryParam (String param)
 
void addSelectQueryParam (String param)
 
boolean canDescribe (String absoluteIRI)
 Indicates whether this data source may have some information about a given IRI. More...
 
Model describeResource (String resourceURI)
 Returns a subgraph of the data source describing one resource. More...
 
Map< Property, Integer > getHighIndegreeProperties (String resourceURI)
 If describeResource(String) omits properties of high indegree, then those properties must be returned here with the count of arcs. More...
 
Map< Property, Integer > getHighOutdegreeProperties (String resourceURI)
 If describeResource(String) omits properties of high outdegree, then those properties must be returned here with the count of arcs. More...
 
Model listPropertyValues (String resourceURI, Property property, boolean isInverse)
 Returns a subgraph of the data source. More...
 
List< Resource > getIndex ()
 A list of IRI resources described in this data source. More...
 
AutocompleteEngine< SearchRecordgetLabelIndex ()
 
String getPreviousDescribeQuery ()
 
Model describeResource (String absoluteIRI, String language)
 Returns a subgraph of the data source describing one resource. More...
 

Public Attributes

final String endpointURL
 

Static Public Attributes

static final int MAX_INDEX_SIZE = 1000000
 

Package Attributes

QueryEngineHTTP endpoint
 

Private Member Functions

String[] parseQueryParam (String param)
 
Map< Property, Integer > getHighDegreeProperties (String query, String resourceURI)
 
Model execQueryGraph (String query)
 
ResultSet execQuerySelect (String query)
 
String preProcessQuery (String query, String resourceURI)
 
String preProcessQuery (String query, String resourceURI, Property property)
 
String replaceString (String text, String searchString, String replacement)
 
String toSPARQLArgumentList (Collection<? extends RDFNode > values)
 

Private Attributes

final String defaultGraphURI
 
final boolean supportsSPARQL11
 
final Set< String > resourceQueries
 
final Set< String > propertyQueries
 
final Set< String > inversePropertyQueries
 
final Set< String > anonPropertyQueries
 
final Set< String > anonInversePropertyQueries
 
final CachedPropertyCollection highIndegreeProperties
 
final CachedPropertyCollection highOutdegreeProperties
 
String previousDescribeQuery
 
String contentType = null
 
final Set< String[]> queryParamsSelect = new HashSet<String[]>()
 
final Set< String[]> queryParamsGraph = new HashSet<String[]>()
 
AutocompleteEngine< SearchRecordengine
 
Pattern queryParamPattern = Pattern.compile("(.*?)=(.*)")
 

Detailed Description

A data source backed by a SPARQL endpoint accessed through the SPARQL protocol.

Constructor & Destructor Documentation

◆ RemoteSPARQLDataSource() [1/2]

RemoteSPARQLDataSource ( String  endpointURL,
String  defaultGraphURI 
)
69  {
70  this(endpointURL, defaultGraphURI, false, null, null, null, null, null, null, null);
71  }
final String defaultGraphURI
Definition: RemoteSPARQLDataSource.java:49
final String endpointURL
Definition: RemoteSPARQLDataSource.java:48

References RemoteSPARQLDataSource.defaultGraphURI, and RemoteSPARQLDataSource.endpointURL.

◆ RemoteSPARQLDataSource() [2/2]

RemoteSPARQLDataSource ( String  endpointURL,
String  defaultGraphURI,
boolean  supportsSPARQL11,
Set< String >  resourceQueries,
Set< String >  propertyQueries,
Set< String >  inversePropertyQueries,
Set< String >  anonPropertyQueries,
Set< String >  anonInversePropertyQueries,
CachedPropertyCollection  highIndegreeProperties,
CachedPropertyCollection  highOutdegreeProperties 
)
78  {
79  this.endpointURL = endpointURL;
82  if (resourceQueries == null || resourceQueries.isEmpty()) {
84  new HashSet<String>(Arrays.asList(new String[]{
85  "CONSTRUCT {?__this__ ?p ?o} WHERE {?__this__ ?p ?o. FILTER (?p NOT IN ?__high_outdegree_properties__)}",
86  "CONSTRUCT {?s ?p ?__this__} WHERE {?s ?p ?__this__. FILTER (?p NOT IN ?__high_indegree_properties__)}"
87  })) :
88  Collections.singleton("DESCRIBE ?__this__");
89  }
90  if (propertyQueries == null || propertyQueries.isEmpty()) {
91  propertyQueries = Collections.singleton(
92  "CONSTRUCT {?__this__ ?__property__ ?x} WHERE {?__this__ ?__property__ ?x. FILTER (!isBlank(?x))}");
93  }
94  if (inversePropertyQueries == null || inversePropertyQueries.isEmpty()) {
95  inversePropertyQueries = Collections.singleton(
96  "CONSTRUCT {?x ?__property__ ?__this__} WHERE {?x ?__property__ ?__this__. FILTER (!isBlank(?x))}");
97  }
98  if (anonPropertyQueries == null || anonPropertyQueries.isEmpty()) {
99  anonPropertyQueries = Collections.singleton(
100  "DESCRIBE ?x WHERE {?__this__ ?__property__ ?x. FILTER (isBlank(?x))}");
101  }
102  if (anonInversePropertyQueries == null || anonInversePropertyQueries.isEmpty()) {
103  anonInversePropertyQueries = Collections.singleton(
104  "DESCRIBE ?x WHERE {?x ?__property__ ?__this__. FILTER (isBlank(?x))}");
105  }
111 
114  }
final Set< String > anonInversePropertyQueries
Definition: RemoteSPARQLDataSource.java:58
final boolean supportsSPARQL11
Definition: RemoteSPARQLDataSource.java:50
final CachedPropertyCollection highOutdegreeProperties
Definition: RemoteSPARQLDataSource.java:61
final Set< String > inversePropertyQueries
Definition: RemoteSPARQLDataSource.java:56
final CachedPropertyCollection highIndegreeProperties
Definition: RemoteSPARQLDataSource.java:60
final Set< String > anonPropertyQueries
Definition: RemoteSPARQLDataSource.java:57
final Set< String > propertyQueries
Definition: RemoteSPARQLDataSource.java:55
final Set< String > resourceQueries
Definition: RemoteSPARQLDataSource.java:54

References RemoteSPARQLDataSource.anonInversePropertyQueries, RemoteSPARQLDataSource.anonPropertyQueries, RemoteSPARQLDataSource.defaultGraphURI, RemoteSPARQLDataSource.endpointURL, RemoteSPARQLDataSource.highIndegreeProperties, RemoteSPARQLDataSource.highOutdegreeProperties, RemoteSPARQLDataSource.inversePropertyQueries, RemoteSPARQLDataSource.propertyQueries, RemoteSPARQLDataSource.resourceQueries, and RemoteSPARQLDataSource.supportsSPARQL11.

Member Function Documentation

◆ addGraphQueryParam()

void addGraphQueryParam ( String  param)
124  {
125  queryParamsGraph.add(parseQueryParam(param));
126  }
final Set< String[]> queryParamsGraph
Definition: RemoteSPARQLDataSource.java:66
String[] parseQueryParam(String param)
Definition: RemoteSPARQLDataSource.java:132

References RemoteSPARQLDataSource.parseQueryParam(), and RemoteSPARQLDataSource.queryParamsGraph.

Referenced by Dataset.buildDataSource().

◆ addSelectQueryParam()

void addSelectQueryParam ( String  param)
128  {
130  }
final Set< String[]> queryParamsSelect
Definition: RemoteSPARQLDataSource.java:65

References RemoteSPARQLDataSource.parseQueryParam(), and RemoteSPARQLDataSource.queryParamsSelect.

Referenced by Dataset.buildDataSource().

◆ canDescribe()

boolean canDescribe ( String  absoluteIRI)

Indicates whether this data source may have some information about a given IRI.

If this is false, a client should not bother to call describeResource(String). This method is to allow for optimizations and should respond very fast.

It is also used by the UI to decide whether a click on a resource should go to a Pubby page (if true) or out to the Web (if false).

Parameters
absoluteIRIThe IRI of a resource to be described
Returns
true if this data source might have something about it

Implements DataSource.

144  {
145  return true;
146  }

◆ describeResource() [1/2]

Model describeResource ( String  absoluteIRI,
String  language 
)

Returns a subgraph of the data source describing one resource.

This should include both incoming and outgoing triples. However, it should exclude outgoing arcs where the property is a high-outdegree property, and it should exclude incoming arcs where the property is a high-indegree property. If labels for other resources are included in the result, then they will be used.

Parameters
absoluteIRIThe IRI of the resource to be described
Returns
A subgraph of the data source describing the resource.

Implements DataSource.

403  {
404  // TODO Auto-generated method stub
405  return null;
406  }

◆ describeResource() [2/2]

Model describeResource ( String  absoluteIRI)

Returns a subgraph of the data source describing one resource.

This should include both incoming and outgoing triples. However, it should exclude outgoing arcs where the property is a high-outdegree property, and it should exclude incoming arcs where the property is a high-indegree property. If labels for other resources are included in the result, then they will be used.

Parameters
absoluteIRIThe IRI of the resource to be described
Returns
A subgraph of the data source describing the resource.

Implements DataSource.

149  {
150  // Loop over resource description queries, join results in a single model.
151  // Process each query to replace place-holders of the given resource.
152  Model model = ModelFactory.createDefaultModel();
153  for (String query: resourceQueries) {
154  Model result = execQueryGraph(preProcessQuery(query, resourceURI));
155  model.add(result);
156  model.setNsPrefixes(result);
157  }
158  return model;
159  }
String preProcessQuery(String query, String resourceURI)
Definition: RemoteSPARQLDataSource.java:344
Model execQueryGraph(String query)
Definition: RemoteSPARQLDataSource.java:277

References RemoteSPARQLDataSource.execQueryGraph(), RemoteSPARQLDataSource.preProcessQuery(), and RemoteSPARQLDataSource.resourceQueries.

◆ execQueryGraph()

Model execQueryGraph ( String  query)
private
277  {
278  Model model = ModelFactory.createDefaultModel();
279  previousDescribeQuery = query;
280 
281  // Since we don't know the exact query type (e.g. DESCRIBE or CONSTRUCT),
282  // and com.hp.hpl.jena.query.QueryFactory could throw exceptions on
283  // vendor-specific sections of the query, we use the lower-level
284  // com.hp.hpl.jena.sparql.engine.http.HttpQuery to execute the query and
285  // read the results into model.
286 
287  HttpQuery httpQuery = new HttpQuery(endpointURL);
288  httpQuery.addParam("query", query);
289  if (defaultGraphURI != null) {
290  httpQuery.addParam("default-graph-uri", defaultGraphURI);
291  }
292  for (String[] param: queryParamsGraph) {
293  httpQuery.addParam(param[0], param[1]);
294  }
295 
296  // The rest is more or less a copy of QueryEngineHTTP.execModel()
297  httpQuery.setAccept(contentType);
298  InputStream in = httpQuery.exec();
299 
300  // Don't assume the endpoint actually gives back the content type we
301  // asked for
302  String actualContentType = httpQuery.getContentType();
303 
304  // If the server fails to return a Content-Type then we will assume
305  // the server returned the type we asked for
306  if (actualContentType == null || actualContentType.equals("")) {
307  actualContentType = contentType;
308  }
309 
310  // Try to select language appropriately here based on the model content
311  // type
312  Lang lang = WebContent.contentTypeToLangResultSet(actualContentType);
313  if (!RDFLanguages.isTriples(lang))
314  throw new QueryException("Endpoint <" + endpointURL +
315  "> returned Content Type: " + actualContentType
316  + " which is not a supported RDF graph syntax");
317  RDFDataMgr.read(model, in, lang);
318 
319  // Skip prefixes ns1, ns2, etc, which are usually
320  // auto-assigned by the endpoint and do more harm than good
321  for (String prefix: model.getNsPrefixMap().keySet()) {
322  if (prefix.matches("^ns[0-9]+$")) {
323  model.removeNsPrefix(prefix);
324  }
325  }
326 
327  return model;
328  }
String contentType
Definition: RemoteSPARQLDataSource.java:64
String previousDescribeQuery
Definition: RemoteSPARQLDataSource.java:63

References RemoteSPARQLDataSource.contentType, RemoteSPARQLDataSource.defaultGraphURI, RemoteSPARQLDataSource.endpointURL, RemoteSPARQLDataSource.previousDescribeQuery, and RemoteSPARQLDataSource.queryParamsGraph.

Referenced by RemoteSPARQLDataSource.describeResource(), and RemoteSPARQLDataSource.listPropertyValues().

◆ execQuerySelect()

ResultSet execQuerySelect ( String  query)
private
330  {
331  if(this.endpoint!=null && !this.endpoint.isClosed()) {
332  this.endpoint.close();
333  }
334  this.endpoint = new QueryEngineHTTP(endpointURL, query);
335  if (defaultGraphURI != null) {
336  endpoint.setDefaultGraphURIs(Collections.singletonList(defaultGraphURI));
337  }
338  for (String[] param: queryParamsSelect) {
339  endpoint.addParam(param[0], param[1]);
340  }
341  return endpoint.execSelect();
342  }
QueryEngineHTTP endpoint
Definition: RemoteSPARQLDataSource.java:52

References RemoteSPARQLDataSource.defaultGraphURI, RemoteSPARQLDataSource.endpoint, RemoteSPARQLDataSource.endpointURL, and RemoteSPARQLDataSource.queryParamsSelect.

Referenced by RemoteSPARQLDataSource.getHighDegreeProperties(), RemoteSPARQLDataSource.getIndex(), and RemoteSPARQLDataSource.getLabelIndex().

◆ getHighDegreeProperties()

Map<Property, Integer> getHighDegreeProperties ( String  query,
String  resourceURI 
)
private
186  {
187  if (!supportsSPARQL11) return null;
188  query = preProcessQuery(query, resourceURI);
189  ResultSet rs = execQuerySelect(query);
190  Map<Property, Integer> results = new HashMap<Property, Integer>();
191  while (rs.hasNext()) {
192  QuerySolution solution = rs.next();
193  if (!solution.contains("p") || !solution.contains("count")) continue;
194  Resource p = solution.get("p").asResource();
195  int count = solution.get("count").asLiteral().getInt();
196  results.put(ResourceFactory.createProperty(p.getURI()), count);
197  }
198  return results;
199  }
ResultSet execQuerySelect(String query)
Definition: RemoteSPARQLDataSource.java:330

References RemoteSPARQLDataSource.execQuerySelect(), RemoteSPARQLDataSource.preProcessQuery(), and RemoteSPARQLDataSource.supportsSPARQL11.

Referenced by RemoteSPARQLDataSource.getHighIndegreeProperties(), and RemoteSPARQLDataSource.getHighOutdegreeProperties().

◆ getHighIndegreeProperties()

Map<Property, Integer> getHighIndegreeProperties ( String  resourceIRI)

If describeResource(String) omits properties of high indegree, then those properties must be returned here with the count of arcs.

If high-indegree properties are not omitted, or the resource doesn't have any, then an empty map or null may be returned. Entries with value 0 will be ignored.

Parameters
resourceIRIThe IRI of the resource to be described
Returns
A map containing high-indegree properties with number of arcs for the resource

Implements DataSource.

162  {
164  "SELECT ?p (COUNT(?s) AS ?count) " +
165  "WHERE { " +
166  " ?s ?p ?__this__. " +
167  " FILTER (?p IN ?__high_indegree_properties__)" +
168  "}" +
169  "GROUP BY ?p",
170  resourceURI);
171  }
Map< Property, Integer > getHighDegreeProperties(String query, String resourceURI)
Definition: RemoteSPARQLDataSource.java:185

References RemoteSPARQLDataSource.getHighDegreeProperties().

◆ getHighOutdegreeProperties()

Map<Property, Integer> getHighOutdegreeProperties ( String  resourceIRI)

If describeResource(String) omits properties of high outdegree, then those properties must be returned here with the count of arcs.

If high-outdegree properties are not omitted, or the resource doesn't have any, then an empty map or null may be returned. Entries with value 0 will be ignored.

Parameters
resourceIRIThe IRI of the resource to be described
Returns
A map containing high-outdegree properties with number of arcs for the resource

Implements DataSource.

174  {
176  "SELECT ?p (COUNT(?o) AS ?count) " +
177  "WHERE { " +
178  " ?__this__ ?p ?o. " +
179  " FILTER (?p IN ?__high_outdegree_properties__)" +
180  "}" +
181  "GROUP BY ?p",
182  resourceURI);
183  }

References RemoteSPARQLDataSource.getHighDegreeProperties().

◆ getIndex()

List<Resource> getIndex ( )

A list of IRI resources described in this data source.

Ordering is implementation-defined. Usually a reasonable limit should be applied to the number of resources returned.

Implements DataSource.

220  {
221  System.out.println("Index SPARQL Query");
222  List<Resource> result = new ArrayList<Resource>();
223  ResultSet rs = execQuerySelect(
224  "SELECT DISTINCT ?s { " +
225  "?s ?p ?o " +
226  "FILTER (isURI(?s)) " +
227  "} LIMIT " + DataSource.MAX_INDEX_SIZE);
228  while (rs.hasNext()) {
229  Resource s=rs.next().getResource("s");
230  //System.out.println("1. "+s.toString());
231  result.add(s);
232  }
233  System.out.println("Attempting second query");
234  if (result.size() < DataSource.MAX_INDEX_SIZE) {
235  rs = execQuerySelect(
236  "SELECT DISTINCT ?o { " +
237  "?s ?p ?o " +
238  "FILTER (isURI(?o)) " +
239  "} LIMIT " + (DataSource.MAX_INDEX_SIZE - result.size()));
240  while (rs.hasNext()) {
241  Resource s=rs.next().getResource("o");
242  //System.out.println("2. "+s.toString());
243  result.add(s);
244  }
245  }
246  System.out.println(result.size()+" - "+result.isEmpty());
247  return result;
248  }

References RemoteSPARQLDataSource.execQuerySelect(), and DataSource.MAX_INDEX_SIZE.

◆ getLabelIndex()

AutocompleteEngine<SearchRecord> getLabelIndex ( )

Implements DataSource.

251  {
252  System.out.println("SPARQL Datasource: Get Label Index!!!!");
253  if(engine==null) {
254  engine=SearchIndexInstance.getInstance();
255  System.out.println("Building Label Index....");
256  ResultSet rs = execQuerySelect(
257  "SELECT DISTINCT ?s ?label WHERE { " +
258  "?s <http://www.w3.org/2000/01/rdf-schema#label> ?label . " +
259  "FILTER (isURI(?s)) " +
260  "} LIMIT " + DataSource.MAX_INDEX_SIZE*6);
261  Integer i=0;
262  while (rs.hasNext()) {
263  i++;
264  QuerySolution st=rs.next();
265  System.out.println(st.getLiteral("label").getString());
266  engine.add(new SearchRecord(st.getLiteral("label").getString(),st.getResource("s")));
267  }
268  System.out.println("Got "+i+" labels!");
269  }
270  return engine;
271  }
AutocompleteEngine< SearchRecord > engine
Definition: RemoteSPARQLDataSource.java:67

References RemoteSPARQLDataSource.engine, RemoteSPARQLDataSource.execQuerySelect(), SearchIndexInstance.getInstance(), and DataSource.MAX_INDEX_SIZE.

◆ getPreviousDescribeQuery()

String getPreviousDescribeQuery ( )

◆ listPropertyValues()

Model listPropertyValues ( String  resourceIRI,
Property  property,
boolean  isInverse 
)

Returns a subgraph of the data source.

It lists the values of a particular property of a particular resource. Where values are blank nodes, a complete description of these anonymous resources must be included.

Parameters
resourceIRIThe resource to be examined
propertyThe property we're interested in
isInverseAre we interested in outgoing arcs (false) or incoming (true)?
Returns
A subgraph of the data source.

Implements DataSource.

203  {
204  // Loop over the queries, join results in a single model.
205  // Process each query to replace place-holders of the given resource and property.
206  List<String> queries = new ArrayList<String>();
207  queries.addAll(isInverse ? inversePropertyQueries : propertyQueries);
208  queries.addAll(isInverse ? anonInversePropertyQueries : anonPropertyQueries);
209  Model model = ModelFactory.createDefaultModel();
210  for (String query: queries) {
211  String preprocessed = preProcessQuery(query, resourceURI, property);
212  Model result = execQueryGraph(preprocessed);
213  model.add(result);
214  model.setNsPrefixes(result);
215  }
216  return model;
217  }

References RemoteSPARQLDataSource.anonInversePropertyQueries, RemoteSPARQLDataSource.anonPropertyQueries, RemoteSPARQLDataSource.execQueryGraph(), RemoteSPARQLDataSource.inversePropertyQueries, RemoteSPARQLDataSource.preProcessQuery(), and RemoteSPARQLDataSource.propertyQueries.

◆ parseQueryParam()

String [] parseQueryParam ( String  param)
private
132  {
133  Matcher match = queryParamPattern.matcher(param);
134  if (!match.matches()) {
135  throw new ConfigurationException("Query parameter \"" + param +
136  "\" is not in \"param=value\" form");
137  }
138  return new String[]{match.group(1), match.group(2)};
139  }
Pattern queryParamPattern
Definition: RemoteSPARQLDataSource.java:141

References RemoteSPARQLDataSource.queryParamPattern.

Referenced by RemoteSPARQLDataSource.addGraphQueryParam(), and RemoteSPARQLDataSource.addSelectQueryParam().

◆ preProcessQuery() [1/2]

String preProcessQuery ( String  query,
String  resourceURI 
)
private

◆ preProcessQuery() [2/2]

String preProcessQuery ( String  query,
String  resourceURI,
Property  property 
)
private
348  {
349  String result = replaceString(query, "?__this__", "<" + resourceURI + ">");
350  if (property != null) {
351  result = replaceString(result, "?__property__", "<" + property.getURI() + ">");
352  }
353  result = replaceString(result, "?__high_indegree_properties__",
355  result = replaceString(result, "?__high_outdegree_properties__",
357  return result;
358  }
String toSPARQLArgumentList(Collection<? extends RDFNode > values)
Definition: RemoteSPARQLDataSource.java:378
String replaceString(String text, String searchString, String replacement)
Definition: RemoteSPARQLDataSource.java:360
Collection< Property > get()
Definition: VocabularyStore.java:133

References VocabularyStore.CachedPropertyCollection.get(), RemoteSPARQLDataSource.highIndegreeProperties, RemoteSPARQLDataSource.highOutdegreeProperties, RemoteSPARQLDataSource.replaceString(), and RemoteSPARQLDataSource.toSPARQLArgumentList().

◆ replaceString()

String replaceString ( String  text,
String  searchString,
String  replacement 
)
private
360  {
361  int start = 0;
362  int end = text.indexOf(searchString, start);
363  if (end == -1) {
364  return text;
365  }
366 
367  int replacementLength = searchString.length();
368  StringBuffer buf = new StringBuffer();
369  while (end != -1) {
370  buf.append(text.substring(start, end)).append(replacement);
371  start = end + replacementLength;
372  end = text.indexOf(searchString, start);
373  }
374  buf.append(text.substring(start));
375  return buf.toString();
376  }

Referenced by RemoteSPARQLDataSource.preProcessQuery().

◆ setGraphContentType()

void setGraphContentType ( String  mediaType)

Sets the content type to ask for in graph requests (CONSTRUCT and DESCRIBE) to the remote SPARQL endpoint.

120  {
121  this.contentType = mediaType;
122  }

Referenced by Dataset.buildDataSource().

◆ toSPARQLArgumentList()

String toSPARQLArgumentList ( Collection<? extends RDFNode >  values)
private
378  {
379  if (values == null) return "()";
380  StringBuilder result = new StringBuilder();
381  result.append('(');
382  boolean isFirst = true;
383  for (RDFNode term: values) {
384  if (!isFirst) {
385  result.append(", ");
386  }
387  if (term.isURIResource()) {
388  result.append('<');
389  result.append(term.asResource().getURI());
390  result.append('>');
391  } else {
392  throw new IllegalArgumentException(
393  "toSPARQLArgumentList is only implemented for URIs; " +
394  "called with term " + term);
395  }
396  isFirst = false;
397  }
398  result.append(')');
399  return result.toString();
400  }

Referenced by RemoteSPARQLDataSource.preProcessQuery().

Member Data Documentation

◆ anonInversePropertyQueries

final Set<String> anonInversePropertyQueries
private

◆ anonPropertyQueries

final Set<String> anonPropertyQueries
private

◆ contentType

String contentType = null
private

◆ defaultGraphURI

◆ endpoint

QueryEngineHTTP endpoint
package

◆ endpointURL

◆ engine

◆ highIndegreeProperties

◆ highOutdegreeProperties

◆ inversePropertyQueries

final Set<String> inversePropertyQueries
private

◆ MAX_INDEX_SIZE

◆ previousDescribeQuery

String previousDescribeQuery
private

◆ propertyQueries

final Set<String> propertyQueries
private

◆ queryParamPattern

Pattern queryParamPattern = Pattern.compile("(.*?)=(.*)")
private

◆ queryParamsGraph

final Set<String[]> queryParamsGraph = new HashSet<String[]>()
private

◆ queryParamsSelect

final Set<String[]> queryParamsSelect = new HashSet<String[]>()
private

◆ resourceQueries

final Set<String> resourceQueries
private

◆ supportsSPARQL11