mirror of
https://git.notmuchmail.org/git/notmuch
synced 2024-12-23 09:54:52 +01:00
python: pep8 compliance for filename.py
This commit is contained in:
parent
e69e30edd7
commit
8176326f30
1 changed files with 13 additions and 12 deletions
|
@ -19,17 +19,18 @@ Copyright 2010 Sebastian Spaeth <Sebastian@SSpaeth.de>'
|
||||||
from ctypes import c_char_p
|
from ctypes import c_char_p
|
||||||
from notmuch.globals import nmlib, STATUS, NotmuchError
|
from notmuch.globals import nmlib, STATUS, NotmuchError
|
||||||
|
|
||||||
#------------------------------------------------------------------------------
|
|
||||||
class Filenames(object):
|
class Filenames(object):
|
||||||
"""Represents a list of filenames as returned by notmuch
|
"""Represents a list of filenames as returned by notmuch
|
||||||
|
|
||||||
This object contains the Filenames iterator. The main function is as_generator() which will return a generator so we can do a Filenamesth an iterator over a list of notmuch filenames. Do
|
This object contains the Filenames iterator. The main function is
|
||||||
note that the underlying library only provides a one-time iterator
|
as_generator() which will return a generator so we can do a Filenamesth an
|
||||||
(it cannot reset the iterator to the start). Thus iterating over
|
iterator over a list of notmuch filenames. Do note that the underlying
|
||||||
the function will "exhaust" the list of tags, and a subsequent
|
library only provides a one-time iterator (it cannot reset the iterator to
|
||||||
iteration attempt will raise a :exc:`NotmuchError`
|
the start). Thus iterating over the function will "exhaust" the list of
|
||||||
STATUS.NOT_INITIALIZED. Also note, that any function that uses
|
tags, and a subsequent iteration attempt will raise a :exc:`NotmuchError`
|
||||||
iteration (nearly all) will also exhaust the tags. So both::
|
STATUS.NOT_INITIALIZED. Also note, that any function that uses iteration
|
||||||
|
(nearly all) will also exhaust the tags. So both::
|
||||||
|
|
||||||
for name in filenames: print name
|
for name in filenames: print name
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue