'Direct the output of an iterator to the transport and arrange for
iteration to take place.
@type gen: iterable which yields L{bytes}
@param gen: An iterator over strings.
@rtype: L{Deferred <defer.Deferred>}
@return: A deferred which fires when the iterator finishes.'

def _coiterate(self, gen):

    return self.schedule(_IteratorBuffer(self.transport.writeSequence, gen))
