Searched defs:bz2 (Results 1 - 9 of 9) sorted by relevance

/external/python/cpython2/Lib/encodings/
H A Dbz2_codec.py1 """ Python 'bz2_codec' Codec - bz2 compression encoding
11 import bz2 # this codec needs the optional bz2 module ! namespace
26 output = bz2.compress(input)
44 output = bz2.decompress(input)
58 self.compressobj = bz2.BZ2Compressor()
68 self.compressobj = bz2.BZ2Compressor()
74 self.decompressobj = bz2.BZ2Decompressor()
83 self.decompressobj = bz2.BZ2Decompressor()
95 name="bz2",
[all...]
/external/autotest/server/site_tests/telemetry_AFDOGenerate/
H A Dtelemetry_AFDOGenerate.py26 import bz2 namespace
284 """Given a file name, return bz2 compressed name.
288 return name + '.bz2'
292 """Compresses specified file with bz2.
302 with bz2.BZ2File(dest, 'w') as out:
/external/python/cpython2/Lib/
H A Dfileinput.py374 elif ext == '.bz2':
375 import bz2 namespace
376 return bz2.BZ2File(filename, mode)
H A Dtarfile.py434 elif comptype == "bz2":
436 import bz2 namespace
438 raise CompressionError("bz2 module is not available")
441 self.cmp = bz2.BZ2Decompressor()
443 self.cmp = bz2.BZ2Compressor()
639 return "bz2"
648 support for "r:bz2" and "w:bz2" modes. This is actually
649 a workaround for a limitation in bz2 module's BZ2File
663 import bz2 namespace
1768 import bz2 namespace
[all...]
/external/autotest/client/site_tests/graphics_dEQP/
H A Dgraphics_dEQP.py5 import bz2 namespace
156 if (not '.Pass.bz2' in subset_file and
159 bz2.BZ2File(subset_file).read().splitlines())
213 bz2.BZ2File(subset_file).read().splitlines())
279 subset_name = '%s.%s.bz2' % (test_filter, subset)
292 test_cases = bz2.BZ2File(subset_path).read().splitlines()
/external/python/cpython2/Tools/ccbench/
H A Dccbench.py117 """bz2 compression (C)"""
118 import bz2 namespace
123 bz2.compress(s)
138 for mod in 'bz2', 'hashlib':
144 # For whatever reasons, zlib gives irregular results, so we prefer bz2 or
147 if bz2 is not None:
/external/python/cpython2/Lib/test/
H A Dtest_bz2.py15 bz2 = import_module('bz2') variable
16 from bz2 import BZ2File, BZ2Compressor, BZ2Decompressor
38 ret = bz2.decompress(data)
44 return bz2.decompress(data)
256 # Bug #1194181: bz2.BZ2File opened for write with mode "U"
304 with bz2.BZ2File(self.filename, 'wb') as f:
314 with bz2.BZ2File(self.filename, 'wb') as f:
319 with bz2.BZ2File(self.filename, 'rb') as f:
336 f = bz2
[all...]
H A Dtest_codecs.py1625 import bz2 namespace
H A Dtest_tarfile.py23 import bz2 namespace
25 bz2 = None variable
33 bz2name = os.path.join(TEMPDIR, "testtar.tar.bz2")
232 mode = "r:bz2"
276 elif self.mode.endswith(":bz2"):
277 _open = bz2.BZ2File
376 elif self.mode.endswith(":bz2"):
377 _open = bz2.BZ2File
400 self.skipTest('needs a gz or bz2 mode')
577 if bz2
[all...]

Completed in 354 milliseconds