Repository navigation
Expand file tree
/
Copy pathLoc.Design.cs
More file actions
368 lines (356 loc) · 29.3 KB
/
Copy pathLoc.Design.cs
File metadata and controls
368 lines (356 loc) · 29.3 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
namespace VelaShell.Plugin.Mongo;
public sealed partial class Loc
{
/// <summary>集合设计:索引、Schema 分析、验证规则、选项、统计。</summary>
private static readonly (string Key, string En, string Zh)[] DesignTexts =
[
// ── 标签与子页条 ──
("Design_Title", "Design · {0}", "设计 · {0}"),
("Design_TabIndexes", "Indexes", "索引"),
("Design_TabSchema", "Schema analysis", "Schema 分析"),
("Design_TabValidation", "Validation", "验证规则"),
("Design_TabOptions", "Options", "选项"),
("Design_TabOptionsHint", "TTL · collation", "TTL · 排序规则"),
("Design_TabStats", "Stats", "统计"),
// ── 状态栏 ──
("Design_Status", "Design · {0} · {1}", "设计 · {0} · {1}"),
("Design_StatusIndexes", "{0} indexes · {1}", "{0} 个索引 · {1}"),
("Design_StatusAnalyzing", "Schema · sampling…", "Schema · 抽样分析中…"),
("Design_StatusSchema", "Schema · {0} field paths", "Schema · {0} 个字段路径"),
("Design_StatusValidation", "validationLevel {0} · action {1}", "validationLevel {0} · action {1}"),
("Design_RuleUnsaved", "rule not applied", "规则未保存"),
("Design_StatusOptions", "Options · {0} TTL indexes", "选项 · {0} 个 TTL 索引"),
("Design_StatusStats", "{0} documents · {1}", "{0} 份文档 · {1}"),
// ── 时长 ──
("Design_Seconds", "{0} s", "{0} 秒"),
("Design_Minutes", "{0} min", "{0} 分钟"),
("Design_Hours", "{0} h", "{0} 小时"),
("Design_Days", "{0} days", "{0} 天"),
// ── 索引表 ──
("Design_NewIndex", "New index", "新建索引"),
("Design_Hide", "Hide", "隐藏"),
("Design_Unhide", "Unhide", "取消隐藏"),
("Design_IndexStatsSince", "$indexStats · counting since {0}", "$indexStats · 自 {0} 起统计"),
("Design_IndexStatsUnavailable", "$indexStats unavailable", "$indexStats 不可用"),
("Design_ColName", "Name", "名称"),
("Design_ColKey", "Key", "键"),
("Design_ColType", "Type", "类型"),
("Design_ColAttrs", "Properties", "属性"),
("Design_ColSize", "Size", "大小"),
("Design_ColUsage", "Usage (ops)", "使用 (ops)"),
("Design_ColUsageOps", "Usage (ops)", "使用 (ops)"),
("Design_ViewNoIndexes", "Views have no indexes of their own — queries use the source collection's.", "视图没有自己的索引,查询走源集合的索引。"),
("Design_FormSingle", "Single", "单字段"),
("Design_FormCompound", "Compound", "复合"),
("Design_FormMultiKey", "Multikey", "多键"),
("Design_FormText", "Text", "文本"),
("Design_FormGeo", "Geo", "地理"),
("Design_FormHashed", "Hashed", "哈希"),
("Design_FormWildcard", "Wildcard", "通配符"),
("Design_AttrUnique", "unique", "唯一"),
("Design_AttrSparse", "sparse", "稀疏"),
("Design_AttrPartial", "partial", "部分"),
("Design_AttrTtl", "TTL {0}", "TTL {0}"),
("Design_AttrHidden", "hidden", "隐藏"),
("Design_AttrUnused", "unused {0} d", "未使用 {0} 天"),
("Design_Building", "Building {0}%", "构建中 {0}%"),
// ── 隐藏 / 删除 ──
("Design_HideTitle", "Hide index", "隐藏索引"),
("Design_UnhideTitle", "Unhide index", "取消隐藏索引"),
("Design_HideBody", "Hide {0} on {1}? The optimizer stops using it, but writes still maintain it — unhide any time.",
"隐藏 {1} 上的 {0}?优化器不再使用它,但写入时照常维护,随时可以取消隐藏。"),
("Design_UnhideBody", "Unhide {0} on {1}? The optimizer may start using it right away.",
"取消隐藏 {1} 上的 {0}?优化器会立即重新考虑使用它。"),
("Design_HiddenDone", "Hid {0}", "已隐藏 {0}"),
("Design_UnhiddenDone", "Unhid {0}", "已取消隐藏 {0}"),
("Design_Undo", "Undo", "撤销"),
("Design_DropTitle", "Drop index", "删除索引"),
("Design_DropBody", "Drop {0} from {1}? Queries using it fall back to other plans or a collection scan, and rebuilding means scanning the whole collection again.",
"删除 {1} 上的 {0}?依赖它的查询会改走别的计划或全表扫描;重建需要重新扫描整个集合。"),
("Design_DropHideInstead", "Hide it instead (reversible)…", "改为隐藏(可随时恢复)…"),
("Design_Dropped", "Dropped index {0}", "已删除索引 {0}"),
// ── 索引建议 ──
("Design_AdviceTitle", "Index advice", "索引建议"),
("Design_AdviceSource", "From system.profile slow queries and $indexStats · last 7 days", "基于 system.profile 慢查询与 $indexStats · 近 7 天"),
("Design_AdviceCreateTitle", "{0} filter hits {1}", "{0} 过滤出现 {1}"),
("Design_AdviceCreateDetail", "{0} queries · avg {1} ms · scans {2}, returns ≈ {3}; ESR puts equality fields first and ranges last",
"{0} 次查询 · 平均 {1} ms · 扫描 {2} 返回 ≈ {3};ESR 规则建议等值字段在前、范围字段在后"),
("Design_AdviceCreate", "Create this index", "创建此索引"),
("Design_AdviceExtendTitle", "{0} could become a compound index", "{0} 可扩展为复合索引"),
("Design_AdviceExtendDetail", "{0} slow queries still need {1} after using it; adding {2} would replace it",
"{0} 次慢查询走它之后仍需{1};若新增 {2} 可替代当前索引"),
("Design_AdviceInMemorySort", "an in-memory sort", "内存排序"),
("Design_AdviceOverScan", "heavy over-scanning", "大量多扫"),
("Design_AdviceViewQuery", "View query", "查看查询"),
("Design_AdviceRedundantTitle", "{0} duplicates the prefix of {1}", "{0} 与 {1} 前缀重复"),
("Design_AdviceRedundantDetail", "{0} serves every query {1} can; {1} takes {2} — hide it for a week before dropping",
"{0} 能覆盖 {1} 的全部查询;{1} 占用 {2},可先隐藏观察一周再删除"),
("Design_AdviceHide", "Hide index", "隐藏索引"),
("Design_AdviceUnusedTitle", "{0} unused for {1} days", "{0} 近 {1} 天未被使用"),
("Design_AdviceUnusedDetail", "Takes {0} ({1}% of all indexes); hide it (hideIndex) and watch for a week before dropping",
"占用 {0}(索引总量的 {1}%);可先隐藏(hideIndex)观察一周再删除"),
("Design_AdviceProfilerOffTitle", "The profiler is off", "慢查询分析器未开启"),
("Design_AdviceProfilerOffDetail", "system.profile has nothing for this collection. Set the profiler to level 1 under Slow queries and advice will appear here.",
"system.profile 里没有这个集合的记录。在「慢查询」里把 profiler 设为 level 1 后,这里会基于慢查询给出建议。"),
("Design_AdviceProfilerDenied", "Your user can't read system.profile, so slow-query advice is unavailable.",
"当前用户读不了 system.profile,无法基于慢查询给建议。"),
("Design_AdviceOpenProfiler", "Open slow queries", "打开慢查询"),
("Design_AdviceNone", "Nothing to act on: no slow scans or in-memory sorts on this collection in the last 7 days, and no redundant or long-unused indexes.",
"暂无建议:近 7 天没有命中该集合的全表扫描 / 内存排序慢查询,也没有冗余或长期未用的索引。"),
// ── 新建索引 ──
("Design_Fields", "Fields", "字段"),
("Design_DragHint", "Key order is the prefix order · ↑ ↓ or drag ⠿", "键序即前缀顺序 · ↑ ↓ 或拖动 ⠿ 调整"),
("Design_FieldPlaceholder", "field.path", "字段路径"),
("Design_AddField", "Add field", "添加字段"),
("Design_Kind", "Type", "类型"),
("Design_KindNormal", "Regular", "普通"),
("Design_KindText", "Text", "文本"),
("Design_KindHashed", "Hashed", "哈希"),
("Design_KindWildcard", "Wildcard", "通配符"),
("Design_Options", "Options", "选项"),
("Design_OptUnique", "Unique · unique", "唯一 unique"),
("Design_OptSparse", "Sparse · sparse", "稀疏 sparse"),
("Design_OptHidden", "Hidden after build · hidden", "创建后隐藏 hidden"),
("Design_OptHiddenHint", "for canary checks", "用于灰度验证"),
("Design_OptTtl", "TTL expiry", "TTL 过期"),
("Design_OptPartial", "Partial · partialFilterExpression", "部分索引 partialFilterExpression"),
("Design_Name", "Name", "名称"),
("Design_NameAuto", "auto", "自动生成"),
("Design_NameCustom", "custom", "已自定义"),
("Design_DirAsc", "1 asc", "1 升序"),
("Design_DirDesc", "-1 desc", "-1 降序"),
("Design_RoleEquality", "equality", "等值"),
("Design_RoleSort", "sort", "排序"),
("Design_RoleRange", "range", "范围"),
("Design_CreateIndex", "Create index", "创建索引"),
("Design_EditorTarget", "Runs createIndexes on {0}", "将在 {0} 上执行 createIndexes"),
("Design_DraftBadge", "new", "新建"),
("Design_DraftUsage", "not created yet", "待创建"),
("Design_ColOrder", "Order / type", "排序 / 类型"),
("Design_ColRole", "ESR role", "ESR 角色"),
("Design_ColSampled", "Sampled type", "抽样类型"),
("Design_MoveUp", "Move up", "上移"),
("Design_MoveDown", "Move down", "下移"),
("Design_RemoveField", "Remove field", "移除字段"),
("Design_TypeOptions", "Type & options", "类型与选项"),
("Design_Preview", "Command preview", "命令预览"),
("Design_OptUniqueHint", "rejects duplicate keys", "拒绝重复键值"),
("Design_OptSparseHint", "skips docs without the field", "跳过缺该字段的文档"),
("Design_OptPartialHint", "only docs matching the filter", "只索引满足条件的文档"),
("Design_CloseEditor", "Close the editor", "关闭编辑器"),
("Design_NoSampleFields", "No sampled fields — type a field path", "没有抽样字段 · 直接输入字段路径"),
("Design_ErrNoFields", "Add at least one field", "至少添加一个字段"),
("Design_ErrUniqueKind", "Text, hashed, wildcard and 2dsphere indexes can't be unique", "文本、哈希、通配符与 2dsphere 索引不能设为唯一"),
("Design_ErrTtlSingle", "TTL needs a single-field regular index on a date field", "TTL 只能建在单个日期字段的普通索引上"),
("Design_ErrTtlSeconds", "expireAfterSeconds must be a non-negative integer", "expireAfterSeconds 须为非负整数"),
("Design_ErrSparsePartial", "sparse and partialFilterExpression can't be combined", "sparse 与 partialFilterExpression 不能同时使用"),
("Design_ErrPartial", "partialFilterExpression: {0}", "partialFilterExpression:{0}"),
("Design_ErrPartialEmpty", "partialFilterExpression is empty", "partialFilterExpression 为空"),
("Design_ErrNameExists", "An index named {0} already exists", "已有同名索引 {0}"),
("Design_ErrGranularity", "Granularity can only get coarser (seconds → minutes → hours)", "粒度只能往粗调(seconds → minutes → hours)"),
("Design_ImpactTitle", "Estimated size ≈ {0} · build ≈ {1}", "预计大小 ≈ {0} · 构建约 {1}"),
("Design_ImpactOptimized", "Since 4.4 builds are optimized: an exclusive lock only briefly at start and end, and replica set members build simultaneously.",
"4.4 起为优化构建:仅在开始与结束时短暂持排他锁,副本集各成员同时构建。"),
("Design_ImpactLegacy", "Before 4.4, foreground builds block reads and writes on the collection — run it off-peak.",
"4.4 以前的前台构建会阻塞该集合的读写,建议在低峰期执行。"),
("Design_ImpactPartial", "A partial index only holds matching documents, so it ends up smaller.", "部分索引只收录满足条件的文档,实际会更小。"),
("Design_Estimate", "Estimate", "预估"),
("Design_CreateTitle", "Create index", "创建索引"),
("Design_CreateBody", "Create {0} on {1}? The build scans the whole collection.", "在 {1} 上创建 {0}?构建会扫描整个集合。"),
("Design_Created", "Created index {0}", "已创建索引 {0}"),
("Design_CreatedHidden", "Created hidden — unhide it once it checks out.", "已按隐藏状态创建,验证没问题后再取消隐藏。"),
// ── Schema 分析 ──
("Design_Reanalyze", "Re-analyze", "重新分析"),
("Design_FilterCarried", "Filter carried over:", "筛选条件沿用:"),
("Design_FilterNone", "none · whole collection", "无 · 全集合抽样"),
("Design_ColField", "Field", "字段"),
("Design_ColTypes", "Types & presence", "类型与出现率"),
("Design_ColDistribution", "Distribution", "值分布"),
("Design_LengthLabel", "Length", "长度"),
("Design_Analyzing", "Sampling…", "正在抽样分析…"),
("Design_SchemaEmpty", "No documents sampled — the collection is empty or the filter excluded everything.",
"没有抽到文档 —— 集合为空,或筛选条件过滤掉了全部文档。"),
("Design_SchemaTiming", "Analyzed in {0} s · {1}", "分析用时 {0} s · {1}"),
("Design_Sampled", "Sampled {0} / {1}", "抽样 {0} / {1}"),
("Design_LegendMissing", "missing {0}", "缺失 {0}"),
("Design_HintMixed", "Mixed types ⚠ consider unifying to {0}", "混合类型 ⚠ 建议统一为 {0}"),
("Design_HintUnique", "{0} · unique", "{0} · 唯一"),
("Design_HintMissingDefault", "{0} · {1}% missing · consider a default", "{0} · {1}% 缺失 · 建议补默认值"),
("Design_HintOptional", "{0} · {1}% missing · optional field", "{0} · {1}% 缺失 · 可选字段"),
("Design_HintEqualityPrefix", "{0} · {1} values · good equality prefix", "{0} · {1} 个取值 · 适合作等值前缀"),
("Design_HintNearlyUnique", "{0} · nearly every value distinct", "{0} · 几乎各不相同"),
("Design_HintDistinct", "{0} · {1} distinct values", "{0} · {1} 个取值"),
("Design_HintNumeric", "{0} · median {1} · P95 {2}", "{0} · 中位数 {1} · P95 {2}"),
("Design_HintWeekendDip", "{0} · clear weekend dip", "{0} · 周末低谷明显"),
("Design_HintDateSpan", "{0} · spans {1} days", "{0} · 跨 {1} 天"),
("Design_HintArrayObjects", "{0} · sub-fields present {1}%", "{0} · 子字段 {1}% 出现"),
("Design_HintArrayAvg", "{0} · {1} items on average", "{0} · 平均 {1} 项"),
("Design_HintObject", "{0} · {1} sub-fields", "{0} · {1} 个子字段"),
("Design_HintBoolean", "{0} · true {1}%", "{0} · true 占 {1}%"),
("Design_HintReference", "{0} · {1} distinct references", "{0} · {1} 个不同引用"),
("Design_VizUniqueValues", "{0} unique values", "{0} 个唯一值"),
("Design_VizDistinct", "{0} distinct values", "{0} 个不同取值"),
("Design_VizIdTime", "timestamps {0}", "时间戳 {0}"),
("Design_VizExample", "e.g. {0}", "例 {0}"),
("Design_VizLength", "length {0}–{1}", "长度 {0}–{1}"),
("Design_VizChildren", "fields: {0}", "子字段:{0}"),
("Design_VizAllNull", "all null", "全部为 null"),
("Design_VizOther", "other {0}%", "其它 {0}%"),
// ── 由抽样生成验证规则 ──
("Design_GenTitle", "Validation rule from the sample", "由抽样生成验证规则"),
("Design_LevelLabel", "Level · validationLevel", "验证级别 validationLevel"),
("Design_ActionLabel", "On violation · validationAction", "违规处理 validationAction"),
("Design_GenChecking", "Pre-checking existing data…", "正在预检现有数据…"),
("Design_GenFailTitle", "Pre-check: {0} existing documents would fail", "现有数据预检:{0} 份文档将不符合"),
("Design_GenAllPass", "Pre-check: every existing document passes", "现有数据预检:全部符合"),
("Design_GenAllPassDetail", "Safe to roll out as strict + error.", "可以直接以 strict + error 上线。"),
("Design_GenReasons", "Top reasons: {0}. ", "主要原因:{0}。"),
("Design_GenAdvice", "Consider rolling out as moderate + warn and watching first.", "建议先以 moderate + warn 上线观察。"),
("Design_GenViewFailures", "View these {0} documents in the query editor", "在查询编辑器中查看这 {0} 份文档"),
("Design_EditInEditor", "Adjust in editor", "在编辑器中调整"),
("Design_ApplyAsRule", "Apply as validation rule", "应用为验证规则"),
("Design_ReasonMissing", "{0} missing", "{0} 缺失"),
// ── 验证规则 ──
("Design_NoRule", "none", "未设置"),
("Design_QueryRule", "query", "查询表达式"),
("Design_RuleGenerate", "Generate from schema analysis", "从 Schema 分析生成"),
("Design_RuleFormat", "Format", "格式化"),
("Design_RuleHistory", "History", "历史版本"),
("Design_SyntaxOk", "Syntax OK", "语法正确"),
("Design_SyntaxError", "Syntax error: {0}", "语法错误:{0}"),
("Design_RuleUnsupported", "Views and time series collections don't support validation rules.", "视图与时序集合不支持验证规则。"),
("Design_TestTitle", "Rule test", "规则测试"),
("Design_PrecheckTitle", "Pre-check existing documents", "对现有文档预检"),
("Design_PrecheckSample", "sample {0}", "抽样 {0}"),
("Design_Pass", "Pass {0}", "通过 {0}"),
("Design_Fail", "Fail {0}", "不通过 {0}"),
("Design_FailReasons", "Why they fail", "不通过原因"),
("Design_ReasonServer", "(server-side)", "(服务器判定)"),
("Design_Copies", "{0} docs", "{0} 份"),
("Design_Example", "e.g. _id {0}", "例:_id {0}"),
("Design_ViewInGrid", "View in grid", "在网格中查看"),
("Design_NoFailures", "Every sampled document passes.", "抽样文档全部通过。"),
("Design_TryTitle", "Try a document", "试写文档"),
("Design_TryHint", "validated live, never written", "实时校验,不写入数据库"),
("Design_TryPass", "Passes", "通过"),
("Design_TryFail", "Fails (validationAction: {0} → {1})", "不通过(validationAction: {0} → {1})"),
("Design_TryFailWarn", "still written, a warning is logged", "仍会写入并记录警告"),
("Design_TryFailError", "the write is rejected", "写入会被拒绝"),
("Design_TryServerOnly", "The server rejects it; the client-side check can't tell which keyword.", "服务器判定不通过;客户端预检没有覆盖到具体关键字。"),
("Design_TryRuleInvalid", "Fix the rule's syntax to test documents.", "规则语法有误,修正后才能试写。"),
("Design_DiscardChanges", "Discard changes", "放弃修改"),
("Design_ApplyRule", "Apply rule", "应用规则"),
("Design_NoHistory", "No history yet — the old rule is saved every time you apply.", "暂无历史版本 · 每次应用规则前自动保存旧规则"),
("Design_Level_off", "no validation", "不校验"),
("Design_Level_moderate", "inserts + updates to valid docs", "校验插入与本就合规文档的更新"),
("Design_Level_strict", "every insert and update", "校验全部插入与更新"),
("Design_Action_warn", "write, log a warning", "写入并记录警告"),
("Design_Action_error", "reject the write", "拒绝写入"),
("Design_ApplyTitle", "Apply validation rule", "应用验证规则"),
("Design_ApplyBody", "Run collMod on {0} with validationLevel {1} · validationAction {2}?",
"对 {0} 执行 collMod:validationLevel {1} · validationAction {2}?"),
("Design_ApplyRejects", "{0} existing documents fail it; updates to them will be rejected.", "有 {0} 份现有文档不符合,对它们的更新会被拒绝。"),
("Design_ApplyWarns", "{0} existing documents fail it; writes to them will log warnings.", "有 {0} 份现有文档不符合,对它们的写入会记录警告。"),
("Design_PrecheckFailures", "Failing (pre-check)", "预检不通过"),
("Design_Applied", "Validation rule applied", "已应用验证规则"),
("Design_CompletionKeyword", "keyword", "关键字"),
("Design_CompletionOperator", "operator", "运算符"),
("Design_CompletionField", "field · {0}", "字段 · {0}"),
("Design_Kw_jsonSchema", "Validate documents against a JSON Schema (a draft-4 subset extended with bsonType).",
"按 JSON Schema(draft 4 子集,扩展了 bsonType)校验文档。"),
("Design_Kw_bsonType", "BSON type alias or a list of them: \"string\", \"int\", \"decimal\", \"date\"…",
"BSON 类型别名或其数组:\"string\"、\"int\"、\"decimal\"、\"date\"…"),
("Design_Kw_required", "Fields that must be present.", "必须存在的字段。"),
("Design_Kw_properties", "A schema for each field.", "逐个字段的子 schema。"),
("Design_Kw_enum", "The value must be one of the listed values.", "值必须是列出的取值之一。"),
("Design_Kw_minimum", "The number must be ≥ the given value.", "数值必须 ≥ 给定数。"),
("Design_Kw_maximum", "The number must be ≤ the given value.", "数值必须 ≤ 给定数。"),
("Design_Kw_exclusiveMinimum", "Makes minimum strict (>).", "让 minimum 变成严格大于。"),
("Design_Kw_exclusiveMaximum", "Makes maximum strict (<).", "让 maximum 变成严格小于。"),
("Design_Kw_minLength", "String length must be ≥ n.", "字符串长度须 ≥ n。"),
("Design_Kw_maxLength", "String length must be ≤ n.", "字符串长度须 ≤ n。"),
("Design_Kw_pattern", "The string must match the regular expression.", "字符串必须匹配该正则。"),
("Design_Kw_items", "A schema for array elements.", "数组元素的 schema。"),
("Design_Kw_minItems", "Array length must be ≥ n.", "数组长度须 ≥ n。"),
("Design_Kw_maxItems", "Array length must be ≤ n.", "数组长度须 ≤ n。"),
("Design_Kw_uniqueItems", "Array elements must be distinct.", "数组元素不得重复。"),
("Design_Kw_additionalProperties", "false rejects fields not listed in properties.", "为 false 时拒绝 properties 之外的字段。"),
("Design_Kw_patternProperties", "Schemas for field names matching a regular expression.", "按正则匹配字段名的子 schema。"),
("Design_Kw_minProperties", "The object must have ≥ n fields.", "对象字段数须 ≥ n。"),
("Design_Kw_maxProperties", "The object must have ≤ n fields.", "对象字段数须 ≤ n。"),
("Design_Kw_description", "Free text; it shows up in validation errors.", "说明文字,会出现在校验错误里。"),
("Design_Kw_title", "A short label.", "简短标题。"),
("Design_Kw_anyOf", "Valid if at least one sub-schema matches.", "至少满足其中一个子 schema。"),
("Design_Kw_allOf", "Valid if every sub-schema matches.", "须满足全部子 schema。"),
("Design_Kw_oneOf", "Valid if exactly one sub-schema matches.", "恰好满足其中一个子 schema。"),
("Design_Kw_not", "Valid if the sub-schema does not match.", "不满足该子 schema 才算通过。"),
("Design_Kw_multipleOf", "The number must be a multiple of the given value.", "数值必须是给定数的整数倍。"),
("Design_KwGroup_numeric", "numeric constraint", "数值约束"),
("Design_KwGroup_string", "string constraint", "字符串约束"),
("Design_KwGroup_array", "array constraint", "数组约束"),
("Design_KwGroup_object", "object constraint", "对象约束"),
("Design_KwGroup_type", "type constraint", "类型约束"),
("Design_KwGroup_logic", "combinator", "组合"),
("Design_KwGroup_operator", "query operator", "查询运算符"),
("Design_KwGroup_meta", "annotation", "说明"),
("Design_HoverFailures", " In the sample, {0} documents violate it ({1}). {2}", "抽样中有 {0} 份文档违反它({1})。{2}"),
("Design_HoverOff", "validationLevel is off: nothing is validated right now.", "validationLevel 为 off:当前不做校验。"),
("Design_HoverWarn", "Under {0} they can still be written; violations only log a warning.", "在 {0} 下它们仍可写入,违规只记录警告。"),
("Design_HoverErrorModerate", "Under moderate, existing invalid documents can still be updated, but new writes are rejected.",
"在 moderate 下已有的不合规文档仍可更新,但新写入会被拒绝。"),
("Design_HoverErrorStrict", "Under strict, updates to them and new writes are all rejected.", "在 strict 下对它们的更新与新写入都会被拒绝。"),
// ── 选项 ──
("Design_OptTtlSection", "TTL indexes", "TTL 过期索引"),
("Design_OptTtlHint", "A background thread removes expired documents about every 60 s. Changing the seconds takes effect immediately — no rebuild.",
"后台线程约每 60 秒清理一次过期文档;改秒数立即生效,不重建索引。"),
("Design_OptTtlNone", "No TTL indexes. Tick “TTL expiry” when creating an index to expire documents by a date field.",
"没有 TTL 索引。新建索引时勾选「TTL 过期」即可让文档按日期字段自动删除。"),
("Design_OptTtlChange", "TTL of {0} → {1}", "{0} 的 TTL → {1}"),
("Design_OptCollation", "Collation", "排序规则 collation"),
("Design_ReadOnly", "read-only", "只读"),
("Design_OptCollationNone", "Not set · binary comparison (simple)", "未设置 · 按二进制比较(simple)"),
("Design_OptCollationHint", "Collation is fixed at creation; to change it, create a new collection and migrate the data.",
"排序规则只能在建集合时指定;要改只能新建集合后迁移数据。"),
("Design_OptCappedSection", "Capped collection", "固定集合 capped"),
("Design_OptCappedSize", "Size limit (bytes)", "大小上限(字节)"),
("Design_OptCappedMax", "Document limit", "文档数上限"),
("Design_Unlimited", "unlimited", "不限"),
("Design_OptCappedHint", "Adjustable with collMod since 6.0; shrinking evicts the oldest documents right away.",
"6.0 起可用 collMod 调整;缩小上限会立刻淘汰最早的文档。"),
("Design_OptCapped", "the capped limits", "固定集合上限"),
("Design_OptTsSection", "Time series", "时序集合 timeseries"),
("Design_OptGranularity", "Granularity", "粒度 granularity"),
("Design_NeverExpire", "never expires", "不过期"),
("Design_OptTsHint", "timeField / metaField can't change after creation; granularity can only get coarser (seconds → minutes → hours).",
"timeField / metaField 建好后不能改;粒度只能往粗调(seconds → minutes → hours)。"),
("Design_OptTimeSeries", "the time series options", "时序参数"),
("Design_OptViewSection", "View definition", "视图定义"),
("Design_OptViewOn", "Source · viewOn", "源集合 viewOn"),
("Design_OptViewPipeline", "Pipeline", "管道 pipeline"),
("Design_OptView", "the view definition", "视图定义"),
("Design_OptPrePostSection", "Change stream pre- and post-images", "变更流前后镜像"),
("Design_OptPrePostHint", "When on, change streams can return full documents from before and after updates and deletes (6.0+); the images take space in config.system.preimages.",
"开启后 change stream 能拿到更新 / 删除前后的完整文档(6.0+);镜像会额外占用 config.system.preimages 的空间。"),
("Design_OptPrePost", "pre- and post-images", "前后镜像"),
("Design_OptRaw", "listCollections options", "listCollections options 原文"),
("Design_CollModTitle", "Modify collection", "修改集合"),
("Design_CollModBody", "Run collMod on {0} to change {1}?", "对 {0} 执行 collMod,修改{1}?"),
("Design_CollModDone", "Updated {0}", "已更新{0}"),
// ── 统计 ──
("Design_StatDocs", "Documents", "文档数"),
("Design_StatAvg", "avg {0}", "平均 {0}"),
("Design_StatData", "Data size", "数据大小"),
("Design_StatUncompressed", "uncompressed", "未压缩"),
("Design_StatStorage", "Storage size", "存储大小"),
("Design_StatRatio", "Compression", "压缩比"),
("Design_StatRatioSub", "data ÷ storage", "数据 ÷ 存储"),
("Design_StatIndexes", "Index size", "索引总大小"),
("Design_StatIndexCount", "{0} indexes", "{0} 个索引"),
("Design_StatFree", "Reclaimable", "可回收空间"),
("Design_StatFreeCompact", "over 20% of storage — consider compact", "超过存储的 20% · 可考虑 compact"),
("Design_StatFreeOk", "freeStorageSize", "freeStorageSize"),
("Design_CopyRaw", "Copy JSON", "复制 JSON"),
("Design_StatsIndexSizes", "Index sizes", "索引大小"),
("Design_StatsRaw", "Raw JSON · $collStats storageStats", "原始 JSON · $collStats storageStats"),
];
}