summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNadeem Vawda <nadeem.vawda@gmail.com>2012-02-04 11:08:11 (GMT)
committerNadeem Vawda <nadeem.vawda@gmail.com>2012-02-04 11:08:11 (GMT)
commitcac8909d0cfe0f52fd0a0409ca58d46b34e58962 (patch)
treed41c102cb5f1600839a717c89e096ac90d575eb2
parentff962c5f1f197dacf831431898370b7425cae2a1 (diff)
downloadcpython-cac8909d0cfe0f52fd0a0409ca58d46b34e58962.zip
cpython-cac8909d0cfe0f52fd0a0409ca58d46b34e58962.tar.gz
cpython-cac8909d0cfe0f52fd0a0409ca58d46b34e58962.tar.bz2
Update docstring for BZ2File.__init__().
-rw-r--r--Lib/bz2.py10
1 files changed, 7 insertions, 3 deletions
diff --git a/Lib/bz2.py b/Lib/bz2.py
index 36e5558..5c228f9 100644
--- a/Lib/bz2.py
+++ b/Lib/bz2.py
@@ -47,13 +47,17 @@ class BZ2File(io.BufferedIOBase):
the file object given by fileobj. Exactly one of these two
parameters should be provided.
- mode can be 'r' for reading (default), or 'w' for writing.
+ mode can be 'r' for reading (default), 'w' for (over)writing, or
+ 'a' for appending.
buffering is ignored. Its use is deprecated.
- If mode is 'w', compresslevel can be a number between 1 and 9
- specifying the level of compression: 1 produces the least
+ If mode is 'w' or 'a', compresslevel can be a number between 1
+ and 9 specifying the level of compression: 1 produces the least
compression, and 9 (default) produces the most compression.
+
+ If mode is 'r', the input file may be the concatenation of
+ multiple compressed streams.
"""
# This lock must be recursive, so that BufferedIOBase's
# readline(), readlines() and writelines() don't deadlock.