code: def advance(self):
      
      hasMore = True
      try:
        self.__iter.next()
      except StopIteration:
        self.__iter = None
        hasMore = False
  
      return hasMore
docs: Advances the iteration;
  
      Returns:      True if more iterations remain; False if this is the final
                    iteration.