@php-wasm/universal 3.1.29 → 3.1.31

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -11,10 +11,51 @@ const schema11 = {
11
11
  name: { type: 'string' },
12
12
  version: { type: 'string' },
13
13
  mode: { type: 'string', const: 'php-extension' },
14
+ loadWithIniDirective: {
15
+ $ref: '#/definitions/PHPExtensionLoadDirective',
16
+ description:
17
+ 'The first directive of the generated startup `.ini` file. Defaults to `extension`; use `zend_extension` for Zend extensions like Xdebug. Use `false` to stage the `.so` without registering it in php.ini.',
18
+ },
19
+ iniEntries: {
20
+ type: 'object',
21
+ additionalProperties: { type: 'string' },
22
+ description:
23
+ 'Additional `key=value` lines for the generated startup `.ini` file.',
24
+ },
25
+ env: {
26
+ type: 'object',
27
+ additionalProperties: { type: 'string' },
28
+ description:
29
+ 'Environment variables added before the extension is loaded.',
30
+ },
31
+ extensionDir: {
32
+ type: 'string',
33
+ description:
34
+ 'VFS directory where PHP.wasm writes the extension `.so` file and its per-extension ini file. Defaults to `PHP_EXTENSIONS_DIR`.',
35
+ },
14
36
  artifacts: {
15
37
  type: 'array',
16
38
  items: {
17
- $ref: '#/definitions/PHPExtensionManifestArtifact',
39
+ type: 'object',
40
+ properties: {
41
+ phpVersion: {
42
+ type: 'string',
43
+ description:
44
+ 'PHP major/minor version, e.g. `8.4`.',
45
+ },
46
+ sourcePath: {
47
+ type: 'string',
48
+ description:
49
+ 'Relative to the manifest URL/base URL, or an absolute URL.',
50
+ },
51
+ extraFiles: {
52
+ $ref: '#/definitions/PHPExtensionManifestExtraFiles',
53
+ description:
54
+ 'URL-backed files needed only by this artifact.',
55
+ },
56
+ },
57
+ required: ['phpVersion', 'sourcePath'],
58
+ additionalProperties: false,
18
59
  },
19
60
  },
20
61
  extraFiles: {
@@ -28,26 +69,17 @@ const schema11 = {
28
69
  description:
29
70
  'Extension artifact manifest. Lets callers publish a matrix of `.so` files and lets `resolvePHPExtension()` select the artifact matching the current PHP version. External extension artifacts are JSPI-only.',
30
71
  },
31
- PHPExtensionManifestArtifact: {
32
- type: 'object',
33
- properties: {
34
- phpVersion: {
35
- type: 'string',
36
- description: 'PHP major/minor version, e.g. `8.4`.',
37
- },
38
- sourcePath: {
39
- type: 'string',
40
- description:
41
- 'Relative to the manifest URL/base URL, or an absolute URL.',
42
- },
43
- extraFiles: {
44
- $ref: '#/definitions/PHPExtensionManifestExtraFiles',
45
- description:
46
- 'URL-backed files needed only by this artifact.',
47
- },
48
- },
49
- required: ['phpVersion', 'sourcePath'],
50
- additionalProperties: false,
72
+ PHPExtensionLoadDirective: {
73
+ anyOf: [
74
+ { $ref: '#/definitions/PHPExtensionIniDirective' },
75
+ { type: 'boolean', const: false },
76
+ ],
77
+ },
78
+ PHPExtensionIniDirective: {
79
+ type: 'string',
80
+ enum: ['extension', 'zend_extension'],
81
+ description:
82
+ 'The php.ini directive used to load the extension. Use `extension` for regular PHP extensions and `zend_extension` for Zend extensions like Xdebug.',
51
83
  },
52
84
  PHPExtensionManifestExtraFiles: {
53
85
  type: 'object',
@@ -60,35 +92,32 @@ const schema11 = {
60
92
  nodes: {
61
93
  type: 'array',
62
94
  items: {
63
- $ref: '#/definitions/PHPExtensionManifestExtraFile',
95
+ type: 'object',
96
+ properties: {
97
+ vfsPath: {
98
+ type: 'string',
99
+ description:
100
+ "Joined with the group's `vfsRoot` to form the final VFS path.",
101
+ },
102
+ type: {
103
+ type: 'string',
104
+ enum: ['file', 'directory'],
105
+ description:
106
+ 'Defaults to "file". Only file nodes need a `sourcePath`.',
107
+ },
108
+ sourcePath: {
109
+ type: 'string',
110
+ description:
111
+ 'Relative to the manifest URL/base URL, or an absolute URL.',
112
+ },
113
+ },
114
+ required: ['vfsPath'],
115
+ additionalProperties: false,
64
116
  },
65
117
  },
66
118
  },
67
119
  additionalProperties: false,
68
120
  },
69
- PHPExtensionManifestExtraFile: {
70
- type: 'object',
71
- properties: {
72
- vfsPath: {
73
- type: 'string',
74
- description:
75
- "Joined with the group's `vfsRoot` to form the final VFS path.",
76
- },
77
- type: {
78
- type: 'string',
79
- enum: ['file', 'directory'],
80
- description:
81
- 'Defaults to "file". Only file nodes need a `sourcePath`.',
82
- },
83
- sourcePath: {
84
- type: 'string',
85
- description:
86
- 'Relative to the manifest URL/base URL, or an absolute URL.',
87
- },
88
- },
89
- required: ['vfsPath'],
90
- additionalProperties: false,
91
- },
92
121
  },
93
122
  };
94
123
  const schema12 = {
@@ -97,9 +126,51 @@ const schema12 = {
97
126
  name: { type: 'string' },
98
127
  version: { type: 'string' },
99
128
  mode: { type: 'string', const: 'php-extension' },
129
+ loadWithIniDirective: {
130
+ $ref: '#/definitions/PHPExtensionLoadDirective',
131
+ description:
132
+ 'The first directive of the generated startup `.ini` file. Defaults to `extension`; use `zend_extension` for Zend extensions like Xdebug. Use `false` to stage the `.so` without registering it in php.ini.',
133
+ },
134
+ iniEntries: {
135
+ type: 'object',
136
+ additionalProperties: { type: 'string' },
137
+ description:
138
+ 'Additional `key=value` lines for the generated startup `.ini` file.',
139
+ },
140
+ env: {
141
+ type: 'object',
142
+ additionalProperties: { type: 'string' },
143
+ description:
144
+ 'Environment variables added before the extension is loaded.',
145
+ },
146
+ extensionDir: {
147
+ type: 'string',
148
+ description:
149
+ 'VFS directory where PHP.wasm writes the extension `.so` file and its per-extension ini file. Defaults to `PHP_EXTENSIONS_DIR`.',
150
+ },
100
151
  artifacts: {
101
152
  type: 'array',
102
- items: { $ref: '#/definitions/PHPExtensionManifestArtifact' },
153
+ items: {
154
+ type: 'object',
155
+ properties: {
156
+ phpVersion: {
157
+ type: 'string',
158
+ description: 'PHP major/minor version, e.g. `8.4`.',
159
+ },
160
+ sourcePath: {
161
+ type: 'string',
162
+ description:
163
+ 'Relative to the manifest URL/base URL, or an absolute URL.',
164
+ },
165
+ extraFiles: {
166
+ $ref: '#/definitions/PHPExtensionManifestExtraFiles',
167
+ description:
168
+ 'URL-backed files needed only by this artifact.',
169
+ },
170
+ },
171
+ required: ['phpVersion', 'sourcePath'],
172
+ additionalProperties: false,
173
+ },
103
174
  },
104
175
  extraFiles: {
105
176
  $ref: '#/definitions/PHPExtensionManifestExtraFiles',
@@ -112,27 +183,7 @@ const schema12 = {
112
183
  description:
113
184
  'Extension artifact manifest. Lets callers publish a matrix of `.so` files and lets `resolvePHPExtension()` select the artifact matching the current PHP version. External extension artifacts are JSPI-only.',
114
185
  };
115
- const schema13 = {
116
- type: 'object',
117
- properties: {
118
- phpVersion: {
119
- type: 'string',
120
- description: 'PHP major/minor version, e.g. `8.4`.',
121
- },
122
- sourcePath: {
123
- type: 'string',
124
- description:
125
- 'Relative to the manifest URL/base URL, or an absolute URL.',
126
- },
127
- extraFiles: {
128
- $ref: '#/definitions/PHPExtensionManifestExtraFiles',
129
- description: 'URL-backed files needed only by this artifact.',
130
- },
131
- },
132
- required: ['phpVersion', 'sourcePath'],
133
- additionalProperties: false,
134
- };
135
- const schema14 = {
186
+ const schema15 = {
136
187
  type: 'object',
137
188
  properties: {
138
189
  vfsRoot: {
@@ -142,486 +193,146 @@ const schema14 = {
142
193
  },
143
194
  nodes: {
144
195
  type: 'array',
145
- items: { $ref: '#/definitions/PHPExtensionManifestExtraFile' },
196
+ items: {
197
+ type: 'object',
198
+ properties: {
199
+ vfsPath: {
200
+ type: 'string',
201
+ description:
202
+ "Joined with the group's `vfsRoot` to form the final VFS path.",
203
+ },
204
+ type: {
205
+ type: 'string',
206
+ enum: ['file', 'directory'],
207
+ description:
208
+ 'Defaults to "file". Only file nodes need a `sourcePath`.',
209
+ },
210
+ sourcePath: {
211
+ type: 'string',
212
+ description:
213
+ 'Relative to the manifest URL/base URL, or an absolute URL.',
214
+ },
215
+ },
216
+ required: ['vfsPath'],
217
+ additionalProperties: false,
218
+ },
146
219
  },
147
220
  },
148
221
  additionalProperties: false,
149
222
  };
150
- const schema15 = {
151
- type: 'object',
152
- properties: {
153
- vfsPath: {
154
- type: 'string',
155
- description:
156
- "Joined with the group's `vfsRoot` to form the final VFS path.",
157
- },
158
- type: {
159
- type: 'string',
160
- enum: ['file', 'directory'],
161
- description:
162
- 'Defaults to "file". Only file nodes need a `sourcePath`.',
163
- },
164
- sourcePath: {
165
- type: 'string',
166
- description:
167
- 'Relative to the manifest URL/base URL, or an absolute URL.',
168
- },
169
- },
170
- required: ['vfsPath'],
171
- additionalProperties: false,
223
+ const func2 = Object.prototype.hasOwnProperty;
224
+ const schema13 = {
225
+ anyOf: [
226
+ { $ref: '#/definitions/PHPExtensionIniDirective' },
227
+ { type: 'boolean', const: false },
228
+ ],
172
229
  };
173
- function validate13(
230
+ const schema14 = {
231
+ type: 'string',
232
+ enum: ['extension', 'zend_extension'],
233
+ description:
234
+ 'The php.ini directive used to load the extension. Use `extension` for regular PHP extensions and `zend_extension` for Zend extensions like Xdebug.',
235
+ };
236
+ function validate12(
174
237
  data,
175
238
  { instancePath = '', parentData, parentDataProperty, rootData = data } = {}
176
239
  ) {
177
240
  let vErrors = null;
178
241
  let errors = 0;
179
- if (errors === 0) {
180
- if (data && typeof data == 'object' && !Array.isArray(data)) {
181
- const _errs1 = errors;
182
- for (const key0 in data) {
183
- if (!(key0 === 'vfsRoot' || key0 === 'nodes')) {
184
- validate13.errors = [
185
- {
186
- instancePath,
187
- schemaPath: '#/additionalProperties',
188
- keyword: 'additionalProperties',
189
- params: { additionalProperty: key0 },
190
- message: 'must NOT have additional properties',
191
- },
192
- ];
193
- return false;
194
- break;
195
- }
196
- }
197
- if (_errs1 === errors) {
198
- if (data.vfsRoot !== undefined) {
199
- const _errs2 = errors;
200
- if (typeof data.vfsRoot !== 'string') {
201
- validate13.errors = [
202
- {
203
- instancePath: instancePath + '/vfsRoot',
204
- schemaPath: '#/properties/vfsRoot/type',
205
- keyword: 'type',
206
- params: { type: 'string' },
207
- message: 'must be string',
208
- },
209
- ];
210
- return false;
211
- }
212
- var valid0 = _errs2 === errors;
213
- } else {
214
- var valid0 = true;
215
- }
216
- if (valid0) {
217
- if (data.nodes !== undefined) {
218
- let data1 = data.nodes;
219
- const _errs4 = errors;
220
- if (errors === _errs4) {
221
- if (Array.isArray(data1)) {
222
- var valid1 = true;
223
- const len0 = data1.length;
224
- for (let i0 = 0; i0 < len0; i0++) {
225
- let data2 = data1[i0];
226
- const _errs6 = errors;
227
- const _errs7 = errors;
228
- if (errors === _errs7) {
229
- if (
230
- data2 &&
231
- typeof data2 == 'object' &&
232
- !Array.isArray(data2)
233
- ) {
234
- let missing0;
235
- if (
236
- data2.vfsPath === undefined &&
237
- (missing0 = 'vfsPath')
238
- ) {
239
- validate13.errors = [
240
- {
241
- instancePath:
242
- instancePath +
243
- '/nodes/' +
244
- i0,
245
- schemaPath:
246
- '#/definitions/PHPExtensionManifestExtraFile/required',
247
- keyword: 'required',
248
- params: {
249
- missingProperty:
250
- missing0,
251
- },
252
- message:
253
- "must have required property '" +
254
- missing0 +
255
- "'",
256
- },
257
- ];
258
- return false;
259
- } else {
260
- const _errs9 = errors;
261
- for (const key1 in data2) {
262
- if (
263
- !(
264
- key1 ===
265
- 'vfsPath' ||
266
- key1 === 'type' ||
267
- key1 ===
268
- 'sourcePath'
269
- )
270
- ) {
271
- validate13.errors = [
272
- {
273
- instancePath:
274
- instancePath +
275
- '/nodes/' +
276
- i0,
277
- schemaPath:
278
- '#/definitions/PHPExtensionManifestExtraFile/additionalProperties',
279
- keyword:
280
- 'additionalProperties',
281
- params: {
282
- additionalProperty:
283
- key1,
284
- },
285
- message:
286
- 'must NOT have additional properties',
287
- },
288
- ];
289
- return false;
290
- break;
291
- }
292
- }
293
- if (_errs9 === errors) {
294
- if (
295
- data2.vfsPath !==
296
- undefined
297
- ) {
298
- const _errs10 = errors;
299
- if (
300
- typeof data2.vfsPath !==
301
- 'string'
302
- ) {
303
- validate13.errors =
304
- [
305
- {
306
- instancePath:
307
- instancePath +
308
- '/nodes/' +
309
- i0 +
310
- '/vfsPath',
311
- schemaPath:
312
- '#/definitions/PHPExtensionManifestExtraFile/properties/vfsPath/type',
313
- keyword:
314
- 'type',
315
- params: {
316
- type: 'string',
317
- },
318
- message:
319
- 'must be string',
320
- },
321
- ];
322
- return false;
323
- }
324
- var valid3 =
325
- _errs10 === errors;
326
- } else {
327
- var valid3 = true;
328
- }
329
- if (valid3) {
330
- if (
331
- data2.type !==
332
- undefined
333
- ) {
334
- let data4 =
335
- data2.type;
336
- const _errs12 =
337
- errors;
338
- if (
339
- typeof data4 !==
340
- 'string'
341
- ) {
342
- validate13.errors =
343
- [
344
- {
345
- instancePath:
346
- instancePath +
347
- '/nodes/' +
348
- i0 +
349
- '/type',
350
- schemaPath:
351
- '#/definitions/PHPExtensionManifestExtraFile/properties/type/type',
352
- keyword:
353
- 'type',
354
- params: {
355
- type: 'string',
356
- },
357
- message:
358
- 'must be string',
359
- },
360
- ];
361
- return false;
362
- }
363
- if (
364
- !(
365
- data4 ===
366
- 'file' ||
367
- data4 ===
368
- 'directory'
369
- )
370
- ) {
371
- validate13.errors =
372
- [
373
- {
374
- instancePath:
375
- instancePath +
376
- '/nodes/' +
377
- i0 +
378
- '/type',
379
- schemaPath:
380
- '#/definitions/PHPExtensionManifestExtraFile/properties/type/enum',
381
- keyword:
382
- 'enum',
383
- params: {
384
- allowedValues:
385
- schema15
386
- .properties
387
- .type
388
- .enum,
389
- },
390
- message:
391
- 'must be equal to one of the allowed values',
392
- },
393
- ];
394
- return false;
395
- }
396
- var valid3 =
397
- _errs12 ===
398
- errors;
399
- } else {
400
- var valid3 = true;
401
- }
402
- if (valid3) {
403
- if (
404
- data2.sourcePath !==
405
- undefined
406
- ) {
407
- const _errs14 =
408
- errors;
409
- if (
410
- typeof data2.sourcePath !==
411
- 'string'
412
- ) {
413
- validate13.errors =
414
- [
415
- {
416
- instancePath:
417
- instancePath +
418
- '/nodes/' +
419
- i0 +
420
- '/sourcePath',
421
- schemaPath:
422
- '#/definitions/PHPExtensionManifestExtraFile/properties/sourcePath/type',
423
- keyword:
424
- 'type',
425
- params: {
426
- type: 'string',
427
- },
428
- message:
429
- 'must be string',
430
- },
431
- ];
432
- return false;
433
- }
434
- var valid3 =
435
- _errs14 ===
436
- errors;
437
- } else {
438
- var valid3 = true;
439
- }
440
- }
441
- }
442
- }
443
- }
444
- } else {
445
- validate13.errors = [
446
- {
447
- instancePath:
448
- instancePath +
449
- '/nodes/' +
450
- i0,
451
- schemaPath:
452
- '#/definitions/PHPExtensionManifestExtraFile/type',
453
- keyword: 'type',
454
- params: { type: 'object' },
455
- message: 'must be object',
456
- },
457
- ];
458
- return false;
459
- }
460
- }
461
- var valid1 = _errs6 === errors;
462
- if (!valid1) {
463
- break;
464
- }
465
- }
466
- } else {
467
- validate13.errors = [
468
- {
469
- instancePath: instancePath + '/nodes',
470
- schemaPath: '#/properties/nodes/type',
471
- keyword: 'type',
472
- params: { type: 'array' },
473
- message: 'must be array',
474
- },
475
- ];
476
- return false;
477
- }
478
- }
479
- var valid0 = _errs4 === errors;
480
- } else {
481
- var valid0 = true;
482
- }
483
- }
484
- }
242
+ const _errs0 = errors;
243
+ let valid0 = false;
244
+ const _errs1 = errors;
245
+ if (typeof data !== 'string') {
246
+ const err0 = {
247
+ instancePath,
248
+ schemaPath: '#/definitions/PHPExtensionIniDirective/type',
249
+ keyword: 'type',
250
+ params: { type: 'string' },
251
+ message: 'must be string',
252
+ };
253
+ if (vErrors === null) {
254
+ vErrors = [err0];
485
255
  } else {
486
- validate13.errors = [
487
- {
488
- instancePath,
489
- schemaPath: '#/type',
490
- keyword: 'type',
491
- params: { type: 'object' },
492
- message: 'must be object',
493
- },
494
- ];
495
- return false;
256
+ vErrors.push(err0);
496
257
  }
258
+ errors++;
497
259
  }
498
- validate13.errors = vErrors;
499
- return errors === 0;
500
- }
501
- function validate12(
502
- data,
503
- { instancePath = '', parentData, parentDataProperty, rootData = data } = {}
504
- ) {
505
- let vErrors = null;
506
- let errors = 0;
507
- if (errors === 0) {
508
- if (data && typeof data == 'object' && !Array.isArray(data)) {
509
- let missing0;
510
- if (
511
- (data.phpVersion === undefined && (missing0 = 'phpVersion')) ||
512
- (data.sourcePath === undefined && (missing0 = 'sourcePath'))
513
- ) {
514
- validate12.errors = [
515
- {
516
- instancePath,
517
- schemaPath: '#/required',
518
- keyword: 'required',
519
- params: { missingProperty: missing0 },
520
- message:
521
- "must have required property '" + missing0 + "'",
522
- },
523
- ];
524
- return false;
260
+ if (!(data === 'extension' || data === 'zend_extension')) {
261
+ const err1 = {
262
+ instancePath,
263
+ schemaPath: '#/definitions/PHPExtensionIniDirective/enum',
264
+ keyword: 'enum',
265
+ params: { allowedValues: schema14.enum },
266
+ message: 'must be equal to one of the allowed values',
267
+ };
268
+ if (vErrors === null) {
269
+ vErrors = [err1];
270
+ } else {
271
+ vErrors.push(err1);
272
+ }
273
+ errors++;
274
+ }
275
+ var _valid0 = _errs1 === errors;
276
+ valid0 = valid0 || _valid0;
277
+ if (!valid0) {
278
+ const _errs4 = errors;
279
+ if (typeof data !== 'boolean') {
280
+ const err2 = {
281
+ instancePath,
282
+ schemaPath: '#/anyOf/1/type',
283
+ keyword: 'type',
284
+ params: { type: 'boolean' },
285
+ message: 'must be boolean',
286
+ };
287
+ if (vErrors === null) {
288
+ vErrors = [err2];
525
289
  } else {
526
- const _errs1 = errors;
527
- for (const key0 in data) {
528
- if (
529
- !(
530
- key0 === 'phpVersion' ||
531
- key0 === 'sourcePath' ||
532
- key0 === 'extraFiles'
533
- )
534
- ) {
535
- validate12.errors = [
536
- {
537
- instancePath,
538
- schemaPath: '#/additionalProperties',
539
- keyword: 'additionalProperties',
540
- params: { additionalProperty: key0 },
541
- message: 'must NOT have additional properties',
542
- },
543
- ];
544
- return false;
545
- break;
546
- }
547
- }
548
- if (_errs1 === errors) {
549
- if (data.phpVersion !== undefined) {
550
- const _errs2 = errors;
551
- if (typeof data.phpVersion !== 'string') {
552
- validate12.errors = [
553
- {
554
- instancePath: instancePath + '/phpVersion',
555
- schemaPath: '#/properties/phpVersion/type',
556
- keyword: 'type',
557
- params: { type: 'string' },
558
- message: 'must be string',
559
- },
560
- ];
561
- return false;
562
- }
563
- var valid0 = _errs2 === errors;
564
- } else {
565
- var valid0 = true;
566
- }
567
- if (valid0) {
568
- if (data.sourcePath !== undefined) {
569
- const _errs4 = errors;
570
- if (typeof data.sourcePath !== 'string') {
571
- validate12.errors = [
572
- {
573
- instancePath:
574
- instancePath + '/sourcePath',
575
- schemaPath:
576
- '#/properties/sourcePath/type',
577
- keyword: 'type',
578
- params: { type: 'string' },
579
- message: 'must be string',
580
- },
581
- ];
582
- return false;
583
- }
584
- var valid0 = _errs4 === errors;
585
- } else {
586
- var valid0 = true;
587
- }
588
- if (valid0) {
589
- if (data.extraFiles !== undefined) {
590
- const _errs6 = errors;
591
- if (
592
- !validate13(data.extraFiles, {
593
- instancePath:
594
- instancePath + '/extraFiles',
595
- parentData: data,
596
- parentDataProperty: 'extraFiles',
597
- rootData,
598
- })
599
- ) {
600
- vErrors =
601
- vErrors === null
602
- ? validate13.errors
603
- : vErrors.concat(validate13.errors);
604
- errors = vErrors.length;
605
- }
606
- var valid0 = _errs6 === errors;
607
- } else {
608
- var valid0 = true;
609
- }
610
- }
611
- }
612
- }
290
+ vErrors.push(err2);
613
291
  }
292
+ errors++;
293
+ }
294
+ if (false !== data) {
295
+ const err3 = {
296
+ instancePath,
297
+ schemaPath: '#/anyOf/1/const',
298
+ keyword: 'const',
299
+ params: { allowedValue: false },
300
+ message: 'must be equal to constant',
301
+ };
302
+ if (vErrors === null) {
303
+ vErrors = [err3];
304
+ } else {
305
+ vErrors.push(err3);
306
+ }
307
+ errors++;
308
+ }
309
+ var _valid0 = _errs4 === errors;
310
+ valid0 = valid0 || _valid0;
311
+ }
312
+ if (!valid0) {
313
+ const err4 = {
314
+ instancePath,
315
+ schemaPath: '#/anyOf',
316
+ keyword: 'anyOf',
317
+ params: {},
318
+ message: 'must match a schema in anyOf',
319
+ };
320
+ if (vErrors === null) {
321
+ vErrors = [err4];
614
322
  } else {
615
- validate12.errors = [
616
- {
617
- instancePath,
618
- schemaPath: '#/type',
619
- keyword: 'type',
620
- params: { type: 'object' },
621
- message: 'must be object',
622
- },
623
- ];
624
- return false;
323
+ vErrors.push(err4);
324
+ }
325
+ errors++;
326
+ validate12.errors = vErrors;
327
+ return false;
328
+ } else {
329
+ errors = _errs0;
330
+ if (vErrors !== null) {
331
+ if (_errs0) {
332
+ vErrors.length = _errs0;
333
+ } else {
334
+ vErrors = null;
335
+ }
625
336
  }
626
337
  }
627
338
  validate12.errors = vErrors;
@@ -654,15 +365,7 @@ function validate11(
654
365
  } else {
655
366
  const _errs1 = errors;
656
367
  for (const key0 in data) {
657
- if (
658
- !(
659
- key0 === 'name' ||
660
- key0 === 'version' ||
661
- key0 === 'mode' ||
662
- key0 === 'artifacts' ||
663
- key0 === 'extraFiles'
664
- )
665
- ) {
368
+ if (!func2.call(schema12.properties, key0)) {
666
369
  validate11.errors = [
667
370
  {
668
371
  instancePath,
@@ -754,85 +457,1390 @@ function validate11(
754
457
  var valid0 = true;
755
458
  }
756
459
  if (valid0) {
757
- if (data.artifacts !== undefined) {
758
- let data3 = data.artifacts;
460
+ if (data.loadWithIniDirective !== undefined) {
759
461
  const _errs8 = errors;
760
- if (errors === _errs8) {
761
- if (Array.isArray(data3)) {
762
- var valid1 = true;
763
- const len0 = data3.length;
764
- for (let i0 = 0; i0 < len0; i0++) {
765
- const _errs10 = errors;
766
- if (
767
- !validate12(data3[i0], {
768
- instancePath:
769
- instancePath +
770
- '/artifacts/' +
771
- i0,
772
- parentData: data3,
773
- parentDataProperty: i0,
774
- rootData,
775
- })
776
- ) {
777
- vErrors =
778
- vErrors === null
779
- ? validate12.errors
780
- : vErrors.concat(
781
- validate12.errors
782
- );
783
- errors = vErrors.length;
784
- }
785
- var valid1 = _errs10 === errors;
786
- if (!valid1) {
787
- break;
788
- }
789
- }
790
- } else {
791
- validate11.errors = [
792
- {
793
- instancePath:
794
- instancePath +
795
- '/artifacts',
796
- schemaPath:
797
- '#/properties/artifacts/type',
798
- keyword: 'type',
799
- params: { type: 'array' },
800
- message: 'must be array',
801
- },
802
- ];
803
- return false;
804
- }
462
+ if (
463
+ !validate12(data.loadWithIniDirective, {
464
+ instancePath:
465
+ instancePath +
466
+ '/loadWithIniDirective',
467
+ parentData: data,
468
+ parentDataProperty:
469
+ 'loadWithIniDirective',
470
+ rootData,
471
+ })
472
+ ) {
473
+ vErrors =
474
+ vErrors === null
475
+ ? validate12.errors
476
+ : vErrors.concat(
477
+ validate12.errors
478
+ );
479
+ errors = vErrors.length;
805
480
  }
806
481
  var valid0 = _errs8 === errors;
807
482
  } else {
808
483
  var valid0 = true;
809
484
  }
810
485
  if (valid0) {
811
- if (data.extraFiles !== undefined) {
812
- const _errs11 = errors;
813
- if (
814
- !validate13(data.extraFiles, {
815
- instancePath:
816
- instancePath +
817
- '/extraFiles',
818
- parentData: data,
819
- parentDataProperty:
820
- 'extraFiles',
821
- rootData,
822
- })
823
- ) {
824
- vErrors =
825
- vErrors === null
826
- ? validate13.errors
827
- : vErrors.concat(
828
- validate13.errors
829
- );
830
- errors = vErrors.length;
486
+ if (data.iniEntries !== undefined) {
487
+ let data4 = data.iniEntries;
488
+ const _errs9 = errors;
489
+ if (errors === _errs9) {
490
+ if (
491
+ data4 &&
492
+ typeof data4 == 'object' &&
493
+ !Array.isArray(data4)
494
+ ) {
495
+ for (const key1 in data4) {
496
+ const _errs12 = errors;
497
+ if (
498
+ typeof data4[key1] !==
499
+ 'string'
500
+ ) {
501
+ validate11.errors = [
502
+ {
503
+ instancePath:
504
+ instancePath +
505
+ '/iniEntries/' +
506
+ key1
507
+ .replace(
508
+ /~/g,
509
+ '~0'
510
+ )
511
+ .replace(
512
+ /\//g,
513
+ '~1'
514
+ ),
515
+ schemaPath:
516
+ '#/properties/iniEntries/additionalProperties/type',
517
+ keyword: 'type',
518
+ params: {
519
+ type: 'string',
520
+ },
521
+ message:
522
+ 'must be string',
523
+ },
524
+ ];
525
+ return false;
526
+ }
527
+ var valid1 =
528
+ _errs12 === errors;
529
+ if (!valid1) {
530
+ break;
531
+ }
532
+ }
533
+ } else {
534
+ validate11.errors = [
535
+ {
536
+ instancePath:
537
+ instancePath +
538
+ '/iniEntries',
539
+ schemaPath:
540
+ '#/properties/iniEntries/type',
541
+ keyword: 'type',
542
+ params: {
543
+ type: 'object',
544
+ },
545
+ message:
546
+ 'must be object',
547
+ },
548
+ ];
549
+ return false;
550
+ }
831
551
  }
832
- var valid0 = _errs11 === errors;
552
+ var valid0 = _errs9 === errors;
833
553
  } else {
834
554
  var valid0 = true;
835
555
  }
556
+ if (valid0) {
557
+ if (data.env !== undefined) {
558
+ let data6 = data.env;
559
+ const _errs14 = errors;
560
+ if (errors === _errs14) {
561
+ if (
562
+ data6 &&
563
+ typeof data6 == 'object' &&
564
+ !Array.isArray(data6)
565
+ ) {
566
+ for (const key2 in data6) {
567
+ const _errs17 = errors;
568
+ if (
569
+ typeof data6[
570
+ key2
571
+ ] !== 'string'
572
+ ) {
573
+ validate11.errors =
574
+ [
575
+ {
576
+ instancePath:
577
+ instancePath +
578
+ '/env/' +
579
+ key2
580
+ .replace(
581
+ /~/g,
582
+ '~0'
583
+ )
584
+ .replace(
585
+ /\//g,
586
+ '~1'
587
+ ),
588
+ schemaPath:
589
+ '#/properties/env/additionalProperties/type',
590
+ keyword:
591
+ 'type',
592
+ params: {
593
+ type: 'string',
594
+ },
595
+ message:
596
+ 'must be string',
597
+ },
598
+ ];
599
+ return false;
600
+ }
601
+ var valid2 =
602
+ _errs17 === errors;
603
+ if (!valid2) {
604
+ break;
605
+ }
606
+ }
607
+ } else {
608
+ validate11.errors = [
609
+ {
610
+ instancePath:
611
+ instancePath +
612
+ '/env',
613
+ schemaPath:
614
+ '#/properties/env/type',
615
+ keyword: 'type',
616
+ params: {
617
+ type: 'object',
618
+ },
619
+ message:
620
+ 'must be object',
621
+ },
622
+ ];
623
+ return false;
624
+ }
625
+ }
626
+ var valid0 = _errs14 === errors;
627
+ } else {
628
+ var valid0 = true;
629
+ }
630
+ if (valid0) {
631
+ if (
632
+ data.extensionDir !== undefined
633
+ ) {
634
+ const _errs19 = errors;
635
+ if (
636
+ typeof data.extensionDir !==
637
+ 'string'
638
+ ) {
639
+ validate11.errors = [
640
+ {
641
+ instancePath:
642
+ instancePath +
643
+ '/extensionDir',
644
+ schemaPath:
645
+ '#/properties/extensionDir/type',
646
+ keyword: 'type',
647
+ params: {
648
+ type: 'string',
649
+ },
650
+ message:
651
+ 'must be string',
652
+ },
653
+ ];
654
+ return false;
655
+ }
656
+ var valid0 = _errs19 === errors;
657
+ } else {
658
+ var valid0 = true;
659
+ }
660
+ if (valid0) {
661
+ if (
662
+ data.artifacts !== undefined
663
+ ) {
664
+ let data9 = data.artifacts;
665
+ const _errs21 = errors;
666
+ if (errors === _errs21) {
667
+ if (
668
+ Array.isArray(data9)
669
+ ) {
670
+ var valid3 = true;
671
+ const len0 =
672
+ data9.length;
673
+ for (
674
+ let i0 = 0;
675
+ i0 < len0;
676
+ i0++
677
+ ) {
678
+ let data10 =
679
+ data9[i0];
680
+ const _errs23 =
681
+ errors;
682
+ if (
683
+ errors ===
684
+ _errs23
685
+ ) {
686
+ if (
687
+ data10 &&
688
+ typeof data10 ==
689
+ 'object' &&
690
+ !Array.isArray(
691
+ data10
692
+ )
693
+ ) {
694
+ let missing1;
695
+ if (
696
+ (data10.phpVersion ===
697
+ undefined &&
698
+ (missing1 =
699
+ 'phpVersion')) ||
700
+ (data10.sourcePath ===
701
+ undefined &&
702
+ (missing1 =
703
+ 'sourcePath'))
704
+ ) {
705
+ validate11.errors =
706
+ [
707
+ {
708
+ instancePath:
709
+ instancePath +
710
+ '/artifacts/' +
711
+ i0,
712
+ schemaPath:
713
+ '#/properties/artifacts/items/required',
714
+ keyword:
715
+ 'required',
716
+ params: {
717
+ missingProperty:
718
+ missing1,
719
+ },
720
+ message:
721
+ "must have required property '" +
722
+ missing1 +
723
+ "'",
724
+ },
725
+ ];
726
+ return false;
727
+ } else {
728
+ const _errs25 =
729
+ errors;
730
+ for (const key3 in data10) {
731
+ if (
732
+ !(
733
+ key3 ===
734
+ 'phpVersion' ||
735
+ key3 ===
736
+ 'sourcePath' ||
737
+ key3 ===
738
+ 'extraFiles'
739
+ )
740
+ ) {
741
+ validate11.errors =
742
+ [
743
+ {
744
+ instancePath:
745
+ instancePath +
746
+ '/artifacts/' +
747
+ i0,
748
+ schemaPath:
749
+ '#/properties/artifacts/items/additionalProperties',
750
+ keyword:
751
+ 'additionalProperties',
752
+ params: {
753
+ additionalProperty:
754
+ key3,
755
+ },
756
+ message:
757
+ 'must NOT have additional properties',
758
+ },
759
+ ];
760
+ return false;
761
+ break;
762
+ }
763
+ }
764
+ if (
765
+ _errs25 ===
766
+ errors
767
+ ) {
768
+ if (
769
+ data10.phpVersion !==
770
+ undefined
771
+ ) {
772
+ const _errs26 =
773
+ errors;
774
+ if (
775
+ typeof data10.phpVersion !==
776
+ 'string'
777
+ ) {
778
+ validate11.errors =
779
+ [
780
+ {
781
+ instancePath:
782
+ instancePath +
783
+ '/artifacts/' +
784
+ i0 +
785
+ '/phpVersion',
786
+ schemaPath:
787
+ '#/properties/artifacts/items/properties/phpVersion/type',
788
+ keyword:
789
+ 'type',
790
+ params: {
791
+ type: 'string',
792
+ },
793
+ message:
794
+ 'must be string',
795
+ },
796
+ ];
797
+ return false;
798
+ }
799
+ var valid4 =
800
+ _errs26 ===
801
+ errors;
802
+ } else {
803
+ var valid4 = true;
804
+ }
805
+ if (
806
+ valid4
807
+ ) {
808
+ if (
809
+ data10.sourcePath !==
810
+ undefined
811
+ ) {
812
+ const _errs28 =
813
+ errors;
814
+ if (
815
+ typeof data10.sourcePath !==
816
+ 'string'
817
+ ) {
818
+ validate11.errors =
819
+ [
820
+ {
821
+ instancePath:
822
+ instancePath +
823
+ '/artifacts/' +
824
+ i0 +
825
+ '/sourcePath',
826
+ schemaPath:
827
+ '#/properties/artifacts/items/properties/sourcePath/type',
828
+ keyword:
829
+ 'type',
830
+ params: {
831
+ type: 'string',
832
+ },
833
+ message:
834
+ 'must be string',
835
+ },
836
+ ];
837
+ return false;
838
+ }
839
+ var valid4 =
840
+ _errs28 ===
841
+ errors;
842
+ } else {
843
+ var valid4 = true;
844
+ }
845
+ if (
846
+ valid4
847
+ ) {
848
+ if (
849
+ data10.extraFiles !==
850
+ undefined
851
+ ) {
852
+ let data13 =
853
+ data10.extraFiles;
854
+ const _errs30 =
855
+ errors;
856
+ const _errs31 =
857
+ errors;
858
+ if (
859
+ errors ===
860
+ _errs31
861
+ ) {
862
+ if (
863
+ data13 &&
864
+ typeof data13 ==
865
+ 'object' &&
866
+ !Array.isArray(
867
+ data13
868
+ )
869
+ ) {
870
+ const _errs33 =
871
+ errors;
872
+ for (const key4 in data13) {
873
+ if (
874
+ !(
875
+ key4 ===
876
+ 'vfsRoot' ||
877
+ key4 ===
878
+ 'nodes'
879
+ )
880
+ ) {
881
+ validate11.errors =
882
+ [
883
+ {
884
+ instancePath:
885
+ instancePath +
886
+ '/artifacts/' +
887
+ i0 +
888
+ '/extraFiles',
889
+ schemaPath:
890
+ '#/definitions/PHPExtensionManifestExtraFiles/additionalProperties',
891
+ keyword:
892
+ 'additionalProperties',
893
+ params: {
894
+ additionalProperty:
895
+ key4,
896
+ },
897
+ message:
898
+ 'must NOT have additional properties',
899
+ },
900
+ ];
901
+ return false;
902
+ break;
903
+ }
904
+ }
905
+ if (
906
+ _errs33 ===
907
+ errors
908
+ ) {
909
+ if (
910
+ data13.vfsRoot !==
911
+ undefined
912
+ ) {
913
+ const _errs34 =
914
+ errors;
915
+ if (
916
+ typeof data13.vfsRoot !==
917
+ 'string'
918
+ ) {
919
+ validate11.errors =
920
+ [
921
+ {
922
+ instancePath:
923
+ instancePath +
924
+ '/artifacts/' +
925
+ i0 +
926
+ '/extraFiles/vfsRoot',
927
+ schemaPath:
928
+ '#/definitions/PHPExtensionManifestExtraFiles/properties/vfsRoot/type',
929
+ keyword:
930
+ 'type',
931
+ params: {
932
+ type: 'string',
933
+ },
934
+ message:
935
+ 'must be string',
936
+ },
937
+ ];
938
+ return false;
939
+ }
940
+ var valid6 =
941
+ _errs34 ===
942
+ errors;
943
+ } else {
944
+ var valid6 = true;
945
+ }
946
+ if (
947
+ valid6
948
+ ) {
949
+ if (
950
+ data13.nodes !==
951
+ undefined
952
+ ) {
953
+ let data15 =
954
+ data13.nodes;
955
+ const _errs36 =
956
+ errors;
957
+ if (
958
+ errors ===
959
+ _errs36
960
+ ) {
961
+ if (
962
+ Array.isArray(
963
+ data15
964
+ )
965
+ ) {
966
+ var valid7 = true;
967
+ const len1 =
968
+ data15.length;
969
+ for (
970
+ let i1 = 0;
971
+ i1 <
972
+ len1;
973
+ i1++
974
+ ) {
975
+ let data16 =
976
+ data15[
977
+ i1
978
+ ];
979
+ const _errs38 =
980
+ errors;
981
+ if (
982
+ errors ===
983
+ _errs38
984
+ ) {
985
+ if (
986
+ data16 &&
987
+ typeof data16 ==
988
+ 'object' &&
989
+ !Array.isArray(
990
+ data16
991
+ )
992
+ ) {
993
+ let missing2;
994
+ if (
995
+ data16.vfsPath ===
996
+ undefined &&
997
+ (missing2 =
998
+ 'vfsPath')
999
+ ) {
1000
+ validate11.errors =
1001
+ [
1002
+ {
1003
+ instancePath:
1004
+ instancePath +
1005
+ '/artifacts/' +
1006
+ i0 +
1007
+ '/extraFiles/nodes/' +
1008
+ i1,
1009
+ schemaPath:
1010
+ '#/definitions/PHPExtensionManifestExtraFiles/properties/nodes/items/required',
1011
+ keyword:
1012
+ 'required',
1013
+ params: {
1014
+ missingProperty:
1015
+ missing2,
1016
+ },
1017
+ message:
1018
+ "must have required property '" +
1019
+ missing2 +
1020
+ "'",
1021
+ },
1022
+ ];
1023
+ return false;
1024
+ } else {
1025
+ const _errs40 =
1026
+ errors;
1027
+ for (const key5 in data16) {
1028
+ if (
1029
+ !(
1030
+ key5 ===
1031
+ 'vfsPath' ||
1032
+ key5 ===
1033
+ 'type' ||
1034
+ key5 ===
1035
+ 'sourcePath'
1036
+ )
1037
+ ) {
1038
+ validate11.errors =
1039
+ [
1040
+ {
1041
+ instancePath:
1042
+ instancePath +
1043
+ '/artifacts/' +
1044
+ i0 +
1045
+ '/extraFiles/nodes/' +
1046
+ i1,
1047
+ schemaPath:
1048
+ '#/definitions/PHPExtensionManifestExtraFiles/properties/nodes/items/additionalProperties',
1049
+ keyword:
1050
+ 'additionalProperties',
1051
+ params: {
1052
+ additionalProperty:
1053
+ key5,
1054
+ },
1055
+ message:
1056
+ 'must NOT have additional properties',
1057
+ },
1058
+ ];
1059
+ return false;
1060
+ break;
1061
+ }
1062
+ }
1063
+ if (
1064
+ _errs40 ===
1065
+ errors
1066
+ ) {
1067
+ if (
1068
+ data16.vfsPath !==
1069
+ undefined
1070
+ ) {
1071
+ const _errs41 =
1072
+ errors;
1073
+ if (
1074
+ typeof data16.vfsPath !==
1075
+ 'string'
1076
+ ) {
1077
+ validate11.errors =
1078
+ [
1079
+ {
1080
+ instancePath:
1081
+ instancePath +
1082
+ '/artifacts/' +
1083
+ i0 +
1084
+ '/extraFiles/nodes/' +
1085
+ i1 +
1086
+ '/vfsPath',
1087
+ schemaPath:
1088
+ '#/definitions/PHPExtensionManifestExtraFiles/properties/nodes/items/properties/vfsPath/type',
1089
+ keyword:
1090
+ 'type',
1091
+ params: {
1092
+ type: 'string',
1093
+ },
1094
+ message:
1095
+ 'must be string',
1096
+ },
1097
+ ];
1098
+ return false;
1099
+ }
1100
+ var valid8 =
1101
+ _errs41 ===
1102
+ errors;
1103
+ } else {
1104
+ var valid8 = true;
1105
+ }
1106
+ if (
1107
+ valid8
1108
+ ) {
1109
+ if (
1110
+ data16.type !==
1111
+ undefined
1112
+ ) {
1113
+ let data18 =
1114
+ data16.type;
1115
+ const _errs43 =
1116
+ errors;
1117
+ if (
1118
+ typeof data18 !==
1119
+ 'string'
1120
+ ) {
1121
+ validate11.errors =
1122
+ [
1123
+ {
1124
+ instancePath:
1125
+ instancePath +
1126
+ '/artifacts/' +
1127
+ i0 +
1128
+ '/extraFiles/nodes/' +
1129
+ i1 +
1130
+ '/type',
1131
+ schemaPath:
1132
+ '#/definitions/PHPExtensionManifestExtraFiles/properties/nodes/items/properties/type/type',
1133
+ keyword:
1134
+ 'type',
1135
+ params: {
1136
+ type: 'string',
1137
+ },
1138
+ message:
1139
+ 'must be string',
1140
+ },
1141
+ ];
1142
+ return false;
1143
+ }
1144
+ if (
1145
+ !(
1146
+ data18 ===
1147
+ 'file' ||
1148
+ data18 ===
1149
+ 'directory'
1150
+ )
1151
+ ) {
1152
+ validate11.errors =
1153
+ [
1154
+ {
1155
+ instancePath:
1156
+ instancePath +
1157
+ '/artifacts/' +
1158
+ i0 +
1159
+ '/extraFiles/nodes/' +
1160
+ i1 +
1161
+ '/type',
1162
+ schemaPath:
1163
+ '#/definitions/PHPExtensionManifestExtraFiles/properties/nodes/items/properties/type/enum',
1164
+ keyword:
1165
+ 'enum',
1166
+ params: {
1167
+ allowedValues:
1168
+ schema15
1169
+ .properties
1170
+ .nodes
1171
+ .items
1172
+ .properties
1173
+ .type
1174
+ .enum,
1175
+ },
1176
+ message:
1177
+ 'must be equal to one of the allowed values',
1178
+ },
1179
+ ];
1180
+ return false;
1181
+ }
1182
+ var valid8 =
1183
+ _errs43 ===
1184
+ errors;
1185
+ } else {
1186
+ var valid8 = true;
1187
+ }
1188
+ if (
1189
+ valid8
1190
+ ) {
1191
+ if (
1192
+ data16.sourcePath !==
1193
+ undefined
1194
+ ) {
1195
+ const _errs45 =
1196
+ errors;
1197
+ if (
1198
+ typeof data16.sourcePath !==
1199
+ 'string'
1200
+ ) {
1201
+ validate11.errors =
1202
+ [
1203
+ {
1204
+ instancePath:
1205
+ instancePath +
1206
+ '/artifacts/' +
1207
+ i0 +
1208
+ '/extraFiles/nodes/' +
1209
+ i1 +
1210
+ '/sourcePath',
1211
+ schemaPath:
1212
+ '#/definitions/PHPExtensionManifestExtraFiles/properties/nodes/items/properties/sourcePath/type',
1213
+ keyword:
1214
+ 'type',
1215
+ params: {
1216
+ type: 'string',
1217
+ },
1218
+ message:
1219
+ 'must be string',
1220
+ },
1221
+ ];
1222
+ return false;
1223
+ }
1224
+ var valid8 =
1225
+ _errs45 ===
1226
+ errors;
1227
+ } else {
1228
+ var valid8 = true;
1229
+ }
1230
+ }
1231
+ }
1232
+ }
1233
+ }
1234
+ } else {
1235
+ validate11.errors =
1236
+ [
1237
+ {
1238
+ instancePath:
1239
+ instancePath +
1240
+ '/artifacts/' +
1241
+ i0 +
1242
+ '/extraFiles/nodes/' +
1243
+ i1,
1244
+ schemaPath:
1245
+ '#/definitions/PHPExtensionManifestExtraFiles/properties/nodes/items/type',
1246
+ keyword:
1247
+ 'type',
1248
+ params: {
1249
+ type: 'object',
1250
+ },
1251
+ message:
1252
+ 'must be object',
1253
+ },
1254
+ ];
1255
+ return false;
1256
+ }
1257
+ }
1258
+ var valid7 =
1259
+ _errs38 ===
1260
+ errors;
1261
+ if (
1262
+ !valid7
1263
+ ) {
1264
+ break;
1265
+ }
1266
+ }
1267
+ } else {
1268
+ validate11.errors =
1269
+ [
1270
+ {
1271
+ instancePath:
1272
+ instancePath +
1273
+ '/artifacts/' +
1274
+ i0 +
1275
+ '/extraFiles/nodes',
1276
+ schemaPath:
1277
+ '#/definitions/PHPExtensionManifestExtraFiles/properties/nodes/type',
1278
+ keyword:
1279
+ 'type',
1280
+ params: {
1281
+ type: 'array',
1282
+ },
1283
+ message:
1284
+ 'must be array',
1285
+ },
1286
+ ];
1287
+ return false;
1288
+ }
1289
+ }
1290
+ var valid6 =
1291
+ _errs36 ===
1292
+ errors;
1293
+ } else {
1294
+ var valid6 = true;
1295
+ }
1296
+ }
1297
+ }
1298
+ } else {
1299
+ validate11.errors =
1300
+ [
1301
+ {
1302
+ instancePath:
1303
+ instancePath +
1304
+ '/artifacts/' +
1305
+ i0 +
1306
+ '/extraFiles',
1307
+ schemaPath:
1308
+ '#/definitions/PHPExtensionManifestExtraFiles/type',
1309
+ keyword:
1310
+ 'type',
1311
+ params: {
1312
+ type: 'object',
1313
+ },
1314
+ message:
1315
+ 'must be object',
1316
+ },
1317
+ ];
1318
+ return false;
1319
+ }
1320
+ }
1321
+ var valid4 =
1322
+ _errs30 ===
1323
+ errors;
1324
+ } else {
1325
+ var valid4 = true;
1326
+ }
1327
+ }
1328
+ }
1329
+ }
1330
+ }
1331
+ } else {
1332
+ validate11.errors =
1333
+ [
1334
+ {
1335
+ instancePath:
1336
+ instancePath +
1337
+ '/artifacts/' +
1338
+ i0,
1339
+ schemaPath:
1340
+ '#/properties/artifacts/items/type',
1341
+ keyword:
1342
+ 'type',
1343
+ params: {
1344
+ type: 'object',
1345
+ },
1346
+ message:
1347
+ 'must be object',
1348
+ },
1349
+ ];
1350
+ return false;
1351
+ }
1352
+ }
1353
+ var valid3 =
1354
+ _errs23 ===
1355
+ errors;
1356
+ if (!valid3) {
1357
+ break;
1358
+ }
1359
+ }
1360
+ } else {
1361
+ validate11.errors =
1362
+ [
1363
+ {
1364
+ instancePath:
1365
+ instancePath +
1366
+ '/artifacts',
1367
+ schemaPath:
1368
+ '#/properties/artifacts/type',
1369
+ keyword:
1370
+ 'type',
1371
+ params: {
1372
+ type: 'array',
1373
+ },
1374
+ message:
1375
+ 'must be array',
1376
+ },
1377
+ ];
1378
+ return false;
1379
+ }
1380
+ }
1381
+ var valid0 =
1382
+ _errs21 === errors;
1383
+ } else {
1384
+ var valid0 = true;
1385
+ }
1386
+ if (valid0) {
1387
+ if (
1388
+ data.extraFiles !==
1389
+ undefined
1390
+ ) {
1391
+ let data20 =
1392
+ data.extraFiles;
1393
+ const _errs47 = errors;
1394
+ const _errs48 = errors;
1395
+ if (
1396
+ errors === _errs48
1397
+ ) {
1398
+ if (
1399
+ data20 &&
1400
+ typeof data20 ==
1401
+ 'object' &&
1402
+ !Array.isArray(
1403
+ data20
1404
+ )
1405
+ ) {
1406
+ const _errs50 =
1407
+ errors;
1408
+ for (const key6 in data20) {
1409
+ if (
1410
+ !(
1411
+ key6 ===
1412
+ 'vfsRoot' ||
1413
+ key6 ===
1414
+ 'nodes'
1415
+ )
1416
+ ) {
1417
+ validate11.errors =
1418
+ [
1419
+ {
1420
+ instancePath:
1421
+ instancePath +
1422
+ '/extraFiles',
1423
+ schemaPath:
1424
+ '#/definitions/PHPExtensionManifestExtraFiles/additionalProperties',
1425
+ keyword:
1426
+ 'additionalProperties',
1427
+ params: {
1428
+ additionalProperty:
1429
+ key6,
1430
+ },
1431
+ message:
1432
+ 'must NOT have additional properties',
1433
+ },
1434
+ ];
1435
+ return false;
1436
+ break;
1437
+ }
1438
+ }
1439
+ if (
1440
+ _errs50 ===
1441
+ errors
1442
+ ) {
1443
+ if (
1444
+ data20.vfsRoot !==
1445
+ undefined
1446
+ ) {
1447
+ const _errs51 =
1448
+ errors;
1449
+ if (
1450
+ typeof data20.vfsRoot !==
1451
+ 'string'
1452
+ ) {
1453
+ validate11.errors =
1454
+ [
1455
+ {
1456
+ instancePath:
1457
+ instancePath +
1458
+ '/extraFiles/vfsRoot',
1459
+ schemaPath:
1460
+ '#/definitions/PHPExtensionManifestExtraFiles/properties/vfsRoot/type',
1461
+ keyword:
1462
+ 'type',
1463
+ params: {
1464
+ type: 'string',
1465
+ },
1466
+ message:
1467
+ 'must be string',
1468
+ },
1469
+ ];
1470
+ return false;
1471
+ }
1472
+ var valid10 =
1473
+ _errs51 ===
1474
+ errors;
1475
+ } else {
1476
+ var valid10 = true;
1477
+ }
1478
+ if (
1479
+ valid10
1480
+ ) {
1481
+ if (
1482
+ data20.nodes !==
1483
+ undefined
1484
+ ) {
1485
+ let data22 =
1486
+ data20.nodes;
1487
+ const _errs53 =
1488
+ errors;
1489
+ if (
1490
+ errors ===
1491
+ _errs53
1492
+ ) {
1493
+ if (
1494
+ Array.isArray(
1495
+ data22
1496
+ )
1497
+ ) {
1498
+ var valid11 = true;
1499
+ const len2 =
1500
+ data22.length;
1501
+ for (
1502
+ let i2 = 0;
1503
+ i2 <
1504
+ len2;
1505
+ i2++
1506
+ ) {
1507
+ let data23 =
1508
+ data22[
1509
+ i2
1510
+ ];
1511
+ const _errs55 =
1512
+ errors;
1513
+ if (
1514
+ errors ===
1515
+ _errs55
1516
+ ) {
1517
+ if (
1518
+ data23 &&
1519
+ typeof data23 ==
1520
+ 'object' &&
1521
+ !Array.isArray(
1522
+ data23
1523
+ )
1524
+ ) {
1525
+ let missing3;
1526
+ if (
1527
+ data23.vfsPath ===
1528
+ undefined &&
1529
+ (missing3 =
1530
+ 'vfsPath')
1531
+ ) {
1532
+ validate11.errors =
1533
+ [
1534
+ {
1535
+ instancePath:
1536
+ instancePath +
1537
+ '/extraFiles/nodes/' +
1538
+ i2,
1539
+ schemaPath:
1540
+ '#/definitions/PHPExtensionManifestExtraFiles/properties/nodes/items/required',
1541
+ keyword:
1542
+ 'required',
1543
+ params: {
1544
+ missingProperty:
1545
+ missing3,
1546
+ },
1547
+ message:
1548
+ "must have required property '" +
1549
+ missing3 +
1550
+ "'",
1551
+ },
1552
+ ];
1553
+ return false;
1554
+ } else {
1555
+ const _errs57 =
1556
+ errors;
1557
+ for (const key7 in data23) {
1558
+ if (
1559
+ !(
1560
+ key7 ===
1561
+ 'vfsPath' ||
1562
+ key7 ===
1563
+ 'type' ||
1564
+ key7 ===
1565
+ 'sourcePath'
1566
+ )
1567
+ ) {
1568
+ validate11.errors =
1569
+ [
1570
+ {
1571
+ instancePath:
1572
+ instancePath +
1573
+ '/extraFiles/nodes/' +
1574
+ i2,
1575
+ schemaPath:
1576
+ '#/definitions/PHPExtensionManifestExtraFiles/properties/nodes/items/additionalProperties',
1577
+ keyword:
1578
+ 'additionalProperties',
1579
+ params: {
1580
+ additionalProperty:
1581
+ key7,
1582
+ },
1583
+ message:
1584
+ 'must NOT have additional properties',
1585
+ },
1586
+ ];
1587
+ return false;
1588
+ break;
1589
+ }
1590
+ }
1591
+ if (
1592
+ _errs57 ===
1593
+ errors
1594
+ ) {
1595
+ if (
1596
+ data23.vfsPath !==
1597
+ undefined
1598
+ ) {
1599
+ const _errs58 =
1600
+ errors;
1601
+ if (
1602
+ typeof data23.vfsPath !==
1603
+ 'string'
1604
+ ) {
1605
+ validate11.errors =
1606
+ [
1607
+ {
1608
+ instancePath:
1609
+ instancePath +
1610
+ '/extraFiles/nodes/' +
1611
+ i2 +
1612
+ '/vfsPath',
1613
+ schemaPath:
1614
+ '#/definitions/PHPExtensionManifestExtraFiles/properties/nodes/items/properties/vfsPath/type',
1615
+ keyword:
1616
+ 'type',
1617
+ params: {
1618
+ type: 'string',
1619
+ },
1620
+ message:
1621
+ 'must be string',
1622
+ },
1623
+ ];
1624
+ return false;
1625
+ }
1626
+ var valid12 =
1627
+ _errs58 ===
1628
+ errors;
1629
+ } else {
1630
+ var valid12 = true;
1631
+ }
1632
+ if (
1633
+ valid12
1634
+ ) {
1635
+ if (
1636
+ data23.type !==
1637
+ undefined
1638
+ ) {
1639
+ let data25 =
1640
+ data23.type;
1641
+ const _errs60 =
1642
+ errors;
1643
+ if (
1644
+ typeof data25 !==
1645
+ 'string'
1646
+ ) {
1647
+ validate11.errors =
1648
+ [
1649
+ {
1650
+ instancePath:
1651
+ instancePath +
1652
+ '/extraFiles/nodes/' +
1653
+ i2 +
1654
+ '/type',
1655
+ schemaPath:
1656
+ '#/definitions/PHPExtensionManifestExtraFiles/properties/nodes/items/properties/type/type',
1657
+ keyword:
1658
+ 'type',
1659
+ params: {
1660
+ type: 'string',
1661
+ },
1662
+ message:
1663
+ 'must be string',
1664
+ },
1665
+ ];
1666
+ return false;
1667
+ }
1668
+ if (
1669
+ !(
1670
+ data25 ===
1671
+ 'file' ||
1672
+ data25 ===
1673
+ 'directory'
1674
+ )
1675
+ ) {
1676
+ validate11.errors =
1677
+ [
1678
+ {
1679
+ instancePath:
1680
+ instancePath +
1681
+ '/extraFiles/nodes/' +
1682
+ i2 +
1683
+ '/type',
1684
+ schemaPath:
1685
+ '#/definitions/PHPExtensionManifestExtraFiles/properties/nodes/items/properties/type/enum',
1686
+ keyword:
1687
+ 'enum',
1688
+ params: {
1689
+ allowedValues:
1690
+ schema15
1691
+ .properties
1692
+ .nodes
1693
+ .items
1694
+ .properties
1695
+ .type
1696
+ .enum,
1697
+ },
1698
+ message:
1699
+ 'must be equal to one of the allowed values',
1700
+ },
1701
+ ];
1702
+ return false;
1703
+ }
1704
+ var valid12 =
1705
+ _errs60 ===
1706
+ errors;
1707
+ } else {
1708
+ var valid12 = true;
1709
+ }
1710
+ if (
1711
+ valid12
1712
+ ) {
1713
+ if (
1714
+ data23.sourcePath !==
1715
+ undefined
1716
+ ) {
1717
+ const _errs62 =
1718
+ errors;
1719
+ if (
1720
+ typeof data23.sourcePath !==
1721
+ 'string'
1722
+ ) {
1723
+ validate11.errors =
1724
+ [
1725
+ {
1726
+ instancePath:
1727
+ instancePath +
1728
+ '/extraFiles/nodes/' +
1729
+ i2 +
1730
+ '/sourcePath',
1731
+ schemaPath:
1732
+ '#/definitions/PHPExtensionManifestExtraFiles/properties/nodes/items/properties/sourcePath/type',
1733
+ keyword:
1734
+ 'type',
1735
+ params: {
1736
+ type: 'string',
1737
+ },
1738
+ message:
1739
+ 'must be string',
1740
+ },
1741
+ ];
1742
+ return false;
1743
+ }
1744
+ var valid12 =
1745
+ _errs62 ===
1746
+ errors;
1747
+ } else {
1748
+ var valid12 = true;
1749
+ }
1750
+ }
1751
+ }
1752
+ }
1753
+ }
1754
+ } else {
1755
+ validate11.errors =
1756
+ [
1757
+ {
1758
+ instancePath:
1759
+ instancePath +
1760
+ '/extraFiles/nodes/' +
1761
+ i2,
1762
+ schemaPath:
1763
+ '#/definitions/PHPExtensionManifestExtraFiles/properties/nodes/items/type',
1764
+ keyword:
1765
+ 'type',
1766
+ params: {
1767
+ type: 'object',
1768
+ },
1769
+ message:
1770
+ 'must be object',
1771
+ },
1772
+ ];
1773
+ return false;
1774
+ }
1775
+ }
1776
+ var valid11 =
1777
+ _errs55 ===
1778
+ errors;
1779
+ if (
1780
+ !valid11
1781
+ ) {
1782
+ break;
1783
+ }
1784
+ }
1785
+ } else {
1786
+ validate11.errors =
1787
+ [
1788
+ {
1789
+ instancePath:
1790
+ instancePath +
1791
+ '/extraFiles/nodes',
1792
+ schemaPath:
1793
+ '#/definitions/PHPExtensionManifestExtraFiles/properties/nodes/type',
1794
+ keyword:
1795
+ 'type',
1796
+ params: {
1797
+ type: 'array',
1798
+ },
1799
+ message:
1800
+ 'must be array',
1801
+ },
1802
+ ];
1803
+ return false;
1804
+ }
1805
+ }
1806
+ var valid10 =
1807
+ _errs53 ===
1808
+ errors;
1809
+ } else {
1810
+ var valid10 = true;
1811
+ }
1812
+ }
1813
+ }
1814
+ } else {
1815
+ validate11.errors =
1816
+ [
1817
+ {
1818
+ instancePath:
1819
+ instancePath +
1820
+ '/extraFiles',
1821
+ schemaPath:
1822
+ '#/definitions/PHPExtensionManifestExtraFiles/type',
1823
+ keyword:
1824
+ 'type',
1825
+ params: {
1826
+ type: 'object',
1827
+ },
1828
+ message:
1829
+ 'must be object',
1830
+ },
1831
+ ];
1832
+ return false;
1833
+ }
1834
+ }
1835
+ var valid0 =
1836
+ _errs47 === errors;
1837
+ } else {
1838
+ var valid0 = true;
1839
+ }
1840
+ }
1841
+ }
1842
+ }
1843
+ }
836
1844
  }
837
1845
  }
838
1846
  }