summaryrefslogtreecommitdiff
path: root/src/libtracker-miner
diff options
context:
space:
mode:
authorAleksander Morgado <aleksander@lanedo.com>2011-02-08 14:14:40 +0100
committerAleksander Morgado <aleksander@lanedo.com>2011-02-08 14:14:40 +0100
commitb9f8a0e36ebaa1b0e47cca5c61b691b1e004fd79 (patch)
treece2911b166a51e8514d546517ba00791d0a75041 /src/libtracker-miner
parent215eacfba7a06af0c9af956573fb39c74a35933c (diff)
downloadtracker-b9f8a0e36ebaa1b0e47cca5c61b691b1e004fd79.tar.gz
libtracker-miner: Document Tracker Thumbnailer API
Diffstat (limited to 'src/libtracker-miner')
-rw-r--r--src/libtracker-miner/tracker-thumbnailer.c58
1 files changed, 58 insertions, 0 deletions
diff --git a/src/libtracker-miner/tracker-thumbnailer.c b/src/libtracker-miner/tracker-thumbnailer.c
index 9fb95f262..66655caee 100644
--- a/src/libtracker-miner/tracker-thumbnailer.c
+++ b/src/libtracker-miner/tracker-thumbnailer.c
@@ -119,6 +119,15 @@ should_be_thumbnailed (GStrv list,
return should_thumbnail;
}
+/**
+ * tracker_thumbnailer_init:
+ *
+ * Initializes the thumbnailer connection.
+ *
+ * Returns: #TRUE if connection was successfully initialized, #FALSE otherwise.
+ *
+ * Since: 0.8
+ */
gboolean
tracker_thumbnailer_init (void)
{
@@ -249,12 +258,32 @@ error_handler:
return TRUE;
}
+/**
+ * tracker_thumbnailer_shutdown:
+ *
+ * Shuts down the thumbnailer connection.
+ *
+ * Since: 0.8
+ */
void
tracker_thumbnailer_shutdown (void)
{
g_static_private_set (&private_key, NULL, NULL);
}
+/**
+ * tracker_thumbnailer_move_add:
+ * @from_uri: URI of the file before the move
+ * @mime_type: mime-type of the file
+ * @to_uri: URI of the file after the move
+ *
+ * Adds a new request to tell the thumbnailer that @from_uri was moved to
+ * @to_uri. Stored requests can be sent with tracker_thumbnailer_send().
+ *
+ * Returns: #TRUE if successfully stored to be reported, #FALSE otherwise.
+ *
+ * Since: 0.8
+ */
gboolean
tracker_thumbnailer_move_add (const gchar *from_uri,
const gchar *mime_type,
@@ -289,6 +318,18 @@ tracker_thumbnailer_move_add (const gchar *from_uri,
return TRUE;
}
+/**
+ * tracker_thumbnailer_remove_add:
+ * @uri: URI of the file
+ * @mime_type: mime-type of the file
+ *
+ * Adds a new request to tell the thumbnailer that @uri was removed.
+ * Stored requests can be sent with tracker_thumbnailer_send().
+ *
+ * Returns: #TRUE if successfully stored to be reported, #FALSE otherwise.
+ *
+ * Since: 0.8
+ */
gboolean
tracker_thumbnailer_remove_add (const gchar *uri,
const gchar *mime_type)
@@ -317,6 +358,16 @@ tracker_thumbnailer_remove_add (const gchar *uri,
return TRUE;
}
+/**
+ * tracker_thumbnailer_cleanup:
+ * @uri_prefix: URI prefix
+ *
+ * Tells thumbnailer to cleanup all thumbnails under @uri_prefix.
+ *
+ * Returns: #TRUE if successfully reported, #FALSE otherwise.
+ *
+ * Since: 0.8
+ */
gboolean
tracker_thumbnailer_cleanup (const gchar *uri_prefix)
{
@@ -349,6 +400,13 @@ tracker_thumbnailer_cleanup (const gchar *uri_prefix)
return TRUE;
}
+/**
+ * tracker_thumbnailer_send:
+ *
+ * Sends to the thumbnailer all stored requests.
+ *
+ * Since: 0.8
+ */
void
tracker_thumbnailer_send (void)
{