summaryrefslogtreecommitdiff
path: root/libyelp/yelp-storage.c
diff options
context:
space:
mode:
authorShaun McCance <shaunm@gnome.org>2011-02-11 15:44:54 -0500
committerShaun McCance <shaunm@gnome.org>2011-02-11 15:44:54 -0500
commitc6b056db59bf38683543442b2601a20b32bf8301 (patch)
tree206b4cdff2756b4bfeb220b84325247e91ef92db /libyelp/yelp-storage.c
parent4fcf2b3d0139bf78a32574068fd566da8027203d (diff)
downloadyelp-c6b056db59bf38683543442b2601a20b32bf8301.tar.gz
Store and retrieve root title in storage for search results
Diffstat (limited to 'libyelp/yelp-storage.c')
-rw-r--r--libyelp/yelp-storage.c31
1 files changed, 31 insertions, 0 deletions
diff --git a/libyelp/yelp-storage.c b/libyelp/yelp-storage.c
index c4886feb..e901af1d 100644
--- a/libyelp/yelp-storage.c
+++ b/libyelp/yelp-storage.c
@@ -85,3 +85,34 @@ yelp_storage_search (YelpStorage *storage,
else
return NULL;
}
+
+gchar *
+yelp_storage_get_root_title (YelpStorage *storage,
+ const gchar *doc_uri)
+{
+ YelpStorageInterface *iface;
+
+ g_return_if_fail (YELP_IS_STORAGE (storage));
+
+ iface = YELP_STORAGE_GET_INTERFACE (storage);
+
+ if (iface->search)
+ return (*iface->get_root_title) (storage, doc_uri);
+ else
+ return NULL;
+}
+
+void
+yelp_storage_set_root_title (YelpStorage *storage,
+ const gchar *doc_uri,
+ const gchar *title)
+{
+ YelpStorageInterface *iface;
+
+ g_return_if_fail (YELP_IS_STORAGE (storage));
+
+ iface = YELP_STORAGE_GET_INTERFACE (storage);
+
+ if (iface->search)
+ (*iface->set_root_title) (storage, doc_uri, title);
+}