From 06afe9f695fe9027007ba3924943536cf84834c5 Mon Sep 17 00:00:00 2001 From: Andrew Svetlov Date: Tue, 20 Jan 2015 19:19:58 +0200 Subject: [PATCH] Document compression --- docs/web_reference.rst | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/docs/web_reference.rst b/docs/web_reference.rst index c278b3f2a67..4f51fdbbc7a 100644 --- a/docs/web_reference.rst +++ b/docs/web_reference.rst @@ -140,6 +140,29 @@ first positional parameter. .. versionadded:: 0.15 + .. attribute:: compression + + Read-only :class:`bool` property, ``True`` if compression is enabled. + + ``False`` by default. + + .. versionadded:: 0.14 + + .. seealso:: :meth:`enable_compression` + + .. method:: enable_compression(force=False) + + Enable compression. + + When *force* is ``False`` (default) compression is used only + when *deflate* is in *Accept-Encoding* request's header. + + *Accept-Encoding* is not checked if *force* is ``True``. + + .. versionadded:: 0.14 + + .. seealso:: :attr:`compression` + .. attribute:: payload A :class:`~aiohttp.streams.FlowControlStreamReader` instance,