diff options
author | Skip Montanaro <skip@pobox.com> | 2004-01-21 13:47:04 (GMT) |
---|---|---|
committer | Skip Montanaro <skip@pobox.com> | 2004-01-21 13:47:04 (GMT) |
commit | ba0485a92d615dee89cc8eac24cd3a46d8a26a2f (patch) | |
tree | b37ce5a3d29bd3e3ba18ab200aaaf36ebec1cd7b | |
parent | 7895146c4065db61909cae7279e5c8c91b091d16 (diff) | |
download | cpython-ba0485a92d615dee89cc8eac24cd3a46d8a26a2f.zip cpython-ba0485a92d615dee89cc8eac24cd3a46d8a26a2f.tar.gz cpython-ba0485a92d615dee89cc8eac24cd3a46d8a26a2f.tar.bz2 |
expand on notion of row object type
-rw-r--r-- | Doc/lib/libcsv.tex | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/Doc/lib/libcsv.tex b/Doc/lib/libcsv.tex index dda1924..9cf5044 100644 --- a/Doc/lib/libcsv.tex +++ b/Doc/lib/libcsv.tex @@ -285,8 +285,14 @@ according to the current dialect. \subsection{Writer Objects} -Writer objects (\class{DictWriter} instances and objects returned by -the \function{writer()} function) have the following public methods: +\class{Writer} objects (\class{DictWriter} instances and objects returned by +the \function{writer()} function) have the following public methods. A +{}\var{row} must be a sequence of strings or numbers for \class{Writer} +objects and a dictionary mapping fieldnames to strings or numbers (by +passing them through \function{str()} first) for {}\class{DictWriter} +objects. Note that complex numbers are written out surrounded by parens. +This may cause some problems for other programs which read CSV files +(assuming they support complex numbers at all). \begin{methoddesc}[csv writer]{writerow}{row} Write the \var{row} parameter to the writer's file object, formatted @@ -294,7 +300,8 @@ according to the current dialect. \end{methoddesc} \begin{methoddesc}[csv writer]{writerows}{rows} -Write all the \var{rows} parameters to the writer's file object, formatted +Write all the \var{rows} parameters (a list of \var{row} objects as +described above) to the writer's file object, formatted according to the current dialect. \end{methoddesc} |