Represents a single message thread.
Parameters: |
|
---|
Get the thread ID of ‘thread’
The returned string belongs to ‘thread’ and will only be valid for as long as the thread is valid.
Returns: | String with a message ID |
---|---|
Raises : | NotInitializedError if the thread is not initialized. |
Get the total number of messages in ‘thread’
Returns: | The number of all messages in the database belonging to this thread. Contrast with get_matched_messages(). |
---|---|
Raises : | NotInitializedError if the thread is not initialized. |
Returns a Messages iterator for the top-level messages in ‘thread’
This iterator will not necessarily iterate over all of the messages in the thread. It will only iterate over the messages in the thread which are not replies to other messages in the thread.
To iterate over all messages in the thread, the caller will need to iterate over the result of Message.get_replies() for each top-level message (and do that recursively for the resulting messages, etc.).
Returns: | Messages |
---|---|
Raises : | NotInitializedError if query is not initialized |
Raises : | NullPointerError if search_messages failed |
Returns the number of messages in ‘thread’ that matched the query
Returns: | The number of all messages belonging to this thread that matched the Query`from which this thread was created. Contrast with :meth:`get_total_messages. |
---|---|
Raises : | NotInitializedError if the thread is not initialized. |
Returns the authors of ‘thread’
The returned string is a comma-separated list of the names of the authors of mail messages in the query results that belong to this thread.
The returned string belongs to ‘thread’ and will only be valid for as long as this Thread() is not deleted.
Returns the Subject of ‘thread’
The returned string belongs to ‘thread’ and will only be valid for as long as this Thread() is not deleted.
Returns time_t of the oldest message date
Returns: | A time_t timestamp. |
---|---|
Return type: | c_unit64 |
Raises : | NotInitializedError if the message is not initialized. |
Returns time_t of the newest message date
Returns: | A time_t timestamp. |
---|---|
Return type: | c_unit64 |
Raises : | NotInitializedError if the message is not initialized. |
Returns the message tags
In the Notmuch database, tags are stored on individual messages, not on threads. So the tags returned here will be all tags of the messages which matched the search and which belong to this thread.
The Tags object is owned by the thread and as such, will only be valid for as long as this Thread is valid (e.g. until the query from which it derived is explicitely deleted).
Returns: | A Tags iterator. |
---|---|
Raises : | NotInitializedError if query is not initialized |
Raises : | NullPointerError if search_messages failed |