summaryrefslogtreecommitdiffstats
path: root/Doc/lib/libzlib.tex
diff options
context:
space:
mode:
authorAndrew M. Kuchling <amk@amk.ca>1998-12-31 21:14:23 (GMT)
committerAndrew M. Kuchling <amk@amk.ca>1998-12-31 21:14:23 (GMT)
commitf07c328c072e62ada8671ec30392572add22d904 (patch)
tree2770d595032422614cc0ab4407b6a0f393170c23 /Doc/lib/libzlib.tex
parentc0ef565cdf385db38db6dc9ad6f7f77a86f2c523 (diff)
downloadcpython-f07c328c072e62ada8671ec30392572add22d904.zip
cpython-f07c328c072e62ada8671ec30392572add22d904.tar.gz
cpython-f07c328c072e62ada8671ec30392572add22d904.tar.bz2
Document the optional mode argument (Z_FLUSH, Z_SYNC_FLUSH, etc.)
to the flush() method of compressor objects.
Diffstat (limited to 'Doc/lib/libzlib.tex')
-rw-r--r--Doc/lib/libzlib.tex15
1 files changed, 11 insertions, 4 deletions
diff --git a/Doc/lib/libzlib.tex b/Doc/lib/libzlib.tex
index 9dbb16b..aaf4684 100644
--- a/Doc/lib/libzlib.tex
+++ b/Doc/lib/libzlib.tex
@@ -87,11 +87,18 @@ concatenated to the output produced by any preceding calls to the
for later processing.
\end{methoddesc}
-\begin{methoddesc}[Compress]{flush}{}
-All pending input is processed, and an string containing the remaining
-compressed output is returned. After calling \method{flush()}, the
+\begin{methoddesc}[Compress]{flush}{\optional{mode}}
+All pending input is processed, and a string containing the remaining
+compressed output is returned. \var{mode} can be selected from the
+constants \constant{Z_SYNC_FLUSH}, \constant{Z_FULL_FLUSH}, or
+\constant{Z_FINISH}, defaulting to \constant{Z_FINISH}. \constant{Z_SYNC_FLUSH} and
+\constant{Z_FULL_FLUSH} allow compressing further strings of data and
+are used to allow partial error recovery on decompression, while
+\constant{Z_FINISH} finishes the compressed stream and
+prevents compressing any more data. After calling
+\method{flush()} with \var{mode} set to \constant{Z_FINISH}, the
\method{compress()} method cannot be called again; the only realistic
-action is to delete the object.
+action is to delete the object.
\end{methoddesc}
Decompression objects support the following methods: