aboutsummaryrefslogtreecommitdiffhomepage
path: root/notmuch.h
diff options
context:
space:
mode:
authorGravatar Carl Worth <cworth@cworth.org>2009-10-21 15:37:51 -0700
committerGravatar Carl Worth <cworth@cworth.org>2009-10-21 15:40:20 -0700
commit6c5054ebee5beb72c22d91a57c66b8ecdc65f7bf (patch)
tree7a081e37908a868ca0f25adb87dd4e6e31fcef54 /notmuch.h
parent8ad4350fef132b016bbab5eeb1c4a713e51035c6 (diff)
database: Add new notmuch_database_find_message
With this function, and the recently added support for notmuch_message_get_thread_ids, we now recode the find_thread_ids function to work just the way we expect a user of the public notmuch API to work. Not too bad really.
Diffstat (limited to 'notmuch.h')
-rw-r--r--notmuch.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/notmuch.h b/notmuch.h
index 41987b58..93bb66e9 100644
--- a/notmuch.h
+++ b/notmuch.h
@@ -164,6 +164,19 @@ notmuch_status_t
notmuch_database_add_message (notmuch_database_t *database,
const char *filename);
+/* Find a message with the given messsage_id.
+ *
+ * If the database contains a message with the given message_id, then
+ * a new notmuch_message_t object is returned. The caller should call
+ * notmuch_message_destroy when done with the message.
+ *
+ * If no message is found with the given message_id, this function
+ * returns NULL.
+ */
+notmuch_message_t *
+notmuch_database_find_message (notmuch_database_t *database,
+ const char *message_id);
+
/* Create a new query for 'database'.
*
* Here, 'database' should be an open database, (see