| Re: [higgins-dev] [IdAS] filter language: XPath/SPARQL |
SPARQL is meant to describe a query over an RDF graph, so you might get several results back
-----
Question 1: Is the filter expression intended to apply to (a) the entire Context (i.e., the result of the filter should be the set of DigitalSubjects that match), or (b) to a DigitalSubject (i.e., look at
each DigSub and add it to the list if the filter is true)?
<skip>
I assume (a) (sort of), and that there is the capability in the filter of narrowing the result set to only DigitalSubjects. I wouldn't expect callers of getSubjects to have to add that to the filter though. I assume the implementation would auto-add that (since the name of the API implies that only subjects will be returned). So really, this is like (b), but the provider's implementation details are different (provider adds in a filter predicate to only allow DS's).
I don't know enough about SPARQL to know why (b) prevents ordering. My
guess is that at this point, you're the SPARQL expert, so you'll have to
clue us in on the particulars of the problems you see.
<skip>----- Question 2: Is there a canonical RDF/XML representation...
OK, something like ".[type=... or @type=...]".Another case is the representation of type. In Paul's example, we say
that urn:jim-sermersheim is a Person as follows:
<rdf:Description rdf:about="urn:jim-sermersheim"> ... <rdf:type> <rdf:Description rdf:about="&jim;Person> </rdf:type> </rdf:Description>
But in the Primer, they tend to use the following:
<rdf:Description rdf:about="urn:jim-sermersheim"> ... <rdf:type rdf:resource="http://www.novell.com/jim#Person" /> </rdf:Description>
In one case the type is an element, and in the other it's an attribute. How would you use XPath in this case?
Assuming there's no canonical representation, one would have to OR the
two filters which match for those two examples.
While that solves this postalAddress problem, would you somehow force providers to-----<skip>
Question 3: In the example, hasPostalAddress is a separate object.
XPath doesn't let us do this (effectively dereference a pointer to
another element) -- this is what prompted me to ask #3 (alternate
representations) in
http://dev.eclipse.org/mhonarc/lists/higgins-dev/msg00583.html
...Greg