Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 5967667

Browse files
committed
Documented FTP.set_pasv().
1 parent f3963b1 commit 5967667

1 file changed

Lines changed: 15 additions & 13 deletions

File tree

Doc/lib/libftplib.tex

Lines changed: 15 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,17 @@
11
\section{\module{ftplib} ---
2-
FTP protocol client.}
3-
\declaremodule{standard}{ftplib}
2+
FTP protocol client}
43

4+
\declaremodule{standard}{ftplib}
55
\modulesynopsis{FTP protocol client (requires sockets).}
66

7-
\indexii{FTP}{protocol}
8-
97

108
This module defines the class \class{FTP} and a few related items.
11-
The \class{FTP} class implements the client side of the FTP protocol.
12-
You can use this to write Python programs that perform a variety of
13-
automated FTP jobs, such as mirroring other ftp servers. It is also
14-
used by the module \module{urllib} to handle URLs that use FTP. For
15-
more information on FTP (File Transfer Protocol), see Internet
16-
\rfc{959}.
9+
The \class{FTP} class implements the client side of the FTP
10+
protocol.\indexii{FTP}{protocol} You can use this to write Python
11+
programs that perform a variety of automated FTP jobs, such as
12+
mirroring other ftp servers. It is also used by the module
13+
\refmodule{urllib} to handle URLs that use FTP. For more information
14+
on FTP (File Transfer Protocol), see Internet \rfc{959}.
1715

1816
Here's a sample session using the \module{ftplib} module:
1917

@@ -71,8 +69,7 @@ \section{\module{ftplib} ---
7169
\end{excdesc}
7270

7371

74-
\subsection{FTP Objects}
75-
\label{ftp-objects}
72+
\subsection{FTP Objects \label{ftp-objects}}
7673

7774
\class{FTP} instances have the following methods:
7875

@@ -104,7 +101,7 @@ \subsection{FTP Objects}
104101
Log in as the given \var{user}. The \var{passwd} and \var{acct}
105102
parameters are optional and default to the empty string. If no
106103
\var{user} is specified, it defaults to \code{'anonymous'}. If
107-
\var{user} is \code{anonymous}, the default \var{passwd} is
104+
\var{user} is \code{'anonymous'}, the default \var{passwd} is
108105
\samp{\var{realuser}@\var{host}} where \var{realuser} is the real user
109106
name (glanced from the \envvar{LOGNAME} or \envvar{USER} environment
110107
variable) and \var{host} is the hostname as returned by
@@ -151,6 +148,11 @@ \subsection{FTP Objects}
151148
the line to \code{sys.stdout}.
152149
\end{methoddesc}
153150

151+
\begin{methoddesc}{set_pasv}{boolean}
152+
Enable ``passive'' mode if \var{boolean} is true, other disable
153+
passive mode.
154+
\end{methoddesc}
155+
154156
\begin{methoddesc}{storbinary}{command, file, blocksize}
155157
Store a file in binary transfer mode. \var{command} should be an
156158
appropriate \samp{STOR} command, i.e.\ \code{"STOR \var{filename}"}.

0 commit comments

Comments
 (0)