Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 573e8fd

Browse files
committed
[po] auto sync bot
1 parent 8f0d5ce commit 573e8fd

2 files changed

Lines changed: 38 additions & 11 deletions

File tree

library/codecs.po

Lines changed: 23 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -612,7 +612,7 @@ msgstr "以下标准错误处理方案也可通过模块层级函数的方式来
612612
msgid ""
613613
"Implements the ``'strict'`` error handling: each encoding or decoding error "
614614
"raises a :exc:`UnicodeError`."
615-
msgstr ""
615+
msgstr "实现 ``'strict'`` 错误处理方案:每个编码或解码错误都会引发 :exc:`UnicodeError`。"
616616

617617
#: ../../library/codecs.rst:423
618618
msgid ""
@@ -621,43 +621,51 @@ msgid ""
621621
" the codec), and ``'\\ufffd'`` (the Unicode replacement character) for "
622622
"decoding errors."
623623
msgstr ""
624+
"实现 ``'replace'`` 错误处理方案 (仅用于 :term:`文本编码 <text encoding>`):编码错误替换为 ``'?'`` "
625+
"(并由编解码器编码),解码错误替换为 ``'\\ufffd'`` (Unicode 替换字符)。"
624626

625627
#: ../../library/codecs.rst:431
626628
msgid ""
627629
"Implements the ``'ignore'`` error handling: malformed data is ignored and "
628630
"encoding or decoding is continued without further notice."
629-
msgstr ""
631+
msgstr "实现 ``'ignore'`` 错误处理方案:忽略错误格式的数据并且不加进一步通知就继续执行。"
630632

631633
#: ../../library/codecs.rst:437
632634
msgid ""
633635
"Implements the ``'xmlcharrefreplace'`` error handling (for encoding with "
634636
":term:`text encodings <text encoding>` only): the unencodable character is "
635637
"replaced by an appropriate XML character reference."
636638
msgstr ""
639+
"实现 ``'xmlcharrefreplace'`` 错误处理方案 (仅用于 :term:`文本编码 <text encoding>` "
640+
"的编码过程):不可编码的字符将以适当的 XML 字符引用进行替换。"
637641

638642
#: ../../library/codecs.rst:444
639643
msgid ""
640644
"Implements the ``'backslashreplace'`` error handling (for :term:`text "
641645
"encodings <text encoding>` only): malformed data is replaced by a "
642646
"backslashed escape sequence."
643647
msgstr ""
648+
"实现 ``'backslashreplace'`` 错误处理方案 (仅用于 :term:`文本编码 <text "
649+
"encoding>`):错误格式的数据将以带反斜杠的转义序列进行替换。"
644650

645651
#: ../../library/codecs.rst:450
646652
msgid ""
647653
"Implements the ``'namereplace'`` error handling (for encoding with "
648654
":term:`text encodings <text encoding>` only): the unencodable character is "
649655
"replaced by a ``\\N{...}`` escape sequence."
650656
msgstr ""
657+
"实现 ``'namereplace'`` 错误处理方案 (仅用于 :term:`文本编码 <text encoding>` "
658+
"的编码过程):不可编码的字符将以 ``\\N{...}`` 转义序列进行替换。"
651659

652660
#: ../../library/codecs.rst:460
653661
msgid "Stateless Encoding and Decoding"
654-
msgstr ""
662+
msgstr "无状态的编码和解码"
655663

656664
#: ../../library/codecs.rst:462
657665
msgid ""
658666
"The base :class:`Codec` class defines these methods which also define the "
659667
"function interfaces of the stateless encoder and decoder:"
660-
msgstr ""
668+
msgstr "基本 :class:`Codec` 类定义了这些方法,同时还定义了无状态编码器和解码器的函数接口:"
661669

662670
#: ../../library/codecs.rst:468
663671
msgid ""
@@ -666,25 +674,29 @@ msgid ""
666674
" bytes object using a particular character set encoding (e.g., ``cp1252`` or"
667675
" ``iso-8859-1``)."
668676
msgstr ""
677+
"编码 *input* 对象并返回一个元组 (输出对象, 消耗长度)。 例如,:term:`text encoding` 会使用特定的字符集编码格式 "
678+
"(例如 ``cp1252`` 或 ``iso-8859-1``) 将字符串转换为字节串对象。"
669679

670680
#: ../../library/codecs.rst:473 ../../library/codecs.rst:495
671681
msgid ""
672682
"The *errors* argument defines the error handling to apply. It defaults to "
673683
"``'strict'`` handling."
674-
msgstr ""
684+
msgstr "*errors* 参数定义了要应用的错误处理方案。 默认为 ``'strict'`` 处理方案。"
675685

676686
#: ../../library/codecs.rst:476
677687
msgid ""
678688
"The method may not store state in the :class:`Codec` instance. Use "
679689
":class:`StreamWriter` for codecs which have to keep state in order to make "
680690
"encoding efficient."
681691
msgstr ""
692+
"此方法不一定会在 :class:`Codec` 实例中保存状态。 可使用必须保存状态的 :class:`StreamWriter` "
693+
"作为编解码器以便高效地进行编码。"
682694

683695
#: ../../library/codecs.rst:480
684696
msgid ""
685697
"The encoder must be able to handle zero length input and return an empty "
686698
"object of the output object type in this situation."
687-
msgstr ""
699+
msgstr "编码器必须能够处理零长度的输入并在此情况下返回输出对象类型的空对象。"
688700

689701
#: ../../library/codecs.rst:486
690702
msgid ""
@@ -693,20 +705,25 @@ msgid ""
693705
"bytes object encoded using a particular character set encoding to a string "
694706
"object."
695707
msgstr ""
708+
"解码 *input* 对象并返回一个元组 (输出对象, 消耗长度)。 例如,:term:`text encoding` "
709+
"的解码操作会使用特定的字符集编码格式将字节串对象转换为字符串对象。"
696710

697711
#: ../../library/codecs.rst:491
698712
msgid ""
699713
"For text encodings and bytes-to-bytes codecs, *input* must be a bytes object"
700714
" or one which provides the read-only buffer interface -- for example, buffer"
701715
" objects and memory mapped files."
702716
msgstr ""
717+
"对于文本编码格式和字节到字节编解码器,*input* 必须为一个字节串对象或提供了只读缓冲区接口的对象 -- 例如,缓冲区对象和映射到内存的文件。"
703718

704719
#: ../../library/codecs.rst:498
705720
msgid ""
706721
"The method may not store state in the :class:`Codec` instance. Use "
707722
":class:`StreamReader` for codecs which have to keep state in order to make "
708723
"decoding efficient."
709724
msgstr ""
725+
"此方法不一定会在 :class:`Codec` 实例中保存状态。 可使用必须保存状态的 :class:`StreamReader` "
726+
"作为编解码器以便高效地进行解码。"
710727

711728
#: ../../library/codecs.rst:502
712729
msgid ""

library/collections.abc.po

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -388,7 +388,7 @@ msgstr ""
388388

389389
#: ../../library/collections.abc.rst:150
390390
msgid "ABCs for read-only and mutable :term:`sequences <sequence>`."
391-
msgstr ""
391+
msgstr "只读且可变的序列 :term:`sequences <sequence>` 的抽象基类。"
392392

393393
#: ../../library/collections.abc.rst:152
394394
msgid ""
@@ -400,36 +400,43 @@ msgid ""
400400
" be with a linked list), the mixins will have quadratic performance and will"
401401
" likely need to be overridden."
402402
msgstr ""
403+
"实现笔记:一些混入(Maxin)方法比如 :meth:`__iter__`, :meth:`__reversed__` 和 :meth:`index` "
404+
"会重复调用底层的 :meth:`__getitem__` 方法。因此,如果实现的 :meth:`__getitem__` "
405+
"是常数级访问速度,那么相应的混入方法会有一个线性的表现;然而,如果底层方法是线性实现(例如链表),那么混入方法将会是平方级的表现,这也许就需要被重构了。"
403406

404407
#: ../../library/collections.abc.rst:161
405408
msgid "The index() method added support for *stop* and *start* arguments."
406-
msgstr ""
409+
msgstr "index() 方法支持 *stop* 和 *start* 参数。"
407410

408411
#: ../../library/collections.abc.rst:168
409412
msgid "ABCs for read-only and mutable sets."
410-
msgstr ""
413+
msgstr "只读且可变的集合的抽象基类。"
411414

412415
#: ../../library/collections.abc.rst:173
413416
msgid "ABCs for read-only and mutable :term:`mappings <mapping>`."
414-
msgstr ""
417+
msgstr "只读且可变的映射 :term:`mappings <mapping>` 的抽象基类。"
415418

416419
#: ../../library/collections.abc.rst:180
417420
msgid ""
418421
"ABCs for mapping, items, keys, and values :term:`views <dictionary view>`."
419-
msgstr ""
422+
msgstr "映射及其键和值的视图 :term:`views <dictionary view>` 的抽象基类。"
420423

421424
#: ../../library/collections.abc.rst:184
422425
msgid ""
423426
"ABC for :term:`awaitable` objects, which can be used in :keyword:`await` "
424427
"expressions. Custom implementations must provide the :meth:`__await__` "
425428
"method."
426429
msgstr ""
430+
"为可等待对象 :term:`awaitable` 提供的类,可以被用于 :keyword:`await` 表达式中。习惯上必须实现 "
431+
":meth:`__await__` 方法。"
427432

428433
#: ../../library/collections.abc.rst:188
429434
msgid ""
430435
":term:`Coroutine` objects and instances of the "
431436
":class:`~collections.abc.Coroutine` ABC are all instances of this ABC."
432437
msgstr ""
438+
"协程对象 :term:`Coroutine` 和 :class:`~collections.abc.Coroutine` "
439+
"抽象基类的实例都是这个抽象基类的实例。"
433440

434441
#: ../../library/collections.abc.rst:192
435442
msgid ""
@@ -439,6 +446,9 @@ msgid ""
439446
"``isinstance(gencoro, Awaitable)`` for them will return ``False``. Use "
440447
":func:`inspect.isawaitable` to detect them."
441448
msgstr ""
449+
"在 CPython 里,基于生成器的协程(使用 :func:`types.coroutine` 或 :func:`asyncio.coroutine` "
450+
"包装的生成器)都是 *可等待对象*,即使他们不含有 :meth:`__await__` 方法。使用 ``isinstance(gencoro, "
451+
"Awaitable)`` 来检测他们会返回 ``False``。要使用 :func:`inspect.isawaitable` 来检测他们。"
442452

443453
#: ../../library/collections.abc.rst:202
444454
msgid ""

0 commit comments

Comments
 (0)