jazz-tools 0.7.0-alpha.6 → 0.7.0-alpha.7
Sign up to get free protection for your applications and to get access to all the features.
- package/CHANGELOG.md +8 -0
- package/dist/coValues/account.js +62 -29
- package/dist/coValues/account.js.map +1 -1
- package/dist/coValues/coList.js +139 -89
- package/dist/coValues/coList.js.map +1 -1
- package/dist/coValues/coMap.js +135 -151
- package/dist/coValues/coMap.js.map +1 -1
- package/dist/coValues/coStream.js +131 -57
- package/dist/coValues/coStream.js.map +1 -1
- package/dist/coValues/extensions/imageDef.js +10 -7
- package/dist/coValues/extensions/imageDef.js.map +1 -1
- package/dist/coValues/group.js +8 -30
- package/dist/coValues/group.js.map +1 -1
- package/dist/coValues/interfaces.js +6 -2
- package/dist/coValues/interfaces.js.map +1 -1
- package/dist/implementation/encoding.js +21 -0
- package/dist/implementation/encoding.js.map +1 -1
- package/dist/implementation/refs.js +10 -9
- package/dist/implementation/refs.js.map +1 -1
- package/dist/index.js +1 -1
- package/dist/index.js.map +1 -1
- package/dist/tests/coList.test.js +5 -9
- package/dist/tests/coList.test.js.map +1 -1
- package/dist/tests/coMap.test.js +86 -36
- package/dist/tests/coMap.test.js.map +1 -1
- package/dist/tests/coStream.test.js +46 -51
- package/dist/tests/coStream.test.js.map +1 -1
- package/package.json +2 -2
- package/src/coValues/account.ts +82 -52
- package/src/coValues/coList.ts +170 -107
- package/src/coValues/coMap.ts +178 -217
- package/src/coValues/coStream.ts +169 -91
- package/src/coValues/extensions/imageDef.ts +7 -11
- package/src/coValues/group.ts +16 -63
- package/src/coValues/interfaces.ts +9 -8
- package/src/implementation/encoding.ts +55 -16
- package/src/implementation/refs.ts +12 -10
- package/src/index.ts +1 -1
- package/src/tests/coList.test.ts +5 -9
- package/src/tests/coMap.test.ts +67 -51
- package/src/tests/coStream.test.ts +61 -66
package/src/coValues/coMap.ts
CHANGED
@@ -3,36 +3,38 @@ import type { Simplify } from "effect/Types";
|
|
3
3
|
import { Schema } from "@effect/schema";
|
4
4
|
import type {
|
5
5
|
CoValue,
|
6
|
-
Encoder,
|
7
6
|
Encoding,
|
8
7
|
EncodingFor,
|
9
8
|
Group,
|
10
9
|
ID,
|
11
10
|
RefEncoded,
|
12
11
|
EnsureCoValueNullable,
|
13
|
-
|
12
|
+
IsVal,
|
14
13
|
} from "../internal.js";
|
15
14
|
import {
|
16
15
|
Account,
|
17
16
|
CoValueBase,
|
18
17
|
Ref,
|
18
|
+
SchemaInit,
|
19
19
|
inspect,
|
20
20
|
makeRefs,
|
21
21
|
subscriptionsScopes,
|
22
|
+
ItemsSym,
|
23
|
+
InitValues,
|
22
24
|
} from "../internal.js";
|
23
25
|
|
24
|
-
type ValidFields<Fields extends { [key: string]: any;
|
25
|
-
[Key in
|
26
|
-
Key,
|
27
|
-
Fields
|
26
|
+
type ValidFields<Fields extends { [key: string]: any; [ItemsSym]?: any }> = {
|
27
|
+
[Key in keyof Fields & string as IsVal<
|
28
|
+
Fields[Key],
|
29
|
+
IfOptionalKey<Key, Fields>
|
28
30
|
>]?: EnsureCoValueNullable<Fields[Key], Key>;
|
29
31
|
} & {
|
30
|
-
[Key in
|
31
|
-
Key,
|
32
|
-
Fields
|
32
|
+
[Key in keyof Fields & string as IsVal<
|
33
|
+
Fields[Key],
|
34
|
+
IfRequiredKey<Key, Fields>
|
33
35
|
>]: EnsureCoValueNullable<Fields[Key], Key>;
|
34
36
|
} & {
|
35
|
-
[Key in
|
37
|
+
[Key in ItemsSym]?: EnsureCoValueNullable<Fields[ItemsSym], Key>;
|
36
38
|
};
|
37
39
|
|
38
40
|
type IfOptionalKey<Key extends keyof Obj, Obj> = Pick<
|
@@ -50,7 +52,7 @@ type IfRequiredKey<Key extends keyof Obj, Obj> = Pick<
|
|
50
52
|
|
51
53
|
type DefaultFields = {
|
52
54
|
[key: string]: any;
|
53
|
-
|
55
|
+
[ItemsSym]?: any;
|
54
56
|
};
|
55
57
|
|
56
58
|
export class CoMap<Fields extends ValidFields<Fields> = DefaultFields>
|
@@ -66,10 +68,12 @@ export class CoMap<Fields extends ValidFields<Fields> = DefaultFields>
|
|
66
68
|
|
67
69
|
static _encoding: any;
|
68
70
|
get _encoding(): {
|
69
|
-
[Key in OwnKeys<Fields>
|
71
|
+
[Key in OwnKeys<Fields> as IsVal<Fields[Key], Key>]: EncodingFor<
|
72
|
+
Fields[Key]
|
73
|
+
>;
|
70
74
|
} & {
|
71
|
-
|
72
|
-
? EncodingFor<Fields[
|
75
|
+
[ItemsSym]: ItemsSym extends keyof Fields
|
76
|
+
? EncodingFor<Fields[ItemsSym]>
|
73
77
|
: never;
|
74
78
|
} {
|
75
79
|
return (this.constructor as typeof CoMap)._encoding;
|
@@ -92,12 +96,12 @@ export class CoMap<Fields extends ValidFields<Fields> = DefaultFields>
|
|
92
96
|
schema !== "json" && "ref" in schema;
|
93
97
|
}) as OwnKeys<Fields>[],
|
94
98
|
this._loadedAs,
|
95
|
-
(key) =>
|
99
|
+
(key) => this._encoding[key] as RefEncoded<CoValue>
|
96
100
|
) as any;
|
97
101
|
}
|
98
102
|
|
99
103
|
get _edits(): {
|
100
|
-
[Key in OwnKeys<Fields>]: {
|
104
|
+
[Key in OwnKeys<Fields> as IsVal<Fields[Key], Key>]: {
|
101
105
|
value?: Fields[Key];
|
102
106
|
ref?: Fields[Key] extends CoValue ? Ref<Fields[Key]> : never;
|
103
107
|
by?: Account;
|
@@ -124,23 +128,21 @@ export class CoMap<Fields extends ValidFields<Fields> = DefaultFields>
|
|
124
128
|
: new Ref(
|
125
129
|
rawEdit.value as ID<CoValue>,
|
126
130
|
target._loadedAs,
|
127
|
-
descriptor
|
131
|
+
descriptor
|
128
132
|
).accessFrom(target),
|
129
133
|
ref:
|
130
134
|
descriptor !== "json" && "ref" in descriptor
|
131
135
|
? new Ref(
|
132
136
|
rawEdit.value as ID<CoValue>,
|
133
137
|
target._loadedAs,
|
134
|
-
descriptor
|
138
|
+
descriptor
|
135
139
|
)
|
136
140
|
: undefined,
|
137
141
|
by:
|
138
142
|
rawEdit.by &&
|
139
|
-
new Ref(
|
140
|
-
|
141
|
-
|
142
|
-
Account
|
143
|
-
).accessFrom(target),
|
143
|
+
new Ref(rawEdit.by as ID<Account>, target._loadedAs, {
|
144
|
+
ref: () => Account,
|
145
|
+
}).accessFrom(target),
|
144
146
|
madeAt: rawEdit.at,
|
145
147
|
};
|
146
148
|
},
|
@@ -151,6 +153,11 @@ export class CoMap<Fields extends ValidFields<Fields> = DefaultFields>
|
|
151
153
|
return Account.fromNode(this._raw.core.node);
|
152
154
|
}
|
153
155
|
|
156
|
+
[InitValues]?: {
|
157
|
+
init: Simplify<CoMapInit<Fields>>;
|
158
|
+
owner: Account | Group;
|
159
|
+
};
|
160
|
+
|
154
161
|
constructor(_init: undefined, options: { fromRaw: RawCoMap });
|
155
162
|
constructor(
|
156
163
|
init: Simplify<CoMapInit<Fields>>,
|
@@ -162,29 +169,21 @@ export class CoMap<Fields extends ValidFields<Fields> = DefaultFields>
|
|
162
169
|
) {
|
163
170
|
super();
|
164
171
|
|
165
|
-
if (
|
166
|
-
|
167
|
-
|
168
|
-
|
169
|
-
|
170
|
-
|
172
|
+
if (init && "owner" in options) {
|
173
|
+
this[InitValues] = { init, owner: options.owner };
|
174
|
+
} else if ("fromRaw" in options) {
|
175
|
+
Object.defineProperties(this, {
|
176
|
+
id: {
|
177
|
+
value: options.fromRaw.id as unknown as ID<this>,
|
178
|
+
enumerable: false,
|
179
|
+
},
|
180
|
+
_raw: { value: options.fromRaw, enumerable: false },
|
181
|
+
});
|
182
|
+
} else {
|
183
|
+
throw new Error("Invalid CoMap constructor arguments");
|
171
184
|
}
|
172
185
|
|
173
|
-
|
174
|
-
|
175
|
-
Object.defineProperties(this, {
|
176
|
-
id: {
|
177
|
-
value: raw.id,
|
178
|
-
enumerable: false,
|
179
|
-
},
|
180
|
-
_raw: { value: raw, enumerable: false },
|
181
|
-
});
|
182
|
-
|
183
|
-
this.definePropertiesFromSchema();
|
184
|
-
|
185
|
-
if (this._encoding._item) {
|
186
|
-
return new Proxy(this, CoMapProxyHandler<Fields>());
|
187
|
-
}
|
186
|
+
return new Proxy(this, CoMapProxyHandler as ProxyHandler<this>);
|
188
187
|
}
|
189
188
|
|
190
189
|
toJSON() {
|
@@ -214,144 +213,43 @@ export class CoMap<Fields extends ValidFields<Fields> = DefaultFields>
|
|
214
213
|
}
|
215
214
|
|
216
215
|
rawFromInit<Fields extends object = Record<string, any>>(
|
217
|
-
|
218
|
-
|
216
|
+
init: Simplify<CoMapInit<Fields>> | undefined,
|
217
|
+
owner: Account | Group
|
219
218
|
) {
|
220
|
-
|
221
|
-
|
222
|
-
if ("fromRaw" in options) {
|
223
|
-
raw = options.fromRaw;
|
224
|
-
} else {
|
225
|
-
const rawOwner = options.owner._raw;
|
219
|
+
const rawOwner = owner._raw;
|
226
220
|
|
227
|
-
|
228
|
-
|
229
|
-
|
221
|
+
const rawInit = {} as {
|
222
|
+
[key in keyof Fields]: JsonValue | undefined;
|
223
|
+
};
|
230
224
|
|
231
|
-
|
232
|
-
|
233
|
-
|
225
|
+
if (init)
|
226
|
+
for (const key of Object.keys(init) as (keyof Fields)[]) {
|
227
|
+
const initValue = init[key as keyof typeof init];
|
234
228
|
|
235
|
-
|
236
|
-
|
237
|
-
|
229
|
+
const descriptor = (this._encoding[
|
230
|
+
key as keyof typeof this._encoding
|
231
|
+
] || this._encoding[ItemsSym]) as Encoding;
|
238
232
|
|
239
|
-
|
240
|
-
|
241
|
-
|
242
|
-
|
243
|
-
|
244
|
-
}
|
245
|
-
} else if ("encoded" in descriptor) {
|
246
|
-
rawInit[key] = Schema.encodeSync(descriptor.encoded)(
|
247
|
-
initValue as any
|
248
|
-
);
|
233
|
+
if (descriptor === "json") {
|
234
|
+
rawInit[key] = initValue as JsonValue;
|
235
|
+
} else if ("ref" in descriptor) {
|
236
|
+
if (initValue) {
|
237
|
+
rawInit[key] = (initValue as unknown as CoValue).id;
|
249
238
|
}
|
239
|
+
} else if ("encoded" in descriptor) {
|
240
|
+
rawInit[key] = Schema.encodeSync(descriptor.encoded)(
|
241
|
+
initValue as any
|
242
|
+
);
|
250
243
|
}
|
251
|
-
|
252
|
-
raw = rawOwner.createMap(rawInit);
|
253
|
-
}
|
254
|
-
return raw;
|
255
|
-
}
|
256
|
-
|
257
|
-
static encoding<V extends CoMap>(
|
258
|
-
this: { new (...args: any): V } & typeof CoMap,
|
259
|
-
fields: Simplify<{
|
260
|
-
[Key in keyof V["_encoding"] as V["_encoding"][Key] extends never
|
261
|
-
? never
|
262
|
-
: Key]: Simplify<V["_encoding"][Key]>;
|
263
|
-
}>
|
264
|
-
) {
|
265
|
-
this._encoding ||= {};
|
266
|
-
Object.assign(this._encoding, fields);
|
267
|
-
}
|
268
|
-
|
269
|
-
private definePropertiesFromSchema() {
|
270
|
-
for (const [key, fieldSchema] of Object.entries(this._encoding)) {
|
271
|
-
if (key === "indexSignature") continue;
|
272
|
-
const descriptor = fieldSchema as Encoding;
|
273
|
-
if (descriptor === "json") {
|
274
|
-
Object.defineProperty(
|
275
|
-
this,
|
276
|
-
key,
|
277
|
-
this.primitivePropDef(key as string)
|
278
|
-
);
|
279
|
-
} else if ("encoded" in descriptor) {
|
280
|
-
Object.defineProperty(
|
281
|
-
this,
|
282
|
-
key,
|
283
|
-
this.encodedPropDef(key as string, descriptor.encoded)
|
284
|
-
);
|
285
|
-
} else if ("ref" in descriptor) {
|
286
|
-
Object.defineProperty(
|
287
|
-
this,
|
288
|
-
key,
|
289
|
-
this.refPropDef(
|
290
|
-
key as string,
|
291
|
-
(descriptor as RefEncoded<CoValue>).ref
|
292
|
-
)
|
293
|
-
);
|
294
244
|
}
|
295
|
-
}
|
296
|
-
}
|
297
245
|
|
298
|
-
|
299
|
-
return {
|
300
|
-
get: () => {
|
301
|
-
return this._raw.get(key);
|
302
|
-
},
|
303
|
-
set(this: CoMap, value: JsonValue) {
|
304
|
-
this._raw.set(key, value);
|
305
|
-
},
|
306
|
-
enumerable: true,
|
307
|
-
configurable: true,
|
308
|
-
};
|
309
|
-
}
|
310
|
-
|
311
|
-
private encodedPropDef(key: string, arg: Encoder<any>): PropertyDescriptor {
|
312
|
-
return {
|
313
|
-
get: () => {
|
314
|
-
const raw = this._raw.get(key);
|
315
|
-
return raw === undefined
|
316
|
-
? undefined
|
317
|
-
: Schema.decodeSync(arg)(raw);
|
318
|
-
},
|
319
|
-
set(this: CoMap, value: unknown) {
|
320
|
-
this._raw.set(key, Schema.encodeSync(arg)(value));
|
321
|
-
},
|
322
|
-
enumerable: true,
|
323
|
-
configurable: true,
|
324
|
-
};
|
325
|
-
}
|
326
|
-
|
327
|
-
private refPropDef(
|
328
|
-
key: string,
|
329
|
-
ref: () => CoValueClass<CoValue>
|
330
|
-
): PropertyDescriptor {
|
331
|
-
return {
|
332
|
-
get: () => {
|
333
|
-
const rawID = this._raw.get(key);
|
334
|
-
return rawID === undefined
|
335
|
-
? undefined
|
336
|
-
: new Ref(
|
337
|
-
rawID as unknown as ID<CoValue>,
|
338
|
-
this._loadedAs,
|
339
|
-
ref()
|
340
|
-
).accessFrom(this);
|
341
|
-
},
|
342
|
-
set: (value: CoValue) => {
|
343
|
-
this._raw.set(key, value.id);
|
344
|
-
subscriptionsScopes.get(this)?.onRefAccessedOrSet(value.id);
|
345
|
-
},
|
346
|
-
enumerable: true,
|
347
|
-
configurable: true,
|
348
|
-
};
|
246
|
+
return rawOwner.createMap(rawInit);
|
349
247
|
}
|
350
248
|
}
|
351
249
|
|
352
250
|
export type OwnKeys<Fields extends object> = Exclude<
|
353
251
|
keyof Fields & string,
|
354
|
-
keyof CoMap<Record<string, never>>
|
252
|
+
keyof CoMap<Record<string, never>>
|
355
253
|
>;
|
356
254
|
|
357
255
|
export type CoMapInit<Fields extends object> = {
|
@@ -359,19 +257,44 @@ export type CoMapInit<Fields extends object> = {
|
|
359
257
|
? never
|
360
258
|
: null extends Fields[Key]
|
361
259
|
? never
|
362
|
-
: Key]: Fields[Key];
|
363
|
-
} & { [Key in OwnKeys<Fields>]?: Fields[Key] };
|
260
|
+
: IsVal<Fields[Key], Key>]: Fields[Key];
|
261
|
+
} & { [Key in OwnKeys<Fields> as IsVal<Fields[Key], Key>]?: Fields[Key] };
|
262
|
+
|
263
|
+
function tryInit(map: CoMap) {
|
264
|
+
if (
|
265
|
+
map[InitValues] &&
|
266
|
+
(map._encoding[ItemsSym] ||
|
267
|
+
Object.keys(map[InitValues].init).every(
|
268
|
+
(key) => map._encoding[key]
|
269
|
+
))
|
270
|
+
) {
|
271
|
+
const raw = map.rawFromInit(
|
272
|
+
map[InitValues].init,
|
273
|
+
map[InitValues].owner
|
274
|
+
);
|
275
|
+
Object.defineProperties(map, {
|
276
|
+
id: {
|
277
|
+
value: raw.id,
|
278
|
+
enumerable: false,
|
279
|
+
},
|
280
|
+
_raw: { value: raw, enumerable: false },
|
281
|
+
});
|
282
|
+
delete map[InitValues];
|
283
|
+
}
|
284
|
+
}
|
364
285
|
|
365
286
|
// TODO: cache handlers per descriptor for performance?
|
366
|
-
|
367
|
-
|
368
|
-
|
369
|
-
|
370
|
-
|
371
|
-
|
372
|
-
|
373
|
-
|
374
|
-
|
287
|
+
const CoMapProxyHandler: ProxyHandler<CoMap> = {
|
288
|
+
get(target, key, receiver) {
|
289
|
+
if (key === "_encoding") {
|
290
|
+
return Reflect.get(target, key);
|
291
|
+
} else if (key in target) {
|
292
|
+
return Reflect.get(target, key, receiver);
|
293
|
+
} else {
|
294
|
+
const descriptor = (target._encoding[
|
295
|
+
key as keyof CoMap["_encoding"]
|
296
|
+
] || target._encoding[ItemsSym]) as Encoding;
|
297
|
+
if (descriptor && typeof key === "string") {
|
375
298
|
const raw = target._raw.get(key);
|
376
299
|
|
377
300
|
if (descriptor === "json") {
|
@@ -386,52 +309,90 @@ function CoMapProxyHandler<Fields extends ValidFields<Fields>>(): ProxyHandler<
|
|
386
309
|
: new Ref(
|
387
310
|
raw as unknown as ID<CoValue>,
|
388
311
|
target._loadedAs,
|
389
|
-
descriptor
|
390
|
-
).accessFrom(
|
312
|
+
descriptor
|
313
|
+
).accessFrom(receiver);
|
391
314
|
}
|
392
|
-
}
|
393
|
-
},
|
394
|
-
set(target, key, value, receiver) {
|
395
|
-
const descriptor = target._encoding._item as Encoding;
|
396
|
-
if (key in target || typeof key === "symbol") {
|
397
|
-
return Reflect.set(target, key, value, receiver);
|
398
315
|
} else {
|
399
|
-
|
400
|
-
target._raw.set(key, value);
|
401
|
-
} else if ("encoded" in descriptor) {
|
402
|
-
target._raw.set(
|
403
|
-
key,
|
404
|
-
Schema.encodeSync(descriptor.encoded)(value)
|
405
|
-
);
|
406
|
-
} else if ("ref" in descriptor) {
|
407
|
-
target._raw.set(key, value.id);
|
408
|
-
subscriptionsScopes
|
409
|
-
.get(target)
|
410
|
-
?.onRefAccessedOrSet(value.id);
|
411
|
-
}
|
412
|
-
return true;
|
316
|
+
return undefined;
|
413
317
|
}
|
414
|
-
}
|
415
|
-
|
416
|
-
|
417
|
-
|
418
|
-
|
419
|
-
|
420
|
-
|
318
|
+
}
|
319
|
+
},
|
320
|
+
set(target, key, value, receiver) {
|
321
|
+
if (
|
322
|
+
(typeof key === "string" || ItemsSym) &&
|
323
|
+
typeof value === "object" &&
|
324
|
+
SchemaInit in value
|
325
|
+
) {
|
326
|
+
(target.constructor as typeof CoMap)._encoding ||= {};
|
327
|
+
(target.constructor as typeof CoMap)._encoding[key] =
|
328
|
+
value[SchemaInit];
|
329
|
+
tryInit(target);
|
330
|
+
return true;
|
331
|
+
}
|
332
|
+
|
333
|
+
const descriptor = (target._encoding[key as keyof CoMap["_encoding"]] ||
|
334
|
+
target._encoding[ItemsSym]) as Encoding;
|
335
|
+
if (descriptor && typeof key === "string") {
|
336
|
+
if (descriptor === "json") {
|
337
|
+
target._raw.set(key, value);
|
338
|
+
} else if ("encoded" in descriptor) {
|
339
|
+
target._raw.set(
|
340
|
+
key,
|
341
|
+
Schema.encodeSync(descriptor.encoded)(value)
|
342
|
+
);
|
343
|
+
} else if ("ref" in descriptor) {
|
344
|
+
target._raw.set(key, value.id);
|
345
|
+
subscriptionsScopes.get(target)?.onRefAccessedOrSet(value.id);
|
421
346
|
}
|
347
|
+
return true;
|
348
|
+
} else {
|
349
|
+
return Reflect.set(target, key, value, receiver);
|
350
|
+
}
|
351
|
+
},
|
352
|
+
defineProperty(target, key, attributes) {
|
353
|
+
if (
|
354
|
+
"value" in attributes &&
|
355
|
+
typeof attributes.value === "object" &&
|
356
|
+
SchemaInit in attributes.value
|
357
|
+
) {
|
358
|
+
(target.constructor as typeof CoMap)._encoding ||= {};
|
359
|
+
(target.constructor as typeof CoMap)._encoding[key as string] =
|
360
|
+
attributes.value[SchemaInit];
|
361
|
+
tryInit(target);
|
362
|
+
return true;
|
363
|
+
} else {
|
364
|
+
return Reflect.defineProperty(target, key, attributes);
|
365
|
+
}
|
366
|
+
},
|
367
|
+
ownKeys(target) {
|
368
|
+
const keys = Reflect.ownKeys(target).filter((k) => k !== ItemsSym);
|
369
|
+
for (const key of Reflect.ownKeys(target._encoding)) {
|
370
|
+
if (key !== ItemsSym && !keys.includes(key)) {
|
371
|
+
keys.push(key);
|
372
|
+
}
|
373
|
+
}
|
374
|
+
for (const key of target._raw.keys()) {
|
375
|
+
if (!keys.includes(key)) {
|
376
|
+
keys.push(key);
|
377
|
+
}
|
378
|
+
}
|
422
379
|
|
423
|
-
|
424
|
-
|
425
|
-
|
426
|
-
|
427
|
-
|
428
|
-
|
380
|
+
return keys;
|
381
|
+
},
|
382
|
+
getOwnPropertyDescriptor(target, key) {
|
383
|
+
if (key in target) {
|
384
|
+
return Reflect.getOwnPropertyDescriptor(target, key);
|
385
|
+
} else {
|
386
|
+
const descriptor = (target._encoding[
|
387
|
+
key as keyof CoMap["_encoding"]
|
388
|
+
] || target._encoding[ItemsSym]) as Encoding;
|
389
|
+
if (descriptor || key in target._raw.ops) {
|
429
390
|
return {
|
430
391
|
enumerable: true,
|
431
392
|
configurable: true,
|
432
393
|
writable: true,
|
433
394
|
};
|
434
395
|
}
|
435
|
-
}
|
436
|
-
}
|
437
|
-
}
|
396
|
+
}
|
397
|
+
},
|
398
|
+
};
|