[tracker/libtracker-sparql-porting: 10/44] tracker-extract: Drop use of libtracker-client function



commit a42fe02e58ebb50796f44ab7ffa5f6b5124d27b2
Author: Jürg Billeter <j bitron ch>
Date:   Tue Jul 20 10:46:40 2010 +0200

    tracker-extract: Drop use of libtracker-client function

 .../libtracker-extract/tracker-extract-mockup.c    |    8 ++++----
 src/tracker-extract/tracker-extract-flac.c         |    4 ++--
 src/tracker-extract/tracker-extract-gif.c          |    6 +++---
 src/tracker-extract/tracker-extract-gstreamer.c    |    8 ++++----
 src/tracker-extract/tracker-extract-jpeg.c         |    8 ++++----
 src/tracker-extract/tracker-extract-libxine.c      |    4 ++--
 src/tracker-extract/tracker-extract-mp3.c          |    8 ++++----
 src/tracker-extract/tracker-extract-mplayer.c      |    2 +-
 src/tracker-extract/tracker-extract-png.c          |    6 +++---
 src/tracker-extract/tracker-extract-tiff.c         |    8 ++++----
 src/tracker-extract/tracker-extract-totem.c        |    4 ++--
 src/tracker-extract/tracker-extract-vorbis.c       |    4 ++--
 12 files changed, 35 insertions(+), 35 deletions(-)
---
diff --git a/examples/libtracker-extract/tracker-extract-mockup.c b/examples/libtracker-extract/tracker-extract-mockup.c
index 38ef50d..18d5c01 100644
--- a/examples/libtracker-extract/tracker-extract-mockup.c
+++ b/examples/libtracker-extract/tracker-extract-mockup.c
@@ -154,7 +154,7 @@ extract_mockup (const gchar          *uri,
 	 *  data objects, for example, an artist which might be used n times)
 	 */
 	if (performer) {
-		performer_uri = tracker_uri_printf_escaped ("urn:artist:%s", performer);
+		performer_uri = tracker_sparql_escape_uri_printf ("urn:artist:%s", performer);
 
 		tracker_sparql_builder_insert_open (preupdate, NULL);
 		tracker_sparql_builder_subject_iri (preupdate, performer_uri);
@@ -168,7 +168,7 @@ extract_mockup (const gchar          *uri,
 	}
 
 	if (composer) {
-		composer_uri = tracker_uri_printf_escaped ("urn:artist:%s", composer);
+		composer_uri = tracker_sparql_escape_uri_printf ("urn:artist:%s", composer);
 
 		tracker_sparql_builder_insert_open (preupdate, NULL);
 		tracker_sparql_builder_subject_iri (preupdate, composer_uri);
@@ -182,7 +182,7 @@ extract_mockup (const gchar          *uri,
 	}
 
 	if (lyricist) {
-		lyricist_uri = tracker_uri_printf_escaped ("urn:artist:%s", lyricist);
+		lyricist_uri = tracker_sparql_escape_uri_printf ("urn:artist:%s", lyricist);
 
 		tracker_sparql_builder_insert_open (preupdate, NULL);
 		tracker_sparql_builder_subject_iri (preupdate, lyricist_uri);
@@ -196,7 +196,7 @@ extract_mockup (const gchar          *uri,
 	}
 
 	if (album) {
-		album_uri = tracker_uri_printf_escaped ("urn:album:%s", album);
+		album_uri = tracker_sparql_escape_uri_printf ("urn:album:%s", album);
 
 		tracker_sparql_builder_insert_open (preupdate, NULL);
 		tracker_sparql_builder_subject_iri (preupdate, album_uri);
diff --git a/src/tracker-extract/tracker-extract-flac.c b/src/tracker-extract/tracker-extract-flac.c
index ca6cfe3..5315d55 100644
--- a/src/tracker-extract/tracker-extract-flac.c
+++ b/src/tracker-extract/tracker-extract-flac.c
@@ -221,7 +221,7 @@ extract_flac (const gchar          *uri,
 	                                  fd.performer);
 
 	if (creator) {
-		artist_uri = tracker_uri_printf_escaped ("urn:artist:%s", creator);
+		artist_uri = tracker_sparql_escape_uri_printf ("urn:artist:%s", creator);
 
 		tracker_sparql_builder_insert_open (preupdate, NULL);
 		tracker_sparql_builder_subject_iri (preupdate, artist_uri);
@@ -233,7 +233,7 @@ extract_flac (const gchar          *uri,
 	}
 
 	if (fd.album) {
-		album_uri = tracker_uri_printf_escaped ("urn:album:%s", fd.album);
+		album_uri = tracker_sparql_escape_uri_printf ("urn:album:%s", fd.album);
 
 		tracker_sparql_builder_insert_open (preupdate, NULL);
 
diff --git a/src/tracker-extract/tracker-extract-gif.c b/src/tracker-extract/tracker-extract-gif.c
index 329c0ef..577608f 100644
--- a/src/tracker-extract/tracker-extract-gif.c
+++ b/src/tracker-extract/tracker-extract-gif.c
@@ -200,7 +200,7 @@ read_metadata (TrackerSparqlBuilder *preupdate,
 	}
 
 	if (xd->creator) {
-		gchar *uri = tracker_uri_printf_escaped ("urn:contact:%s", xd->creator);
+		gchar *uri = tracker_sparql_escape_uri_printf ("urn:contact:%s", xd->creator);
 
 		tracker_sparql_builder_insert_open (preupdate, NULL);
 		tracker_sparql_builder_subject_iri (preupdate, uri);
@@ -241,7 +241,7 @@ read_metadata (TrackerSparqlBuilder *preupdate,
 	}
 
 	if (md.artist) {
-		gchar *uri = tracker_uri_printf_escaped ("urn:contact:%s", md.artist);
+		gchar *uri = tracker_sparql_escape_uri_printf ("urn:contact:%s", md.artist);
 
 		tracker_sparql_builder_insert_open (preupdate, NULL);
 		tracker_sparql_builder_subject_iri (preupdate, uri);
@@ -333,7 +333,7 @@ read_metadata (TrackerSparqlBuilder *preupdate,
 	g_ptr_array_free (keywords, TRUE);
 
 	if (xd->publisher) {
-		gchar *uri = tracker_uri_printf_escaped ("urn:contact:%s", xd->publisher);
+		gchar *uri = tracker_sparql_escape_uri_printf ("urn:contact:%s", xd->publisher);
 
 		tracker_sparql_builder_insert_open (preupdate, NULL);
 		tracker_sparql_builder_subject_iri (preupdate, uri);
diff --git a/src/tracker-extract/tracker-extract-gstreamer.c b/src/tracker-extract/tracker-extract-gstreamer.c
index 940e593..7bd8321 100644
--- a/src/tracker-extract/tracker-extract-gstreamer.c
+++ b/src/tracker-extract/tracker-extract-gstreamer.c
@@ -540,7 +540,7 @@ extract_metadata (MetadataExtractor      *extractor,
 			gst_tag_list_get_string (extractor->tagcache, GST_TAG_ARTIST, &artist_local);
 
 			if (artist_local) {
-				artist_uri = tracker_uri_printf_escaped ("urn:artist:%s", artist_local);
+				artist_uri = tracker_sparql_escape_uri_printf ("urn:artist:%s", artist_local);
 
 				tracker_sparql_builder_insert_open (preupdate, NULL);
 				tracker_sparql_builder_subject_iri (preupdate, artist_uri);
@@ -554,7 +554,7 @@ extract_metadata (MetadataExtractor      *extractor,
 			temp = tracker_coalesce_strip (2, performer, artist_local);
 
 			if (temp) {
-				performer_uri = tracker_uri_printf_escaped ("urn:artist:%s", temp);
+				performer_uri = tracker_sparql_escape_uri_printf ("urn:artist:%s", temp);
 
 				tracker_sparql_builder_insert_open (preupdate, NULL);
 				tracker_sparql_builder_subject_iri (preupdate, performer_uri);
@@ -574,7 +574,7 @@ extract_metadata (MetadataExtractor      *extractor,
 			gst_tag_list_get_string (extractor->tagcache, GST_TAG_COMPOSER, &s);
 
 			if (s) {
-				composer_uri = tracker_uri_printf_escaped ("urn:artist:%s", s);
+				composer_uri = tracker_sparql_escape_uri_printf ("urn:artist:%s", s);
 
 				tracker_sparql_builder_insert_open (preupdate, NULL);
 
@@ -602,7 +602,7 @@ extract_metadata (MetadataExtractor      *extractor,
 
 			needs_audio = TRUE;
 
-			album_uri = tracker_uri_printf_escaped ("urn:album:%s", s);
+			album_uri = tracker_sparql_escape_uri_printf ("urn:album:%s", s);
 
 			tracker_sparql_builder_insert_open (preupdate, NULL);
 
diff --git a/src/tracker-extract/tracker-extract-jpeg.c b/src/tracker-extract/tracker-extract-jpeg.c
index 2c8d4bf..5a84387 100644
--- a/src/tracker-extract/tracker-extract-jpeg.c
+++ b/src/tracker-extract/tracker-extract-jpeg.c
@@ -280,7 +280,7 @@ extract_jpeg (const gchar          *uri,
 	tracker_sparql_builder_object_int64 (metadata, cinfo.image_height);
 
 	if (id->contact) {
-		gchar *uri = tracker_uri_printf_escaped ("urn:contact:%s", id->contact);
+		gchar *uri = tracker_sparql_escape_uri_printf ("urn:contact:%s", id->contact);
 
 		tracker_sparql_builder_insert_open (preupdate, NULL);
 		tracker_sparql_builder_subject_iri (preupdate, uri);
@@ -310,7 +310,7 @@ extract_jpeg (const gchar          *uri,
 	}
 
 	if (xd->publisher) {
-		gchar *uri = tracker_uri_printf_escaped ("urn:contact:%s", xd->publisher);
+		gchar *uri = tracker_sparql_escape_uri_printf ("urn:contact:%s", xd->publisher);
 
 		tracker_sparql_builder_insert_open (preupdate, NULL);
 		tracker_sparql_builder_subject_iri (preupdate, uri);
@@ -438,7 +438,7 @@ extract_jpeg (const gchar          *uri,
 	}
 
 	if (md.artist) {
-		gchar *uri = tracker_uri_printf_escaped ("urn:contact:%s", md.artist);
+		gchar *uri = tracker_sparql_escape_uri_printf ("urn:contact:%s", md.artist);
 
 		tracker_sparql_builder_insert_open (preupdate, NULL);
 		tracker_sparql_builder_subject_iri (preupdate, uri);
@@ -485,7 +485,7 @@ extract_jpeg (const gchar          *uri,
 	}
 
 	if (md.creator) {
-		gchar *uri = tracker_uri_printf_escaped ("urn:contact:%s", md.creator);
+		gchar *uri = tracker_sparql_escape_uri_printf ("urn:contact:%s", md.creator);
 
 		tracker_sparql_builder_insert_open (preupdate, NULL);
 		tracker_sparql_builder_subject_iri (preupdate, uri);
diff --git a/src/tracker-extract/tracker-extract-libxine.c b/src/tracker-extract/tracker-extract-libxine.c
index 316c495..8b65598 100644
--- a/src/tracker-extract/tracker-extract-libxine.c
+++ b/src/tracker-extract/tracker-extract-libxine.c
@@ -99,7 +99,7 @@ tracker_extract_xine (const gchar          *uri,
 
 	author = xine_get_meta_info (stream, XINE_META_INFO_ARTIST);
 	if (author) {
-		gchar *canonical_uri = tracker_uri_printf_escaped ("urn:artist:%s", author);
+		gchar *canonical_uri = tracker_sparql_escape_uri_printf ("urn:artist:%s", author);
 
 		tracker_sparql_builder_insert_open (preupdate, NULL);
 
@@ -114,7 +114,7 @@ tracker_extract_xine (const gchar          *uri,
 
 	album = xine_get_meta_info (stream, XINE_META_INFO_ALBUM);
 	if (album) {
-		gchar *canonical_uri = tracker_uri_printf_escaped ("urn:album:%s", album);
+		gchar *canonical_uri = tracker_sparql_escape_uri_printf ("urn:album:%s", album);
 
 		tracker_sparql_builder_insert_open (preupdate, NULL);
 
diff --git a/src/tracker-extract/tracker-extract-mp3.c b/src/tracker-extract/tracker-extract-mp3.c
index d1ab435..f98bef3 100644
--- a/src/tracker-extract/tracker-extract-mp3.c
+++ b/src/tracker-extract/tracker-extract-mp3.c
@@ -2058,7 +2058,7 @@ extract_mp3 (const gchar          *uri,
 	}
 
 	if (md.performer) {
-		md.performer_uri = tracker_uri_printf_escaped ("urn:artist:%s", md.performer);
+		md.performer_uri = tracker_sparql_escape_uri_printf ("urn:artist:%s", md.performer);
 
 		tracker_sparql_builder_insert_open (preupdate, NULL);
 
@@ -2072,7 +2072,7 @@ extract_mp3 (const gchar          *uri,
 	}
 
 	if (md.composer) {
-		md.composer_uri = tracker_uri_printf_escaped ("urn:artist:%s", md.composer);
+		md.composer_uri = tracker_sparql_escape_uri_printf ("urn:artist:%s", md.composer);
 
 		tracker_sparql_builder_insert_open (preupdate, NULL);
 
@@ -2086,7 +2086,7 @@ extract_mp3 (const gchar          *uri,
 	}
 
 	if (md.lyricist) {
-		md.lyricist_uri = tracker_uri_printf_escaped ("urn:artist:%s", md.lyricist);
+		md.lyricist_uri = tracker_sparql_escape_uri_printf ("urn:artist:%s", md.lyricist);
 
 		tracker_sparql_builder_insert_open (preupdate, NULL);
 		tracker_sparql_builder_subject_iri (preupdate, md.lyricist_uri);
@@ -2098,7 +2098,7 @@ extract_mp3 (const gchar          *uri,
 	}
 
 	if (md.album) {
-		md.album_uri = tracker_uri_printf_escaped ("urn:album:%s", md.album);
+		md.album_uri = tracker_sparql_escape_uri_printf ("urn:album:%s", md.album);
 
 		tracker_sparql_builder_insert_open (preupdate, NULL);
 
diff --git a/src/tracker-extract/tracker-extract-mplayer.c b/src/tracker-extract/tracker-extract-mplayer.c
index 34896a6..98077c8 100644
--- a/src/tracker-extract/tracker-extract-mplayer.c
+++ b/src/tracker-extract/tracker-extract-mplayer.c
@@ -90,7 +90,7 @@ copy_hash_table_entry (gpointer key,
 	ForeachCopyInfo *info = user_data;
 
 	if (g_strcmp0 (key, "nmm:performer") == 0) {
-		gchar *canonical_uri = tracker_uri_printf_escaped ("urn:artist:%s", value);
+		gchar *canonical_uri = tracker_sparql_escape_uri_printf ("urn:artist:%s", value);
 
 		tracker_sparql_builder_insert_open (info->preupdate, NULL);
 
diff --git a/src/tracker-extract/tracker-extract-png.c b/src/tracker-extract/tracker-extract-png.c
index b08f7d2..d564679 100644
--- a/src/tracker-extract/tracker-extract-png.c
+++ b/src/tracker-extract/tracker-extract-png.c
@@ -240,7 +240,7 @@ read_metadata (TrackerSparqlBuilder *preupdate,
 	g_free (ed->software);
 
 	if (md.creator) {
-		gchar *uri = tracker_uri_printf_escaped ("urn:contact:%s", md.creator);
+		gchar *uri = tracker_sparql_escape_uri_printf ("urn:contact:%s", md.creator);
 
 		tracker_sparql_builder_insert_open (preupdate, NULL);
 		tracker_sparql_builder_subject_iri (preupdate, uri);
@@ -281,7 +281,7 @@ read_metadata (TrackerSparqlBuilder *preupdate,
 	}
 
 	if (md.artist) {
-		gchar *uri = tracker_uri_printf_escaped ("urn:contact:%s", md.artist);
+		gchar *uri = tracker_sparql_escape_uri_printf ("urn:contact:%s", md.artist);
 
 		tracker_sparql_builder_insert_open (preupdate, NULL);
 		tracker_sparql_builder_subject_iri (preupdate, uri);
@@ -355,7 +355,7 @@ read_metadata (TrackerSparqlBuilder *preupdate,
 	}
 
 	if (xd->publisher) {
-		gchar *uri = tracker_uri_printf_escaped ("urn:contact:%s", xd->publisher);
+		gchar *uri = tracker_sparql_escape_uri_printf ("urn:contact:%s", xd->publisher);
 
 		tracker_sparql_builder_insert_open (preupdate, NULL);
 		tracker_sparql_builder_subject_iri (preupdate, uri);
diff --git a/src/tracker-extract/tracker-extract-tiff.c b/src/tracker-extract/tracker-extract-tiff.c
index ae09e3b..5b2b9c5 100644
--- a/src/tracker-extract/tracker-extract-tiff.c
+++ b/src/tracker-extract/tracker-extract-tiff.c
@@ -416,7 +416,7 @@ extract_tiff (const gchar          *uri,
 	}
 
 	if (xd->publisher) {
-		gchar *uri = tracker_uri_printf_escaped ("urn:contact:%s", xd->publisher);
+		gchar *uri = tracker_sparql_escape_uri_printf ("urn:contact:%s", xd->publisher);
 
 		tracker_sparql_builder_insert_open (preupdate, NULL);
 		tracker_sparql_builder_subject_iri (preupdate, uri);
@@ -507,7 +507,7 @@ extract_tiff (const gchar          *uri,
 	}
 
 	if (id->contact) {
-		gchar *uri = tracker_uri_printf_escaped ("urn:contact:%s", id->contact);
+		gchar *uri = tracker_sparql_escape_uri_printf ("urn:contact:%s", id->contact);
 
 		tracker_sparql_builder_insert_open (preupdate, NULL);
 		tracker_sparql_builder_subject_iri (preupdate, uri);
@@ -584,7 +584,7 @@ extract_tiff (const gchar          *uri,
 	}
 
 	if (md.artist) {
-		gchar *uri = tracker_uri_printf_escaped ("urn:contact:%s", md.artist);
+		gchar *uri = tracker_sparql_escape_uri_printf ("urn:contact:%s", md.artist);
 
 		tracker_sparql_builder_insert_open (preupdate, NULL);
 		tracker_sparql_builder_subject_iri (preupdate, uri);
@@ -625,7 +625,7 @@ extract_tiff (const gchar          *uri,
 	}
 
 	if (md.creator) {
-		gchar *uri = tracker_uri_printf_escaped ("urn:contact:%s", md.creator);
+		gchar *uri = tracker_sparql_escape_uri_printf ("urn:contact:%s", md.creator);
 
 		tracker_sparql_builder_insert_open (preupdate, NULL);
 		tracker_sparql_builder_subject_iri (preupdate, uri);
diff --git a/src/tracker-extract/tracker-extract-totem.c b/src/tracker-extract/tracker-extract-totem.c
index f5346fd..b87bb64 100644
--- a/src/tracker-extract/tracker-extract-totem.c
+++ b/src/tracker-extract/tracker-extract-totem.c
@@ -105,10 +105,10 @@ extract_totem (const gchar          *uri,
 
 					if (g_strcmp0 (tags[i][0], "TOTEM_INFO_ARTIST") == 0) {
 						artist = g_strdup (value);
-						artist_uri = tracker_uri_printf_escaped ("urn:artist:%s", artist);
+						artist_uri = tracker_sparql_escape_uri_printf ("urn:artist:%s", artist);
 					} else if (g_strcmp0 (tags[i][0], "TOTEM_INFO_ALBUM") == 0) {
 						album = g_strdup (value);
-						album_uri = tracker_uri_printf_escaped ("urn:album:%s", album);
+						album_uri = tracker_sparql_escape_uri_printf ("urn:album:%s", album);
 					} else {
 						g_hash_table_insert (tmp_metadata, g_strdup (tags[i][1]), g_strdup (value));
 					}
diff --git a/src/tracker-extract/tracker-extract-vorbis.c b/src/tracker-extract/tracker-extract-vorbis.c
index bdfcd38..cfda452 100644
--- a/src/tracker-extract/tracker-extract-vorbis.c
+++ b/src/tracker-extract/tracker-extract-vorbis.c
@@ -172,7 +172,7 @@ extract_vorbis (const char *uri,
 	md.creator = tracker_coalesce_strip (3, vd.artist, vd.album_artist, vd.performer);
 
 	if (md.creator) {
-		gchar *uri = tracker_uri_printf_escaped ("urn:artist:%s", md.creator);
+		gchar *uri = tracker_sparql_escape_uri_printf ("urn:artist:%s", md.creator);
 
 		tracker_sparql_builder_insert_open (preupdate, NULL);
 		tracker_sparql_builder_subject_iri (preupdate, uri);
@@ -188,7 +188,7 @@ extract_vorbis (const char *uri,
 	}
 
 	if (vd.album) {
-		gchar *uri = tracker_uri_printf_escaped ("urn:album:%s", vd.album);
+		gchar *uri = tracker_sparql_escape_uri_printf ("urn:album:%s", vd.album);
 
 		tracker_sparql_builder_insert_open (preupdate, NULL);
 		tracker_sparql_builder_subject_iri (preupdate, uri);



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]