HTTP Objects

HTTP instances have the following methods:
\begin{funcdesc}{set_debuglevel}{level}
Set the debugging level (the amount of d...
... debug level is \code{0}, meaning no debugging output is
printed.
\end{funcdesc}

\begin{funcdesc}{connect}{host\optional{\, port}}
Connect to the server given by...
...tly only if
the instance was instantiated without passing a host.
\end{funcdesc}

\begin{funcdesc}{send}{data}
Send data to the server. This should be used direct...
...hod has been called and before
\code{getreply()} has been called.
\end{funcdesc}

\begin{funcdesc}{putrequest}{request\, selector}
This should be the first call a...
...he \var{selector} string, and the HTTP version
(\code{HTTP/1.0}).
\end{funcdesc}

\begin{funcdesc}{putheader}{header\, argument\optional{\, ...}}
Send an RFC-822 ...
...nuation lines are sent,
each consisting of a tab and an argument.
\end{funcdesc}

\begin{funcdesc}{endheaders}{}
Send a blank line to the server, signalling the end of the headers.
\end{funcdesc}

\begin{funcdesc}{getreply}{}
Complete the request by shutting down the sending e...
... the description of the \code{rfc822} module.
\stmodindex{rfc822}
\end{funcdesc}

\begin{funcdesc}{getfile}{}
Return a file object from which the data returned by...
...e \code{read()}, \code{readline()} or \code{readlines()}
methods.
\end{funcdesc}