diff options
author | Sam Thursfield <ssssam@gmail.com> | 2016-03-27 00:15:33 +0000 |
---|---|---|
committer | Sam Thursfield <sam@afuera.me.uk> | 2016-07-14 13:20:48 +0100 |
commit | 8cc026da8cdebba4d5b17ed23841ec59d79f60e3 (patch) | |
tree | eb5af6ba2150d6dcd86a70582ab736c9eb48b3ce /tests/libtracker-sparql/tracker-test.c | |
parent | 032e2a7ed874bacce4ca5f0dd9ddbad6ab8f5f81 (diff) | |
download | tracker-wip/sam/resource-rebase-6.tar.gz |
Use TrackerResource instead of TrackerSparqlBuilder in all extractorswip/sam/resource-rebase-6
For a long time, all the Tracker extractors have manually constructed a
SPARQL update command using TrackerSparqlBuilder to represent their
output. This commit changes all of them to use the TrackerResource
class instead, which makes the code a lot more concise and readable.
This introduces some API breaks in the internal libtracker-extract
library. This has been a private library since Tracker 0.16 or earlier,
so it's fine.
If the extractors only output SPARQL then they are only useful to
people who are using a SPARQL store. Now we can output a serialization
format like Turtle as well. This will hopefully make the extract modules
useful outside of Tracker itself.
I've tried to preserve the behaviour of the extractors as much as
possible, but there are two things that are now handled differently:
* nao:Tag resources are given a fixed URI based on the tag label, such
as <urn:tag:My_Tag>. Previously they were inserted as blank nodes,
so tracker-store would give them unique IDs like <urn:uuid:1234...>
* All extractors created nco:Contact resources for content publishers,
but previously some would assign fixed URIs based on the name
<urn:contact:James%20Joyce>, while others would insert them as blank
nodes so they would be assigned unique IDs like <urn:uuid:1234...>.
Now, all extractors create nco:Contact resources with fixed URIs
based on the content creator's name.
https://bugzilla.gnome.org/show_bug.cgi?id=767472
Diffstat (limited to 'tests/libtracker-sparql/tracker-test.c')
0 files changed, 0 insertions, 0 deletions