class documentation

class _SynchronousProducer: (source)

Implements interfaces: twisted.web.iweb.IBodyProducer

View In Hierarchy

A partial implementation of an :obj:`IBodyProducer` which produces its entire payload immediately. There is no way to access to an instance of this object from :obj:`RequestTraversalAgent` or :obj:`StubTreq`, or even a :obj:`Resource: passed to :obj:`StubTreq`. This does not implement the :func:`IBodyProducer.stopProducing` method, because that is very difficult to trigger. (The request from `RequestTraversalAgent` would have to be canceled while it is still in the transmitting state), and the intent is to use `RequestTraversalAgent` to make synchronous requests.

Method __init__ Create a synchronous producer with some bytes.
Method startProducing Immediately produce all data.
Instance Variable body Undocumented
Instance Variable length Undocumented
def __init__(self, body): (source)

Create a synchronous producer with some bytes.

def startProducing(self, consumer): (source)

Immediately produce all data.

body = (source)

Undocumented

length = (source)

Undocumented