Commit 58c95391 authored by Fred Drake's avatar Fred Drake

Removed some stray periods, and fix up a number of visible markup

consistency errors (mostly omitted "()" at the end of function and
method names).

Reported by Milan Zamazal <pdm@zamazal.org>.
parent 9c3c5e40
...@@ -28,18 +28,19 @@ whose values are \class{Morsel}s. Note that upon setting a key to ...@@ -28,18 +28,19 @@ whose values are \class{Morsel}s. Note that upon setting a key to
a value, the value is first converted to a \class{Morsel} containing a value, the value is first converted to a \class{Morsel} containing
the key and the value. the key and the value.
If \var{input} is given, it is passed to the \method{load} method. If \var{input} is given, it is passed to the \method{load()} method.
\end{classdesc} \end{classdesc}
\begin{classdesc}{SimpleCookie}{\optional{input}} \begin{classdesc}{SimpleCookie}{\optional{input}}
This class derives from \class{BaseCookie} and overrides \method{value_decode} This class derives from \class{BaseCookie} and overrides
and \method{value_encode} to be the identity and \function{str()} respectively. \method{value_decode()} and \method{value_encode()} to be the identity
and \function{str()} respectively.
\end{classdesc} \end{classdesc}
\begin{classdesc}{SerialCookie}{\optional{input}} \begin{classdesc}{SerialCookie}{\optional{input}}
This class derives from \class{BaseCookie} and overrides \method{value_decode} This class derives from \class{BaseCookie} and overrides
and \method{value_encode} to be the \function{pickle.loads()} and \method{value_decode()} and \method{value_encode()} to be the
\function{pickle.dumps}. \function{pickle.loads()} and \function{pickle.dumps()}.
Do not use this class. Reading pickled values from a cookie is a Do not use this class. Reading pickled values from a cookie is a
security hole, as arbitrary client-code can be run on security hole, as arbitrary client-code can be run on
...@@ -49,11 +50,11 @@ compatibility. ...@@ -49,11 +50,11 @@ compatibility.
\end{classdesc} \end{classdesc}
\begin{classdesc}{SmartCookie}{\optional{input}} \begin{classdesc}{SmartCookie}{\optional{input}}
This class derives from \class{BaseCookie}. It overrides \method{value_decode} This class derives from \class{BaseCookie}. It overrides
to be \function{pickle.loads()} if it is a valid pickle, and otherwise \method{value_decode()} to be \function{pickle.loads()} if it is a
the value itself. It overrides \method{value_encode} to be valid pickle, and otherwise the value itself. It overrides
\function{pickle.dumps()} unless it is a string, in which case it returns \method{value_encode()} to be \function{pickle.dumps()} unless it is a
the value itself. string, in which case it returns the value itself.
The same security warning from \class{SerialCookie} applies here. The same security warning from \class{SerialCookie} applies here.
\end{classdesc} \end{classdesc}
...@@ -78,15 +79,15 @@ Return an encoded value. \var{val} can be any type, but return value ...@@ -78,15 +79,15 @@ Return an encoded value. \var{val} can be any type, but return value
must be a string. This method does nothing in \class{BaseCookie} --- it exists must be a string. This method does nothing in \class{BaseCookie} --- it exists
so it can be overridden so it can be overridden
In general, it should be the case that \method{value_encode} and In general, it should be the case that \method{value_encode()} and
\method{value_decode} are inverses on the range of \var{value_decode}. \method{value_decode()} are inverses on the range of \var{value_decode}.
\end{methoddesc}. \end{methoddesc}
\begin{methoddesc}[BaseCookie]{output}{\optional{attrs\optional{, header\optional{, sep}}}} \begin{methoddesc}[BaseCookie]{output}{\optional{attrs\optional{, header\optional{, sep}}}}
Return a string representation suitable to be sent as HTTP headers. Return a string representation suitable to be sent as HTTP headers.
\var{attrs} and \var{header} are sent to each \class{Morsel}'s \method{output} \var{attrs} and \var{header} are sent to each \class{Morsel}'s
method. \var{sep} is used to join the headers together, and is by default \method{output()} method. \var{sep} is used to join the headers
a newline. together, and is by default a newline.
\end{methoddesc} \end{methoddesc}
\begin{methoddesc}[BaseCookie]{js_output}{\optional{attrs}} \begin{methoddesc}[BaseCookie]{js_output}{\optional{attrs}}
...@@ -161,7 +162,7 @@ Return an embeddable JavaScript snippet, which, if run on a browser which ...@@ -161,7 +162,7 @@ Return an embeddable JavaScript snippet, which, if run on a browser which
supports JavaScript, will act the same as if the HTTP header was sent. supports JavaScript, will act the same as if the HTTP header was sent.
The meaning for \var{attrs} is the same as in \method{output()}. The meaning for \var{attrs} is the same as in \method{output()}.
\end{methoddesc}. \end{methoddesc}
\begin{methoddesc}[Morsel]{OutputString}{\optional{attrs}} \begin{methoddesc}[Morsel]{OutputString}{\optional{attrs}}
Return a string representing the Morsel, without any surrounding HTTP Return a string representing the Morsel, without any surrounding HTTP
......
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