@nestia/migrate 0.9.6 → 0.10.0
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.
- package/lib/MigrateApplication.js +367 -197
- package/lib/MigrateApplication.js.map +1 -1
- package/lib/analyzers/MigrateControllerAnalyzer.js +5 -0
- package/lib/analyzers/MigrateControllerAnalyzer.js.map +1 -1
- package/lib/analyzers/MigrateMethodAnalyzer.js +121 -36
- package/lib/analyzers/MigrateMethodAnalyzer.js.map +1 -1
- package/lib/bundles/NEST_TEMPLATE.js +2 -2
- package/lib/bundles/SDK_TEMPLATE.js +1 -1
- package/lib/programmers/MigrateSchemaProgrammer.js +15 -13
- package/lib/programmers/MigrateSchemaProgrammer.js.map +1 -1
- package/lib/structures/ISwagger.d.ts +1 -1
- package/lib/structures/ISwaggerComponents.d.ts +7 -1
- package/lib/structures/ISwaggerRoute.d.ts +6 -41
- package/lib/structures/ISwaggerRouteBodyContent.d.ts +14 -0
- package/lib/structures/ISwaggerRouteBodyContent.js +3 -0
- package/lib/structures/ISwaggerRouteBodyContent.js.map +1 -0
- package/lib/structures/ISwaggerRouteHeader.d.ts +0 -0
- package/lib/structures/ISwaggerRouteHeader.js +2 -0
- package/lib/structures/ISwaggerRouteHeader.js.map +1 -0
- package/lib/structures/ISwaggerRouteParameter.d.ts +13 -0
- package/lib/structures/ISwaggerRouteParameter.js +3 -0
- package/lib/structures/ISwaggerRouteParameter.js.map +1 -0
- package/lib/structures/ISwaggerRouteRequestBody.d.ts +11 -0
- package/lib/structures/ISwaggerRouteRequestBody.js +3 -0
- package/lib/structures/ISwaggerRouteRequestBody.js.map +1 -0
- package/lib/structures/ISwaggerRouteResponse.d.ts +10 -0
- package/lib/structures/ISwaggerRouteResponse.js +3 -0
- package/lib/structures/ISwaggerRouteResponse.js.map +1 -0
- package/lib/utils/SwaggerComponentsExplorer.d.ts +9 -0
- package/lib/utils/SwaggerComponentsExplorer.js +29 -0
- package/lib/utils/SwaggerComponentsExplorer.js.map +1 -0
- package/lib/utils/SwaggerExplorer.d.ts +0 -0
- package/lib/utils/SwaggerExplorer.js +2 -0
- package/lib/utils/SwaggerExplorer.js.map +1 -0
- package/lib/utils/SwaggerTypeChecker.d.ts +2 -2
- package/lib/utils/SwaggerTypeChecker.js +25 -25
- package/lib/utils/SwaggerTypeChecker.js.map +1 -1
- package/package.json +2 -2
- package/src/analyzers/MigrateControllerAnalyzer.ts +7 -0
- package/src/analyzers/MigrateMethodAnalyzer.ts +147 -71
- package/src/bundles/NEST_TEMPLATE.ts +2 -2
- package/src/bundles/SDK_TEMPLATE.ts +1 -1
- package/src/programmers/MigrateSchemaProgrammer.ts +19 -16
- package/src/structures/ISwagger.ts +4 -1
- package/src/structures/ISwaggerComponents.ts +7 -1
- package/src/structures/ISwaggerRoute.ts +9 -44
- package/src/structures/ISwaggerRouteBodyContent.ts +15 -0
- package/src/structures/ISwaggerRouteHeader.ts +0 -0
- package/src/structures/ISwaggerRouteParameter.ts +14 -0
- package/src/structures/ISwaggerRouteRequestBody.ts +12 -0
- package/src/structures/ISwaggerRouteResponse.ts +11 -0
- package/src/utils/SwaggerComponentsExplorer.ts +43 -0
- package/src/utils/SwaggerTypeChecker.ts +5 -5
@@ -20,122 +20,141 @@ class MigrateApplication {
|
|
20
20
|
const result = (input => {
|
21
21
|
const errors = [];
|
22
22
|
const __is = input => {
|
23
|
-
const $io0 = input => "string" === typeof input.openapi && RegExp(/^3\.0\.[+-]?\d+(?:\.\d+)?(?:[eE][+-]?\d+)?$/).test(input.openapi) && ("object" === typeof input.info && null !== input.info && $io1(input.info)) && (Array.isArray(input.servers) && input.servers.every(elem => "object" === typeof elem && null !== elem && $io4(elem))) && ("object" === typeof input.components && null !== input.components && false === Array.isArray(input.components) && $io5(input.components)) && ("object" === typeof input.paths && null !== input.paths && false === Array.isArray(input.paths) && $
|
23
|
+
const $io0 = input => "string" === typeof input.openapi && RegExp(/^3\.0\.[+-]?\d+(?:\.\d+)?(?:[eE][+-]?\d+)?$/).test(input.openapi) && ("object" === typeof input.info && null !== input.info && $io1(input.info)) && (Array.isArray(input.servers) && input.servers.every(elem => "object" === typeof elem && null !== elem && $io4(elem))) && ("object" === typeof input.components && null !== input.components && false === Array.isArray(input.components) && $io5(input.components)) && ("object" === typeof input.paths && null !== input.paths && false === Array.isArray(input.paths) && $io36(input.paths)) && (undefined === input.security || Array.isArray(input.security) && input.security.every(elem => "object" === typeof elem && null !== elem && false === Array.isArray(elem) && $io49(elem)));
|
24
24
|
const $io1 = input => "string" === typeof input.title && (undefined === input.description || "string" === typeof input.description) && (undefined === input.termsOfService || "string" === typeof input.termsOfService && (/\/|:/.test(input.termsOfService) && /^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)(?:\?(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i.test(input.termsOfService))) && (undefined === input.contact || "object" === typeof input.contact && null !== input.contact && false === Array.isArray(input.contact) && $io2(input.contact)) && (undefined === input.license || "object" === typeof input.license && null !== input.license && $io3(input.license)) && "string" === typeof input.version;
|
25
25
|
const $io2 = input => (undefined === input.name || "string" === typeof input.name) && (undefined === input.url || "string" === typeof input.url && (/\/|:/.test(input.url) && /^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)(?:\?(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i.test(input.url))) && (undefined === input.email || "string" === typeof input.email && /^[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*@(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?$/i.test(input.email));
|
26
26
|
const $io3 = input => "string" === typeof input.name && (undefined === input.url || "string" === typeof input.url && (/\/|:/.test(input.url) && /^(?:[a-z][a-z0-9+\-.]*:)(?:\/?\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:]|%[0-9a-f]{2})*@)?(?:\[(?:(?:(?:(?:[0-9a-f]{1,4}:){6}|::(?:[0-9a-f]{1,4}:){5}|(?:[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){4}|(?:(?:[0-9a-f]{1,4}:){0,1}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){3}|(?:(?:[0-9a-f]{1,4}:){0,2}[0-9a-f]{1,4})?::(?:[0-9a-f]{1,4}:){2}|(?:(?:[0-9a-f]{1,4}:){0,3}[0-9a-f]{1,4})?::[0-9a-f]{1,4}:|(?:(?:[0-9a-f]{1,4}:){0,4}[0-9a-f]{1,4})?::)(?:[0-9a-f]{1,4}:[0-9a-f]{1,4}|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?))|(?:(?:[0-9a-f]{1,4}:){0,5}[0-9a-f]{1,4})?::[0-9a-f]{1,4}|(?:(?:[0-9a-f]{1,4}:){0,6}[0-9a-f]{1,4})?::)|[Vv][0-9a-f]+\.[a-z0-9\-._~!$&'()*+,;=:]+)\]|(?:(?:25[0-5]|2[0-4]\d|[01]?\d\d?)\.){3}(?:25[0-5]|2[0-4]\d|[01]?\d\d?)|(?:[a-z0-9\-._~!$&'()*+,;=]|%[0-9a-f]{2})*)(?::\d*)?(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*|\/(?:(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)?|(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})+(?:\/(?:[a-z0-9\-._~!$&'()*+,;=:@]|%[0-9a-f]{2})*)*)(?:\?(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?(?:#(?:[a-z0-9\-._~!$&'()*+,;=:@/?]|%[0-9a-f]{2})*)?$/i.test(input.url)));
|
27
27
|
const $io4 = input => "string" === typeof input.url && (undefined === input.description || "string" === typeof input.description);
|
28
|
-
const $io5 = input => (undefined === input.schemas || "object" === typeof input.schemas && null !== input.schemas && false === Array.isArray(input.schemas) && $
|
28
|
+
const $io5 = input => (undefined === input.parameters || "object" === typeof input.parameters && null !== input.parameters && false === Array.isArray(input.parameters) && $io6(input.parameters)) && (undefined === input.responses || "object" === typeof input.responses && null !== input.responses && false === Array.isArray(input.responses) && $io21(input.responses)) && (undefined === input.schemas || "object" === typeof input.schemas && null !== input.schemas && false === Array.isArray(input.schemas) && $io18(input.schemas)) && (undefined === input.securitySchemes || "object" === typeof input.securitySchemes && null !== input.securitySchemes && false === Array.isArray(input.securitySchemes) && $io25(input.securitySchemes)) && (undefined === input["x-nestia-namespace"] || "string" === typeof input["x-nestia-namespace"]);
|
29
29
|
const $io6 = input => Object.keys(input).every(key => {
|
30
|
+
const value = input[key];
|
31
|
+
if (undefined === value)
|
32
|
+
return true;
|
33
|
+
return "object" === typeof value && null !== value && $io7(value);
|
34
|
+
});
|
35
|
+
const $io7 = input => (undefined === input.name || "string" === typeof input.name) && ("cookie" === input["in"] || "header" === input["in"] || "path" === input["in"] || "query" === input["in"]) && ("object" === typeof input.schema && null !== input.schema && false === Array.isArray(input.schema) && $iu0(input.schema)) && (undefined === input.required || "boolean" === typeof input.required) && (undefined === input.description || "string" === typeof input.description);
|
36
|
+
const $io8 = input => null !== input.type && undefined === input.type && (undefined === input.title || "string" === typeof input.title) && (undefined === input.description || "string" === typeof input.description) && (undefined === input.deprecated || "boolean" === typeof input.deprecated) && (undefined === input["x-typia-optional"] || "boolean" === typeof input["x-typia-optional"]) && (undefined === input["x-typia-rest"] || "boolean" === typeof input["x-typia-rest"]);
|
37
|
+
const $io9 = input => "null" === input.type && (undefined === input.title || "string" === typeof input.title) && (undefined === input.description || "string" === typeof input.description) && (undefined === input.deprecated || "boolean" === typeof input.deprecated) && (undefined === input["x-typia-optional"] || "boolean" === typeof input["x-typia-optional"]) && (undefined === input["x-typia-rest"] || "boolean" === typeof input["x-typia-rest"]);
|
38
|
+
const $io10 = input => Array.isArray(input.anyOf) && input.anyOf.every(elem => "object" === typeof elem && null !== elem && false === Array.isArray(elem) && $iu0(elem)) && (undefined === input.title || "string" === typeof input.title) && (undefined === input.description || "string" === typeof input.description) && (undefined === input.deprecated || "boolean" === typeof input.deprecated) && (undefined === input["x-typia-optional"] || "boolean" === typeof input["x-typia-optional"]) && (undefined === input["x-typia-rest"] || "boolean" === typeof input["x-typia-rest"]);
|
39
|
+
const $io11 = input => Array.isArray(input.oneOf) && input.oneOf.every(elem => "object" === typeof elem && null !== elem && false === Array.isArray(elem) && $iu0(elem)) && (undefined === input.title || "string" === typeof input.title) && (undefined === input.description || "string" === typeof input.description) && (undefined === input.deprecated || "boolean" === typeof input.deprecated) && (undefined === input["x-typia-optional"] || "boolean" === typeof input["x-typia-optional"]) && (undefined === input["x-typia-rest"] || "boolean" === typeof input["x-typia-rest"]);
|
40
|
+
const $io12 = input => (undefined === input["default"] || "boolean" === typeof input["default"]) && (undefined === input["enum"] || Array.isArray(input["enum"]) && input["enum"].every(elem => "boolean" === typeof elem)) && "boolean" === input.type && (undefined === input.nullable || "boolean" === typeof input.nullable) && (undefined === input.title || "string" === typeof input.title) && (undefined === input.description || "string" === typeof input.description) && (undefined === input.deprecated || "boolean" === typeof input.deprecated) && (undefined === input["x-typia-optional"] || "boolean" === typeof input["x-typia-optional"]) && (undefined === input["x-typia-rest"] || "boolean" === typeof input["x-typia-rest"]);
|
41
|
+
const $io13 = input => (undefined === input["default"] || "number" === typeof input["default"] && (Math.floor(input["default"]) === input["default"] && -2147483648 <= input["default"] && input["default"] <= 2147483647)) && (undefined === input["enum"] || Array.isArray(input["enum"]) && input["enum"].every(elem => "number" === typeof elem)) && (undefined === input.minimum || "number" === typeof input.minimum && (Math.floor(input.minimum) === input.minimum && -2147483648 <= input.minimum && input.minimum <= 2147483647)) && (undefined === input.maximum || "number" === typeof input.maximum && (Math.floor(input.maximum) === input.maximum && -2147483648 <= input.maximum && input.maximum <= 2147483647)) && (undefined === input.exclusiveMinimum || "boolean" === typeof input.exclusiveMinimum) && (undefined === input.exclusiveMaximum || "boolean" === typeof input.exclusiveMaximum) && (undefined === input.multipleOf || "number" === typeof input.multipleOf && (Math.floor(input.multipleOf) === input.multipleOf && 0 <= input.multipleOf && input.multipleOf <= 4294967295)) && "integer" === input.type && (undefined === input.nullable || "boolean" === typeof input.nullable) && (undefined === input.title || "string" === typeof input.title) && (undefined === input.description || "string" === typeof input.description) && (undefined === input.deprecated || "boolean" === typeof input.deprecated) && (undefined === input["x-typia-optional"] || "boolean" === typeof input["x-typia-optional"]) && (undefined === input["x-typia-rest"] || "boolean" === typeof input["x-typia-rest"]);
|
42
|
+
const $io14 = input => (undefined === input["default"] || "number" === typeof input["default"]) && (undefined === input["enum"] || Array.isArray(input["enum"]) && input["enum"].every(elem => "number" === typeof elem)) && (undefined === input.minimum || "number" === typeof input.minimum) && (undefined === input.maximum || "number" === typeof input.maximum) && (undefined === input.exclusiveMinimum || "boolean" === typeof input.exclusiveMinimum) && (undefined === input.exclusiveMaximum || "boolean" === typeof input.exclusiveMaximum) && (undefined === input.multipleOf || "number" === typeof input.multipleOf) && "number" === input.type && (undefined === input.nullable || "boolean" === typeof input.nullable) && (undefined === input.title || "string" === typeof input.title) && (undefined === input.description || "string" === typeof input.description) && (undefined === input.deprecated || "boolean" === typeof input.deprecated) && (undefined === input["x-typia-optional"] || "boolean" === typeof input["x-typia-optional"]) && (undefined === input["x-typia-rest"] || "boolean" === typeof input["x-typia-rest"]);
|
43
|
+
const $io15 = input => (undefined === input["default"] || "string" === typeof input["default"]) && (undefined === input["enum"] || Array.isArray(input["enum"]) && input["enum"].every(elem => "string" === typeof elem)) && (undefined === input.format || "string" === typeof input.format) && (undefined === input.pattern || "string" === typeof input.pattern) && (undefined === input.minLength || "number" === typeof input.minLength && (Math.floor(input.minLength) === input.minLength && 0 <= input.minLength && input.minLength <= 4294967295)) && (undefined === input.maxLength || "number" === typeof input.maxLength && (Math.floor(input.maxLength) === input.maxLength && 0 <= input.maxLength && input.maxLength <= 4294967295)) && "string" === input.type && (undefined === input.nullable || "boolean" === typeof input.nullable) && (undefined === input.title || "string" === typeof input.title) && (undefined === input.description || "string" === typeof input.description) && (undefined === input.deprecated || "boolean" === typeof input.deprecated) && (undefined === input["x-typia-optional"] || "boolean" === typeof input["x-typia-optional"]) && (undefined === input["x-typia-rest"] || "boolean" === typeof input["x-typia-rest"]);
|
44
|
+
const $io16 = input => "object" === typeof input.items && null !== input.items && false === Array.isArray(input.items) && $iu0(input.items) && (undefined === input.minItems || "number" === typeof input.minItems && (Math.floor(input.minItems) === input.minItems && 0 <= input.minItems && input.minItems <= 4294967295)) && (undefined === input.maxItems || "number" === typeof input.maxItems && (Math.floor(input.maxItems) === input.maxItems && 0 <= input.maxItems && input.maxItems <= 4294967295)) && (undefined === input["x-typia-tuple"] || "object" === typeof input["x-typia-tuple"] && null !== input["x-typia-tuple"] && $io20(input["x-typia-tuple"])) && "array" === input.type && (undefined === input.nullable || "boolean" === typeof input.nullable) && (undefined === input.title || "string" === typeof input.title) && (undefined === input.description || "string" === typeof input.description) && (undefined === input.deprecated || "boolean" === typeof input.deprecated) && (undefined === input["x-typia-optional"] || "boolean" === typeof input["x-typia-optional"]) && (undefined === input["x-typia-rest"] || "boolean" === typeof input["x-typia-rest"]);
|
45
|
+
const $io17 = input => (undefined === input.properties || "object" === typeof input.properties && null !== input.properties && false === Array.isArray(input.properties) && $io18(input.properties)) && (undefined === input.required || Array.isArray(input.required) && input.required.every(elem => "string" === typeof elem)) && (null !== input.additionalProperties && (undefined === input.additionalProperties || "boolean" === typeof input.additionalProperties || "object" === typeof input.additionalProperties && null !== input.additionalProperties && false === Array.isArray(input.additionalProperties) && $iu0(input.additionalProperties))) && (undefined === input["x-typia-patternProperties"] || "object" === typeof input["x-typia-patternProperties"] && null !== input["x-typia-patternProperties"] && false === Array.isArray(input["x-typia-patternProperties"]) && $io18(input["x-typia-patternProperties"])) && "object" === input.type && (undefined === input.nullable || "boolean" === typeof input.nullable) && (undefined === input.title || "string" === typeof input.title) && (undefined === input.description || "string" === typeof input.description) && (undefined === input.deprecated || "boolean" === typeof input.deprecated) && (undefined === input["x-typia-optional"] || "boolean" === typeof input["x-typia-optional"]) && (undefined === input["x-typia-rest"] || "boolean" === typeof input["x-typia-rest"]);
|
46
|
+
const $io18 = input => Object.keys(input).every(key => {
|
30
47
|
const value = input[key];
|
31
48
|
if (undefined === value)
|
32
49
|
return true;
|
33
50
|
return "object" === typeof value && null !== value && false === Array.isArray(value) && $iu0(value);
|
34
51
|
});
|
35
|
-
const $
|
36
|
-
const $
|
37
|
-
const $
|
38
|
-
const $io10 = input => Array.isArray(input.oneOf) && input.oneOf.every(elem => "object" === typeof elem && null !== elem && false === Array.isArray(elem) && $iu0(elem)) && (undefined === input.title || "string" === typeof input.title) && (undefined === input.description || "string" === typeof input.description) && (undefined === input.deprecated || "boolean" === typeof input.deprecated) && (undefined === input["x-typia-optional"] || "boolean" === typeof input["x-typia-optional"]) && (undefined === input["x-typia-rest"] || "boolean" === typeof input["x-typia-rest"]);
|
39
|
-
const $io11 = input => (undefined === input["default"] || "boolean" === typeof input["default"]) && (undefined === input["enum"] || Array.isArray(input["enum"]) && input["enum"].every(elem => "boolean" === typeof elem)) && "boolean" === input.type && (undefined === input.nullable || "boolean" === typeof input.nullable) && (undefined === input.title || "string" === typeof input.title) && (undefined === input.description || "string" === typeof input.description) && (undefined === input.deprecated || "boolean" === typeof input.deprecated) && (undefined === input["x-typia-optional"] || "boolean" === typeof input["x-typia-optional"]) && (undefined === input["x-typia-rest"] || "boolean" === typeof input["x-typia-rest"]);
|
40
|
-
const $io12 = input => (undefined === input["default"] || "number" === typeof input["default"] && (Math.floor(input["default"]) === input["default"] && -2147483648 <= input["default"] && input["default"] <= 2147483647)) && (undefined === input["enum"] || Array.isArray(input["enum"]) && input["enum"].every(elem => "number" === typeof elem)) && (undefined === input.minimum || "number" === typeof input.minimum && (Math.floor(input.minimum) === input.minimum && -2147483648 <= input.minimum && input.minimum <= 2147483647)) && (undefined === input.maximum || "number" === typeof input.maximum && (Math.floor(input.maximum) === input.maximum && -2147483648 <= input.maximum && input.maximum <= 2147483647)) && (undefined === input.exclusiveMinimum || "boolean" === typeof input.exclusiveMinimum) && (undefined === input.exclusiveMaximum || "boolean" === typeof input.exclusiveMaximum) && (undefined === input.multipleOf || "number" === typeof input.multipleOf && (Math.floor(input.multipleOf) === input.multipleOf && 0 <= input.multipleOf && input.multipleOf <= 4294967295)) && "integer" === input.type && (undefined === input.nullable || "boolean" === typeof input.nullable) && (undefined === input.title || "string" === typeof input.title) && (undefined === input.description || "string" === typeof input.description) && (undefined === input.deprecated || "boolean" === typeof input.deprecated) && (undefined === input["x-typia-optional"] || "boolean" === typeof input["x-typia-optional"]) && (undefined === input["x-typia-rest"] || "boolean" === typeof input["x-typia-rest"]);
|
41
|
-
const $io13 = input => (undefined === input["default"] || "number" === typeof input["default"]) && (undefined === input["enum"] || Array.isArray(input["enum"]) && input["enum"].every(elem => "number" === typeof elem)) && (undefined === input.minimum || "number" === typeof input.minimum) && (undefined === input.maximum || "number" === typeof input.maximum) && (undefined === input.exclusiveMinimum || "boolean" === typeof input.exclusiveMinimum) && (undefined === input.exclusiveMaximum || "boolean" === typeof input.exclusiveMaximum) && (undefined === input.multipleOf || "number" === typeof input.multipleOf) && "number" === input.type && (undefined === input.nullable || "boolean" === typeof input.nullable) && (undefined === input.title || "string" === typeof input.title) && (undefined === input.description || "string" === typeof input.description) && (undefined === input.deprecated || "boolean" === typeof input.deprecated) && (undefined === input["x-typia-optional"] || "boolean" === typeof input["x-typia-optional"]) && (undefined === input["x-typia-rest"] || "boolean" === typeof input["x-typia-rest"]);
|
42
|
-
const $io14 = input => (undefined === input["default"] || "string" === typeof input["default"]) && (undefined === input["enum"] || Array.isArray(input["enum"]) && input["enum"].every(elem => "string" === typeof elem)) && (undefined === input.format || "string" === typeof input.format) && (undefined === input.pattern || "string" === typeof input.pattern) && (undefined === input.minLength || "number" === typeof input.minLength && (Math.floor(input.minLength) === input.minLength && 0 <= input.minLength && input.minLength <= 4294967295)) && (undefined === input.maxLength || "number" === typeof input.maxLength && (Math.floor(input.maxLength) === input.maxLength && 0 <= input.maxLength && input.maxLength <= 4294967295)) && "string" === input.type && (undefined === input.nullable || "boolean" === typeof input.nullable) && (undefined === input.title || "string" === typeof input.title) && (undefined === input.description || "string" === typeof input.description) && (undefined === input.deprecated || "boolean" === typeof input.deprecated) && (undefined === input["x-typia-optional"] || "boolean" === typeof input["x-typia-optional"]) && (undefined === input["x-typia-rest"] || "boolean" === typeof input["x-typia-rest"]);
|
43
|
-
const $io15 = input => "object" === typeof input.items && null !== input.items && false === Array.isArray(input.items) && $iu0(input.items) && (undefined === input.minItems || "number" === typeof input.minItems && (Math.floor(input.minItems) === input.minItems && 0 <= input.minItems && input.minItems <= 4294967295)) && (undefined === input.maxItems || "number" === typeof input.maxItems && (Math.floor(input.maxItems) === input.maxItems && 0 <= input.maxItems && input.maxItems <= 4294967295)) && (undefined === input["x-typia-tuple"] || "object" === typeof input["x-typia-tuple"] && null !== input["x-typia-tuple"] && $io18(input["x-typia-tuple"])) && "array" === input.type && (undefined === input.nullable || "boolean" === typeof input.nullable) && (undefined === input.title || "string" === typeof input.title) && (undefined === input.description || "string" === typeof input.description) && (undefined === input.deprecated || "boolean" === typeof input.deprecated) && (undefined === input["x-typia-optional"] || "boolean" === typeof input["x-typia-optional"]) && (undefined === input["x-typia-rest"] || "boolean" === typeof input["x-typia-rest"]);
|
44
|
-
const $io16 = input => (undefined === input.properties || "object" === typeof input.properties && null !== input.properties && false === Array.isArray(input.properties) && $io6(input.properties)) && (undefined === input.required || Array.isArray(input.required) && input.required.every(elem => "string" === typeof elem)) && (null !== input.additionalProperties && (undefined === input.additionalProperties || "boolean" === typeof input.additionalProperties || "object" === typeof input.additionalProperties && null !== input.additionalProperties && false === Array.isArray(input.additionalProperties) && $iu0(input.additionalProperties))) && (undefined === input["x-typia-patternProperties"] || "object" === typeof input["x-typia-patternProperties"] && null !== input["x-typia-patternProperties"] && false === Array.isArray(input["x-typia-patternProperties"]) && $io6(input["x-typia-patternProperties"])) && "object" === input.type && (undefined === input.nullable || "boolean" === typeof input.nullable) && (undefined === input.title || "string" === typeof input.title) && (undefined === input.description || "string" === typeof input.description) && (undefined === input.deprecated || "boolean" === typeof input.deprecated) && (undefined === input["x-typia-optional"] || "boolean" === typeof input["x-typia-optional"]) && (undefined === input["x-typia-rest"] || "boolean" === typeof input["x-typia-rest"]);
|
45
|
-
const $io17 = input => "string" === typeof input.$ref && (undefined === input.title || "string" === typeof input.title) && (undefined === input.description || "string" === typeof input.description) && (undefined === input.deprecated || "boolean" === typeof input.deprecated) && (undefined === input["x-typia-optional"] || "boolean" === typeof input["x-typia-optional"]) && (undefined === input["x-typia-rest"] || "boolean" === typeof input["x-typia-rest"]);
|
46
|
-
const $io18 = input => Array.isArray(input.items) && input.items.every(elem => "object" === typeof elem && null !== elem && false === Array.isArray(elem) && $iu0(elem)) && "array" === input.type && (undefined === input.nullable || "boolean" === typeof input.nullable) && (undefined === input.title || "string" === typeof input.title) && (undefined === input.description || "string" === typeof input.description) && (undefined === input.deprecated || "boolean" === typeof input.deprecated) && (undefined === input["x-typia-optional"] || "boolean" === typeof input["x-typia-optional"]) && (undefined === input["x-typia-rest"] || "boolean" === typeof input["x-typia-rest"]);
|
47
|
-
const $io19 = input => Object.keys(input).every(key => {
|
52
|
+
const $io19 = input => "string" === typeof input.$ref && (undefined === input.title || "string" === typeof input.title) && (undefined === input.description || "string" === typeof input.description) && (undefined === input.deprecated || "boolean" === typeof input.deprecated) && (undefined === input["x-typia-optional"] || "boolean" === typeof input["x-typia-optional"]) && (undefined === input["x-typia-rest"] || "boolean" === typeof input["x-typia-rest"]);
|
53
|
+
const $io20 = input => Array.isArray(input.items) && input.items.every(elem => "object" === typeof elem && null !== elem && false === Array.isArray(elem) && $iu0(elem)) && "array" === input.type && (undefined === input.nullable || "boolean" === typeof input.nullable) && (undefined === input.title || "string" === typeof input.title) && (undefined === input.description || "string" === typeof input.description) && (undefined === input.deprecated || "boolean" === typeof input.deprecated) && (undefined === input["x-typia-optional"] || "boolean" === typeof input["x-typia-optional"]) && (undefined === input["x-typia-rest"] || "boolean" === typeof input["x-typia-rest"]);
|
54
|
+
const $io21 = input => Object.keys(input).every(key => {
|
48
55
|
const value = input[key];
|
49
56
|
if (undefined === value)
|
50
57
|
return true;
|
51
|
-
return "object" === typeof value && null !== value && $
|
58
|
+
return "object" === typeof value && null !== value && false === Array.isArray(value) && $io22(value);
|
52
59
|
});
|
53
|
-
const $
|
54
|
-
const $
|
55
|
-
const $
|
56
|
-
const $
|
57
|
-
const $io24 = input => "oauth2" === input.type && ("object" === typeof input.flows && null !== input.flows && false === Array.isArray(input.flows) && $io25(input.flows)) && (undefined === input.description || "string" === typeof input.description);
|
58
|
-
const $io25 = input => (undefined === input.authorizationCode || "object" === typeof input.authorizationCode && null !== input.authorizationCode && $io26(input.authorizationCode)) && (undefined === input.implicit || "object" === typeof input.implicit && null !== input.implicit && $io28(input.implicit)) && (undefined === input.password || "object" === typeof input.password && null !== input.password && false === Array.isArray(input.password) && $io29(input.password)) && (undefined === input.clientCredentials || "object" === typeof input.clientCredentials && null !== input.clientCredentials && false === Array.isArray(input.clientCredentials) && $io29(input.clientCredentials));
|
59
|
-
const $io26 = input => "string" === typeof input.authorizationUrl && (undefined === input.tokenUrl || "string" === typeof input.tokenUrl) && (undefined === input.refreshUrl || "string" === typeof input.refreshUrl) && (undefined === input.scopes || "object" === typeof input.scopes && null !== input.scopes && false === Array.isArray(input.scopes) && $io27(input.scopes));
|
60
|
-
const $io27 = input => Object.keys(input).every(key => {
|
60
|
+
const $io22 = input => (undefined === input.description || "string" === typeof input.description) && (undefined === input.content || "object" === typeof input.content && null !== input.content && false === Array.isArray(input.content) && $io23(input.content));
|
61
|
+
const $io23 = input => (undefined === input["text/plain"] || "object" === typeof input["text/plain"] && null !== input["text/plain"] && false === Array.isArray(input["text/plain"]) && $io24(input["text/plain"])) && (undefined === input["application/json"] || "object" === typeof input["application/json"] && null !== input["application/json"] && false === Array.isArray(input["application/json"]) && $io24(input["application/json"])) && (undefined === input["application/x-www-form-urlencoded"] || "object" === typeof input["application/x-www-form-urlencoded"] && null !== input["application/x-www-form-urlencoded"] && false === Array.isArray(input["application/x-www-form-urlencoded"]) && $io24(input["application/x-www-form-urlencoded"])) && (undefined === input["multipart/form-data"] || "object" === typeof input["multipart/form-data"] && null !== input["multipart/form-data"] && false === Array.isArray(input["multipart/form-data"]) && $io24(input["multipart/form-data"])) && (undefined === input["*/*"] || "object" === typeof input["*/*"] && null !== input["*/*"] && false === Array.isArray(input["*/*"]) && $io24(input["*/*"]));
|
62
|
+
const $io24 = input => undefined === input.schema || "object" === typeof input.schema && null !== input.schema && false === Array.isArray(input.schema) && $iu0(input.schema);
|
63
|
+
const $io25 = input => Object.keys(input).every(key => {
|
61
64
|
const value = input[key];
|
62
65
|
if (undefined === value)
|
63
66
|
return true;
|
64
|
-
return "
|
67
|
+
return "object" === typeof value && null !== value && $iu2(value);
|
65
68
|
});
|
66
|
-
const $
|
67
|
-
const $
|
68
|
-
const $
|
69
|
+
const $io26 = input => "http" === input.type && "basic" === input.scheme;
|
70
|
+
const $io27 = input => "http" === input.type && "bearer" === input.scheme && (undefined === input.bearerFormat || "string" === typeof input.bearerFormat);
|
71
|
+
const $io28 = input => "apiKey" === input.type && (undefined === input["in"] || "cookie" === input["in"] || "header" === input["in"] || "query" === input["in"]) && (undefined === input.name || "string" === typeof input.name);
|
72
|
+
const $io29 = input => "openIdConnect" === input.type && "string" === typeof input.openIdConnectUrl;
|
73
|
+
const $io30 = input => "oauth2" === input.type && ("object" === typeof input.flows && null !== input.flows && false === Array.isArray(input.flows) && $io31(input.flows)) && (undefined === input.description || "string" === typeof input.description);
|
74
|
+
const $io31 = input => (undefined === input.authorizationCode || "object" === typeof input.authorizationCode && null !== input.authorizationCode && $io32(input.authorizationCode)) && (undefined === input.implicit || "object" === typeof input.implicit && null !== input.implicit && $io34(input.implicit)) && (undefined === input.password || "object" === typeof input.password && null !== input.password && false === Array.isArray(input.password) && $io35(input.password)) && (undefined === input.clientCredentials || "object" === typeof input.clientCredentials && null !== input.clientCredentials && false === Array.isArray(input.clientCredentials) && $io35(input.clientCredentials));
|
75
|
+
const $io32 = input => "string" === typeof input.authorizationUrl && (undefined === input.tokenUrl || "string" === typeof input.tokenUrl) && (undefined === input.refreshUrl || "string" === typeof input.refreshUrl) && (undefined === input.scopes || "object" === typeof input.scopes && null !== input.scopes && false === Array.isArray(input.scopes) && $io33(input.scopes));
|
76
|
+
const $io33 = input => Object.keys(input).every(key => {
|
69
77
|
const value = input[key];
|
70
78
|
if (undefined === value)
|
71
79
|
return true;
|
72
|
-
return "
|
80
|
+
return "string" === typeof value;
|
73
81
|
});
|
74
|
-
const $
|
82
|
+
const $io34 = input => "string" === typeof input.authorizationUrl && (undefined === input.refreshUrl || "string" === typeof input.refreshUrl) && (undefined === input.scopes || "object" === typeof input.scopes && null !== input.scopes && false === Array.isArray(input.scopes) && $io33(input.scopes));
|
83
|
+
const $io35 = input => (undefined === input.tokenUrl || "string" === typeof input.tokenUrl) && (undefined === input.refreshUrl || "string" === typeof input.refreshUrl) && (undefined === input.scopes || "object" === typeof input.scopes && null !== input.scopes && false === Array.isArray(input.scopes) && $io33(input.scopes));
|
84
|
+
const $io36 = input => Object.keys(input).every(key => {
|
75
85
|
const value = input[key];
|
76
86
|
if (undefined === value)
|
77
87
|
return true;
|
78
|
-
return "object" === typeof value && null !== value && false === Array.isArray(value) && $
|
88
|
+
return "object" === typeof value && null !== value && false === Array.isArray(value) && $io37(value);
|
79
89
|
});
|
80
|
-
const $
|
81
|
-
const $
|
82
|
-
const $
|
83
|
-
const $
|
84
|
-
const $
|
85
|
-
const $
|
86
|
-
const $
|
87
|
-
const $
|
88
|
-
const $
|
89
|
-
const $
|
90
|
+
const $io37 = input => (undefined === input.get || "object" === typeof input.get && null !== input.get && false === Array.isArray(input.get) && $io38(input.get)) && (undefined === input.post || "object" === typeof input.post && null !== input.post && false === Array.isArray(input.post) && $io38(input.post)) && (undefined === input.patch || "object" === typeof input.patch && null !== input.patch && false === Array.isArray(input.patch) && $io38(input.patch)) && (undefined === input.put || "object" === typeof input.put && null !== input.put && false === Array.isArray(input.put) && $io38(input.put)) && (undefined === input["delete"] || "object" === typeof input["delete"] && null !== input["delete"] && false === Array.isArray(input["delete"]) && $io38(input["delete"]));
|
91
|
+
const $io38 = input => (undefined === input.parameters || Array.isArray(input.parameters) && input.parameters.every(elem => "object" === typeof elem && null !== elem && $iu1(elem))) && (undefined === input.requestBody || "object" === typeof input.requestBody && null !== input.requestBody && $io40(input.requestBody)) && (undefined === input.responses || "object" === typeof input.responses && null !== input.responses && false === Array.isArray(input.responses) && $io47(input.responses)) && (undefined === input.summary || "string" === typeof input.summary) && (undefined === input.description || "string" === typeof input.description) && (undefined === input.deprecated || "boolean" === typeof input.deprecated) && (undefined === input.security || Array.isArray(input.security) && input.security.every(elem => "object" === typeof elem && null !== elem && false === Array.isArray(elem) && $io49(elem))) && (undefined === input.tags || Array.isArray(input.tags) && input.tags.every(elem => "string" === typeof elem)) && (undefined === input["x-nestia-jsDocTags"] || Array.isArray(input["x-nestia-jsDocTags"]) && input["x-nestia-jsDocTags"].every(elem => "object" === typeof elem && null !== elem && $io50(elem)));
|
92
|
+
const $io39 = input => "string" === typeof input.$ref && RegExp(/^#\/components\/parameters\/(.*)/).test(input.$ref);
|
93
|
+
const $io40 = input => (undefined === input.description || "string" === typeof input.description) && ("object" === typeof input.content && null !== input.content && false === Array.isArray(input.content) && $io41(input.content)) && (undefined === input.required || "boolean" === typeof input.required) && (undefined === input["x-nestia-encrypted"] || "boolean" === typeof input["x-nestia-encrypted"]);
|
94
|
+
const $io41 = input => (undefined === input["text/plain"] || "object" === typeof input["text/plain"] && null !== input["text/plain"] && $io42(input["text/plain"])) && (undefined === input["application/json"] || "object" === typeof input["application/json"] && null !== input["application/json"] && $io43(input["application/json"])) && (undefined === input["application/x-www-form-urlencoded"] || "object" === typeof input["application/x-www-form-urlencoded"] && null !== input["application/x-www-form-urlencoded"] && $io44(input["application/x-www-form-urlencoded"])) && (undefined === input["multipart/form-data"] || "object" === typeof input["multipart/form-data"] && null !== input["multipart/form-data"] && $io45(input["multipart/form-data"])) && (undefined === input["*/*"] || "object" === typeof input["*/*"] && null !== input["*/*"] && $io46(input["*/*"]));
|
95
|
+
const $io42 = input => "object" === typeof input.schema && null !== input.schema && false === Array.isArray(input.schema) && $iu0(input.schema);
|
96
|
+
const $io43 = input => "object" === typeof input.schema && null !== input.schema && false === Array.isArray(input.schema) && $iu0(input.schema);
|
97
|
+
const $io44 = input => "object" === typeof input.schema && null !== input.schema && false === Array.isArray(input.schema) && $iu0(input.schema);
|
98
|
+
const $io45 = input => "object" === typeof input.schema && null !== input.schema && false === Array.isArray(input.schema) && $iu0(input.schema);
|
99
|
+
const $io46 = input => "object" === typeof input.schema && null !== input.schema && false === Array.isArray(input.schema) && $iu0(input.schema);
|
100
|
+
const $io47 = input => Object.keys(input).every(key => {
|
90
101
|
const value = input[key];
|
91
102
|
if (undefined === value)
|
92
103
|
return true;
|
93
|
-
return "object" === typeof value && null !== value && false === Array.isArray(value) && $
|
104
|
+
return "object" === typeof value && null !== value && false === Array.isArray(value) && $io48(value);
|
94
105
|
});
|
95
|
-
const $
|
96
|
-
const $
|
106
|
+
const $io48 = input => (undefined === input.description || "string" === typeof input.description) && (undefined === input.content || "object" === typeof input.content && null !== input.content && false === Array.isArray(input.content) && $io41(input.content)) && (undefined === input["x-nestia-encrypted"] || "boolean" === typeof input["x-nestia-encrypted"]);
|
107
|
+
const $io49 = input => Object.keys(input).every(key => {
|
97
108
|
const value = input[key];
|
98
109
|
if (undefined === value)
|
99
110
|
return true;
|
100
111
|
return Array.isArray(value) && value.every(elem => "string" === typeof elem);
|
101
112
|
});
|
102
|
-
const $
|
103
|
-
const $
|
113
|
+
const $io50 = input => "string" === typeof input.name && (undefined === input.text || Array.isArray(input.text) && input.text.every(elem => "object" === typeof elem && null !== elem && $io51(elem)));
|
114
|
+
const $io51 = input => "string" === typeof input.text && "string" === typeof input.kind;
|
104
115
|
const $iu0 = input => (() => {
|
105
116
|
if ("null" === input.type)
|
106
|
-
return $io8(input);
|
107
|
-
else if (undefined !== input.anyOf)
|
108
117
|
return $io9(input);
|
109
|
-
else if (undefined !== input.
|
118
|
+
else if (undefined !== input.anyOf)
|
110
119
|
return $io10(input);
|
111
|
-
else if (
|
120
|
+
else if (undefined !== input.oneOf)
|
112
121
|
return $io11(input);
|
122
|
+
else if ("boolean" === input.type)
|
123
|
+
return $io12(input);
|
113
124
|
else if ("number" === input.type)
|
114
|
-
return $
|
125
|
+
return $io14(input);
|
115
126
|
else if ("integer" === input.type)
|
116
|
-
return $
|
127
|
+
return $io13(input);
|
117
128
|
else if ("string" === input.type)
|
118
|
-
return $io14(input);
|
119
|
-
else if ("array" === input.type)
|
120
129
|
return $io15(input);
|
121
|
-
else if ("
|
130
|
+
else if ("array" === input.type)
|
122
131
|
return $io16(input);
|
123
|
-
else if (
|
132
|
+
else if ("object" === input.type)
|
124
133
|
return $io17(input);
|
134
|
+
else if (undefined !== input.$ref)
|
135
|
+
return $io19(input);
|
125
136
|
else
|
126
|
-
return $
|
137
|
+
return $io8(input);
|
127
138
|
})();
|
128
139
|
const $iu1 = input => (() => {
|
140
|
+
if (undefined !== input["in"])
|
141
|
+
return $io7(input);
|
142
|
+
else if (undefined !== input.$ref)
|
143
|
+
return $io39(input);
|
144
|
+
else
|
145
|
+
return false;
|
146
|
+
})();
|
147
|
+
const $iu2 = input => (() => {
|
129
148
|
if ("basic" === input.scheme)
|
130
|
-
return $
|
149
|
+
return $io26(input);
|
131
150
|
else if ("bearer" === input.scheme)
|
132
|
-
return $
|
151
|
+
return $io27(input);
|
133
152
|
else if ("apiKey" === input.type)
|
134
|
-
return $
|
153
|
+
return $io28(input);
|
135
154
|
else if ("openIdConnect" === input.type)
|
136
|
-
return $
|
155
|
+
return $io29(input);
|
137
156
|
else if ("oauth2" === input.type)
|
138
|
-
return $
|
157
|
+
return $io30(input);
|
139
158
|
else
|
140
159
|
return false;
|
141
160
|
})();
|
@@ -185,7 +204,7 @@ class MigrateApplication {
|
|
185
204
|
path: _path + ".paths",
|
186
205
|
expected: "Record<string, ISwagger.IPath>",
|
187
206
|
value: input.paths
|
188
|
-
})) && $
|
207
|
+
})) && $vo36(input.paths, _path + ".paths", true && _exceptionable) || $report(_exceptionable, {
|
189
208
|
path: _path + ".paths",
|
190
209
|
expected: "Record<string, ISwagger.IPath>",
|
191
210
|
value: input.paths
|
@@ -197,7 +216,7 @@ class MigrateApplication {
|
|
197
216
|
path: _path + ".security[" + _index2 + "]",
|
198
217
|
expected: "Record<string, Array<string>>",
|
199
218
|
value: elem
|
200
|
-
})) && $
|
219
|
+
})) && $vo49(elem, _path + ".security[" + _index2 + "]", true && _exceptionable) || $report(_exceptionable, {
|
201
220
|
path: _path + ".security[" + _index2 + "]",
|
202
221
|
expected: "Record<string, Array<string>>",
|
203
222
|
value: elem
|
@@ -286,11 +305,27 @@ class MigrateApplication {
|
|
286
305
|
expected: "(string | undefined)",
|
287
306
|
value: input.description
|
288
307
|
})].every(flag => flag);
|
289
|
-
const $vo5 = (input, _path, _exceptionable = true) => [undefined === input.
|
308
|
+
const $vo5 = (input, _path, _exceptionable = true) => [undefined === input.parameters || ("object" === typeof input.parameters && null !== input.parameters && false === Array.isArray(input.parameters) || $report(_exceptionable, {
|
309
|
+
path: _path + ".parameters",
|
310
|
+
expected: "(Record<string, ISwaggerRouteParameter> | undefined)",
|
311
|
+
value: input.parameters
|
312
|
+
})) && $vo6(input.parameters, _path + ".parameters", true && _exceptionable) || $report(_exceptionable, {
|
313
|
+
path: _path + ".parameters",
|
314
|
+
expected: "(Record<string, ISwaggerRouteParameter> | undefined)",
|
315
|
+
value: input.parameters
|
316
|
+
}), undefined === input.responses || ("object" === typeof input.responses && null !== input.responses && false === Array.isArray(input.responses) || $report(_exceptionable, {
|
317
|
+
path: _path + ".responses",
|
318
|
+
expected: "(Record<string, ISwaggerRouteResponse> | undefined)",
|
319
|
+
value: input.responses
|
320
|
+
})) && $vo21(input.responses, _path + ".responses", true && _exceptionable) || $report(_exceptionable, {
|
321
|
+
path: _path + ".responses",
|
322
|
+
expected: "(Record<string, ISwaggerRouteResponse> | undefined)",
|
323
|
+
value: input.responses
|
324
|
+
}), undefined === input.schemas || ("object" === typeof input.schemas && null !== input.schemas && false === Array.isArray(input.schemas) || $report(_exceptionable, {
|
290
325
|
path: _path + ".schemas",
|
291
326
|
expected: "(Record<string, ISwaggerSchema> | undefined)",
|
292
327
|
value: input.schemas
|
293
|
-
})) && $
|
328
|
+
})) && $vo18(input.schemas, _path + ".schemas", true && _exceptionable) || $report(_exceptionable, {
|
294
329
|
path: _path + ".schemas",
|
295
330
|
expected: "(Record<string, ISwaggerSchema> | undefined)",
|
296
331
|
value: input.schemas
|
@@ -298,30 +333,55 @@ class MigrateApplication {
|
|
298
333
|
path: _path + ".securitySchemes",
|
299
334
|
expected: "(Record<string, ISwaggerSecurityScheme> | undefined)",
|
300
335
|
value: input.securitySchemes
|
301
|
-
})) && $
|
336
|
+
})) && $vo25(input.securitySchemes, _path + ".securitySchemes", true && _exceptionable) || $report(_exceptionable, {
|
302
337
|
path: _path + ".securitySchemes",
|
303
338
|
expected: "(Record<string, ISwaggerSecurityScheme> | undefined)",
|
304
339
|
value: input.securitySchemes
|
305
|
-
}), undefined === input
|
306
|
-
path: _path + "
|
340
|
+
}), undefined === input["x-nestia-namespace"] || "string" === typeof input["x-nestia-namespace"] || $report(_exceptionable, {
|
341
|
+
path: _path + "[\"x-nestia-namespace\"]",
|
307
342
|
expected: "(string | undefined)",
|
308
|
-
value: input
|
343
|
+
value: input["x-nestia-namespace"]
|
309
344
|
})].every(flag => flag);
|
310
345
|
const $vo6 = (input, _path, _exceptionable = true) => [false === _exceptionable || Object.keys(input).map(key => {
|
311
346
|
const value = input[key];
|
312
347
|
if (undefined === value)
|
313
348
|
return true;
|
314
|
-
return ("object" === typeof value && null !== value
|
349
|
+
return ("object" === typeof value && null !== value || $report(_exceptionable, {
|
315
350
|
path: _path + $join(key),
|
316
|
-
expected: "
|
351
|
+
expected: "ISwaggerRouteParameter",
|
317
352
|
value: value
|
318
|
-
})) && $
|
353
|
+
})) && $vo7(value, _path + $join(key), true && _exceptionable) || $report(_exceptionable, {
|
319
354
|
path: _path + $join(key),
|
320
|
-
expected: "
|
355
|
+
expected: "ISwaggerRouteParameter",
|
321
356
|
value: value
|
322
357
|
});
|
323
358
|
}).every(flag => flag)].every(flag => flag);
|
324
|
-
const $vo7 = (input, _path, _exceptionable = true) => [
|
359
|
+
const $vo7 = (input, _path, _exceptionable = true) => [undefined === input.name || "string" === typeof input.name || $report(_exceptionable, {
|
360
|
+
path: _path + ".name",
|
361
|
+
expected: "(string | undefined)",
|
362
|
+
value: input.name
|
363
|
+
}), "cookie" === input["in"] || "header" === input["in"] || "path" === input["in"] || "query" === input["in"] || $report(_exceptionable, {
|
364
|
+
path: _path + "[\"in\"]",
|
365
|
+
expected: "(\"cookie\" | \"header\" | \"path\" | \"query\")",
|
366
|
+
value: input["in"]
|
367
|
+
}), ("object" === typeof input.schema && null !== input.schema && false === Array.isArray(input.schema) || $report(_exceptionable, {
|
368
|
+
path: _path + ".schema",
|
369
|
+
expected: "(ISwaggerSchema.IAnyOf | ISwaggerSchema.IArray | ISwaggerSchema.IBoolean | ISwaggerSchema.IInteger | ISwaggerSchema.INullOnly | ISwaggerSchema.INumber | ISwaggerSchema.IObject | ISwaggerSchema.IOneOf | ISwaggerSchema.IReference | ISwaggerSchema.IString | ISwaggerSchema.IUnknown)",
|
370
|
+
value: input.schema
|
371
|
+
})) && $vu0(input.schema, _path + ".schema", true && _exceptionable) || $report(_exceptionable, {
|
372
|
+
path: _path + ".schema",
|
373
|
+
expected: "(ISwaggerSchema.IAnyOf | ISwaggerSchema.IArray | ISwaggerSchema.IBoolean | ISwaggerSchema.IInteger | ISwaggerSchema.INullOnly | ISwaggerSchema.INumber | ISwaggerSchema.IObject | ISwaggerSchema.IOneOf | ISwaggerSchema.IReference | ISwaggerSchema.IString | ISwaggerSchema.IUnknown)",
|
374
|
+
value: input.schema
|
375
|
+
}), undefined === input.required || "boolean" === typeof input.required || $report(_exceptionable, {
|
376
|
+
path: _path + ".required",
|
377
|
+
expected: "(boolean | undefined)",
|
378
|
+
value: input.required
|
379
|
+
}), undefined === input.description || "string" === typeof input.description || $report(_exceptionable, {
|
380
|
+
path: _path + ".description",
|
381
|
+
expected: "(string | undefined)",
|
382
|
+
value: input.description
|
383
|
+
})].every(flag => flag);
|
384
|
+
const $vo8 = (input, _path, _exceptionable = true) => [(null !== input.type || $report(_exceptionable, {
|
325
385
|
path: _path + ".type",
|
326
386
|
expected: "undefined",
|
327
387
|
value: input.type
|
@@ -350,7 +410,7 @@ class MigrateApplication {
|
|
350
410
|
expected: "(boolean | undefined)",
|
351
411
|
value: input["x-typia-rest"]
|
352
412
|
})].every(flag => flag);
|
353
|
-
const $
|
413
|
+
const $vo9 = (input, _path, _exceptionable = true) => ["null" === input.type || $report(_exceptionable, {
|
354
414
|
path: _path + ".type",
|
355
415
|
expected: "\"null\"",
|
356
416
|
value: input.type
|
@@ -375,7 +435,7 @@ class MigrateApplication {
|
|
375
435
|
expected: "(boolean | undefined)",
|
376
436
|
value: input["x-typia-rest"]
|
377
437
|
})].every(flag => flag);
|
378
|
-
const $
|
438
|
+
const $vo10 = (input, _path, _exceptionable = true) => [(Array.isArray(input.anyOf) || $report(_exceptionable, {
|
379
439
|
path: _path + ".anyOf",
|
380
440
|
expected: "Array<ISwaggerSchema>",
|
381
441
|
value: input.anyOf
|
@@ -412,7 +472,7 @@ class MigrateApplication {
|
|
412
472
|
expected: "(boolean | undefined)",
|
413
473
|
value: input["x-typia-rest"]
|
414
474
|
})].every(flag => flag);
|
415
|
-
const $
|
475
|
+
const $vo11 = (input, _path, _exceptionable = true) => [(Array.isArray(input.oneOf) || $report(_exceptionable, {
|
416
476
|
path: _path + ".oneOf",
|
417
477
|
expected: "Array<ISwaggerSchema>",
|
418
478
|
value: input.oneOf
|
@@ -449,7 +509,7 @@ class MigrateApplication {
|
|
449
509
|
expected: "(boolean | undefined)",
|
450
510
|
value: input["x-typia-rest"]
|
451
511
|
})].every(flag => flag);
|
452
|
-
const $
|
512
|
+
const $vo12 = (input, _path, _exceptionable = true) => [undefined === input["default"] || "boolean" === typeof input["default"] || $report(_exceptionable, {
|
453
513
|
path: _path + "[\"default\"]",
|
454
514
|
expected: "(boolean | undefined)",
|
455
515
|
value: input["default"]
|
@@ -494,7 +554,7 @@ class MigrateApplication {
|
|
494
554
|
expected: "(boolean | undefined)",
|
495
555
|
value: input["x-typia-rest"]
|
496
556
|
})].every(flag => flag);
|
497
|
-
const $
|
557
|
+
const $vo13 = (input, _path, _exceptionable = true) => [undefined === input["default"] || "number" === typeof input["default"] && (Math.floor(input["default"]) === input["default"] && -2147483648 <= input["default"] && input["default"] <= 2147483647 || $report(_exceptionable, {
|
498
558
|
path: _path + "[\"default\"]",
|
499
559
|
expected: "number & Type<\"int32\">",
|
500
560
|
value: input["default"]
|
@@ -575,7 +635,7 @@ class MigrateApplication {
|
|
575
635
|
expected: "(boolean | undefined)",
|
576
636
|
value: input["x-typia-rest"]
|
577
637
|
})].every(flag => flag);
|
578
|
-
const $
|
638
|
+
const $vo14 = (input, _path, _exceptionable = true) => [undefined === input["default"] || "number" === typeof input["default"] || $report(_exceptionable, {
|
579
639
|
path: _path + "[\"default\"]",
|
580
640
|
expected: "(number | undefined)",
|
581
641
|
value: input["default"]
|
@@ -640,7 +700,7 @@ class MigrateApplication {
|
|
640
700
|
expected: "(boolean | undefined)",
|
641
701
|
value: input["x-typia-rest"]
|
642
702
|
})].every(flag => flag);
|
643
|
-
const $
|
703
|
+
const $vo15 = (input, _path, _exceptionable = true) => [undefined === input["default"] || "string" === typeof input["default"] || $report(_exceptionable, {
|
644
704
|
path: _path + "[\"default\"]",
|
645
705
|
expected: "(string | undefined)",
|
646
706
|
value: input["default"]
|
@@ -709,7 +769,7 @@ class MigrateApplication {
|
|
709
769
|
expected: "(boolean | undefined)",
|
710
770
|
value: input["x-typia-rest"]
|
711
771
|
})].every(flag => flag);
|
712
|
-
const $
|
772
|
+
const $vo16 = (input, _path, _exceptionable = true) => [("object" === typeof input.items && null !== input.items && false === Array.isArray(input.items) || $report(_exceptionable, {
|
713
773
|
path: _path + ".items",
|
714
774
|
expected: "(ISwaggerSchema.IAnyOf | ISwaggerSchema.IArray | ISwaggerSchema.IBoolean | ISwaggerSchema.IInteger | ISwaggerSchema.INullOnly | ISwaggerSchema.INumber | ISwaggerSchema.IObject | ISwaggerSchema.IOneOf | ISwaggerSchema.IReference | ISwaggerSchema.IString | ISwaggerSchema.IUnknown)",
|
715
775
|
value: input.items
|
@@ -737,7 +797,7 @@ class MigrateApplication {
|
|
737
797
|
path: _path + "[\"x-typia-tuple\"]",
|
738
798
|
expected: "(ISwaggerSchema.ITuple | undefined)",
|
739
799
|
value: input["x-typia-tuple"]
|
740
|
-
})) && $
|
800
|
+
})) && $vo20(input["x-typia-tuple"], _path + "[\"x-typia-tuple\"]", true && _exceptionable) || $report(_exceptionable, {
|
741
801
|
path: _path + "[\"x-typia-tuple\"]",
|
742
802
|
expected: "(ISwaggerSchema.ITuple | undefined)",
|
743
803
|
value: input["x-typia-tuple"]
|
@@ -770,11 +830,11 @@ class MigrateApplication {
|
|
770
830
|
expected: "(boolean | undefined)",
|
771
831
|
value: input["x-typia-rest"]
|
772
832
|
})].every(flag => flag);
|
773
|
-
const $
|
833
|
+
const $vo17 = (input, _path, _exceptionable = true) => [undefined === input.properties || ("object" === typeof input.properties && null !== input.properties && false === Array.isArray(input.properties) || $report(_exceptionable, {
|
774
834
|
path: _path + ".properties",
|
775
835
|
expected: "(Record<string, ISwaggerSchema> | undefined)",
|
776
836
|
value: input.properties
|
777
|
-
})) && $
|
837
|
+
})) && $vo18(input.properties, _path + ".properties", true && _exceptionable) || $report(_exceptionable, {
|
778
838
|
path: _path + ".properties",
|
779
839
|
expected: "(Record<string, ISwaggerSchema> | undefined)",
|
780
840
|
value: input.properties
|
@@ -806,7 +866,7 @@ class MigrateApplication {
|
|
806
866
|
path: _path + "[\"x-typia-patternProperties\"]",
|
807
867
|
expected: "(Record<string, ISwaggerSchema> | undefined)",
|
808
868
|
value: input["x-typia-patternProperties"]
|
809
|
-
})) && $
|
869
|
+
})) && $vo18(input["x-typia-patternProperties"], _path + "[\"x-typia-patternProperties\"]", true && _exceptionable) || $report(_exceptionable, {
|
810
870
|
path: _path + "[\"x-typia-patternProperties\"]",
|
811
871
|
expected: "(Record<string, ISwaggerSchema> | undefined)",
|
812
872
|
value: input["x-typia-patternProperties"]
|
@@ -839,7 +899,21 @@ class MigrateApplication {
|
|
839
899
|
expected: "(boolean | undefined)",
|
840
900
|
value: input["x-typia-rest"]
|
841
901
|
})].every(flag => flag);
|
842
|
-
const $
|
902
|
+
const $vo18 = (input, _path, _exceptionable = true) => [false === _exceptionable || Object.keys(input).map(key => {
|
903
|
+
const value = input[key];
|
904
|
+
if (undefined === value)
|
905
|
+
return true;
|
906
|
+
return ("object" === typeof value && null !== value && false === Array.isArray(value) || $report(_exceptionable, {
|
907
|
+
path: _path + $join(key),
|
908
|
+
expected: "(ISwaggerSchema.IAnyOf | ISwaggerSchema.IArray | ISwaggerSchema.IBoolean | ISwaggerSchema.IInteger | ISwaggerSchema.INullOnly | ISwaggerSchema.INumber | ISwaggerSchema.IObject | ISwaggerSchema.IOneOf | ISwaggerSchema.IReference | ISwaggerSchema.IString | ISwaggerSchema.IUnknown)",
|
909
|
+
value: value
|
910
|
+
})) && $vu0(value, _path + $join(key), true && _exceptionable) || $report(_exceptionable, {
|
911
|
+
path: _path + $join(key),
|
912
|
+
expected: "(ISwaggerSchema.IAnyOf | ISwaggerSchema.IArray | ISwaggerSchema.IBoolean | ISwaggerSchema.IInteger | ISwaggerSchema.INullOnly | ISwaggerSchema.INumber | ISwaggerSchema.IObject | ISwaggerSchema.IOneOf | ISwaggerSchema.IReference | ISwaggerSchema.IString | ISwaggerSchema.IUnknown)",
|
913
|
+
value: value
|
914
|
+
});
|
915
|
+
}).every(flag => flag)].every(flag => flag);
|
916
|
+
const $vo19 = (input, _path, _exceptionable = true) => ["string" === typeof input.$ref || $report(_exceptionable, {
|
843
917
|
path: _path + ".$ref",
|
844
918
|
expected: "string",
|
845
919
|
value: input.$ref
|
@@ -864,7 +938,7 @@ class MigrateApplication {
|
|
864
938
|
expected: "(boolean | undefined)",
|
865
939
|
value: input["x-typia-rest"]
|
866
940
|
})].every(flag => flag);
|
867
|
-
const $
|
941
|
+
const $vo20 = (input, _path, _exceptionable = true) => [(Array.isArray(input.items) || $report(_exceptionable, {
|
868
942
|
path: _path + ".items",
|
869
943
|
expected: "Array<ISwaggerSchema>",
|
870
944
|
value: input.items
|
@@ -909,7 +983,84 @@ class MigrateApplication {
|
|
909
983
|
expected: "(boolean | undefined)",
|
910
984
|
value: input["x-typia-rest"]
|
911
985
|
})].every(flag => flag);
|
912
|
-
const $
|
986
|
+
const $vo21 = (input, _path, _exceptionable = true) => [false === _exceptionable || Object.keys(input).map(key => {
|
987
|
+
const value = input[key];
|
988
|
+
if (undefined === value)
|
989
|
+
return true;
|
990
|
+
return ("object" === typeof value && null !== value && false === Array.isArray(value) || $report(_exceptionable, {
|
991
|
+
path: _path + $join(key),
|
992
|
+
expected: "ISwaggerRouteResponse",
|
993
|
+
value: value
|
994
|
+
})) && $vo22(value, _path + $join(key), true && _exceptionable) || $report(_exceptionable, {
|
995
|
+
path: _path + $join(key),
|
996
|
+
expected: "ISwaggerRouteResponse",
|
997
|
+
value: value
|
998
|
+
});
|
999
|
+
}).every(flag => flag)].every(flag => flag);
|
1000
|
+
const $vo22 = (input, _path, _exceptionable = true) => [undefined === input.description || "string" === typeof input.description || $report(_exceptionable, {
|
1001
|
+
path: _path + ".description",
|
1002
|
+
expected: "(string | undefined)",
|
1003
|
+
value: input.description
|
1004
|
+
}), undefined === input.content || ("object" === typeof input.content && null !== input.content && false === Array.isArray(input.content) || $report(_exceptionable, {
|
1005
|
+
path: _path + ".content",
|
1006
|
+
expected: "(ISwaggerRouteBodyContent | undefined)",
|
1007
|
+
value: input.content
|
1008
|
+
})) && $vo23(input.content, _path + ".content", true && _exceptionable) || $report(_exceptionable, {
|
1009
|
+
path: _path + ".content",
|
1010
|
+
expected: "(ISwaggerRouteBodyContent | undefined)",
|
1011
|
+
value: input.content
|
1012
|
+
})].every(flag => flag);
|
1013
|
+
const $vo23 = (input, _path, _exceptionable = true) => [undefined === input["text/plain"] || ("object" === typeof input["text/plain"] && null !== input["text/plain"] && false === Array.isArray(input["text/plain"]) || $report(_exceptionable, {
|
1014
|
+
path: _path + "[\"text/plain\"]",
|
1015
|
+
expected: "(ISwaggerRouteBodyContent.IMediaType | undefined)",
|
1016
|
+
value: input["text/plain"]
|
1017
|
+
})) && $vo24(input["text/plain"], _path + "[\"text/plain\"]", true && _exceptionable) || $report(_exceptionable, {
|
1018
|
+
path: _path + "[\"text/plain\"]",
|
1019
|
+
expected: "(ISwaggerRouteBodyContent.IMediaType | undefined)",
|
1020
|
+
value: input["text/plain"]
|
1021
|
+
}), undefined === input["application/json"] || ("object" === typeof input["application/json"] && null !== input["application/json"] && false === Array.isArray(input["application/json"]) || $report(_exceptionable, {
|
1022
|
+
path: _path + "[\"application/json\"]",
|
1023
|
+
expected: "(ISwaggerRouteBodyContent.IMediaType | undefined)",
|
1024
|
+
value: input["application/json"]
|
1025
|
+
})) && $vo24(input["application/json"], _path + "[\"application/json\"]", true && _exceptionable) || $report(_exceptionable, {
|
1026
|
+
path: _path + "[\"application/json\"]",
|
1027
|
+
expected: "(ISwaggerRouteBodyContent.IMediaType | undefined)",
|
1028
|
+
value: input["application/json"]
|
1029
|
+
}), undefined === input["application/x-www-form-urlencoded"] || ("object" === typeof input["application/x-www-form-urlencoded"] && null !== input["application/x-www-form-urlencoded"] && false === Array.isArray(input["application/x-www-form-urlencoded"]) || $report(_exceptionable, {
|
1030
|
+
path: _path + "[\"application/x-www-form-urlencoded\"]",
|
1031
|
+
expected: "(ISwaggerRouteBodyContent.IMediaType | undefined)",
|
1032
|
+
value: input["application/x-www-form-urlencoded"]
|
1033
|
+
})) && $vo24(input["application/x-www-form-urlencoded"], _path + "[\"application/x-www-form-urlencoded\"]", true && _exceptionable) || $report(_exceptionable, {
|
1034
|
+
path: _path + "[\"application/x-www-form-urlencoded\"]",
|
1035
|
+
expected: "(ISwaggerRouteBodyContent.IMediaType | undefined)",
|
1036
|
+
value: input["application/x-www-form-urlencoded"]
|
1037
|
+
}), undefined === input["multipart/form-data"] || ("object" === typeof input["multipart/form-data"] && null !== input["multipart/form-data"] && false === Array.isArray(input["multipart/form-data"]) || $report(_exceptionable, {
|
1038
|
+
path: _path + "[\"multipart/form-data\"]",
|
1039
|
+
expected: "(ISwaggerRouteBodyContent.IMediaType | undefined)",
|
1040
|
+
value: input["multipart/form-data"]
|
1041
|
+
})) && $vo24(input["multipart/form-data"], _path + "[\"multipart/form-data\"]", true && _exceptionable) || $report(_exceptionable, {
|
1042
|
+
path: _path + "[\"multipart/form-data\"]",
|
1043
|
+
expected: "(ISwaggerRouteBodyContent.IMediaType | undefined)",
|
1044
|
+
value: input["multipart/form-data"]
|
1045
|
+
}), undefined === input["*/*"] || ("object" === typeof input["*/*"] && null !== input["*/*"] && false === Array.isArray(input["*/*"]) || $report(_exceptionable, {
|
1046
|
+
path: _path + "[\"*/*\"]",
|
1047
|
+
expected: "(ISwaggerRouteBodyContent.IMediaType | undefined)",
|
1048
|
+
value: input["*/*"]
|
1049
|
+
})) && $vo24(input["*/*"], _path + "[\"*/*\"]", true && _exceptionable) || $report(_exceptionable, {
|
1050
|
+
path: _path + "[\"*/*\"]",
|
1051
|
+
expected: "(ISwaggerRouteBodyContent.IMediaType | undefined)",
|
1052
|
+
value: input["*/*"]
|
1053
|
+
})].every(flag => flag);
|
1054
|
+
const $vo24 = (input, _path, _exceptionable = true) => [undefined === input.schema || ("object" === typeof input.schema && null !== input.schema && false === Array.isArray(input.schema) || $report(_exceptionable, {
|
1055
|
+
path: _path + ".schema",
|
1056
|
+
expected: "(ISwaggerSchema.IAnyOf | ISwaggerSchema.IArray | ISwaggerSchema.IBoolean | ISwaggerSchema.IInteger | ISwaggerSchema.INullOnly | ISwaggerSchema.INumber | ISwaggerSchema.IObject | ISwaggerSchema.IOneOf | ISwaggerSchema.IReference | ISwaggerSchema.IString | ISwaggerSchema.IUnknown | undefined)",
|
1057
|
+
value: input.schema
|
1058
|
+
})) && $vu0(input.schema, _path + ".schema", true && _exceptionable) || $report(_exceptionable, {
|
1059
|
+
path: _path + ".schema",
|
1060
|
+
expected: "(ISwaggerSchema.IAnyOf | ISwaggerSchema.IArray | ISwaggerSchema.IBoolean | ISwaggerSchema.IInteger | ISwaggerSchema.INullOnly | ISwaggerSchema.INumber | ISwaggerSchema.IObject | ISwaggerSchema.IOneOf | ISwaggerSchema.IReference | ISwaggerSchema.IString | ISwaggerSchema.IUnknown | undefined)",
|
1061
|
+
value: input.schema
|
1062
|
+
})].every(flag => flag);
|
1063
|
+
const $vo25 = (input, _path, _exceptionable = true) => [false === _exceptionable || Object.keys(input).map(key => {
|
913
1064
|
const value = input[key];
|
914
1065
|
if (undefined === value)
|
915
1066
|
return true;
|
@@ -917,13 +1068,13 @@ class MigrateApplication {
|
|
917
1068
|
path: _path + $join(key),
|
918
1069
|
expected: "(ISwaggerSecurityScheme.IApiKey | ISwaggerSecurityScheme.IHttpBasic | ISwaggerSecurityScheme.IHttpBearer | ISwaggerSecurityScheme.IOAuth2 | ISwaggerSecurityScheme.IOpenId)",
|
919
1070
|
value: value
|
920
|
-
})) && $
|
1071
|
+
})) && $vu2(value, _path + $join(key), true && _exceptionable) || $report(_exceptionable, {
|
921
1072
|
path: _path + $join(key),
|
922
1073
|
expected: "(ISwaggerSecurityScheme.IApiKey | ISwaggerSecurityScheme.IHttpBasic | ISwaggerSecurityScheme.IHttpBearer | ISwaggerSecurityScheme.IOAuth2 | ISwaggerSecurityScheme.IOpenId)",
|
923
1074
|
value: value
|
924
1075
|
});
|
925
1076
|
}).every(flag => flag)].every(flag => flag);
|
926
|
-
const $
|
1077
|
+
const $vo26 = (input, _path, _exceptionable = true) => ["http" === input.type || $report(_exceptionable, {
|
927
1078
|
path: _path + ".type",
|
928
1079
|
expected: "\"http\"",
|
929
1080
|
value: input.type
|
@@ -932,7 +1083,7 @@ class MigrateApplication {
|
|
932
1083
|
expected: "\"basic\"",
|
933
1084
|
value: input.scheme
|
934
1085
|
})].every(flag => flag);
|
935
|
-
const $
|
1086
|
+
const $vo27 = (input, _path, _exceptionable = true) => ["http" === input.type || $report(_exceptionable, {
|
936
1087
|
path: _path + ".type",
|
937
1088
|
expected: "\"http\"",
|
938
1089
|
value: input.type
|
@@ -945,11 +1096,11 @@ class MigrateApplication {
|
|
945
1096
|
expected: "(string | undefined)",
|
946
1097
|
value: input.bearerFormat
|
947
1098
|
})].every(flag => flag);
|
948
|
-
const $
|
1099
|
+
const $vo28 = (input, _path, _exceptionable = true) => ["apiKey" === input.type || $report(_exceptionable, {
|
949
1100
|
path: _path + ".type",
|
950
1101
|
expected: "\"apiKey\"",
|
951
1102
|
value: input.type
|
952
|
-
}), undefined === input["in"] || "
|
1103
|
+
}), undefined === input["in"] || "cookie" === input["in"] || "header" === input["in"] || "query" === input["in"] || $report(_exceptionable, {
|
953
1104
|
path: _path + "[\"in\"]",
|
954
1105
|
expected: "(\"cookie\" | \"header\" | \"query\" | undefined)",
|
955
1106
|
value: input["in"]
|
@@ -958,7 +1109,7 @@ class MigrateApplication {
|
|
958
1109
|
expected: "(string | undefined)",
|
959
1110
|
value: input.name
|
960
1111
|
})].every(flag => flag);
|
961
|
-
const $
|
1112
|
+
const $vo29 = (input, _path, _exceptionable = true) => ["openIdConnect" === input.type || $report(_exceptionable, {
|
962
1113
|
path: _path + ".type",
|
963
1114
|
expected: "\"openIdConnect\"",
|
964
1115
|
value: input.type
|
@@ -967,7 +1118,7 @@ class MigrateApplication {
|
|
967
1118
|
expected: "string",
|
968
1119
|
value: input.openIdConnectUrl
|
969
1120
|
})].every(flag => flag);
|
970
|
-
const $
|
1121
|
+
const $vo30 = (input, _path, _exceptionable = true) => ["oauth2" === input.type || $report(_exceptionable, {
|
971
1122
|
path: _path + ".type",
|
972
1123
|
expected: "\"oauth2\"",
|
973
1124
|
value: input.type
|
@@ -975,7 +1126,7 @@ class MigrateApplication {
|
|
975
1126
|
path: _path + ".flows",
|
976
1127
|
expected: "ISwaggerSecurityScheme.IOAuth2.IFlowSet",
|
977
1128
|
value: input.flows
|
978
|
-
})) && $
|
1129
|
+
})) && $vo31(input.flows, _path + ".flows", true && _exceptionable) || $report(_exceptionable, {
|
979
1130
|
path: _path + ".flows",
|
980
1131
|
expected: "ISwaggerSecurityScheme.IOAuth2.IFlowSet",
|
981
1132
|
value: input.flows
|
@@ -984,11 +1135,11 @@ class MigrateApplication {
|
|
984
1135
|
expected: "(string | undefined)",
|
985
1136
|
value: input.description
|
986
1137
|
})].every(flag => flag);
|
987
|
-
const $
|
1138
|
+
const $vo31 = (input, _path, _exceptionable = true) => [undefined === input.authorizationCode || ("object" === typeof input.authorizationCode && null !== input.authorizationCode || $report(_exceptionable, {
|
988
1139
|
path: _path + ".authorizationCode",
|
989
1140
|
expected: "(ISwaggerSecurityScheme.IOAuth2.IFlow | undefined)",
|
990
1141
|
value: input.authorizationCode
|
991
|
-
})) && $
|
1142
|
+
})) && $vo32(input.authorizationCode, _path + ".authorizationCode", true && _exceptionable) || $report(_exceptionable, {
|
992
1143
|
path: _path + ".authorizationCode",
|
993
1144
|
expected: "(ISwaggerSecurityScheme.IOAuth2.IFlow | undefined)",
|
994
1145
|
value: input.authorizationCode
|
@@ -996,7 +1147,7 @@ class MigrateApplication {
|
|
996
1147
|
path: _path + ".implicit",
|
997
1148
|
expected: "(Omit<ISwaggerSecurityScheme.IOAuth2.IFlow, \"tokenUrl\"> | undefined)",
|
998
1149
|
value: input.implicit
|
999
|
-
})) && $
|
1150
|
+
})) && $vo34(input.implicit, _path + ".implicit", true && _exceptionable) || $report(_exceptionable, {
|
1000
1151
|
path: _path + ".implicit",
|
1001
1152
|
expected: "(Omit<ISwaggerSecurityScheme.IOAuth2.IFlow, \"tokenUrl\"> | undefined)",
|
1002
1153
|
value: input.implicit
|
@@ -1004,7 +1155,7 @@ class MigrateApplication {
|
|
1004
1155
|
path: _path + ".password",
|
1005
1156
|
expected: "(Omit<ISwaggerSecurityScheme.IOAuth2.IFlow, \"authorizationUrl\"> | undefined)",
|
1006
1157
|
value: input.password
|
1007
|
-
})) && $
|
1158
|
+
})) && $vo35(input.password, _path + ".password", true && _exceptionable) || $report(_exceptionable, {
|
1008
1159
|
path: _path + ".password",
|
1009
1160
|
expected: "(Omit<ISwaggerSecurityScheme.IOAuth2.IFlow, \"authorizationUrl\"> | undefined)",
|
1010
1161
|
value: input.password
|
@@ -1012,12 +1163,12 @@ class MigrateApplication {
|
|
1012
1163
|
path: _path + ".clientCredentials",
|
1013
1164
|
expected: "(Omit<ISwaggerSecurityScheme.IOAuth2.IFlow, \"authorizationUrl\"> | undefined)",
|
1014
1165
|
value: input.clientCredentials
|
1015
|
-
})) && $
|
1166
|
+
})) && $vo35(input.clientCredentials, _path + ".clientCredentials", true && _exceptionable) || $report(_exceptionable, {
|
1016
1167
|
path: _path + ".clientCredentials",
|
1017
1168
|
expected: "(Omit<ISwaggerSecurityScheme.IOAuth2.IFlow, \"authorizationUrl\"> | undefined)",
|
1018
1169
|
value: input.clientCredentials
|
1019
1170
|
})].every(flag => flag);
|
1020
|
-
const $
|
1171
|
+
const $vo32 = (input, _path, _exceptionable = true) => ["string" === typeof input.authorizationUrl || $report(_exceptionable, {
|
1021
1172
|
path: _path + ".authorizationUrl",
|
1022
1173
|
expected: "string",
|
1023
1174
|
value: input.authorizationUrl
|
@@ -1033,12 +1184,12 @@ class MigrateApplication {
|
|
1033
1184
|
path: _path + ".scopes",
|
1034
1185
|
expected: "(Record<string, string> | undefined)",
|
1035
1186
|
value: input.scopes
|
1036
|
-
})) && $
|
1187
|
+
})) && $vo33(input.scopes, _path + ".scopes", true && _exceptionable) || $report(_exceptionable, {
|
1037
1188
|
path: _path + ".scopes",
|
1038
1189
|
expected: "(Record<string, string> | undefined)",
|
1039
1190
|
value: input.scopes
|
1040
1191
|
})].every(flag => flag);
|
1041
|
-
const $
|
1192
|
+
const $vo33 = (input, _path, _exceptionable = true) => [false === _exceptionable || Object.keys(input).map(key => {
|
1042
1193
|
const value = input[key];
|
1043
1194
|
if (undefined === value)
|
1044
1195
|
return true;
|
@@ -1048,7 +1199,7 @@ class MigrateApplication {
|
|
1048
1199
|
value: value
|
1049
1200
|
});
|
1050
1201
|
}).every(flag => flag)].every(flag => flag);
|
1051
|
-
const $
|
1202
|
+
const $vo34 = (input, _path, _exceptionable = true) => ["string" === typeof input.authorizationUrl || $report(_exceptionable, {
|
1052
1203
|
path: _path + ".authorizationUrl",
|
1053
1204
|
expected: "string",
|
1054
1205
|
value: input.authorizationUrl
|
@@ -1060,12 +1211,12 @@ class MigrateApplication {
|
|
1060
1211
|
path: _path + ".scopes",
|
1061
1212
|
expected: "(Record<string, string> | undefined)",
|
1062
1213
|
value: input.scopes
|
1063
|
-
})) && $
|
1214
|
+
})) && $vo33(input.scopes, _path + ".scopes", true && _exceptionable) || $report(_exceptionable, {
|
1064
1215
|
path: _path + ".scopes",
|
1065
1216
|
expected: "(Record<string, string> | undefined)",
|
1066
1217
|
value: input.scopes
|
1067
1218
|
})].every(flag => flag);
|
1068
|
-
const $
|
1219
|
+
const $vo35 = (input, _path, _exceptionable = true) => [undefined === input.tokenUrl || "string" === typeof input.tokenUrl || $report(_exceptionable, {
|
1069
1220
|
path: _path + ".tokenUrl",
|
1070
1221
|
expected: "(string | undefined)",
|
1071
1222
|
value: input.tokenUrl
|
@@ -1077,12 +1228,12 @@ class MigrateApplication {
|
|
1077
1228
|
path: _path + ".scopes",
|
1078
1229
|
expected: "(Record<string, string> | undefined)",
|
1079
1230
|
value: input.scopes
|
1080
|
-
})) && $
|
1231
|
+
})) && $vo33(input.scopes, _path + ".scopes", true && _exceptionable) || $report(_exceptionable, {
|
1081
1232
|
path: _path + ".scopes",
|
1082
1233
|
expected: "(Record<string, string> | undefined)",
|
1083
1234
|
value: input.scopes
|
1084
1235
|
})].every(flag => flag);
|
1085
|
-
const $
|
1236
|
+
const $vo36 = (input, _path, _exceptionable = true) => [false === _exceptionable || Object.keys(input).map(key => {
|
1086
1237
|
const value = input[key];
|
1087
1238
|
if (undefined === value)
|
1088
1239
|
return true;
|
@@ -1090,47 +1241,74 @@ class MigrateApplication {
|
|
1090
1241
|
path: _path + $join(key),
|
1091
1242
|
expected: "ISwagger.IPath",
|
1092
1243
|
value: value
|
1093
|
-
})) && $
|
1244
|
+
})) && $vo37(value, _path + $join(key), true && _exceptionable) || $report(_exceptionable, {
|
1094
1245
|
path: _path + $join(key),
|
1095
1246
|
expected: "ISwagger.IPath",
|
1096
1247
|
value: value
|
1097
1248
|
});
|
1098
1249
|
}).every(flag => flag)].every(flag => flag);
|
1099
|
-
const $
|
1100
|
-
|
1101
|
-
|
1102
|
-
|
1103
|
-
|
1104
|
-
|
1105
|
-
|
1106
|
-
|
1107
|
-
|
1108
|
-
|
1109
|
-
|
1110
|
-
|
1111
|
-
|
1112
|
-
|
1113
|
-
|
1250
|
+
const $vo37 = (input, _path, _exceptionable = true) => [undefined === input.get || ("object" === typeof input.get && null !== input.get && false === Array.isArray(input.get) || $report(_exceptionable, {
|
1251
|
+
path: _path + ".get",
|
1252
|
+
expected: "(ISwaggerRoute | undefined)",
|
1253
|
+
value: input.get
|
1254
|
+
})) && $vo38(input.get, _path + ".get", true && _exceptionable) || $report(_exceptionable, {
|
1255
|
+
path: _path + ".get",
|
1256
|
+
expected: "(ISwaggerRoute | undefined)",
|
1257
|
+
value: input.get
|
1258
|
+
}), undefined === input.post || ("object" === typeof input.post && null !== input.post && false === Array.isArray(input.post) || $report(_exceptionable, {
|
1259
|
+
path: _path + ".post",
|
1260
|
+
expected: "(ISwaggerRoute | undefined)",
|
1261
|
+
value: input.post
|
1262
|
+
})) && $vo38(input.post, _path + ".post", true && _exceptionable) || $report(_exceptionable, {
|
1263
|
+
path: _path + ".post",
|
1264
|
+
expected: "(ISwaggerRoute | undefined)",
|
1265
|
+
value: input.post
|
1266
|
+
}), undefined === input.patch || ("object" === typeof input.patch && null !== input.patch && false === Array.isArray(input.patch) || $report(_exceptionable, {
|
1267
|
+
path: _path + ".patch",
|
1268
|
+
expected: "(ISwaggerRoute | undefined)",
|
1269
|
+
value: input.patch
|
1270
|
+
})) && $vo38(input.patch, _path + ".patch", true && _exceptionable) || $report(_exceptionable, {
|
1271
|
+
path: _path + ".patch",
|
1272
|
+
expected: "(ISwaggerRoute | undefined)",
|
1273
|
+
value: input.patch
|
1274
|
+
}), undefined === input.put || ("object" === typeof input.put && null !== input.put && false === Array.isArray(input.put) || $report(_exceptionable, {
|
1275
|
+
path: _path + ".put",
|
1276
|
+
expected: "(ISwaggerRoute | undefined)",
|
1277
|
+
value: input.put
|
1278
|
+
})) && $vo38(input.put, _path + ".put", true && _exceptionable) || $report(_exceptionable, {
|
1279
|
+
path: _path + ".put",
|
1280
|
+
expected: "(ISwaggerRoute | undefined)",
|
1281
|
+
value: input.put
|
1282
|
+
}), undefined === input["delete"] || ("object" === typeof input["delete"] && null !== input["delete"] && false === Array.isArray(input["delete"]) || $report(_exceptionable, {
|
1283
|
+
path: _path + "[\"delete\"]",
|
1284
|
+
expected: "(ISwaggerRoute | undefined)",
|
1285
|
+
value: input["delete"]
|
1286
|
+
})) && $vo38(input["delete"], _path + "[\"delete\"]", true && _exceptionable) || $report(_exceptionable, {
|
1287
|
+
path: _path + "[\"delete\"]",
|
1288
|
+
expected: "(ISwaggerRoute | undefined)",
|
1289
|
+
value: input["delete"]
|
1290
|
+
})].every(flag => flag);
|
1291
|
+
const $vo38 = (input, _path, _exceptionable = true) => [undefined === input.parameters || (Array.isArray(input.parameters) || $report(_exceptionable, {
|
1114
1292
|
path: _path + ".parameters",
|
1115
|
-
expected: "(Array<
|
1293
|
+
expected: "(Array<ISwaggerRouteParameter | IReference> | undefined)",
|
1116
1294
|
value: input.parameters
|
1117
1295
|
})) && input.parameters.map((elem, _index11) => ("object" === typeof elem && null !== elem || $report(_exceptionable, {
|
1118
1296
|
path: _path + ".parameters[" + _index11 + "]",
|
1119
|
-
expected: "
|
1297
|
+
expected: "(ISwaggerRouteParameter | ISwaggerRouteParameter.IReference)",
|
1120
1298
|
value: elem
|
1121
|
-
})) && $
|
1299
|
+
})) && $vu1(elem, _path + ".parameters[" + _index11 + "]", true && _exceptionable) || $report(_exceptionable, {
|
1122
1300
|
path: _path + ".parameters[" + _index11 + "]",
|
1123
|
-
expected: "
|
1301
|
+
expected: "(ISwaggerRouteParameter | ISwaggerRouteParameter.IReference)",
|
1124
1302
|
value: elem
|
1125
1303
|
})).every(flag => flag) || $report(_exceptionable, {
|
1126
1304
|
path: _path + ".parameters",
|
1127
|
-
expected: "(Array<
|
1305
|
+
expected: "(Array<ISwaggerRouteParameter | IReference> | undefined)",
|
1128
1306
|
value: input.parameters
|
1129
1307
|
}), undefined === input.requestBody || ("object" === typeof input.requestBody && null !== input.requestBody || $report(_exceptionable, {
|
1130
1308
|
path: _path + ".requestBody",
|
1131
1309
|
expected: "(ISwaggerRoute.IRequestBody | undefined)",
|
1132
1310
|
value: input.requestBody
|
1133
|
-
})) && $
|
1311
|
+
})) && $vo40(input.requestBody, _path + ".requestBody", true && _exceptionable) || $report(_exceptionable, {
|
1134
1312
|
path: _path + ".requestBody",
|
1135
1313
|
expected: "(ISwaggerRoute.IRequestBody | undefined)",
|
1136
1314
|
value: input.requestBody
|
@@ -1138,7 +1316,7 @@ class MigrateApplication {
|
|
1138
1316
|
path: _path + ".responses",
|
1139
1317
|
expected: "(ISwaggerRoute.IResponseBody | undefined)",
|
1140
1318
|
value: input.responses
|
1141
|
-
})) && $
|
1319
|
+
})) && $vo47(input.responses, _path + ".responses", true && _exceptionable) || $report(_exceptionable, {
|
1142
1320
|
path: _path + ".responses",
|
1143
1321
|
expected: "(ISwaggerRoute.IResponseBody | undefined)",
|
1144
1322
|
value: input.responses
|
@@ -1162,7 +1340,7 @@ class MigrateApplication {
|
|
1162
1340
|
path: _path + ".security[" + _index12 + "]",
|
1163
1341
|
expected: "Record<string, Array<string>>",
|
1164
1342
|
value: elem
|
1165
|
-
})) && $
|
1343
|
+
})) && $vo49(elem, _path + ".security[" + _index12 + "]", true && _exceptionable) || $report(_exceptionable, {
|
1166
1344
|
path: _path + ".security[" + _index12 + "]",
|
1167
1345
|
expected: "Record<string, Array<string>>",
|
1168
1346
|
value: elem
|
@@ -1190,7 +1368,7 @@ class MigrateApplication {
|
|
1190
1368
|
path: _path + "[\"x-nestia-jsDocTags\"][" + _index14 + "]",
|
1191
1369
|
expected: "IJsDocTagInfo",
|
1192
1370
|
value: elem
|
1193
|
-
})) && $
|
1371
|
+
})) && $vo50(elem, _path + "[\"x-nestia-jsDocTags\"][" + _index14 + "]", true && _exceptionable) || $report(_exceptionable, {
|
1194
1372
|
path: _path + "[\"x-nestia-jsDocTags\"][" + _index14 + "]",
|
1195
1373
|
expected: "IJsDocTagInfo",
|
1196
1374
|
value: elem
|
@@ -1199,32 +1377,12 @@ class MigrateApplication {
|
|
1199
1377
|
expected: "(Array<IJsDocTagInfo> | undefined)",
|
1200
1378
|
value: input["x-nestia-jsDocTags"]
|
1201
1379
|
})].every(flag => flag);
|
1202
|
-
const $
|
1203
|
-
path: _path + "
|
1204
|
-
expected: "
|
1205
|
-
value: input
|
1206
|
-
}), "header" === input["in"] || "query" === input["in"] || "cookie" === input["in"] || "path" === input["in"] || $report(_exceptionable, {
|
1207
|
-
path: _path + "[\"in\"]",
|
1208
|
-
expected: "(\"cookie\" | \"header\" | \"path\" | \"query\")",
|
1209
|
-
value: input["in"]
|
1210
|
-
}), ("object" === typeof input.schema && null !== input.schema && false === Array.isArray(input.schema) || $report(_exceptionable, {
|
1211
|
-
path: _path + ".schema",
|
1212
|
-
expected: "(ISwaggerSchema.IAnyOf | ISwaggerSchema.IArray | ISwaggerSchema.IBoolean | ISwaggerSchema.IInteger | ISwaggerSchema.INullOnly | ISwaggerSchema.INumber | ISwaggerSchema.IObject | ISwaggerSchema.IOneOf | ISwaggerSchema.IReference | ISwaggerSchema.IString | ISwaggerSchema.IUnknown)",
|
1213
|
-
value: input.schema
|
1214
|
-
})) && $vu0(input.schema, _path + ".schema", true && _exceptionable) || $report(_exceptionable, {
|
1215
|
-
path: _path + ".schema",
|
1216
|
-
expected: "(ISwaggerSchema.IAnyOf | ISwaggerSchema.IArray | ISwaggerSchema.IBoolean | ISwaggerSchema.IInteger | ISwaggerSchema.INullOnly | ISwaggerSchema.INumber | ISwaggerSchema.IObject | ISwaggerSchema.IOneOf | ISwaggerSchema.IReference | ISwaggerSchema.IString | ISwaggerSchema.IUnknown)",
|
1217
|
-
value: input.schema
|
1218
|
-
}), undefined === input.required || "boolean" === typeof input.required || $report(_exceptionable, {
|
1219
|
-
path: _path + ".required",
|
1220
|
-
expected: "(boolean | undefined)",
|
1221
|
-
value: input.required
|
1222
|
-
}), undefined === input.description || "string" === typeof input.description || $report(_exceptionable, {
|
1223
|
-
path: _path + ".description",
|
1224
|
-
expected: "(string | undefined)",
|
1225
|
-
value: input.description
|
1380
|
+
const $vo39 = (input, _path, _exceptionable = true) => ["string" === typeof input.$ref && RegExp(/^#\/components\/parameters\/(.*)/).test(input.$ref) || $report(_exceptionable, {
|
1381
|
+
path: _path + ".$ref",
|
1382
|
+
expected: "`#/components/parameters/${string}`",
|
1383
|
+
value: input.$ref
|
1226
1384
|
})].every(flag => flag);
|
1227
|
-
const $
|
1385
|
+
const $vo40 = (input, _path, _exceptionable = true) => [undefined === input.description || "string" === typeof input.description || $report(_exceptionable, {
|
1228
1386
|
path: _path + ".description",
|
1229
1387
|
expected: "(string | undefined)",
|
1230
1388
|
value: input.description
|
@@ -1232,7 +1390,7 @@ class MigrateApplication {
|
|
1232
1390
|
path: _path + ".content",
|
1233
1391
|
expected: "ISwaggerRoute.IContent",
|
1234
1392
|
value: input.content
|
1235
|
-
})) && $
|
1393
|
+
})) && $vo41(input.content, _path + ".content", true && _exceptionable) || $report(_exceptionable, {
|
1236
1394
|
path: _path + ".content",
|
1237
1395
|
expected: "ISwaggerRoute.IContent",
|
1238
1396
|
value: input.content
|
@@ -1245,11 +1403,11 @@ class MigrateApplication {
|
|
1245
1403
|
expected: "(boolean | undefined)",
|
1246
1404
|
value: input["x-nestia-encrypted"]
|
1247
1405
|
})].every(flag => flag);
|
1248
|
-
const $
|
1406
|
+
const $vo41 = (input, _path, _exceptionable = true) => [undefined === input["text/plain"] || ("object" === typeof input["text/plain"] && null !== input["text/plain"] || $report(_exceptionable, {
|
1249
1407
|
path: _path + "[\"text/plain\"]",
|
1250
1408
|
expected: "(__type | undefined)",
|
1251
1409
|
value: input["text/plain"]
|
1252
|
-
})) && $
|
1410
|
+
})) && $vo42(input["text/plain"], _path + "[\"text/plain\"]", true && _exceptionable) || $report(_exceptionable, {
|
1253
1411
|
path: _path + "[\"text/plain\"]",
|
1254
1412
|
expected: "(__type | undefined)",
|
1255
1413
|
value: input["text/plain"]
|
@@ -1257,7 +1415,7 @@ class MigrateApplication {
|
|
1257
1415
|
path: _path + "[\"application/json\"]",
|
1258
1416
|
expected: "(__type.o1 | undefined)",
|
1259
1417
|
value: input["application/json"]
|
1260
|
-
})) && $
|
1418
|
+
})) && $vo43(input["application/json"], _path + "[\"application/json\"]", true && _exceptionable) || $report(_exceptionable, {
|
1261
1419
|
path: _path + "[\"application/json\"]",
|
1262
1420
|
expected: "(__type.o1 | undefined)",
|
1263
1421
|
value: input["application/json"]
|
@@ -1265,7 +1423,7 @@ class MigrateApplication {
|
|
1265
1423
|
path: _path + "[\"application/x-www-form-urlencoded\"]",
|
1266
1424
|
expected: "(__type.o2 | undefined)",
|
1267
1425
|
value: input["application/x-www-form-urlencoded"]
|
1268
|
-
})) && $
|
1426
|
+
})) && $vo44(input["application/x-www-form-urlencoded"], _path + "[\"application/x-www-form-urlencoded\"]", true && _exceptionable) || $report(_exceptionable, {
|
1269
1427
|
path: _path + "[\"application/x-www-form-urlencoded\"]",
|
1270
1428
|
expected: "(__type.o2 | undefined)",
|
1271
1429
|
value: input["application/x-www-form-urlencoded"]
|
@@ -1273,7 +1431,7 @@ class MigrateApplication {
|
|
1273
1431
|
path: _path + "[\"multipart/form-data\"]",
|
1274
1432
|
expected: "(__type.o3 | undefined)",
|
1275
1433
|
value: input["multipart/form-data"]
|
1276
|
-
})) && $
|
1434
|
+
})) && $vo45(input["multipart/form-data"], _path + "[\"multipart/form-data\"]", true && _exceptionable) || $report(_exceptionable, {
|
1277
1435
|
path: _path + "[\"multipart/form-data\"]",
|
1278
1436
|
expected: "(__type.o3 | undefined)",
|
1279
1437
|
value: input["multipart/form-data"]
|
@@ -1281,12 +1439,12 @@ class MigrateApplication {
|
|
1281
1439
|
path: _path + "[\"*/*\"]",
|
1282
1440
|
expected: "(__type.o4 | undefined)",
|
1283
1441
|
value: input["*/*"]
|
1284
|
-
})) && $
|
1442
|
+
})) && $vo46(input["*/*"], _path + "[\"*/*\"]", true && _exceptionable) || $report(_exceptionable, {
|
1285
1443
|
path: _path + "[\"*/*\"]",
|
1286
1444
|
expected: "(__type.o4 | undefined)",
|
1287
1445
|
value: input["*/*"]
|
1288
1446
|
})].every(flag => flag);
|
1289
|
-
const $
|
1447
|
+
const $vo42 = (input, _path, _exceptionable = true) => [("object" === typeof input.schema && null !== input.schema && false === Array.isArray(input.schema) || $report(_exceptionable, {
|
1290
1448
|
path: _path + ".schema",
|
1291
1449
|
expected: "(ISwaggerSchema.IAnyOf | ISwaggerSchema.IArray | ISwaggerSchema.IBoolean | ISwaggerSchema.IInteger | ISwaggerSchema.INullOnly | ISwaggerSchema.INumber | ISwaggerSchema.IObject | ISwaggerSchema.IOneOf | ISwaggerSchema.IReference | ISwaggerSchema.IString | ISwaggerSchema.IUnknown)",
|
1292
1450
|
value: input.schema
|
@@ -1295,7 +1453,7 @@ class MigrateApplication {
|
|
1295
1453
|
expected: "(ISwaggerSchema.IAnyOf | ISwaggerSchema.IArray | ISwaggerSchema.IBoolean | ISwaggerSchema.IInteger | ISwaggerSchema.INullOnly | ISwaggerSchema.INumber | ISwaggerSchema.IObject | ISwaggerSchema.IOneOf | ISwaggerSchema.IReference | ISwaggerSchema.IString | ISwaggerSchema.IUnknown)",
|
1296
1454
|
value: input.schema
|
1297
1455
|
})].every(flag => flag);
|
1298
|
-
const $
|
1456
|
+
const $vo43 = (input, _path, _exceptionable = true) => [("object" === typeof input.schema && null !== input.schema && false === Array.isArray(input.schema) || $report(_exceptionable, {
|
1299
1457
|
path: _path + ".schema",
|
1300
1458
|
expected: "(ISwaggerSchema.IAnyOf | ISwaggerSchema.IArray | ISwaggerSchema.IBoolean | ISwaggerSchema.IInteger | ISwaggerSchema.INullOnly | ISwaggerSchema.INumber | ISwaggerSchema.IObject | ISwaggerSchema.IOneOf | ISwaggerSchema.IReference | ISwaggerSchema.IString | ISwaggerSchema.IUnknown)",
|
1301
1459
|
value: input.schema
|
@@ -1304,7 +1462,7 @@ class MigrateApplication {
|
|
1304
1462
|
expected: "(ISwaggerSchema.IAnyOf | ISwaggerSchema.IArray | ISwaggerSchema.IBoolean | ISwaggerSchema.IInteger | ISwaggerSchema.INullOnly | ISwaggerSchema.INumber | ISwaggerSchema.IObject | ISwaggerSchema.IOneOf | ISwaggerSchema.IReference | ISwaggerSchema.IString | ISwaggerSchema.IUnknown)",
|
1305
1463
|
value: input.schema
|
1306
1464
|
})].every(flag => flag);
|
1307
|
-
const $
|
1465
|
+
const $vo44 = (input, _path, _exceptionable = true) => [("object" === typeof input.schema && null !== input.schema && false === Array.isArray(input.schema) || $report(_exceptionable, {
|
1308
1466
|
path: _path + ".schema",
|
1309
1467
|
expected: "(ISwaggerSchema.IAnyOf | ISwaggerSchema.IArray | ISwaggerSchema.IBoolean | ISwaggerSchema.IInteger | ISwaggerSchema.INullOnly | ISwaggerSchema.INumber | ISwaggerSchema.IObject | ISwaggerSchema.IOneOf | ISwaggerSchema.IReference | ISwaggerSchema.IString | ISwaggerSchema.IUnknown)",
|
1310
1468
|
value: input.schema
|
@@ -1313,7 +1471,7 @@ class MigrateApplication {
|
|
1313
1471
|
expected: "(ISwaggerSchema.IAnyOf | ISwaggerSchema.IArray | ISwaggerSchema.IBoolean | ISwaggerSchema.IInteger | ISwaggerSchema.INullOnly | ISwaggerSchema.INumber | ISwaggerSchema.IObject | ISwaggerSchema.IOneOf | ISwaggerSchema.IReference | ISwaggerSchema.IString | ISwaggerSchema.IUnknown)",
|
1314
1472
|
value: input.schema
|
1315
1473
|
})].every(flag => flag);
|
1316
|
-
const $
|
1474
|
+
const $vo45 = (input, _path, _exceptionable = true) => [("object" === typeof input.schema && null !== input.schema && false === Array.isArray(input.schema) || $report(_exceptionable, {
|
1317
1475
|
path: _path + ".schema",
|
1318
1476
|
expected: "(ISwaggerSchema.IAnyOf | ISwaggerSchema.IArray | ISwaggerSchema.IBoolean | ISwaggerSchema.IInteger | ISwaggerSchema.INullOnly | ISwaggerSchema.INumber | ISwaggerSchema.IObject | ISwaggerSchema.IOneOf | ISwaggerSchema.IReference | ISwaggerSchema.IString | ISwaggerSchema.IUnknown)",
|
1319
1477
|
value: input.schema
|
@@ -1322,7 +1480,7 @@ class MigrateApplication {
|
|
1322
1480
|
expected: "(ISwaggerSchema.IAnyOf | ISwaggerSchema.IArray | ISwaggerSchema.IBoolean | ISwaggerSchema.IInteger | ISwaggerSchema.INullOnly | ISwaggerSchema.INumber | ISwaggerSchema.IObject | ISwaggerSchema.IOneOf | ISwaggerSchema.IReference | ISwaggerSchema.IString | ISwaggerSchema.IUnknown)",
|
1323
1481
|
value: input.schema
|
1324
1482
|
})].every(flag => flag);
|
1325
|
-
const $
|
1483
|
+
const $vo46 = (input, _path, _exceptionable = true) => [("object" === typeof input.schema && null !== input.schema && false === Array.isArray(input.schema) || $report(_exceptionable, {
|
1326
1484
|
path: _path + ".schema",
|
1327
1485
|
expected: "(ISwaggerSchema.IAnyOf | ISwaggerSchema.IArray | ISwaggerSchema.IBoolean | ISwaggerSchema.IInteger | ISwaggerSchema.INullOnly | ISwaggerSchema.INumber | ISwaggerSchema.IObject | ISwaggerSchema.IOneOf | ISwaggerSchema.IReference | ISwaggerSchema.IString | ISwaggerSchema.IUnknown)",
|
1328
1486
|
value: input.schema
|
@@ -1331,7 +1489,7 @@ class MigrateApplication {
|
|
1331
1489
|
expected: "(ISwaggerSchema.IAnyOf | ISwaggerSchema.IArray | ISwaggerSchema.IBoolean | ISwaggerSchema.IInteger | ISwaggerSchema.INullOnly | ISwaggerSchema.INumber | ISwaggerSchema.IObject | ISwaggerSchema.IOneOf | ISwaggerSchema.IReference | ISwaggerSchema.IString | ISwaggerSchema.IUnknown)",
|
1332
1490
|
value: input.schema
|
1333
1491
|
})].every(flag => flag);
|
1334
|
-
const $
|
1492
|
+
const $vo47 = (input, _path, _exceptionable = true) => [false === _exceptionable || Object.keys(input).map(key => {
|
1335
1493
|
const value = input[key];
|
1336
1494
|
if (undefined === value)
|
1337
1495
|
return true;
|
@@ -1339,13 +1497,13 @@ class MigrateApplication {
|
|
1339
1497
|
path: _path + $join(key),
|
1340
1498
|
expected: "__type.o5",
|
1341
1499
|
value: value
|
1342
|
-
})) && $
|
1500
|
+
})) && $vo48(value, _path + $join(key), true && _exceptionable) || $report(_exceptionable, {
|
1343
1501
|
path: _path + $join(key),
|
1344
1502
|
expected: "__type.o5",
|
1345
1503
|
value: value
|
1346
1504
|
});
|
1347
1505
|
}).every(flag => flag)].every(flag => flag);
|
1348
|
-
const $
|
1506
|
+
const $vo48 = (input, _path, _exceptionable = true) => [undefined === input.description || "string" === typeof input.description || $report(_exceptionable, {
|
1349
1507
|
path: _path + ".description",
|
1350
1508
|
expected: "(string | undefined)",
|
1351
1509
|
value: input.description
|
@@ -1353,7 +1511,7 @@ class MigrateApplication {
|
|
1353
1511
|
path: _path + ".content",
|
1354
1512
|
expected: "(ISwaggerRoute.IContent | undefined)",
|
1355
1513
|
value: input.content
|
1356
|
-
})) && $
|
1514
|
+
})) && $vo41(input.content, _path + ".content", true && _exceptionable) || $report(_exceptionable, {
|
1357
1515
|
path: _path + ".content",
|
1358
1516
|
expected: "(ISwaggerRoute.IContent | undefined)",
|
1359
1517
|
value: input.content
|
@@ -1362,7 +1520,7 @@ class MigrateApplication {
|
|
1362
1520
|
expected: "(boolean | undefined)",
|
1363
1521
|
value: input["x-nestia-encrypted"]
|
1364
1522
|
})].every(flag => flag);
|
1365
|
-
const $
|
1523
|
+
const $vo49 = (input, _path, _exceptionable = true) => [false === _exceptionable || Object.keys(input).map(key => {
|
1366
1524
|
const value = input[key];
|
1367
1525
|
if (undefined === value)
|
1368
1526
|
return true;
|
@@ -1380,7 +1538,7 @@ class MigrateApplication {
|
|
1380
1538
|
value: value
|
1381
1539
|
});
|
1382
1540
|
}).every(flag => flag)].every(flag => flag);
|
1383
|
-
const $
|
1541
|
+
const $vo50 = (input, _path, _exceptionable = true) => ["string" === typeof input.name || $report(_exceptionable, {
|
1384
1542
|
path: _path + ".name",
|
1385
1543
|
expected: "string",
|
1386
1544
|
value: input.name
|
@@ -1392,7 +1550,7 @@ class MigrateApplication {
|
|
1392
1550
|
path: _path + ".text[" + _index16 + "]",
|
1393
1551
|
expected: "IJsDocTagInfo.IText",
|
1394
1552
|
value: elem
|
1395
|
-
})) && $
|
1553
|
+
})) && $vo51(elem, _path + ".text[" + _index16 + "]", true && _exceptionable) || $report(_exceptionable, {
|
1396
1554
|
path: _path + ".text[" + _index16 + "]",
|
1397
1555
|
expected: "IJsDocTagInfo.IText",
|
1398
1556
|
value: elem
|
@@ -1401,7 +1559,7 @@ class MigrateApplication {
|
|
1401
1559
|
expected: "(Array<IJsDocTagInfo.IText> | undefined)",
|
1402
1560
|
value: input.text
|
1403
1561
|
})].every(flag => flag);
|
1404
|
-
const $
|
1562
|
+
const $vo51 = (input, _path, _exceptionable = true) => ["string" === typeof input.text || $report(_exceptionable, {
|
1405
1563
|
path: _path + ".text",
|
1406
1564
|
expected: "string",
|
1407
1565
|
value: input.text
|
@@ -1412,39 +1570,51 @@ class MigrateApplication {
|
|
1412
1570
|
})].every(flag => flag);
|
1413
1571
|
const $vu0 = (input, _path, _exceptionable = true) => (() => {
|
1414
1572
|
if ("null" === input.type)
|
1415
|
-
return $vo8(input, _path, true && _exceptionable);
|
1416
|
-
else if (undefined !== input.anyOf)
|
1417
1573
|
return $vo9(input, _path, true && _exceptionable);
|
1418
|
-
else if (undefined !== input.
|
1574
|
+
else if (undefined !== input.anyOf)
|
1419
1575
|
return $vo10(input, _path, true && _exceptionable);
|
1420
|
-
else if (
|
1576
|
+
else if (undefined !== input.oneOf)
|
1421
1577
|
return $vo11(input, _path, true && _exceptionable);
|
1578
|
+
else if ("boolean" === input.type)
|
1579
|
+
return $vo12(input, _path, true && _exceptionable);
|
1422
1580
|
else if ("number" === input.type)
|
1423
|
-
return $
|
1581
|
+
return $vo14(input, _path, true && _exceptionable);
|
1424
1582
|
else if ("integer" === input.type)
|
1425
|
-
return $
|
1583
|
+
return $vo13(input, _path, true && _exceptionable);
|
1426
1584
|
else if ("string" === input.type)
|
1427
|
-
return $vo14(input, _path, true && _exceptionable);
|
1428
|
-
else if ("array" === input.type)
|
1429
1585
|
return $vo15(input, _path, true && _exceptionable);
|
1430
|
-
else if ("
|
1586
|
+
else if ("array" === input.type)
|
1431
1587
|
return $vo16(input, _path, true && _exceptionable);
|
1432
|
-
else if (
|
1588
|
+
else if ("object" === input.type)
|
1433
1589
|
return $vo17(input, _path, true && _exceptionable);
|
1590
|
+
else if (undefined !== input.$ref)
|
1591
|
+
return $vo19(input, _path, true && _exceptionable);
|
1434
1592
|
else
|
1435
|
-
return $
|
1593
|
+
return $vo8(input, _path, true && _exceptionable);
|
1436
1594
|
})();
|
1437
1595
|
const $vu1 = (input, _path, _exceptionable = true) => (() => {
|
1596
|
+
if (undefined !== input["in"])
|
1597
|
+
return $vo7(input, _path, true && _exceptionable);
|
1598
|
+
else if (undefined !== input.$ref)
|
1599
|
+
return $vo39(input, _path, true && _exceptionable);
|
1600
|
+
else
|
1601
|
+
return $report(_exceptionable, {
|
1602
|
+
path: _path,
|
1603
|
+
expected: "(ISwaggerRouteParameter | ISwaggerRouteParameter.IReference)",
|
1604
|
+
value: input
|
1605
|
+
});
|
1606
|
+
})();
|
1607
|
+
const $vu2 = (input, _path, _exceptionable = true) => (() => {
|
1438
1608
|
if ("basic" === input.scheme)
|
1439
|
-
return $
|
1609
|
+
return $vo26(input, _path, true && _exceptionable);
|
1440
1610
|
else if ("bearer" === input.scheme)
|
1441
|
-
return $
|
1611
|
+
return $vo27(input, _path, true && _exceptionable);
|
1442
1612
|
else if ("apiKey" === input.type)
|
1443
|
-
return $
|
1613
|
+
return $vo28(input, _path, true && _exceptionable);
|
1444
1614
|
else if ("openIdConnect" === input.type)
|
1445
|
-
return $
|
1615
|
+
return $vo29(input, _path, true && _exceptionable);
|
1446
1616
|
else if ("oauth2" === input.type)
|
1447
|
-
return $
|
1617
|
+
return $vo30(input, _path, true && _exceptionable);
|
1448
1618
|
else
|
1449
1619
|
return $report(_exceptionable, {
|
1450
1620
|
path: _path,
|