aboutsummaryrefslogtreecommitdiffstats
path: root/libibex/find.c
diff options
context:
space:
mode:
Diffstat (limited to 'libibex/find.c')
-rw-r--r--libibex/find.c16
1 files changed, 16 insertions, 0 deletions
diff --git a/libibex/find.c b/libibex/find.c
index e0b5d263c8..1bb58917ac 100644
--- a/libibex/find.c
+++ b/libibex/find.c
@@ -56,6 +56,22 @@ ibex_find (ibex *ib, char *word)
}
/**
+ * ibex_contains_name:
+ * @ib:
+ * @name:
+ *
+ * Returns #TRUE if the ibex @ib has any index entry for
+ * the key @name.
+ *
+ * Return value:
+ **/
+gboolean
+ibex_contains_name(ibex *ib, char *name)
+{
+ return g_tree_lookup(ib->files, name) != NULL;
+}
+
+/**
* ibex_find_name: Check if a word occurs in a given file
* @ib: an ibex
* @name: a filename