Exemplo n.º 1
0
 def clear(self, username, password):
     '''Clear this GMail mailbox (remove all messages and labels). To avoid
     unintentionally deletion of your messages, you have to reenter your
     mailbox name.'''
     mailbox = raw_input("Do you want to delete all messages from your mailbox (%s)?\nPlease, repeat the name of your mailbox: " % username)
     if mailbox != username:
         print "Mailbox names doesn't match"
         return
     self.notifier = ConsoleNotifier()
     b = GMailBackup(username, password, self.notifier)
     b.clear()