if (!supportsSPARQL11) return null;
query = preProcessQuery(query, resourceURI);
ResultSet rs = execQuerySelect(query);
Map<Property, Integer> results = new HashMap<Property, Integer>();
while (rs.hasNext()) {
QuerySolution solution = rs.next();
if (!solution.contains("p") || !solution.contains("count")) continue;
Resource p = solution.get("p").asResource();
int count = solution.get("count").asLiteral().getInt();
results.put(ResourceFactory.createProperty(p.getURI()), count);
}
return results;
}