Package corebio :: Package utils :: Class Reiterate
[frames | no frames]

Type Reiterate

object --+
         |
        Reiterate


A flexible wrapper around a simple iterator.

Method Summary
  __init__(self, *args, **kw)
  __iter__(self)
  __new__(cls, iterator)
(Static method)
  filter(self, predicate)
Return the next item in the iteration that satisifed the predicate.
  has_item(self)
More items to return?...
  index(self)
The number of items returned.
  next(self)
Return the next item in the iteration.
  peek(self)
Returns the next item, but does not advance the iteration.
  push(self, item)
Push an item back onto the top of the iterator,...
    Inherited from object
  __delattr__(...)
x.__delattr__('name') <==> del x.name...
  __getattribute__(...)
x.__getattribute__('name') <==> x.name...
  __hash__(x)
x.__hash__() <==> hash(x)...
  __reduce__(...)
helper for pickle...
  __reduce_ex__(...)
helper for pickle...
  __repr__(x)
x.__repr__() <==> repr(x)...
  __setattr__(...)
x.__setattr__('name', value) <==> x.name = value...
  __str__(x)
x.__str__() <==> str(x)...

Instance Method Details

filter(self, predicate)

Return the next item in the iteration that satisifed the 
predicate.

has_item(self)

More items to return?

index(self)

The number of items returned. Incremented by next(), Decremented
by push(), unchanged by peek()

next(self)

Return the next item in the iteration.

peek(self)

Returns the next item, but does not advance the iteration.
Returns None if no more items. (Bit may also return None as the
next item.)

push(self, item)

Push an item back onto the top of the iterator,

Generated by Epydoc 2.1 on http://epydoc.sf.net