'Iterate over response data.
.. versionadded:: 1.6
:param chunk_size: Number of bytes to read into memory
:type chunk_size: ``int``
:param decode_unicode: Decode to Unicode using detected encoding
:type decode_unicode: ``Boolean``
:returns: iterator'

def iter_content(self, chunk_size=4096, decode_unicode=False):

    if (not self.stream):
        raise RuntimeError('You    cannot    call    `iter_content`    on    a    Response    unless    you    passed    `stream=True`    to    `get()`/`post()`/`request()`.')
    if self._content_loaded:
        raise RuntimeError('`content`    has    already    been    read    from    this    Response.')
    def decode_stream(iterator, r):
        decoder = codecs.getincrementaldecoder(r.encoding)(errors='replace')
        for chunk in iterator:
            data = decoder.decode(chunk)
            if data:
                (yield data)
        data = decoder.decode('', final=True)
        if data:
            (yield data)
    def generate():
        if self._gzipped:
            decoder = zlib.decompressobj((16 + zlib.MAX_WBITS))
        while True:
            chunk = self.raw.read(chunk_size)
            if (not chunk):
                break
            if self._gzipped:
                chunk = decoder.decompress(chunk)
            (yield chunk)
    chunks = generate()
    if (decode_unicode and self.encoding):
        chunks = decode_stream(chunks, self)
    return chunks
