Kaydet (Commit) 3ffe5639 authored tarafından Andrew M. Kuchling's avatar Andrew M. Kuchling

Correction from Antoine Pitrou: BufferedWriter and Reader support seek()

üst bf0a5951
...@@ -1025,12 +1025,13 @@ the :mod:`io` module: ...@@ -1025,12 +1025,13 @@ the :mod:`io` module:
There are five concrete classes implementing this ABC. There are five concrete classes implementing this ABC.
:class:`BufferedWriter` and :class:`BufferedReader` are for objects :class:`BufferedWriter` and :class:`BufferedReader` are for objects
that only support writing or reading and don't support random that support write-only or read-only usage that have a :meth:`seek`
access. :class:`BufferedRandom` adds the :meth:`seek` method for method for random access. :class:`BufferedRandom` objects support
random access, and :class:`BufferedRWPair` is for objects such as read and write access upon the same underlying stream, and
TTYs that have both read and write operations that act upon :class:`BufferedRWPair` is for objects such as TTYs that have both
unconnected streams of data. The :class:`BytesIO` read and write operations acting upon unconnected streams of data.
class supports reading, writing, and seeking over an in-memory buffer. The :class:`BytesIO` class supports reading, writing, and seeking
over an in-memory buffer.
* :class:`TextIOBase`: Provides functions for reading and writing * :class:`TextIOBase`: Provides functions for reading and writing
strings (remember, strings will be Unicode in Python 3.0), strings (remember, strings will be Unicode in Python 3.0),
...@@ -3152,5 +3153,5 @@ Acknowledgements ...@@ -3152,5 +3153,5 @@ Acknowledgements
The author would like to thank the following people for offering suggestions, The author would like to thank the following people for offering suggestions,
corrections and assistance with various drafts of this article: corrections and assistance with various drafts of this article:
Georg Brandl, Jim Jewett. Georg Brandl, Jim Jewett, Antoine Pitrou.
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