CARVIEW |
Select Language
HTTP/2 302
server: nginx
date: Tue, 05 Aug 2025 20:41:57 GMT
content-type: text/plain; charset=utf-8
content-length: 0
x-archive-redirect-reason: found capture at 20071208102657
location: https://web.archive.org/web/20071208102657/https://wiki.python.org/moin/StreamReader
server-timing: captures_list;dur=0.789756, exclusion.robots;dur=0.031365, exclusion.robots.policy;dur=0.014588, esindex;dur=0.019891, cdx.remote;dur=41.112201, LoadShardBlock;dur=498.380046, PetaboxLoader3.datanode;dur=158.995884, PetaboxLoader3.resolve;dur=312.815083
x-app-server: wwwb-app213
x-ts: 302
x-tr: 574
server-timing: TR;dur=0,Tw;dur=0,Tc;dur=0
set-cookie: wb-p-SERVER=wwwb-app213; path=/
x-location: All
x-rl: 0
x-na: 0
x-page-cache: MISS
server-timing: MISS
x-nid: DigitalOcean
referrer-policy: no-referrer-when-downgrade
permissions-policy: interest-cohort=()
HTTP/2 200
server: nginx
date: Tue, 05 Aug 2025 20:41:58 GMT
content-type: text/html;charset=utf-8
x-archive-orig-date: Sat, 08 Dec 2007 10:26:56 GMT
x-archive-orig-server: Apache/2.0.54 (Debian GNU/Linux) mod_fastcgi/2.4.2
x-archive-orig-connection: close
x-archive-guessed-content-type: text/html
x-archive-guessed-charset: utf-8
memento-datetime: Sat, 08 Dec 2007 10:26:57 GMT
link: ; rel="original", ; rel="timemap"; type="application/link-format", ; rel="timegate", ; rel="first memento"; datetime="Sat, 08 Dec 2007 10:26:57 GMT", ; rel="memento"; datetime="Sat, 08 Dec 2007 10:26:57 GMT", ; rel="next memento"; datetime="Fri, 23 Oct 2009 05:36:06 GMT", ; rel="last memento"; datetime="Tue, 15 Apr 2025 14:32:13 GMT"
content-security-policy: default-src 'self' 'unsafe-eval' 'unsafe-inline' data: blob: archive.org web.archive.org web-static.archive.org wayback-api.archive.org athena.archive.org analytics.archive.org pragma.archivelab.org wwwb-events.archive.org
x-archive-src: 52_1_20071208084132_crawl105-c/52_1_20071208102225_crawl107.arc.gz
server-timing: captures_list;dur=0.523444, exclusion.robots;dur=0.020165, exclusion.robots.policy;dur=0.009609, esindex;dur=0.011701, cdx.remote;dur=62.644618, LoadShardBlock;dur=462.564157, PetaboxLoader3.datanode;dur=222.008942, PetaboxLoader3.resolve;dur=722.498460, load_resource;dur=532.481488
x-app-server: wwwb-app213
x-ts: 200
x-tr: 1106
server-timing: TR;dur=0,Tw;dur=0,Tc;dur=0
x-location: All
x-rl: 0
x-na: 0
x-page-cache: MISS
server-timing: MISS
x-nid: DigitalOcean
referrer-policy: no-referrer-when-downgrade
permissions-policy: interest-cohort=()
content-encoding: gzip
StreamReader - PythonInfo Wiki
StreamReader
As of Python2.5, StreamReader wraps (contains) a stream. It defines read and other respective methods to read the data from the stream and "decode" them. The class exposes all other methods of the stream instance.
Pseudocode of the codecs.StreamReader definition:
1 class StreamReader(Codec):
2 def __init__(self, stream):
3 ....
4
5 def read(self):
6 return self.decode(stream.read())
The decode method normally converts values of type str to unicode.
Codec modules will attach the decode method to the class definition derived from StreamReader during the initialization. An excerpt from encodings.utf_8.StreamReader:
1 class StreamReader(codecs.StreamReader):
2 decode = codecs.utf_8_decode
See also: StreamWriter, StreamReaderWriter, StreamRecoder.
EditText (last edited 2007-04-02 22:38:49 by IlguizLatypov)
DeleteCache (cached 2007-09-01 22:08:48)- Login
- Navigation
- Actions
- Your recent pages