Permalink
Browse files

Add maildir import/export support

  • Loading branch information...
jelly committed Jun 8, 2014
1 parent 932643d commit 2aaf7faa775e443cd94e986ea8ad3916cf849f4d
Showing with 11 additions and 0 deletions.
  1. +11 −0 zarafa/__init__.py
View
@@ -429,6 +429,17 @@ def mbox(self, location):
mboxfile.add(item.eml())
mboxfile.unlock()
def maildir(self):
destination = mailbox.MH(self.name)
destination.lock()
for item in self.items():
destination.add(item.eml())
destination.unlock()
def read_maildir(self, location):
for message in mailbox.MH(location):
newitem = Item(self,message.__str__())
def __unicode__(self):
return u'Folder(%s)' % self.name

0 comments on commit 2aaf7fa

Please sign in to comment.