gzip_decoder.py
def decompress_raw_data_to_unicode_stream(raw_data_fd):
    """
    Decompresses a raw data in file like object and yields
    a Unicode string.
    """
    obj = zlib.decompressobj(MAGIC_NUMBER + zlib.MAX_WBITS)
    yield u'['
    d = raw_data_fd.read(CHUNK_SIZE)
    while d:
        yield obj.decompress(d).decode(u'utf-8')
        while obj.unused_data != b'':
            unused_data = obj.unused_data
            obj = zlib.decompressobj(MAGIC_NUMBER + zlib.MAX_WBITS)
            yield obj.decompress(unused_data).decode(u'utf-8')
        d = raw_data_fd.read(CHUNK_SIZE)
    yield obj.flush().decode(u'utf-8') + u']'

    Decompresses a raw data in file like object and yields
    a Unicode string.
    
Decompresses a raw data in file like object and yields
a Unicode string.
Decompresses a raw data in file like object and yields a Unicode string .
def decompress_raw_data_to_unicode_stream(raw_data_fd):
    obj = zlib.decompressobj(MAGIC_NUMBER + zlib.MAX_WBITS)
    yield u'['
    d = raw_data_fd.read(CHUNK_SIZE)
    while d:
        yield obj.decompress(d).decode(u'utf-8')
        while obj.unused_data != b'':
            unused_data = obj.unused_data
            obj = zlib.decompressobj(MAGIC_NUMBER + zlib.MAX_WBITS)
            yield obj.decompress(unused_data).decode(u'utf-8')
        d = raw_data_fd.read(CHUNK_SIZE)
    yield obj.flush().decode(u'utf-8') + u']'
def decompress_raw_data_to_unicode_stream ( raw_data_fd ) : obj = zlib . decompressobj ( MAGIC_NUMBER + zlib . MAX_WBITS ) yield u'[' d = raw_data_fd . read ( CHUNK_SIZE ) while d : yield obj . decompress ( d ) . decode ( u'utf-8' ) while obj . unused_data != b'' : unused_data = obj . unused_data obj = zlib . decompressobj ( MAGIC_NUMBER + zlib . MAX_WBITS ) yield obj . decompress ( unused_data ) . decode ( u'utf-8' ) d = raw_data_fd . read ( CHUNK_SIZE ) yield obj . flush ( ) . decode ( u'utf-8' ) + u']'
Decompresses a raw data in file like object and yields
a Unicode string.
Decompresses a raw data in file like object and yields a Unicode string .
"""
    Decompresses a raw data in file like object and yields
    a Unicode string.
    """
raw_data_fd