Bio :: GenBank :: Iterator :: Class Iterator
[hide private]
[frames] | no frames]

Class Iterator

source code

object --+
         |
        Iterator

Iterator interface to move over a file of GenBank entries one at a time (OBSOLETE).

This class is likely to be deprecated in a future release of Biopython. Please use Bio.SeqIO.parse(..., format="gb") or Bio.GenBank.parse(...) for SeqRecord and GenBank specific Record objects respectively instead.

Instance Methods [hide private]
 
__init__(self, handle, parser=None)
Initialize the iterator.
source code
 
__next__(self)
Return the next GenBank record from the handle.
source code
 
next(self)
Python 2 style alias for Python 3 style __next__ method.
source code
 
__iter__(self) source code

Inherited from object: __delattr__, __format__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __sizeof__, __str__, __subclasshook__

Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, handle, parser=None)
(Constructor)

source code 

Initialize the iterator.

Arguments:

  • handle - A handle with GenBank entries to iterate through.
  • parser - An optional parser to pass the entries through before returning them. If None, then the raw entry will be returned.
Overrides: object.__init__

__next__(self)

source code 

Return the next GenBank record from the handle.

Will return None if we ran out of records.