Kaydet (Commit) 54820dc8 authored tarafından Fred Drake's avatar Fred Drake

Fixed index references to modules.

üst 6206394a
...@@ -75,7 +75,7 @@ to control pickling: they can define methods called ...@@ -75,7 +75,7 @@ to control pickling: they can define methods called
\code{__getinitargs__()}, \code{__getstate__()} and \code{__getinitargs__()}, \code{__getstate__()} and
\code{__setstate__()}. See the description of module \code{pickle} \code{__setstate__()}. See the description of module \code{pickle}
for information on these methods. for information on these methods.
\stmodindex{pickle} \refstmodindex{pickle}
\renewcommand{\indexsubitem}{(copy protocol)} \renewcommand{\indexsubitem}{(copy protocol)}
\ttindex{__getinitargs__} \ttindex{__getinitargs__}
\ttindex{__getstate__} \ttindex{__getstate__}
......
...@@ -19,10 +19,10 @@ from and extends the \code{SGMLParser} class defined in module ...@@ -19,10 +19,10 @@ from and extends the \code{SGMLParser} class defined in module
provided in the \code{formatter} module; refer to the documentation provided in the \code{formatter} module; refer to the documentation
for that module for information on the formatter interface. for that module for information on the formatter interface.
\index{SGML} \index{SGML}
\stmodindex{sgmllib} \refstmodindex{sgmllib}
\ttindex{SGMLParser} \ttindex{SGMLParser}
\index{formatter} \index{formatter}
\stmodindex{formatter} \refstmodindex{formatter}
The following is a summary of the interface defined by The following is a summary of the interface defined by
\code{sgmllib.SGMLParser}: \code{sgmllib.SGMLParser}:
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
This module defines a class which implements the client side of the This module defines a class which implements the client side of the
HTTP protocol. It is normally not used directly --- the module HTTP protocol. It is normally not used directly --- the module
\code{urllib} uses it to handle URLs that use HTTP. \code{urllib} uses it to handle URLs that use HTTP.
\stmodindex{urllib} \refstmodindex{urllib}
The module defines one class, \code{HTTP}. An \code{HTTP} instance The module defines one class, \code{HTTP}. An \code{HTTP} instance
represents one transaction with an HTTP server. It should be represents one transaction with an HTTP server. It should be
...@@ -98,7 +98,7 @@ handled properly); \var{message} is the message string corresponding ...@@ -98,7 +98,7 @@ handled properly); \var{message} is the message string corresponding
to the reply code; and \var{headers} is an instance of the class to the reply code; and \var{headers} is an instance of the class
\code{mimetools.Message} containing the headers received from the server. \code{mimetools.Message} containing the headers received from the server.
See the description of the \code{mimetools} module. See the description of the \code{mimetools} module.
\stmodindex{mimetools} \refstmodindex{mimetools}
\end{funcdesc} \end{funcdesc}
\begin{funcdesc}{getfile}{} \begin{funcdesc}{getfile}{}
......
...@@ -20,8 +20,8 @@ and transfer of Python objects through RPC calls, see the modules ...@@ -20,8 +20,8 @@ and transfer of Python objects through RPC calls, see the modules
\code{pickle} and \code{shelve}. The \code{marshal} module exists \code{pickle} and \code{shelve}. The \code{marshal} module exists
mainly to support reading and writing the ``pseudo-compiled'' code for mainly to support reading and writing the ``pseudo-compiled'' code for
Python modules of \samp{.pyc} files. Python modules of \samp{.pyc} files.
\stmodindex{pickle} \refstmodindex{pickle}
\stmodindex{shelve} \refstmodindex{shelve}
\obindex{code} \obindex{code}
Not all Python object types are supported; in general, only objects Not all Python object types are supported; in general, only objects
......
...@@ -25,7 +25,7 @@ byte streams is to write them onto a file, but it is also conceivable ...@@ -25,7 +25,7 @@ byte streams is to write them onto a file, but it is also conceivable
to send them across a network or store them in a database. The module to send them across a network or store them in a database. The module
\code{shelve} provides a simple interface to pickle and unpickle \code{shelve} provides a simple interface to pickle and unpickle
objects on ``dbm''-style database files. objects on ``dbm''-style database files.
\stmodindex{shelve} \refstmodindex{shelve}
\strong{Note:} The \code{pickle} module is rather slow. A \strong{Note:} The \code{pickle} module is rather slow. A
reimplementation of the same algorithm in C, which is up to 1000 times reimplementation of the same algorithm in C, which is up to 1000 times
...@@ -36,7 +36,7 @@ inheritance). ...@@ -36,7 +36,7 @@ inheritance).
Unlike the built-in module \code{marshal}, \code{pickle} handles the Unlike the built-in module \code{marshal}, \code{pickle} handles the
following correctly: following correctly:
\stmodindex{marshal} \refbimodindex{marshal}
\begin{itemize} \begin{itemize}
...@@ -74,7 +74,7 @@ it should, but there's probably no great need for it right now (as ...@@ -74,7 +74,7 @@ it should, but there's probably no great need for it right now (as
long as \code{marshal} continues to be used for reading and writing long as \code{marshal} continues to be used for reading and writing
code objects), and at least this avoids the possibility of smuggling code objects), and at least this avoids the possibility of smuggling
Trojan horses into a program. Trojan horses into a program.
\stmodindex{marshal} \refbimodindex{marshal}
For the benefit of persistency modules written using \code{pickle}, it For the benefit of persistency modules written using \code{pickle}, it
supports the notion of a reference to an object outside the pickled supports the notion of a reference to an object outside the pickled
......
...@@ -6,7 +6,7 @@ This module implements some useful functions on POSIX pathnames. ...@@ -6,7 +6,7 @@ This module implements some useful functions on POSIX pathnames.
\strong{Do not import this module directly.} Instead, import the \strong{Do not import this module directly.} Instead, import the
module \code{os} and use \code{os.path}. module \code{os} and use \code{os.path}.
\stmodindex{os} \refstmodindex{os}
\renewcommand{\indexsubitem}{(in module posixpath)} \renewcommand{\indexsubitem}{(in module posixpath)}
...@@ -38,6 +38,7 @@ initial \samp{\~{}} is replaced by the environment variable \code{\${}HOME}; ...@@ -38,6 +38,7 @@ initial \samp{\~{}} is replaced by the environment variable \code{\${}HOME};
an initial \samp{\~\var{user}} is looked up in the password directory through an initial \samp{\~\var{user}} is looked up in the password directory through
the built-in module \code{pwd}. If the expansion fails, or if the the built-in module \code{pwd}. If the expansion fails, or if the
path does not begin with a tilde, the path is returned unchanged. path does not begin with a tilde, the path is returned unchanged.
\refbimodindex{pwd}
\end{funcdesc} \end{funcdesc}
\begin{funcdesc}{expandvars}{p} \begin{funcdesc}{expandvars}{p}
...@@ -54,14 +55,14 @@ Return true if \var{p} is an absolute pathname (begins with a slash). ...@@ -54,14 +55,14 @@ Return true if \var{p} is an absolute pathname (begins with a slash).
\begin{funcdesc}{isfile}{p} \begin{funcdesc}{isfile}{p}
Return true if \var{p} is an existing regular file. This follows Return true if \var{p} is an existing regular file. This follows
symbolic links, so both \code{islink()} and \code{isfile()} can be true for the same symbolic links, so both \code{islink()} and \code{isfile()} can be
path. true for the same path.
\end{funcdesc} \end{funcdesc}
\begin{funcdesc}{isdir}{p} \begin{funcdesc}{isdir}{p}
Return true if \var{p} is an existing directory. This follows Return true if \var{p} is an existing directory. This follows
symbolic links, so both \code{islink()} and \code{isdir()} can be true for the same symbolic links, so both \code{islink()} and \code{isdir()} can be true
path. for the same path.
\end{funcdesc} \end{funcdesc}
\begin{funcdesc}{islink}{p} \begin{funcdesc}{islink}{p}
...@@ -97,7 +98,7 @@ lower case. ...@@ -97,7 +98,7 @@ lower case.
\begin{funcdesc}{samefile}{p\, q} \begin{funcdesc}{samefile}{p\, q}
Return true if both pathname arguments refer to the same file or directory Return true if both pathname arguments refer to the same file or directory
(as indicated by device number and i-node number). (as indicated by device number and i-node number).
Raise an exception if a stat call on either pathname fails. Raise an exception if a \code{stat()} call on either pathname fails.
\end{funcdesc} \end{funcdesc}
\begin{funcdesc}{split}{p} \begin{funcdesc}{split}{p}
......
...@@ -83,7 +83,7 @@ set at build time with the \code{--exec-prefix} argument to the ...@@ -83,7 +83,7 @@ set at build time with the \code{--exec-prefix} argument to the
(e.g. the \code{config.h} header file) are installed in the directory (e.g. the \code{config.h} header file) are installed in the directory
\code{sys.exec_prefix+"/lib/python\emph{VER}/config"}, and shared library \code{sys.exec_prefix+"/lib/python\emph{VER}/config"}, and shared library
modules are installed in modules are installed in
\code{sys.exec_prefix+"/lib/python\emph{VER}/sharedmodules"}, \code{sys.exec_prefix+"/lib/python\emph{VER}/lib-dynload"},
where \emph{VER} is equal to \code{sys.version[:3]}. where \emph{VER} is equal to \code{sys.version[:3]}.
\end{datadesc} \end{datadesc}
...@@ -115,7 +115,7 @@ without having to re-execute the command that caused the error. ...@@ -115,7 +115,7 @@ without having to re-execute the command that caused the error.
(Typical use is \code{import pdb; pdb.pm()} to enter the post-mortem (Typical use is \code{import pdb; pdb.pm()} to enter the post-mortem
debugger; see the chapter ``The Python Debugger'' for more debugger; see the chapter ``The Python Debugger'' for more
information.) information.)
\stmodindex{pdb} \refstmodindex{pdb}
The meaning of the variables is the same The meaning of the variables is the same
as that of the return values from \code{sys.exc_info()} above. as that of the return values from \code{sys.exc_info()} above.
...@@ -139,7 +139,7 @@ interpreter. If the script directory is not available (e.g. if the ...@@ -139,7 +139,7 @@ interpreter. If the script directory is not available (e.g. if the
interpreter is invoked interactively or if the script is read from interpreter is invoked interactively or if the script is read from
standard input), \code{sys.path[0]} is the empty string, which directs standard input), \code{sys.path[0]} is the empty string, which directs
Python to search modules in the current directory first. Notice that Python to search modules in the current directory first. Notice that
the script directory is inserted {\em before} the entries inserted as the script directory is inserted \emph{before} the entries inserted as
a result of \code{\$PYTHONPATH}. a result of \code{\$PYTHONPATH}.
\end{datadesc} \end{datadesc}
...@@ -215,11 +215,11 @@ maximizing responsiveness as well as overhead. ...@@ -215,11 +215,11 @@ maximizing responsiveness as well as overhead.
own prompts and (almost all of) its error messages go to own prompts and (almost all of) its error messages go to
\code{sys.stderr}. \code{sys.stdout} and \code{sys.stderr} needn't \code{sys.stderr}. \code{sys.stdout} and \code{sys.stderr} needn't
be built-in file objects: any object is acceptable as long as it has be built-in file objects: any object is acceptable as long as it has
a \code{write} method that takes a string argument. (Changing these a \code{write()} method that takes a string argument. (Changing these
objects doesn't affect the standard I/O streams of processes objects doesn't affect the standard I/O streams of processes
executed by \code{popen()}, \code{system()} or the \code{exec*()} executed by \code{popen()}, \code{system()} or the \code{exec*()}
family of functions in the \code{os} module.) family of functions in the \code{os} module.)
\stmodindex{os} \refstmodindex{os}
\end{datadesc} \end{datadesc}
\begin{datadesc}{tracebacklimit} \begin{datadesc}{tracebacklimit}
......
...@@ -75,7 +75,7 @@ to control pickling: they can define methods called ...@@ -75,7 +75,7 @@ to control pickling: they can define methods called
\code{__getinitargs__()}, \code{__getstate__()} and \code{__getinitargs__()}, \code{__getstate__()} and
\code{__setstate__()}. See the description of module \code{pickle} \code{__setstate__()}. See the description of module \code{pickle}
for information on these methods. for information on these methods.
\stmodindex{pickle} \refstmodindex{pickle}
\renewcommand{\indexsubitem}{(copy protocol)} \renewcommand{\indexsubitem}{(copy protocol)}
\ttindex{__getinitargs__} \ttindex{__getinitargs__}
\ttindex{__getstate__} \ttindex{__getstate__}
......
...@@ -19,10 +19,10 @@ from and extends the \code{SGMLParser} class defined in module ...@@ -19,10 +19,10 @@ from and extends the \code{SGMLParser} class defined in module
provided in the \code{formatter} module; refer to the documentation provided in the \code{formatter} module; refer to the documentation
for that module for information on the formatter interface. for that module for information on the formatter interface.
\index{SGML} \index{SGML}
\stmodindex{sgmllib} \refstmodindex{sgmllib}
\ttindex{SGMLParser} \ttindex{SGMLParser}
\index{formatter} \index{formatter}
\stmodindex{formatter} \refstmodindex{formatter}
The following is a summary of the interface defined by The following is a summary of the interface defined by
\code{sgmllib.SGMLParser}: \code{sgmllib.SGMLParser}:
......
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
This module defines a class which implements the client side of the This module defines a class which implements the client side of the
HTTP protocol. It is normally not used directly --- the module HTTP protocol. It is normally not used directly --- the module
\code{urllib} uses it to handle URLs that use HTTP. \code{urllib} uses it to handle URLs that use HTTP.
\stmodindex{urllib} \refstmodindex{urllib}
The module defines one class, \code{HTTP}. An \code{HTTP} instance The module defines one class, \code{HTTP}. An \code{HTTP} instance
represents one transaction with an HTTP server. It should be represents one transaction with an HTTP server. It should be
...@@ -98,7 +98,7 @@ handled properly); \var{message} is the message string corresponding ...@@ -98,7 +98,7 @@ handled properly); \var{message} is the message string corresponding
to the reply code; and \var{headers} is an instance of the class to the reply code; and \var{headers} is an instance of the class
\code{mimetools.Message} containing the headers received from the server. \code{mimetools.Message} containing the headers received from the server.
See the description of the \code{mimetools} module. See the description of the \code{mimetools} module.
\stmodindex{mimetools} \refstmodindex{mimetools}
\end{funcdesc} \end{funcdesc}
\begin{funcdesc}{getfile}{} \begin{funcdesc}{getfile}{}
......
...@@ -20,8 +20,8 @@ and transfer of Python objects through RPC calls, see the modules ...@@ -20,8 +20,8 @@ and transfer of Python objects through RPC calls, see the modules
\code{pickle} and \code{shelve}. The \code{marshal} module exists \code{pickle} and \code{shelve}. The \code{marshal} module exists
mainly to support reading and writing the ``pseudo-compiled'' code for mainly to support reading and writing the ``pseudo-compiled'' code for
Python modules of \samp{.pyc} files. Python modules of \samp{.pyc} files.
\stmodindex{pickle} \refstmodindex{pickle}
\stmodindex{shelve} \refstmodindex{shelve}
\obindex{code} \obindex{code}
Not all Python object types are supported; in general, only objects Not all Python object types are supported; in general, only objects
......
...@@ -25,7 +25,7 @@ byte streams is to write them onto a file, but it is also conceivable ...@@ -25,7 +25,7 @@ byte streams is to write them onto a file, but it is also conceivable
to send them across a network or store them in a database. The module to send them across a network or store them in a database. The module
\code{shelve} provides a simple interface to pickle and unpickle \code{shelve} provides a simple interface to pickle and unpickle
objects on ``dbm''-style database files. objects on ``dbm''-style database files.
\stmodindex{shelve} \refstmodindex{shelve}
\strong{Note:} The \code{pickle} module is rather slow. A \strong{Note:} The \code{pickle} module is rather slow. A
reimplementation of the same algorithm in C, which is up to 1000 times reimplementation of the same algorithm in C, which is up to 1000 times
...@@ -36,7 +36,7 @@ inheritance). ...@@ -36,7 +36,7 @@ inheritance).
Unlike the built-in module \code{marshal}, \code{pickle} handles the Unlike the built-in module \code{marshal}, \code{pickle} handles the
following correctly: following correctly:
\stmodindex{marshal} \refbimodindex{marshal}
\begin{itemize} \begin{itemize}
...@@ -74,7 +74,7 @@ it should, but there's probably no great need for it right now (as ...@@ -74,7 +74,7 @@ it should, but there's probably no great need for it right now (as
long as \code{marshal} continues to be used for reading and writing long as \code{marshal} continues to be used for reading and writing
code objects), and at least this avoids the possibility of smuggling code objects), and at least this avoids the possibility of smuggling
Trojan horses into a program. Trojan horses into a program.
\stmodindex{marshal} \refbimodindex{marshal}
For the benefit of persistency modules written using \code{pickle}, it For the benefit of persistency modules written using \code{pickle}, it
supports the notion of a reference to an object outside the pickled supports the notion of a reference to an object outside the pickled
......
...@@ -6,7 +6,7 @@ This module implements some useful functions on POSIX pathnames. ...@@ -6,7 +6,7 @@ This module implements some useful functions on POSIX pathnames.
\strong{Do not import this module directly.} Instead, import the \strong{Do not import this module directly.} Instead, import the
module \code{os} and use \code{os.path}. module \code{os} and use \code{os.path}.
\stmodindex{os} \refstmodindex{os}
\renewcommand{\indexsubitem}{(in module posixpath)} \renewcommand{\indexsubitem}{(in module posixpath)}
...@@ -38,6 +38,7 @@ initial \samp{\~{}} is replaced by the environment variable \code{\${}HOME}; ...@@ -38,6 +38,7 @@ initial \samp{\~{}} is replaced by the environment variable \code{\${}HOME};
an initial \samp{\~\var{user}} is looked up in the password directory through an initial \samp{\~\var{user}} is looked up in the password directory through
the built-in module \code{pwd}. If the expansion fails, or if the the built-in module \code{pwd}. If the expansion fails, or if the
path does not begin with a tilde, the path is returned unchanged. path does not begin with a tilde, the path is returned unchanged.
\refbimodindex{pwd}
\end{funcdesc} \end{funcdesc}
\begin{funcdesc}{expandvars}{p} \begin{funcdesc}{expandvars}{p}
...@@ -54,14 +55,14 @@ Return true if \var{p} is an absolute pathname (begins with a slash). ...@@ -54,14 +55,14 @@ Return true if \var{p} is an absolute pathname (begins with a slash).
\begin{funcdesc}{isfile}{p} \begin{funcdesc}{isfile}{p}
Return true if \var{p} is an existing regular file. This follows Return true if \var{p} is an existing regular file. This follows
symbolic links, so both \code{islink()} and \code{isfile()} can be true for the same symbolic links, so both \code{islink()} and \code{isfile()} can be
path. true for the same path.
\end{funcdesc} \end{funcdesc}
\begin{funcdesc}{isdir}{p} \begin{funcdesc}{isdir}{p}
Return true if \var{p} is an existing directory. This follows Return true if \var{p} is an existing directory. This follows
symbolic links, so both \code{islink()} and \code{isdir()} can be true for the same symbolic links, so both \code{islink()} and \code{isdir()} can be true
path. for the same path.
\end{funcdesc} \end{funcdesc}
\begin{funcdesc}{islink}{p} \begin{funcdesc}{islink}{p}
...@@ -97,7 +98,7 @@ lower case. ...@@ -97,7 +98,7 @@ lower case.
\begin{funcdesc}{samefile}{p\, q} \begin{funcdesc}{samefile}{p\, q}
Return true if both pathname arguments refer to the same file or directory Return true if both pathname arguments refer to the same file or directory
(as indicated by device number and i-node number). (as indicated by device number and i-node number).
Raise an exception if a stat call on either pathname fails. Raise an exception if a \code{stat()} call on either pathname fails.
\end{funcdesc} \end{funcdesc}
\begin{funcdesc}{split}{p} \begin{funcdesc}{split}{p}
......
...@@ -83,7 +83,7 @@ set at build time with the \code{--exec-prefix} argument to the ...@@ -83,7 +83,7 @@ set at build time with the \code{--exec-prefix} argument to the
(e.g. the \code{config.h} header file) are installed in the directory (e.g. the \code{config.h} header file) are installed in the directory
\code{sys.exec_prefix+"/lib/python\emph{VER}/config"}, and shared library \code{sys.exec_prefix+"/lib/python\emph{VER}/config"}, and shared library
modules are installed in modules are installed in
\code{sys.exec_prefix+"/lib/python\emph{VER}/sharedmodules"}, \code{sys.exec_prefix+"/lib/python\emph{VER}/lib-dynload"},
where \emph{VER} is equal to \code{sys.version[:3]}. where \emph{VER} is equal to \code{sys.version[:3]}.
\end{datadesc} \end{datadesc}
...@@ -115,7 +115,7 @@ without having to re-execute the command that caused the error. ...@@ -115,7 +115,7 @@ without having to re-execute the command that caused the error.
(Typical use is \code{import pdb; pdb.pm()} to enter the post-mortem (Typical use is \code{import pdb; pdb.pm()} to enter the post-mortem
debugger; see the chapter ``The Python Debugger'' for more debugger; see the chapter ``The Python Debugger'' for more
information.) information.)
\stmodindex{pdb} \refstmodindex{pdb}
The meaning of the variables is the same The meaning of the variables is the same
as that of the return values from \code{sys.exc_info()} above. as that of the return values from \code{sys.exc_info()} above.
...@@ -139,7 +139,7 @@ interpreter. If the script directory is not available (e.g. if the ...@@ -139,7 +139,7 @@ interpreter. If the script directory is not available (e.g. if the
interpreter is invoked interactively or if the script is read from interpreter is invoked interactively or if the script is read from
standard input), \code{sys.path[0]} is the empty string, which directs standard input), \code{sys.path[0]} is the empty string, which directs
Python to search modules in the current directory first. Notice that Python to search modules in the current directory first. Notice that
the script directory is inserted {\em before} the entries inserted as the script directory is inserted \emph{before} the entries inserted as
a result of \code{\$PYTHONPATH}. a result of \code{\$PYTHONPATH}.
\end{datadesc} \end{datadesc}
...@@ -215,11 +215,11 @@ maximizing responsiveness as well as overhead. ...@@ -215,11 +215,11 @@ maximizing responsiveness as well as overhead.
own prompts and (almost all of) its error messages go to own prompts and (almost all of) its error messages go to
\code{sys.stderr}. \code{sys.stdout} and \code{sys.stderr} needn't \code{sys.stderr}. \code{sys.stdout} and \code{sys.stderr} needn't
be built-in file objects: any object is acceptable as long as it has be built-in file objects: any object is acceptable as long as it has
a \code{write} method that takes a string argument. (Changing these a \code{write()} method that takes a string argument. (Changing these
objects doesn't affect the standard I/O streams of processes objects doesn't affect the standard I/O streams of processes
executed by \code{popen()}, \code{system()} or the \code{exec*()} executed by \code{popen()}, \code{system()} or the \code{exec*()}
family of functions in the \code{os} module.) family of functions in the \code{os} module.)
\stmodindex{os} \refstmodindex{os}
\end{datadesc} \end{datadesc}
\begin{datadesc}{tracebacklimit} \begin{datadesc}{tracebacklimit}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment