Skip to content

Commit b9b7841

Browse files
committed
Issues mongodb#87: translated
1 parent bfcd5c4 commit b9b7841

File tree

5 files changed

+62
-17
lines changed

5 files changed

+62
-17
lines changed

locale/zh/LC_MESSAGES/applications/data-models-applications.po

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,4 +44,4 @@ msgstr ""
4444

4545
#: ../source/includes/toc/dfn-list-data-models-applications.rst:16
4646
msgid "Describes two methods to model monetary data in MongoDB."
47-
msgstr "介绍了两种对货币数据建模的方法。"
47+
msgstr "介绍了两种对金融货币数据建模的方法。"

locale/zh/LC_MESSAGES/data-modeling.po

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,14 +13,16 @@ msgstr ""
1313

1414
#: ../source/data-modeling.txt:3
1515
msgid "Data Models"
16-
msgstr ""
16+
msgstr "数据模型"
1717

1818
#: ../source/data-modeling.txt:7
1919
msgid ""
2020
"Data in MongoDB has a *flexible schema*. :term:`Collections <collection>` do"
2121
" not enforce :term:`document` structure. This flexibility gives you data-"
2222
"modeling choices to match your application and its performance requirements."
2323
msgstr ""
24+
"MongoDB的数据具有 *灵活的模式* 。 :term:`集合 <collection>` 本身没有"
25+
"对文档结构的规则性校验。 这种灵活性让你在为应用程序和其性能需求建模提供了不少选择。"
2426

2527
#: ../source/data-modeling.txt:12
2628
msgid ""
@@ -32,14 +34,18 @@ msgid ""
3234
"Case Studies </use-cases>` provide overviews of application design and "
3335
"include example data models with MongoDB."
3436
msgstr ""
37+
"文章 :doc:`/core/data-modeling-introduction` 提供了对数据建模的一个概括性的介绍。"
38+
"在 :doc:`/core/data-models` 部分有对于建模过程的进一步介绍。"
39+
"文章 :ref:`data-modeling-patterns` 则提供了一些不同数据模型的例子。 另外, "
40+
" :ecosystem:`MongoDB 案例研究 </use-cases>` 也提供了一些应用程序设计方法和相关模型的例子。"
3541

3642
#: ../source/includes/toc/dfn-list-data-modeling-landing.rst:5
3743
msgid ":doc:`/core/data-modeling-introduction`"
3844
msgstr ""
3945

4046
#: ../source/includes/toc/dfn-list-data-modeling-landing.rst:4
4147
msgid "An introduction to data modeling in MongoDB."
42-
msgstr ""
48+
msgstr "简单介绍MongoDB的建模"
4349

4450
#: ../source/includes/toc/dfn-list-data-modeling-landing.rst:11
4551
msgid ":doc:`/core/data-models`"
@@ -51,6 +57,7 @@ msgid ""
5157
"determining a data model, and discussing considerations that should be taken"
5258
" into account."
5359
msgstr ""
60+
"这个是建模的核心文档,讲述了建模时候你需要做的决定以及一些需要考虑的事项。"
5461

5562
#: ../source/includes/toc/dfn-list-data-modeling-landing.rst:16
5663
msgid ":doc:`/applications/data-models`"
@@ -60,7 +67,7 @@ msgstr ""
6067
msgid ""
6168
"Examples of possible data models that you can use to structure your MongoDB "
6269
"documents."
63-
msgstr ""
70+
msgstr "这个部分例讲了一些实用的MongoDB数据模型的例子。"
6471

6572
#: ../source/includes/toc/dfn-list-data-modeling-landing.rst:19
6673
msgid ":doc:`/reference/data-models`"
@@ -70,3 +77,4 @@ msgstr ""
7077
msgid ""
7178
"Reference material for data modeling for developers of MongoDB applications."
7279
msgstr ""
80+
"一些为MongoDB应用开发者建模的参考资料。"

locale/zh/LC_MESSAGES/tutorial/model-data-for-atomic-operations.po

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,6 +83,6 @@ msgid ""
8383
"``0`` and would indicate that you could not check out the book."
8484
msgstr ""
8585
"如果没有满足条件的文档,那么"
86-
":data:`~WriteResult.nMatched` 字段和 :data:`~WriteResult.nModified` 字段都将为"
86+
" :data:`~WriteResult.nMatched` 字段和 :data:`~WriteResult.nModified` 字段都将为"
8787
"``0``,表示该书不可以被出借。"
8888

locale/zh/LC_MESSAGES/tutorial/model-data-for-keyword-search.po

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ msgid ""
9696
"and another for ``allegory``."
9797
msgstr ""
9898
"多键索引会对数组里的每一个值建立一个索引项。在这个例子里 ``whaling`` 和 "
99-
"``allegory`` 个有一个索引项。"
99+
"``allegory`` 个各有一个索引项。"
100100

101101
#: ../source/tutorial/model-data-for-keyword-search.txt:66
102102
msgid "You then query based on the keywords. For example:"
@@ -152,6 +152,6 @@ msgid ""
152152
"some kinds of content and workloads."
153153
msgstr ""
154154
"*异步索引* MongoDBd的关键词索引的创建是同步实时的。这样对于及时得到最新的结果有帮助,但是"
155-
"在某些场景下异步的批处理索引创建会更加搞效一点。"
155+
"在某些场景下异步的批处理索引创建会更加高效一点。"
156156

157157

locale/zh/LC_MESSAGES/tutorial/model-monetary-data.po

Lines changed: 47 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -13,11 +13,11 @@ msgstr ""
1313

1414
#: ../source/tutorial/model-monetary-data.txt:3
1515
msgid "Model Monetary Data"
16-
msgstr ""
16+
msgstr "货币数据建模"
1717

1818
#: ../source/tutorial/model-monetary-data.txt:8
1919
msgid "Overview"
20-
msgstr ""
20+
msgstr "概述"
2121

2222
#: ../source/tutorial/model-monetary-data.txt:10
2323
msgid ""
@@ -29,46 +29,58 @@ msgid ""
2929
" addition, some fractional numeric quantities, such as one third and one "
3030
"tenth, have no exact representation in binary floating point numbers."
3131
msgstr ""
32+
"MongoDB里面的数字字段类型是IEEE 754标准定义的64为浮点数以及32位或64位有符号整数。"
33+
"而一些金融或财务方面的应用经常需要存储一些货币的小数点值。但是当前计算机内实现的浮点数"
34+
"计算能力往往不能满足金融代数的要求。另外浮点数也无法准确地表示1/3或者1/10这样的分数。"
3235

3336
#: ../source/tutorial/model-monetary-data.txt:21
3437
msgid ""
3538
"Arithmetic mentioned on this page refers to server-side arithmetic performed"
3639
" by :program:`mongod` or :program:`mongos`, and not to client-side "
3740
"arithmetic."
3841
msgstr ""
42+
"本文提及的数学计算指的是在服务器端由 :program:`mongod` or :program:`mongos` 执行的计算"
43+
"而非客户端的计算。"
3944

4045
#: ../source/tutorial/model-monetary-data.txt:25
4146
msgid "This document describes two ways to model monetary data in MongoDB:"
42-
msgstr ""
47+
msgstr "这篇文章描述了两种对货币数据的建模方法。"
4348

4449
#: ../source/tutorial/model-monetary-data.txt:27
4550
msgid ""
4651
":ref:`monetary-value-exact-precision` which multiplies the monetary value by"
4752
" a power of 10."
4853
msgstr ""
54+
":ref:`monetary-value-exact-precision` 把货币值乘以10的次方数。"
55+
4956

5057
#: ../source/tutorial/model-monetary-data.txt:30
5158
msgid ""
5259
":ref:`monetary-value-arbitrary-precision` which uses two fields for the "
5360
"value: one field to store the exact monetary value as a non-numeric and "
5461
"another field to store a floating point approximation of the value."
5562
msgstr ""
63+
":ref:`monetary-value-arbitrary-precision` 使用两个字段,一个字段以非数字形式保存"
64+
"真实地货币数值,一个字段则以浮点数的形式保存这个货币数值的大约值。"
5665

5766
#: ../source/tutorial/model-monetary-data.txt:38
5867
msgid "Use Cases for Exact Precision Model"
59-
msgstr ""
68+
msgstr "准确精度的应用场景"
6069

6170
#: ../source/tutorial/model-monetary-data.txt:40
6271
msgid ""
6372
"If you regularly need to perform server-side arithmetic on monetary data, "
6473
"the exact precision model may be appropriate. For instance:"
6574
msgstr ""
75+
"如果你经常需要在服务器端做一些对货币数值的数学计算,那么严格精度可能会更合适一点。"
76+
"例如:"
6677

6778
#: ../source/tutorial/model-monetary-data.txt:43
6879
msgid ""
6980
"If you need to query the database for exact, mathematically valid matches, "
7081
"use :ref:`monetary-value-exact-precision`."
7182
msgstr ""
83+
"假如你需要对货币数值做完全一致的匹配,那么可以考虑使用 :ref:`monetary-value-exact-precision`。"
7284

7385
#: ../source/tutorial/model-monetary-data.txt:46
7486
msgid ""
@@ -77,44 +89,55 @@ msgid ""
7789
"</reference/operator/aggregation-arithmetic>`, use :ref:`monetary-value-"
7890
"exact-precision`."
7991
msgstr ""
92+
"假如你需要做一些服务器端的计算,如 :update:`$inc`, "
93+
":update:`$mul`, 和 :doc:`aggregation framework arithmetic "
94+
"</reference/operator/aggregation-arithmetic>`, 那么可以使用 :ref:`monetary-value-"
95+
"exact-precision`。"
8096

8197
#: ../source/tutorial/model-monetary-data.txt:54
8298
msgid "Use Cases for Arbitrary Precision Model"
83-
msgstr ""
99+
msgstr "任意精度模式的应用场景"
84100

85101
#: ../source/tutorial/model-monetary-data.txt:56
86102
msgid ""
87103
"If there is no need to perform server-side arithmetic on monetary data, "
88104
"modeling monetary data using the arbitrary precision model may be suitable. "
89105
"For instance:"
90106
msgstr ""
107+
"如果没有在服务器端对货币数值进行计算的需要,那么使用任意精度模式的方式可能更为适合一点。"
108+
"例如:"
91109

92110
#: ../source/tutorial/model-monetary-data.txt:60
93111
msgid ""
94112
"If you need to handle arbitrary or unforeseen number of precision, see :ref"
95113
":`monetary-value-arbitrary-precision`."
96114
msgstr ""
115+
"如果你需要处理任意的或者未知的精度,参见"
116+
" :ref:`monetary-value-arbitrary-precision`。"
97117

98118
#: ../source/tutorial/model-monetary-data.txt:63
99119
msgid ""
100120
"If server-side approximations are sufficient, possibly with client-side "
101121
"post-processing, see :ref:`monetary-value-arbitrary-precision`."
102122
msgstr ""
123+
"如果服务器端的近似值计算可以满足要求,或者能够利用客户端作进一步处理,那么也可以使用"
124+
" :ref:`monetary-value-arbitrary-precision`。"
103125

104126
#: ../source/tutorial/model-monetary-data.txt:70
105127
msgid "Exact Precision"
106-
msgstr ""
128+
msgstr "准确精度"
107129

108130
#: ../source/tutorial/model-monetary-data.txt:72
109131
msgid "To model monetary data using the exact precision model:"
110-
msgstr ""
132+
msgstr "使用准确精度建模:"
111133

112134
#: ../source/tutorial/model-monetary-data.txt:74
113135
msgid ""
114136
"Determine the maximum precision needed for the monetary value. For example, "
115137
"your application may require precision down to the tenth of one cent for "
116138
"monetary values in ``USD`` currency."
117139
msgstr ""
140+
"确定货币值需要的最高精度。比如说,你的应用程序可能使用十分之一美分作为最小单位。"
118141

119142
#: ../source/tutorial/model-monetary-data.txt:78
120143
msgid ""
@@ -123,20 +146,23 @@ msgid ""
123146
"significant digit of the integer. For example, if the required maximum "
124147
"precision is the tenth of one cent, multiply the monetary value by 1000."
125148
msgstr ""
149+
"把带小数货币值乘以10的次方数以转换成一个整数。如果最高精度要求是十分之一美分,那么就可以"
150+
"把值乘以1000。"
126151

127152
#: ../source/tutorial/model-monetary-data.txt:84
128153
msgid "Store the converted monetary value."
129-
msgstr ""
154+
msgstr "保存转换以后的整形数。"
130155

131156
#: ../source/tutorial/model-monetary-data.txt:86
132157
msgid ""
133158
"For example, the following scales ``9.99 USD`` by 1000 to preserve precision"
134159
" up to one tenth of a cent."
135160
msgstr ""
161+
"例如, 下面这个例子把 ``9.99 USD`` 乘以1000进行放大并得到9990。"
136162

137163
#: ../source/tutorial/model-monetary-data.txt:93
138164
msgid "The model assumes that for a given currency value:"
139-
msgstr ""
165+
msgstr "这个模型假设对于一个特定的货币值:"
140166

141167
#: ../source/tutorial/model-monetary-data.txt:95
142168
msgid ""
@@ -149,45 +175,53 @@ msgid ""
149175
"The scale factor is a constant and known property of the currency; i.e "
150176
"applications can determine the scale factor from the currency."
151177
msgstr ""
178+
"对货币值的放大因子(乘数)对于一种货币来说是一致的并且应用程序能够确定这个放大因子。"
152179

153180
#: ../source/tutorial/model-monetary-data.txt:101
154181
msgid ""
155182
"When using this model, applications must be consistent in performing the "
156183
"appropriate scaling of the values."
157184
msgstr ""
185+
"当使用这个模式的时候,应用程序必须始终一致的执行相应值得换算。"
158186

159187
#: ../source/tutorial/model-monetary-data.txt:104
160188
msgid ""
161189
"For use cases of this model, see :ref:`exact-precision-model-use-case`."
162190
msgstr ""
191+
"对这种模式的使用场景,参见 :ref:`exact-precision-model-use-case`。"
163192

164193
#: ../source/tutorial/model-monetary-data.txt:109
165194
msgid "Arbitrary Precision"
166-
msgstr ""
195+
msgstr "任意精度"
167196

168197
#: ../source/tutorial/model-monetary-data.txt:111
169198
msgid ""
170199
"To model monetary data using the arbitrary precision model, store the value "
171200
"in two fields:"
172201
msgstr ""
202+
"使用任意精度方式建模时,我们需要用两个字段来保存货币值:"
173203

174204
#: ../source/tutorial/model-monetary-data.txt:114
175205
msgid ""
176206
"In one field, encode the exact monetary value as a non-numeric data type; "
177207
"e.g., ``BinData`` or a ``string``."
178208
msgstr ""
209+
"在一个字段里,把货币值原样不动的按照非数字字段进行存储,如"
210+
" ``BinData`` 或者 ``string``。"
179211

180212
#: ../source/tutorial/model-monetary-data.txt:117
181213
msgid ""
182214
"In the second field, store a double-precision floating point approximation "
183215
"of the exact value."
184216
msgstr ""
217+
"在另一个字段里,以双精度浮点数近似值的形式保存所需货币值。"
185218

186219
#: ../source/tutorial/model-monetary-data.txt:120
187220
msgid ""
188221
"The following example uses the arbitrary precision model to store ``9.99 "
189222
"USD`` for the price and ``0.25 USD`` for the fee:"
190223
msgstr ""
224+
"下述例子使用任意精度模式来保存价格字段 ``9.99 USD`` 和费用字段 ``0.25 USD`` :"
191225

192226
#: ../source/tutorial/model-monetary-data.txt:130
193227
msgid ""
@@ -198,8 +232,11 @@ msgid ""
198232
"exact value and then filter out the returned documents based on the exact "
199233
"monetary value."
200234
msgstr ""
235+
"适当使用的话,应用程序可以执行对货币字段按近似字段的值进行范围查找和排序。然而,使用近似字段"
236+
"查询排序时应用程序必须做一些后续处理来对非数字型的货币值进行解码转换成数字,然后返回给客户端。"
201237

202238
#: ../source/tutorial/model-monetary-data.txt:137
203239
msgid ""
204240
"For use cases of this model, see :ref:`arbitrary-precision-model-use-case`."
205241
msgstr ""
242+
"对于这种方式的应用场景,参见 :ref:`arbitrary-precision-model-use-case`。"

0 commit comments

Comments
 (0)