]> git.notmuchmail.org Git - notmuch/blobdiff - cnotmuch/database.py
implement notmuch dump and Messages.len()
[notmuch] / cnotmuch / database.py
index 19460b339e6d9942b093c3155fa6c3575a78e432..8d6124cbc9e816a227b5d7dfeeaa3006519f44b3 100644 (file)
@@ -253,6 +253,13 @@ class Tags(object):
         nmlib.notmuch_tags_move_to_next(self._tags)
         return tag
 
+    def __str__(self):
+        """str() of Tags() is a space separated list of tags
+
+        This iterates over the list of Tags and will therefore 'exhaust' Tags()
+        """
+        return " ".join(self)
+
     def __del__(self):
         """Close and free the notmuch tags"""
         if self._tags is not None: