Module httplib :: Class HTTPConnection
[show private | hide private]
[frames | no frames]

Class HTTPConnection

Known Subclasses:
GSIHTTPConnection

Method Summary
  __init__(self, host, port)
  close(self)
Close the connection to the HTTP server.
  connect(self)
Connect to the host and port specified in __init__.
  endheaders(self)
Indicate that the last header line has been sent to the server.
  getresponse(self)
Get the response from the server.
  putheader(self, header, value)
Send a request header line to the server.
  putrequest(self, method, url, skip_host)
Send a request to the server.
  request(self, method, url, body, headers)
Send a complete request to the server.
  send(self, str)
Send `str' to the server.
  set_debuglevel(self, level)
  _send_request(self, method, url, body, headers)
  _set_hostport(self, host, port)

Class Variable Summary
int auto_open = 1                                                                     
int debuglevel = 0                                                                     
int default_port = 80                                                                    
class response_class = httplib.HTTPResponse
int _http_vsn = 11                                                                    
str _http_vsn_str = 'HTTP/1.1'

Method Details

close(self)

Close the connection to the HTTP server.

connect(self)

Connect to the host and port specified in __init__.

endheaders(self)

Indicate that the last header line has been sent to the server.

getresponse(self)

Get the response from the server.

putheader(self, header, value)

Send a request header line to the server.

For example: h.putheader('Accept', 'text/html')

putrequest(self, method, url, skip_host=0)

Send a request to the server.

`method' specifies an HTTP request method, e.g. 'GET'. `url' specifies the object being requested, e.g. '/index.html'.

request(self, method, url, body=None, headers={})

Send a complete request to the server.

send(self, str)

Send `str' to the server.

Class Variable Details

auto_open

Type:
int
Value:
1                                                                     

debuglevel

Type:
int
Value:
0                                                                     

default_port

Type:
int
Value:
80                                                                    

_http_vsn

Type:
int
Value:
11                                                                    

_http_vsn_str

Type:
str
Value:
'HTTP/1.1'                                                             

Generated by Epydoc 2.0 on Thu Jul 29 13:45:01 2004 http://epydoc.sf.net