Skip to content

Commit 21d40d6

Browse files
authored
Update language snippets for MongoDB changes (#981)
1 parent 22c9421 commit 21d40d6

File tree

1 file changed

+114
-50
lines changed

1 file changed

+114
-50
lines changed

language-snippets.ent

Lines changed: 114 additions & 50 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<!-- $Revision$ -->
3-
<!-- EN-Revision: f0d52500c7f8bda83761b18d6c03965741753abd Maintainer: Gregory Status: ready -->
3+
<!-- EN-Revision: 4639881688d3faaf0073ad71fe0a4b730aea15a0 Maintainer: Gregory Status: ready -->
44
<!-- CREDITS: dallas, mowangjuanzi, Luffy -->
55
<!-- 请保持此文件与英文文件中相应的每个 ENTITY 行号一一对应以便于对照,修改与更新! -->
66

@@ -2970,18 +2970,76 @@ xmlns="http://docbook.org/ns/docbook"><simpara xmlns="http://docbook.org/ns/docb
29702970
<!ENTITY trader.arg.slow.limit 'Lower limit use in the adaptive algorithm. Valid range from 0.01 to 0.99.'>
29712971

29722972
<!-- mongodb -->
2973+
<!ENTITY mongodb.changelog.class-removed '
2974+
<row xmlns="http://docbook.org/ns/docbook">
2975+
<entry>PECL mongodb 2.0.0</entry>
2976+
<entry>
2977+
此类已被移除。
2978+
</entry>
2979+
</row>
2980+
'>
2981+
2982+
<!ENTITY mongodb.changelog.function-removed '
2983+
<row xmlns="http://docbook.org/ns/docbook">
2984+
<entry>PECL mongodb 2.0.0</entry>
2985+
<entry>
2986+
此函数已被移除。
2987+
</entry>
2988+
</row>
2989+
'>
2990+
2991+
<!ENTITY mongodb.changelog.method-removed '
2992+
<row xmlns="http://docbook.org/ns/docbook">
2993+
<entry>PECL mongodb 2.0.0</entry>
2994+
<entry>
2995+
此方法已被移除。
2996+
</entry>
2997+
</row>
2998+
'>
2999+
3000+
<!ENTITY mongodb.changelog.serializable-interface-removed '
3001+
<row xmlns="http://docbook.org/ns/docbook">
3002+
<entry>PECL mongodb 2.0.0</entry>
3003+
<entry>
3004+
<para>
3005+
此类不再实现 <interfacename>Serializable</interfacename> 接口。
3006+
</para>
3007+
</entry>
3008+
</row>
3009+
'>
3010+
29733011
<!ENTITY mongodb.changelog.tentative-return-types '
29743012
<row xmlns="http://docbook.org/ns/docbook">
29753013
<entry>PECL mongodb 1.15.0</entry>
29763014
<entry>
2977-
Return types for methods are declared as tentative on PHP 8.0 and newer,
2978-
triggering deprecation notices in code that implements this interface
2979-
without declaring the appropriate return types. The <code>#[ReturnTypeWillChange]</code>
2980-
attribute can be added to silence the deprecation notice.
3015+
在 PHP 8.0 及更高版本中,方法的返回类型被声明为暂定(tentative),
3016+
这会导致在实现该接口但未声明相应返回类型的代码中触发弃用提示。
3017+
可以添加 <code>#[ReturnTypeWillChange]</code> 属性来消除该弃用提示。
29813018
</entry>
29823019
</row>
29833020
'>
29843021

3022+
<!ENTITY mongodb.changelog.tentative-return-types-enforced '
3023+
<row xmlns="http://docbook.org/ns/docbook">
3024+
<entry>PECL mongodb 2.0.0</entry>
3025+
<entry>
3026+
之前声明为暂定的返回类型现在已被强制执行。
3027+
</entry>
3028+
</row>
3029+
'>
3030+
3031+
<!ENTITY mongodb.changelog.throw-unacknowledged-write '
3032+
<row xmlns="http://docbook.org/ns/docbook">
3033+
<entry>PECL mongodb 2.0.0</entry>
3034+
<entry>
3035+
<para>
3036+
当针对未确认写入调用此方法时,现在会抛出异常,而不是返回 &null;
3037+
</para>
3038+
</entry>
3039+
</row>
3040+
'>
3041+
3042+
29853043
<!ENTITY mongodb.option.collation '
29863044
<row xmlns="http://docbook.org/ns/docbook">
29873045
<entry>collation</entry>
@@ -3594,6 +3652,7 @@ local: {
35943652
<!ENTITY mongodb.throws.authentication '<member xmlns="http://docbook.org/ns/docbook">Throws <classname>MongoDB\Driver\Exception\AuthenticationException</classname> if authentication is needed and fails.</member>'>
35953653
<!ENTITY mongodb.throws.connection '<member xmlns="http://docbook.org/ns/docbook">Throws <classname>MongoDB\Driver\Exception\ConnectionException</classname> if connection to the server fails (for reasons other than authentication).</member>'>
35963654
<!ENTITY mongodb.throws.bson.unexpected '<member xmlns="http://docbook.org/ns/docbook">Throws <classname>MongoDB\Driver\Exception\UnexpectedValueException</classname> if the input did not contain exactly one BSON document. Possible reasons include, but are not limited to, invalid BSON, extra data (after reading one BSON document), or an unexpected <link xlink:href="&url.mongodb.libbson;" xmlns:xlink="http://www.w3.org/1999/xlink">libbson</link> error.</member>'>
3655+
<!ENTITY mongodb.throws.unacknowledged '<member xmlns="http://docbook.org/ns/docbook">Throws <classname>MongoDB\Driver\Exception\LogicException</classname> if the write was not acknowledged.</member>'>
35973656

35983657
<!-- Not used in EN anymore -->
35993658
<!ENTITY mongodb.note.queryable-encryption-preview ''>
@@ -3948,51 +4007,56 @@ local: {
39484007
</para>
39494008
</formalpara>
39504009

3951-
<para>
3952-
<table>
3953-
<title>标志</title>
3954-
<tgroup cols="2">
3955-
<thead>
3956-
<row>
3957-
<entry>标志</entry>
3958-
<entry>&Description;</entry>
3959-
</row>
3960-
</thead>
3961-
<tbody>
3962-
<row>
3963-
<entry><literal>-</literal></entry>
3964-
<entry>
3965-
在指定字段宽度时左对齐,默认右对齐
3966-
</entry>
3967-
</row>
3968-
<row>
3969-
<entry><literal>+</literal></entry>
3970-
<entry>
3971-
正数的加号 <literal>+</literal>前缀,默认负数的前缀是负号。
3972-
</entry>
3973-
</row>
3974-
<row>
3975-
<entry><literal> </literal>(space)</entry>
3976-
<entry>
3977-
空格填充结果。这是默认设置。
3978-
</entry>
3979-
</row>
3980-
<row>
3981-
<entry><literal>0</literal></entry>
3982-
<entry>
3983-
仅用 0 进行左侧数字填充。使用 <literal>s</literal> 标志符可以右侧填充。
3984-
</entry>
3985-
</row>
3986-
<row>
3987-
<entry><literal>&apos;</literal>(char)</entry>
3988-
<entry>
3989-
用字符(char)填充结果。
3990-
</entry>
3991-
</row>
3992-
</tbody>
3993-
</tgroup>
3994-
</table>
3995-
</para>
4010+
<formalpara>
4011+
<title>标志</title>
4012+
<para>
4013+
<informaltable>
4014+
<tgroup cols="2">
4015+
<thead>
4016+
<row>
4017+
<entry>标志</entry>
4018+
<entry>&Description;</entry>
4019+
</row>
4020+
</thead>
4021+
<tbody>
4022+
<row>
4023+
<entry><literal>-</literal></entry>
4024+
<entry>
4025+
在给定字段宽度内左对齐;右对齐是默认值
4026+
</entry>
4027+
</row>
4028+
<row>
4029+
<entry><literal>+</literal></entry>
4030+
<entry>
4031+
在给定字段宽度内为正数添加加号前缀
4032+
<literal>+</literal>;默认情况下,只有负数才会添加负号前缀。
4033+
</entry>
4034+
</row>
4035+
<row>
4036+
<entry><literal> </literal>(space)</entry>
4037+
<entry>
4038+
用空格填充结果。
4039+
这是默认值。
4040+
</entry>
4041+
</row>
4042+
<row>
4043+
<entry><literal>0</literal></entry>
4044+
<entry>
4045+
仅对数字进行左侧零填充。
4046+
对于 <literal>s</literal> 说明符,也可以右侧用零填充。
4047+
</entry>
4048+
</row>
4049+
<row>
4050+
<entry><literal>&apos;</literal>(char)</entry>
4051+
<entry>
4052+
用字符(char)填充结果。
4053+
</entry>
4054+
</row>
4055+
</tbody>
4056+
</tgroup>
4057+
</informaltable>
4058+
</para>
4059+
</formalpara>
39964060

39974061
<formalpara>
39984062
<title>Width</title>

0 commit comments

Comments
 (0)