http://svn.python.org/projects/python/trunk/Lib/httplib.py

http 1.1 客户端类库"""HTTP/1.1 client library
http 1.1 客户端类库

http 1.1 客户端类库
<intro stuff goes here>
http 1.1 客户端类库
<other stuff, too>
http 1.1 客户端类库
http 1.1 客户端类库HTTPConnection goes through a number of 
"states", which define when a client
http 1.1 客户端类库may legally make another request or fetch the response 
for a particular
http 1.1 客户端类库request. This diagram details these state transitions:
http 1.1 客户端类库
http 1.1 客户端类库    (
null)
http 1.1 客户端类库      
|
http 1.1 客户端类库      
| HTTPConnection()
http 1.1 客户端类库      v
http 1.1 客户端类库    Idle
http 1.1 客户端类库      
|
http 1.1 客户端类库      
| putrequest()
http 1.1 客户端类库      v
http 1.1 客户端类库    Request
-started
http 1.1 客户端类库      
|
http 1.1 客户端类库      
| ( putheader() )*  endheaders()
http 1.1 客户端类库      v
http 1.1 客户端类库    Request
-sent
http 1.1 客户端类库      
|
http 1.1 客户端类库      
| response = getresponse()
http 1.1 客户端类库      v
http 1.1 客户端类库    Unread
-response   [Response-headers-read]
http 1.1 客户端类库      
|\____________________
http 1.1 客户端类库      
|                     |
http 1.1 客户端类库      
| response.read()     | putrequest()
http 1.1 客户端类库      v                     v
http 1.1 客户端类库    Idle                  Req
-started-unread-response
http 1.1 客户端类库                     ______
/|
http 1.1 客户端类库                   
/        |
http 1.1 客户端类库   response.read() 
|        | ( putheader() )*  endheaders()
http 1.1 客户端类库                   v        v
http 1.1 客户端类库       Request
-started    Req-sent-unread-response
http 1.1 客户端类库                            
|
http 1.1 客户端类库                            
| response.read()
http 1.1 客户端类库                            v
http 1.1 客户端类库                          Request
-sent
http 1.1 客户端类库
http 1.1 客户端类库This diagram presents the following rules:

相关文章: