'Initialize this HTTP/2 stream.
@param streamID: The numerical stream ID that this object corresponds
to.
@type streamID: L{int}
@param connection: The HTTP/2 connection this stream belongs to.
@type connection: L{H2Connection}
@param headers: The HTTP/2 request headers.
@type headers: A L{list} of L{tuple}s of header name and header value,
both as L{bytes}.
@param requestFactory: A function that builds appropriate request
request objects.
@type requestFactory: A callable that returns a
L{twisted.web.iweb.IRequest}.
@param site: The L{twisted.web.server.Site} object this stream belongs
to, if any.
@type site: L{twisted.web.server.Site}
@param factory: The L{twisted.web.http.HTTPFactory} object that
constructed this stream\'s parent connection.
@type factory: L{twisted.web.http.HTTPFactory}'

def __init__(self, streamID, connection, headers, requestFactory, site, factory):

    self.streamID = streamID
    self.site = site
    self.factory = factory
    self.producing = True
    self.command = None
    self.path = None
    self.producer = None
    self._producerProducing = False
    self._hasStreamingProducer = None
    self._inboundDataBuffer = deque()
    self._conn = connection
    self._request = requestFactory(self, queued=False)
    self._buffer = io.BytesIO()
    self._convertHeaders(headers)
