Make root slightly more flat by yielding all its immediate contents as strings, deferreds or generators that are recursive calls to itself.

ParametersrequestA request object which will be passed to IRenderable.render.
rootAn object to be made flatter. This may be of type unicode, str, slot, Tag, tuple, list, types.GeneratorType, Deferred, or an object that implements IRenderable.
writeA callable which will be invoked with each bytes produced by flattening root.
slotDataA list of dict mapping str slot names to data with which those slots will be replaced.
renderFactoryIf not None, an object that provides IRenderable.
dataEscaperA 1-argument callable which takes bytes or unicode and returns bytes, quoted as appropriate for the rendering context. This is really only one of two values: attributeEscapingDoneOutside or escapeForContent, depending on whether the rendering context is within an attribute or not. See the explanation in writeWithAttributeEscaping.
ReturnsAn iterator that eventually yields bytes that should be written to the output. However it may also yield other iterators or Deferreds; if it yields another iterator, the caller will iterate it; if it yields a Deferred, the result of that Deferred will either be bytes, in which case it's written, or another generator, in which case it is iterated. See _flattenTree for the trampoline that consumes said values. (type: An iterator which yields bytes, Deferred, and more iterators of the same type.)
Function keepGoing Undocumented
def keepGoing(newRoot, dataEscaper=dataEscaper, renderFactory=renderFactory, write=write): (source)
Undocumented
API Documentation for Twisted, generated by pydoctor at 2020-03-20 23:54:06.