more consistent style
Signed-off-by: Nicolas Sebrecht <nicolas.s-dev@laposte.net>
This commit is contained in:
@ -1,5 +1,5 @@
|
||||
# Base folder support
|
||||
# Copyright (C) 2002-2011 John Goerzen & contributors
|
||||
# Copyright (C) 2002-2015 John Goerzen & contributors
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
@ -23,7 +23,6 @@ import offlineimap.accounts
|
||||
import os.path
|
||||
import re
|
||||
from sys import exc_info
|
||||
import traceback
|
||||
|
||||
|
||||
class BaseFolder(object):
|
||||
@ -113,6 +112,7 @@ class BaseFolder(object):
|
||||
def quickchanged(self, statusfolder):
|
||||
""" Runs quick check for folder changes and returns changed
|
||||
status: True -- changed, False -- not changed.
|
||||
|
||||
:param statusfolder: keeps track of the last known folder state.
|
||||
"""
|
||||
return True
|
||||
@ -129,11 +129,13 @@ class BaseFolder(object):
|
||||
return 1
|
||||
|
||||
def getvisiblename(self):
|
||||
"""The nametrans-transposed name of the folder's name"""
|
||||
"""The nametrans-transposed name of the folder's name."""
|
||||
|
||||
return self.visiblename
|
||||
|
||||
def getexplainedname(self):
|
||||
""" Name that shows both real and nametrans-mangled values"""
|
||||
"""Name that shows both real and nametrans-mangled values."""
|
||||
|
||||
if self.name == self.visiblename:
|
||||
return self.name
|
||||
else:
|
||||
@ -603,6 +605,7 @@ class BaseFolder(object):
|
||||
:param new_uid: (optional) If given, the old UID will be changed
|
||||
to a new UID. This allows backends efficient renaming of
|
||||
messages if the UID has changed."""
|
||||
|
||||
raise NotImplementedError
|
||||
|
||||
def deletemessage(self, uid):
|
||||
@ -610,6 +613,7 @@ class BaseFolder(object):
|
||||
Note that this function does not check against dryrun settings,
|
||||
so you need to ensure that it is never called in a
|
||||
dryrun mode."""
|
||||
|
||||
raise NotImplementedError
|
||||
|
||||
def deletemessages(self, uidlist):
|
||||
@ -617,6 +621,7 @@ class BaseFolder(object):
|
||||
Note that this function does not check against dryrun settings,
|
||||
so you need to ensure that it is never called in a
|
||||
dryrun mode."""
|
||||
|
||||
for uid in uidlist:
|
||||
self.deletemessage(uid)
|
||||
|
||||
@ -632,6 +637,7 @@ class BaseFolder(object):
|
||||
:param statusfolder: A LocalStatusFolder instance
|
||||
:param register: whether we should register a new thread."
|
||||
:returns: Nothing on success, or raises an Exception."""
|
||||
|
||||
# Sometimes, it could be the case that if a sync takes awhile,
|
||||
# a message might be deleted from the maildir before it can be
|
||||
# synced to the status cache. This is only a problem with
|
||||
|
Reference in New Issue
Block a user