X-Git-Url: https://git.notmuchmail.org/git?a=blobdiff_plain;f=lib%2Fdatabase.cc;h=09ab9cb037475f7e07a4af5d3ac6dc975c25919e;hb=d9800c893289b56dcc966241528643ae83f2ff9a;hp=fc42c4ba93c3af197de52653792c63ffc31a07c5;hpb=2717ff96a70a252a9ca7afea92a07d12f2139742;p=notmuch diff --git a/lib/database.cc b/lib/database.cc index fc42c4ba..09ab9cb0 100644 --- a/lib/database.cc +++ b/lib/database.cc @@ -63,6 +63,12 @@ typedef struct { * We currently have three different types of documents (mail, ghost, * and directory) and also some metadata. * + * There are two kinds of prefixes used in notmuch. There are the + * human friendly 'prefix names' like "thread:", which are also used + * in the query parser, and the actual prefix terms in the database + * (e.g. "G"). The correspondence is maintained in the file scope data + * structure 'prefix_table'. + * * Mail document * ------------- * A mail document is associated with a particular email message. It @@ -118,9 +124,11 @@ typedef struct { * * In addition, terms from the content of the message are added with * "from", "to", "attachment", and "subject" prefixes for use by the - * user in searching. Similarly, terms from the path of the mail - * message are added with "folder" and "path" prefixes. But the - * database doesn't really care itself about any of these. + * user in searching. + * + * The path of the containing folder is added with the "folder" prefix + * (see _notmuch_message_add_folder_terms). Sub-paths of the the path + * of the mail message are added with the "path" prefix. * * The data portion of a mail document is empty. *