From 4fedbf82cc51fb2cad2e53bce803207456d1965b Mon Sep 17 00:00:00 2001 From: cschan <45995789+cschan1828@users.noreply.github.com> Date: Fri, 8 Dec 2023 00:14:38 +0800 Subject: [PATCH] Revise translations of library/io.po --- library/io.po | 48 ++++++++++++++++++++++++++++++++++++++---------- 1 file changed, 38 insertions(+), 10 deletions(-) diff --git a/library/io.po b/library/io.po index 10bc84371b..c78c0e4a55 100644 --- a/library/io.po +++ b/library/io.po @@ -7,7 +7,7 @@ msgstr "" "Project-Id-Version: Python 3.12\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2023-08-30 00:04+0000\n" -"PO-Revision-Date: 2023-11-22 00:45+0800\n" +"PO-Revision-Date: 2023-12-08 00:08+0800\n" "Last-Translator: Adrian Liaw \n" "Language-Team: Chinese - TAIWAN (https://github.com/python/python-docs-zh-" "tw)\n" @@ -417,6 +417,9 @@ msgid "" "used to specify the various categories of streams, then concrete classes " "providing the standard stream implementations." msgstr "" +"I/O 串流的實作是由多個類別組合成的階層結構所構成。首先是 :term:`abstract " +"base classes ` (抽象基底類別,ABCs),它們被用來規範各" +"種不同類型的串流,接著具體類別會提供標準串流的實作。" #: ../../library/io.rst:258 msgid "" @@ -425,6 +428,9 @@ msgid "" "example, :class:`BufferedIOBase` provides unoptimized implementations of :" "meth:`!readinto` and :meth:`!readline`." msgstr "" +"為了協助具體串流類別的實作,抽象基底類別提供了某些方法的預設實作。舉例來說,:" +"class:`BufferedIOBase` 提供未經最佳化的 :meth:`!readinto` 與 :meth:`!" +"readline` 實作。" #: ../../library/io.rst:263 msgid "" @@ -434,6 +440,9 @@ msgid "" "allowed to raise :exc:`UnsupportedOperation` if they do not support a given " "operation." msgstr "" +"I/O 階層結構的最上層是抽象基底類別 :class:`IOBase`。它定義了串流的基礎的介" +"面。然而,請注意,讀取串流與寫入串流之間並沒有分離;若不支援給定的操作,實作" +"是允許引發 :exc:`UnsupportedOperation` 例外的。" #: ../../library/io.rst:268 msgid "" @@ -441,6 +450,9 @@ msgid "" "reading and writing of bytes to a stream. :class:`FileIO` subclasses :class:" "`RawIOBase` to provide an interface to files in the machine's file system." msgstr "" +"抽象基底類別 :class:`RawIOBase` 繼承 :class:`IOBase`。此類別處理對串流的位元" +"組讀寫。:class:`FileIO` 則繼承 :class:`RawIOBase` 來提供一個介面以存取機器檔" +"案系統內的檔案。" #: ../../library/io.rst:272 msgid "" @@ -452,6 +464,12 @@ msgid "" "interface to seekable streams. Another :class:`BufferedIOBase` subclass, :" "class:`BytesIO`, is a stream of in-memory bytes." msgstr "" +"抽象基底類別 :class:`BufferedIOBase` 繼承 :class:`IOBase`。此類別緩衝原始二進" +"位串流 (:class:`RawIOBase`)。它的子類別 :class:`BufferedWriter`、:class:" +"`BufferedReader` 與 :class:`BufferedRWPair` 分別緩衝可寫、可讀、可讀也可寫的" +"的原始二進位串流。類別 :class:`BufferedRandom` 則提供一個對可搜尋串流 " +"(seekable stream) 的緩衝介面。另一個類別 :class:`BufferedIOBase` 的子類別 :" +"class:`BytesIO`,是一個記憶體內位元組串流。" #: ../../library/io.rst:280 msgid "" @@ -461,6 +479,10 @@ msgid "" "buffered text interface to a buffered raw stream (:class:`BufferedIOBase`). " "Finally, :class:`StringIO` is an in-memory stream for text." msgstr "" +"抽象基底類別 :class:`TextIOBase` 繼承 :class:`IOBase`。此類別處理文本位元組串" +"流,並處理字串的編碼和解碼。類別 :class:`TextIOWrapper` 繼承自 :class:" +"`TextIOBase`,這是個對緩衝原始串流 (:class:`BufferedIOBase`) 的緩衝文本介面。" +"最後,:class:`StringIO` 是個文字記憶體內串流。" #: ../../library/io.rst:286 msgid "" @@ -471,23 +493,23 @@ msgstr "引數名稱不是規範的一部份,只有 :func:`open` 的引數將 #: ../../library/io.rst:289 msgid "" "The following table summarizes the ABCs provided by the :mod:`io` module:" -msgstr "以下表格總結了 :mod:`io` 模組提供的抽象基礎類別 (ABC):" +msgstr "以下表格總結了 :mod:`io` 模組提供的抽象基底類別 (ABC):" #: ../../library/io.rst:294 msgid "ABC" -msgstr "ABC" +msgstr "抽象基底類別 (ABC)" #: ../../library/io.rst:294 msgid "Inherits" -msgstr "" +msgstr "繼承" #: ../../library/io.rst:294 msgid "Stub Methods" -msgstr "" +msgstr "Stub 方法" #: ../../library/io.rst:294 msgid "Mixin Methods and Properties" -msgstr "" +msgstr "Mixin 方法與屬性" #: ../../library/io.rst:296 ../../library/io.rst:301 ../../library/io.rst:303 #: ../../library/io.rst:305 @@ -504,6 +526,9 @@ msgid "" "``__iter__``, ``__next__``, ``readable``, ``readline``, ``readlines``, " "``seekable``, ``tell``, ``writable``, and ``writelines``" msgstr "" +"``close``、``closed``、``__enter__``、``__exit__``、``flush``、``isatty``、" +"``__iter__``、``__next__``、``readable``、``readline``、``readlines``、" +"``seekable``、``tell``、``writable`` 與 ``writelines``" #: ../../library/io.rst:301 msgid ":class:`RawIOBase`" @@ -515,7 +540,7 @@ msgstr "``readinto`` 和 ``write``" #: ../../library/io.rst:301 msgid "Inherited :class:`IOBase` methods, ``read``, and ``readall``" -msgstr "" +msgstr "繼承自 :class:`IOBase` 的方法,``read`` 與 ``readall``" #: ../../library/io.rst:303 msgid ":class:`BufferedIOBase`" @@ -527,7 +552,7 @@ msgstr "``detach``\\ 、\\ ``read``\\ 、\\ ``read1`` 和 ``write``" #: ../../library/io.rst:303 msgid "Inherited :class:`IOBase` methods, ``readinto``, and ``readinto1``" -msgstr "" +msgstr "繼承自 :class:`IOBase` 的方法,``readinto`` 與 ``readinto1``" #: ../../library/io.rst:305 msgid ":class:`TextIOBase`" @@ -541,14 +566,15 @@ msgstr "``detach``\\ 、\\ ``read``\\ 、\\ ``readline`` 和 ``write``" msgid "" "Inherited :class:`IOBase` methods, ``encoding``, ``errors``, and ``newlines``" msgstr "" +"繼承自 :class:`IOBase` 的方法,``encoding``、``errors`` 與 ``newlines``" #: ../../library/io.rst:312 msgid "I/O Base Classes" -msgstr "" +msgstr "I/O 基礎類別" #: ../../library/io.rst:316 msgid "The abstract base class for all I/O classes." -msgstr "" +msgstr "所有 I/O 類別的抽象基礎類別。" #: ../../library/io.rst:318 msgid "" @@ -556,6 +582,8 @@ msgid "" "derived classes can override selectively; the default implementations " "represent a file that cannot be read, written or seeked." msgstr "" +"為許多方法提供了空的抽象實作,衍伸類別可以選擇性地覆寫這些方法;預設的實作代" +"表一個無法讀取、寫入或搜尋的檔案。" #: ../../library/io.rst:323 msgid ""