swagger-client 3.32.1 → 3.32.3
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/dist/swagger-client.browser.js +216 -501
- package/dist/swagger-client.browser.min.js +1 -1
- package/dist/swagger-client.browser.min.js.map +1 -1
- package/es/execute/oas3/style-serializer.js +3 -2
- package/es/http/serializers/request/index.js +1 -3
- package/lib/execute/oas3/style-serializer.js +3 -2
- package/lib/http/serializers/request/index.js +1 -3
- package/package.json +5 -5
|
@@ -856,10 +856,10 @@ function valueEncoder(value, escape = false) {
|
|
|
856
856
|
} else if (typeof value === 'number' || typeof value === 'boolean') {
|
|
857
857
|
value = String(value);
|
|
858
858
|
}
|
|
859
|
-
if (escape && value.length > 0) {
|
|
859
|
+
if (escape && typeof value === 'string' && value.length > 0) {
|
|
860
860
|
return encodeCharacters(value, escape);
|
|
861
861
|
}
|
|
862
|
-
return value;
|
|
862
|
+
return value ?? '';
|
|
863
863
|
}
|
|
864
864
|
function encodeArray({
|
|
865
865
|
key,
|
|
@@ -1951,9 +1951,7 @@ const stringifyQuery = (queryObject, {
|
|
|
1951
1951
|
encode = true
|
|
1952
1952
|
} = {}) => {
|
|
1953
1953
|
const buildNestedParams = (params, key, value) => {
|
|
1954
|
-
if (value
|
|
1955
|
-
params.append(key, '');
|
|
1956
|
-
} else if (Array.isArray(value)) {
|
|
1954
|
+
if (Array.isArray(value)) {
|
|
1957
1955
|
value.reduce((acc, v) => buildNestedParams(params, key, v), params);
|
|
1958
1956
|
} else if (value instanceof Date) {
|
|
1959
1957
|
params.append(key, value.toISOString());
|
|
@@ -35425,6 +35423,14 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
35425
35423
|
|
|
35426
35424
|
// @ts-ignore
|
|
35427
35425
|
const visitAsync = _swagger_api_apidom_core__WEBPACK_IMPORTED_MODULE_0__.visit[Symbol.for('nodejs.util.promisify.custom')];
|
|
35426
|
+
|
|
35427
|
+
/**
|
|
35428
|
+
* @public
|
|
35429
|
+
*/
|
|
35430
|
+
|
|
35431
|
+
/**
|
|
35432
|
+
* @public
|
|
35433
|
+
*/
|
|
35428
35434
|
class OpenAPI3_1DereferenceStrategy extends _DereferenceStrategy_mjs__WEBPACK_IMPORTED_MODULE_1__["default"] {
|
|
35429
35435
|
constructor(options) {
|
|
35430
35436
|
super({
|
|
@@ -35537,7 +35543,10 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
35537
35543
|
|
|
35538
35544
|
|
|
35539
35545
|
|
|
35540
|
-
|
|
35546
|
+
|
|
35547
|
+
/**
|
|
35548
|
+
* @public
|
|
35549
|
+
*/
|
|
35541
35550
|
const isAnchor = uri => {
|
|
35542
35551
|
/**
|
|
35543
35552
|
* MUST start with a letter ([A-Za-z]) or underscore ("_"), followed by any number of letters,
|
|
@@ -35548,13 +35557,17 @@ const isAnchor = uri => {
|
|
|
35548
35557
|
return /^[A-Za-z_][A-Za-z_0-9.-]*$/.test(uri);
|
|
35549
35558
|
};
|
|
35550
35559
|
|
|
35551
|
-
|
|
35560
|
+
/**
|
|
35561
|
+
* @public
|
|
35562
|
+
*/
|
|
35552
35563
|
const uriToAnchor = uri => {
|
|
35553
35564
|
const hash = (0,_util_url_mjs__WEBPACK_IMPORTED_MODULE_0__.getHash)(uri);
|
|
35554
35565
|
return (0,ramda_adjunct__WEBPACK_IMPORTED_MODULE_1__["default"])('#', hash);
|
|
35555
35566
|
};
|
|
35556
35567
|
|
|
35557
|
-
|
|
35568
|
+
/**
|
|
35569
|
+
* @public
|
|
35570
|
+
*/
|
|
35558
35571
|
const parse = anchor => {
|
|
35559
35572
|
if (!isAnchor(anchor)) {
|
|
35560
35573
|
throw new _errors_InvalidJsonSchema$anchorError_mjs__WEBPACK_IMPORTED_MODULE_2__["default"](anchor);
|
|
@@ -35562,7 +35575,10 @@ const parse = anchor => {
|
|
|
35562
35575
|
return anchor;
|
|
35563
35576
|
};
|
|
35564
35577
|
|
|
35565
|
-
|
|
35578
|
+
/**
|
|
35579
|
+
* Evaluates JSON Schema $anchor against ApiDOM fragment.
|
|
35580
|
+
* @public
|
|
35581
|
+
*/
|
|
35566
35582
|
const evaluate = (anchor, element) => {
|
|
35567
35583
|
const token = parse(anchor);
|
|
35568
35584
|
|
|
@@ -35610,6 +35626,7 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
35610
35626
|
|
|
35611
35627
|
/**
|
|
35612
35628
|
* Evaluates JSON Schema $ref containing unknown URI against ApiDOM fragment.
|
|
35629
|
+
* @public
|
|
35613
35630
|
*/
|
|
35614
35631
|
const evaluate = (uri, element) => {
|
|
35615
35632
|
const {
|
|
@@ -35673,6 +35690,9 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
35673
35690
|
|
|
35674
35691
|
|
|
35675
35692
|
|
|
35693
|
+
/**
|
|
35694
|
+
* @public
|
|
35695
|
+
*/
|
|
35676
35696
|
const resolveSchema$refField = (retrievalURI, schemaElement) => {
|
|
35677
35697
|
if (typeof schemaElement.$ref === 'undefined') {
|
|
35678
35698
|
return undefined;
|
|
@@ -35684,6 +35704,10 @@ const resolveSchema$refField = (retrievalURI, schemaElement) => {
|
|
|
35684
35704
|
}, retrievalURI, [...inherited$id, (0,_swagger_api_apidom_core__WEBPACK_IMPORTED_MODULE_1__["default"])(schemaElement.$ref)]);
|
|
35685
35705
|
return `${$refBaseURI}${hash === '#' ? '' : hash}`;
|
|
35686
35706
|
};
|
|
35707
|
+
|
|
35708
|
+
/**
|
|
35709
|
+
* @public
|
|
35710
|
+
*/
|
|
35687
35711
|
const resolveSchema$idField = (retrievalURI, schemaElement) => {
|
|
35688
35712
|
if (typeof schemaElement.$id === 'undefined') {
|
|
35689
35713
|
return undefined;
|
|
@@ -35706,6 +35730,10 @@ const refractToSchemaElement = element => {
|
|
|
35706
35730
|
return refracted;
|
|
35707
35731
|
};
|
|
35708
35732
|
refractToSchemaElement.cache = new WeakMap();
|
|
35733
|
+
|
|
35734
|
+
/**
|
|
35735
|
+
* @public
|
|
35736
|
+
*/
|
|
35709
35737
|
const maybeRefractToSchemaElement = element => {
|
|
35710
35738
|
/**
|
|
35711
35739
|
* Conditional version of refractToSchemaElement, that acts as an identity
|
|
@@ -35725,7 +35753,8 @@ const maybeRefractToSchemaElement = element => {
|
|
|
35725
35753
|
"use strict";
|
|
35726
35754
|
__webpack_require__.r(__webpack_exports__);
|
|
35727
35755
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
35728
|
-
/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__)
|
|
35756
|
+
/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__),
|
|
35757
|
+
/* harmony export */ mutationReplacer: () => (/* binding */ mutationReplacer)
|
|
35729
35758
|
/* harmony export */ });
|
|
35730
35759
|
/* harmony import */ var ramda__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(95201);
|
|
35731
35760
|
/* harmony import */ var ramda__WEBPACK_IMPORTED_MODULE_24__ = __webpack_require__(10796);
|
|
@@ -35778,7 +35807,10 @@ const visitAsync = _swagger_api_apidom_core__WEBPACK_IMPORTED_MODULE_0__.visit[S
|
|
|
35778
35807
|
// initialize element identity manager
|
|
35779
35808
|
const identityManager = new _swagger_api_apidom_core__WEBPACK_IMPORTED_MODULE_1__.IdentityManager();
|
|
35780
35809
|
|
|
35781
|
-
|
|
35810
|
+
/**
|
|
35811
|
+
* Custom mutation replacer.
|
|
35812
|
+
* @public
|
|
35813
|
+
*/
|
|
35782
35814
|
const mutationReplacer = (newElement, oldElement, key, parent) => {
|
|
35783
35815
|
if ((0,_swagger_api_apidom_core__WEBPACK_IMPORTED_MODULE_2__.isMemberElement)(parent)) {
|
|
35784
35816
|
parent.value = newElement; // eslint-disable-line no-param-reassign
|
|
@@ -35786,6 +35818,14 @@ const mutationReplacer = (newElement, oldElement, key, parent) => {
|
|
|
35786
35818
|
parent[key] = newElement; // eslint-disable-line no-param-reassign
|
|
35787
35819
|
}
|
|
35788
35820
|
};
|
|
35821
|
+
|
|
35822
|
+
/**
|
|
35823
|
+
* @public
|
|
35824
|
+
*/
|
|
35825
|
+
|
|
35826
|
+
/**
|
|
35827
|
+
* @public
|
|
35828
|
+
*/
|
|
35789
35829
|
class OpenAPI3_1DereferenceVisitor {
|
|
35790
35830
|
indirections;
|
|
35791
35831
|
namespace;
|
|
@@ -37514,6 +37554,10 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
37514
37554
|
/**
|
|
37515
37555
|
* Everything that is not recognized by other parsers will be considered by this parser
|
|
37516
37556
|
* as a binary data and will be encoded to Base64 format.
|
|
37557
|
+
* @public
|
|
37558
|
+
*/
|
|
37559
|
+
/**
|
|
37560
|
+
* @public
|
|
37517
37561
|
*/
|
|
37518
37562
|
class BinaryParser extends _Parser_mjs__WEBPACK_IMPORTED_MODULE_0__["default"] {
|
|
37519
37563
|
constructor(options) {
|
|
@@ -37758,6 +37802,12 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
37758
37802
|
|
|
37759
37803
|
|
|
37760
37804
|
|
|
37805
|
+
/**
|
|
37806
|
+
* @public
|
|
37807
|
+
*/
|
|
37808
|
+
/**
|
|
37809
|
+
* @public
|
|
37810
|
+
*/
|
|
37761
37811
|
class OpenAPI3_1ResolveStrategy extends _ResolveStrategy_mjs__WEBPACK_IMPORTED_MODULE_0__["default"] {
|
|
37762
37812
|
constructor(options) {
|
|
37763
37813
|
super({
|
|
@@ -44801,50 +44851,6 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
44801
44851
|
|
|
44802
44852
|
|
|
44803
44853
|
|
|
44804
|
-
/***/ }),
|
|
44805
|
-
|
|
44806
|
-
/***/ 41856:
|
|
44807
|
-
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
|
|
44808
|
-
|
|
44809
|
-
"use strict";
|
|
44810
|
-
__webpack_require__.r(__webpack_exports__);
|
|
44811
|
-
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
44812
|
-
/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__)
|
|
44813
|
-
/* harmony export */ });
|
|
44814
|
-
/* harmony import */ var apg_lite__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(16646);
|
|
44815
|
-
|
|
44816
|
-
const fragmentMarker = (state, chars, phraseIndex, phraseLength, data) => {
|
|
44817
|
-
if (state === apg_lite__WEBPACK_IMPORTED_MODULE_0__.identifiers.SEM_PRE) {
|
|
44818
|
-
data.push(['fragment-marker', apg_lite__WEBPACK_IMPORTED_MODULE_0__.utilities.charsToString(chars, phraseIndex, phraseLength)]);
|
|
44819
|
-
} else if (state === apg_lite__WEBPACK_IMPORTED_MODULE_0__.identifiers.SEM_POST) {
|
|
44820
|
-
/* not used in this example */
|
|
44821
|
-
}
|
|
44822
|
-
return apg_lite__WEBPACK_IMPORTED_MODULE_0__.identifiers.SEM_OK;
|
|
44823
|
-
};
|
|
44824
|
-
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (fragmentMarker);
|
|
44825
|
-
|
|
44826
|
-
/***/ }),
|
|
44827
|
-
|
|
44828
|
-
/***/ 97774:
|
|
44829
|
-
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
|
|
44830
|
-
|
|
44831
|
-
"use strict";
|
|
44832
|
-
__webpack_require__.r(__webpack_exports__);
|
|
44833
|
-
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
44834
|
-
/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__)
|
|
44835
|
-
/* harmony export */ });
|
|
44836
|
-
/* harmony import */ var apg_lite__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(16646);
|
|
44837
|
-
|
|
44838
|
-
const fragment = (state, chars, phraseIndex, phraseLength, data) => {
|
|
44839
|
-
if (state === apg_lite__WEBPACK_IMPORTED_MODULE_0__.identifiers.SEM_PRE) {
|
|
44840
|
-
data.push(['fragment', apg_lite__WEBPACK_IMPORTED_MODULE_0__.utilities.charsToString(chars, phraseIndex, phraseLength)]);
|
|
44841
|
-
} else if (state === apg_lite__WEBPACK_IMPORTED_MODULE_0__.identifiers.SEM_POST) {
|
|
44842
|
-
/* not used in this example */
|
|
44843
|
-
}
|
|
44844
|
-
return apg_lite__WEBPACK_IMPORTED_MODULE_0__.identifiers.SEM_OK;
|
|
44845
|
-
};
|
|
44846
|
-
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (fragment);
|
|
44847
|
-
|
|
44848
44854
|
/***/ }),
|
|
44849
44855
|
|
|
44850
44856
|
/***/ 88430:
|
|
@@ -44892,72 +44898,6 @@ const pathTemplate = (state, chars, phraseIndex, phraseLength, data) => {
|
|
|
44892
44898
|
|
|
44893
44899
|
/***/ }),
|
|
44894
44900
|
|
|
44895
|
-
/***/ 28580:
|
|
44896
|
-
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
|
|
44897
|
-
|
|
44898
|
-
"use strict";
|
|
44899
|
-
__webpack_require__.r(__webpack_exports__);
|
|
44900
|
-
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
44901
|
-
/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__)
|
|
44902
|
-
/* harmony export */ });
|
|
44903
|
-
/* harmony import */ var apg_lite__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(16646);
|
|
44904
|
-
|
|
44905
|
-
const path = (state, chars, phraseIndex, phraseLength, data) => {
|
|
44906
|
-
if (state === apg_lite__WEBPACK_IMPORTED_MODULE_0__.identifiers.SEM_PRE) {
|
|
44907
|
-
data.push(['path', apg_lite__WEBPACK_IMPORTED_MODULE_0__.utilities.charsToString(chars, phraseIndex, phraseLength)]);
|
|
44908
|
-
} else if (state === apg_lite__WEBPACK_IMPORTED_MODULE_0__.identifiers.SEM_POST) {
|
|
44909
|
-
/* not used in this example */
|
|
44910
|
-
}
|
|
44911
|
-
return apg_lite__WEBPACK_IMPORTED_MODULE_0__.identifiers.SEM_OK;
|
|
44912
|
-
};
|
|
44913
|
-
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (path);
|
|
44914
|
-
|
|
44915
|
-
/***/ }),
|
|
44916
|
-
|
|
44917
|
-
/***/ 34518:
|
|
44918
|
-
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
|
|
44919
|
-
|
|
44920
|
-
"use strict";
|
|
44921
|
-
__webpack_require__.r(__webpack_exports__);
|
|
44922
|
-
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
44923
|
-
/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__)
|
|
44924
|
-
/* harmony export */ });
|
|
44925
|
-
/* harmony import */ var apg_lite__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(16646);
|
|
44926
|
-
|
|
44927
|
-
const queryMarker = (state, chars, phraseIndex, phraseLength, data) => {
|
|
44928
|
-
if (state === apg_lite__WEBPACK_IMPORTED_MODULE_0__.identifiers.SEM_PRE) {
|
|
44929
|
-
data.push(['query-marker', apg_lite__WEBPACK_IMPORTED_MODULE_0__.utilities.charsToString(chars, phraseIndex, phraseLength)]);
|
|
44930
|
-
} else if (state === apg_lite__WEBPACK_IMPORTED_MODULE_0__.identifiers.SEM_POST) {
|
|
44931
|
-
/* not used in this example */
|
|
44932
|
-
}
|
|
44933
|
-
return apg_lite__WEBPACK_IMPORTED_MODULE_0__.identifiers.SEM_OK;
|
|
44934
|
-
};
|
|
44935
|
-
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (queryMarker);
|
|
44936
|
-
|
|
44937
|
-
/***/ }),
|
|
44938
|
-
|
|
44939
|
-
/***/ 76559:
|
|
44940
|
-
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
|
|
44941
|
-
|
|
44942
|
-
"use strict";
|
|
44943
|
-
__webpack_require__.r(__webpack_exports__);
|
|
44944
|
-
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
44945
|
-
/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__)
|
|
44946
|
-
/* harmony export */ });
|
|
44947
|
-
/* harmony import */ var apg_lite__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(16646);
|
|
44948
|
-
|
|
44949
|
-
const query = (state, chars, phraseIndex, phraseLength, data) => {
|
|
44950
|
-
if (state === apg_lite__WEBPACK_IMPORTED_MODULE_0__.identifiers.SEM_PRE) {
|
|
44951
|
-
data.push(['query', apg_lite__WEBPACK_IMPORTED_MODULE_0__.utilities.charsToString(chars, phraseIndex, phraseLength)]);
|
|
44952
|
-
} else if (state === apg_lite__WEBPACK_IMPORTED_MODULE_0__.identifiers.SEM_POST) {
|
|
44953
|
-
/* not used in this example */
|
|
44954
|
-
}
|
|
44955
|
-
return apg_lite__WEBPACK_IMPORTED_MODULE_0__.identifiers.SEM_OK;
|
|
44956
|
-
};
|
|
44957
|
-
/* harmony default export */ const __WEBPACK_DEFAULT_EXPORT__ = (query);
|
|
44958
|
-
|
|
44959
|
-
/***/ }),
|
|
44960
|
-
|
|
44961
44901
|
/***/ 31696:
|
|
44962
44902
|
/***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
|
|
44963
44903
|
|
|
@@ -45033,20 +44973,12 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
45033
44973
|
/* harmony export */ "default": () => (__WEBPACK_DEFAULT_EXPORT__)
|
|
45034
44974
|
/* harmony export */ });
|
|
45035
44975
|
/* harmony import */ var apg_lite__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(16646);
|
|
45036
|
-
/* harmony import */ var
|
|
44976
|
+
/* harmony import */ var _path_templating_mjs__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(56167);
|
|
45037
44977
|
/* harmony import */ var _callbacks_slash_mjs__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(31696);
|
|
45038
44978
|
/* harmony import */ var _callbacks_path_template_mjs__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(33659);
|
|
45039
|
-
/* harmony import */ var
|
|
45040
|
-
/* harmony import */ var
|
|
45041
|
-
/* harmony import */ var
|
|
45042
|
-
/* harmony import */ var _callbacks_query_marker_mjs__WEBPACK_IMPORTED_MODULE_6__ = __webpack_require__(34518);
|
|
45043
|
-
/* harmony import */ var _callbacks_fragment_mjs__WEBPACK_IMPORTED_MODULE_7__ = __webpack_require__(97774);
|
|
45044
|
-
/* harmony import */ var _callbacks_fragment_marker_mjs__WEBPACK_IMPORTED_MODULE_8__ = __webpack_require__(41856);
|
|
45045
|
-
/* harmony import */ var _callbacks_template_expression_mjs__WEBPACK_IMPORTED_MODULE_9__ = __webpack_require__(82966);
|
|
45046
|
-
/* harmony import */ var _callbacks_template_expression_param_name_mjs__WEBPACK_IMPORTED_MODULE_10__ = __webpack_require__(21926);
|
|
45047
|
-
|
|
45048
|
-
|
|
45049
|
-
|
|
44979
|
+
/* harmony import */ var _callbacks_path_literal_mjs__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(88430);
|
|
44980
|
+
/* harmony import */ var _callbacks_template_expression_mjs__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(82966);
|
|
44981
|
+
/* harmony import */ var _callbacks_template_expression_param_name_mjs__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(21926);
|
|
45050
44982
|
|
|
45051
44983
|
|
|
45052
44984
|
|
|
@@ -45054,22 +44986,15 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
45054
44986
|
|
|
45055
44987
|
|
|
45056
44988
|
|
|
45057
|
-
|
|
45058
|
-
|
|
45059
|
-
const grammar = new _path_templating_mjs__WEBPACK_IMPORTED_MODULE_11__["default"]();
|
|
44989
|
+
const grammar = new _path_templating_mjs__WEBPACK_IMPORTED_MODULE_6__["default"]();
|
|
45060
44990
|
const parse = pathTemplate => {
|
|
45061
44991
|
const parser = new apg_lite__WEBPACK_IMPORTED_MODULE_0__.Parser();
|
|
45062
44992
|
parser.ast = new apg_lite__WEBPACK_IMPORTED_MODULE_0__.Ast();
|
|
45063
44993
|
parser.ast.callbacks['path-template'] = _callbacks_path_template_mjs__WEBPACK_IMPORTED_MODULE_2__["default"];
|
|
45064
|
-
parser.ast.callbacks['path'] = _callbacks_path_mjs__WEBPACK_IMPORTED_MODULE_3__["default"];
|
|
45065
|
-
parser.ast.callbacks['query'] = _callbacks_query_mjs__WEBPACK_IMPORTED_MODULE_5__["default"];
|
|
45066
|
-
parser.ast.callbacks['query-marker'] = _callbacks_query_marker_mjs__WEBPACK_IMPORTED_MODULE_6__["default"];
|
|
45067
|
-
parser.ast.callbacks['fragment'] = _callbacks_fragment_mjs__WEBPACK_IMPORTED_MODULE_7__["default"];
|
|
45068
|
-
parser.ast.callbacks['fragment-marker'] = _callbacks_fragment_marker_mjs__WEBPACK_IMPORTED_MODULE_8__["default"];
|
|
45069
44994
|
parser.ast.callbacks['slash'] = _callbacks_slash_mjs__WEBPACK_IMPORTED_MODULE_1__["default"];
|
|
45070
|
-
parser.ast.callbacks['path-literal'] =
|
|
45071
|
-
parser.ast.callbacks['template-expression'] =
|
|
45072
|
-
parser.ast.callbacks['template-expression-param-name'] =
|
|
44995
|
+
parser.ast.callbacks['path-literal'] = _callbacks_path_literal_mjs__WEBPACK_IMPORTED_MODULE_3__["default"];
|
|
44996
|
+
parser.ast.callbacks['template-expression'] = _callbacks_template_expression_mjs__WEBPACK_IMPORTED_MODULE_4__["default"];
|
|
44997
|
+
parser.ast.callbacks['template-expression-param-name'] = _callbacks_template_expression_param_name_mjs__WEBPACK_IMPORTED_MODULE_5__["default"];
|
|
45073
44998
|
const result = parser.parse(grammar, 'path-template', pathTemplate);
|
|
45074
44999
|
return {
|
|
45075
45000
|
result,
|
|
@@ -45095,22 +45020,22 @@ __webpack_require__.r(__webpack_exports__);
|
|
|
45095
45020
|
function grammar() {
|
|
45096
45021
|
// ```
|
|
45097
45022
|
// SUMMARY
|
|
45098
|
-
// rules =
|
|
45023
|
+
// rules = 13
|
|
45099
45024
|
// udts = 0
|
|
45100
|
-
// opcodes =
|
|
45025
|
+
// opcodes = 65
|
|
45101
45026
|
// --- ABNF original opcodes
|
|
45102
|
-
// ALT =
|
|
45103
|
-
// CAT =
|
|
45104
|
-
// REP =
|
|
45105
|
-
// RNM =
|
|
45106
|
-
// TLS =
|
|
45107
|
-
// TBS =
|
|
45108
|
-
// TRG =
|
|
45027
|
+
// ALT = 7
|
|
45028
|
+
// CAT = 4
|
|
45029
|
+
// REP = 5
|
|
45030
|
+
// RNM = 16
|
|
45031
|
+
// TLS = 27
|
|
45032
|
+
// TBS = 1
|
|
45033
|
+
// TRG = 5
|
|
45109
45034
|
// --- SABNF superset opcodes
|
|
45110
45035
|
// UDT = 0
|
|
45111
45036
|
// AND = 0
|
|
45112
45037
|
// NOT = 0
|
|
45113
|
-
// characters = [
|
|
45038
|
+
// characters = [0 - 1114111]
|
|
45114
45039
|
// ```
|
|
45115
45040
|
/* OBJECT IDENTIFIER (for internal parser use) */
|
|
45116
45041
|
this.grammarObject = 'grammarObject';
|
|
@@ -45124,111 +45049,75 @@ function grammar() {
|
|
|
45124
45049
|
isBkr: false
|
|
45125
45050
|
};
|
|
45126
45051
|
this.rules[1] = {
|
|
45127
|
-
name: 'path',
|
|
45128
|
-
lower: 'path',
|
|
45052
|
+
name: 'path-segment',
|
|
45053
|
+
lower: 'path-segment',
|
|
45129
45054
|
index: 1,
|
|
45130
45055
|
isBkr: false
|
|
45131
45056
|
};
|
|
45132
45057
|
this.rules[2] = {
|
|
45133
|
-
name: '
|
|
45134
|
-
lower: '
|
|
45058
|
+
name: 'slash',
|
|
45059
|
+
lower: 'slash',
|
|
45135
45060
|
index: 2,
|
|
45136
45061
|
isBkr: false
|
|
45137
45062
|
};
|
|
45138
45063
|
this.rules[3] = {
|
|
45139
|
-
name: '
|
|
45140
|
-
lower: '
|
|
45064
|
+
name: 'path-literal',
|
|
45065
|
+
lower: 'path-literal',
|
|
45141
45066
|
index: 3,
|
|
45142
45067
|
isBkr: false
|
|
45143
45068
|
};
|
|
45144
45069
|
this.rules[4] = {
|
|
45145
|
-
name: '
|
|
45146
|
-
lower: '
|
|
45070
|
+
name: 'template-expression',
|
|
45071
|
+
lower: 'template-expression',
|
|
45147
45072
|
index: 4,
|
|
45148
45073
|
isBkr: false
|
|
45149
45074
|
};
|
|
45150
45075
|
this.rules[5] = {
|
|
45151
|
-
name: '
|
|
45152
|
-
lower: '
|
|
45076
|
+
name: 'template-expression-param-name',
|
|
45077
|
+
lower: 'template-expression-param-name',
|
|
45153
45078
|
index: 5,
|
|
45154
45079
|
isBkr: false
|
|
45155
45080
|
};
|
|
45156
45081
|
this.rules[6] = {
|
|
45157
|
-
name: '
|
|
45158
|
-
lower: '
|
|
45082
|
+
name: 'pchar',
|
|
45083
|
+
lower: 'pchar',
|
|
45159
45084
|
index: 6,
|
|
45160
45085
|
isBkr: false
|
|
45161
45086
|
};
|
|
45162
45087
|
this.rules[7] = {
|
|
45163
|
-
name: 'fragment-literal',
|
|
45164
|
-
lower: 'fragment-literal',
|
|
45165
|
-
index: 7,
|
|
45166
|
-
isBkr: false
|
|
45167
|
-
};
|
|
45168
|
-
this.rules[8] = {
|
|
45169
|
-
name: 'fragment-marker',
|
|
45170
|
-
lower: 'fragment-marker',
|
|
45171
|
-
index: 8,
|
|
45172
|
-
isBkr: false
|
|
45173
|
-
};
|
|
45174
|
-
this.rules[9] = {
|
|
45175
|
-
name: 'slash',
|
|
45176
|
-
lower: 'slash',
|
|
45177
|
-
index: 9,
|
|
45178
|
-
isBkr: false
|
|
45179
|
-
};
|
|
45180
|
-
this.rules[10] = {
|
|
45181
|
-
name: 'path-literal',
|
|
45182
|
-
lower: 'path-literal',
|
|
45183
|
-
index: 10,
|
|
45184
|
-
isBkr: false
|
|
45185
|
-
};
|
|
45186
|
-
this.rules[11] = {
|
|
45187
|
-
name: 'template-expression',
|
|
45188
|
-
lower: 'template-expression',
|
|
45189
|
-
index: 11,
|
|
45190
|
-
isBkr: false
|
|
45191
|
-
};
|
|
45192
|
-
this.rules[12] = {
|
|
45193
|
-
name: 'template-expression-param-name',
|
|
45194
|
-
lower: 'template-expression-param-name',
|
|
45195
|
-
index: 12,
|
|
45196
|
-
isBkr: false
|
|
45197
|
-
};
|
|
45198
|
-
this.rules[13] = {
|
|
45199
45088
|
name: 'unreserved',
|
|
45200
45089
|
lower: 'unreserved',
|
|
45201
|
-
index:
|
|
45090
|
+
index: 7,
|
|
45202
45091
|
isBkr: false
|
|
45203
45092
|
};
|
|
45204
|
-
this.rules[
|
|
45093
|
+
this.rules[8] = {
|
|
45205
45094
|
name: 'pct-encoded',
|
|
45206
45095
|
lower: 'pct-encoded',
|
|
45207
|
-
index:
|
|
45096
|
+
index: 8,
|
|
45208
45097
|
isBkr: false
|
|
45209
45098
|
};
|
|
45210
|
-
this.rules[
|
|
45099
|
+
this.rules[9] = {
|
|
45211
45100
|
name: 'sub-delims',
|
|
45212
45101
|
lower: 'sub-delims',
|
|
45213
|
-
index:
|
|
45102
|
+
index: 9,
|
|
45214
45103
|
isBkr: false
|
|
45215
45104
|
};
|
|
45216
|
-
this.rules[
|
|
45105
|
+
this.rules[10] = {
|
|
45217
45106
|
name: 'ALPHA',
|
|
45218
45107
|
lower: 'alpha',
|
|
45219
|
-
index:
|
|
45108
|
+
index: 10,
|
|
45220
45109
|
isBkr: false
|
|
45221
45110
|
};
|
|
45222
|
-
this.rules[
|
|
45111
|
+
this.rules[11] = {
|
|
45223
45112
|
name: 'DIGIT',
|
|
45224
45113
|
lower: 'digit',
|
|
45225
|
-
index:
|
|
45114
|
+
index: 11,
|
|
45226
45115
|
isBkr: false
|
|
45227
45116
|
};
|
|
45228
|
-
this.rules[
|
|
45117
|
+
this.rules[12] = {
|
|
45229
45118
|
name: 'HEXDIG',
|
|
45230
45119
|
lower: 'hexdig',
|
|
45231
|
-
index:
|
|
45120
|
+
index: 12,
|
|
45232
45121
|
isBkr: false
|
|
45233
45122
|
};
|
|
45234
45123
|
|
|
@@ -45244,12 +45133,12 @@ function grammar() {
|
|
|
45244
45133
|
}; // CAT
|
|
45245
45134
|
this.rules[0].opcodes[1] = {
|
|
45246
45135
|
type: 4,
|
|
45247
|
-
index:
|
|
45248
|
-
}; // RNM(
|
|
45136
|
+
index: 2
|
|
45137
|
+
}; // RNM(slash)
|
|
45249
45138
|
this.rules[0].opcodes[2] = {
|
|
45250
45139
|
type: 3,
|
|
45251
45140
|
min: 0,
|
|
45252
|
-
max:
|
|
45141
|
+
max: Infinity
|
|
45253
45142
|
}; // REP
|
|
45254
45143
|
this.rules[0].opcodes[3] = {
|
|
45255
45144
|
type: 2,
|
|
@@ -45257,460 +45146,290 @@ function grammar() {
|
|
|
45257
45146
|
}; // CAT
|
|
45258
45147
|
this.rules[0].opcodes[4] = {
|
|
45259
45148
|
type: 4,
|
|
45260
|
-
index:
|
|
45261
|
-
}; // RNM(
|
|
45149
|
+
index: 1
|
|
45150
|
+
}; // RNM(path-segment)
|
|
45262
45151
|
this.rules[0].opcodes[5] = {
|
|
45263
|
-
type: 4,
|
|
45264
|
-
index: 3
|
|
45265
|
-
}; // RNM(query)
|
|
45266
|
-
this.rules[0].opcodes[6] = {
|
|
45267
|
-
type: 3,
|
|
45268
|
-
min: 0,
|
|
45269
|
-
max: 1
|
|
45270
|
-
}; // REP
|
|
45271
|
-
this.rules[0].opcodes[7] = {
|
|
45272
|
-
type: 2,
|
|
45273
|
-
children: [8, 9]
|
|
45274
|
-
}; // CAT
|
|
45275
|
-
this.rules[0].opcodes[8] = {
|
|
45276
|
-
type: 4,
|
|
45277
|
-
index: 8
|
|
45278
|
-
}; // RNM(fragment-marker)
|
|
45279
|
-
this.rules[0].opcodes[9] = {
|
|
45280
|
-
type: 4,
|
|
45281
|
-
index: 6
|
|
45282
|
-
}; // RNM(fragment)
|
|
45283
|
-
|
|
45284
|
-
/* path */
|
|
45285
|
-
this.rules[1].opcodes = [];
|
|
45286
|
-
this.rules[1].opcodes[0] = {
|
|
45287
|
-
type: 2,
|
|
45288
|
-
children: [1, 2, 6]
|
|
45289
|
-
}; // CAT
|
|
45290
|
-
this.rules[1].opcodes[1] = {
|
|
45291
|
-
type: 4,
|
|
45292
|
-
index: 9
|
|
45293
|
-
}; // RNM(slash)
|
|
45294
|
-
this.rules[1].opcodes[2] = {
|
|
45295
|
-
type: 3,
|
|
45296
|
-
min: 0,
|
|
45297
|
-
max: Infinity
|
|
45298
|
-
}; // REP
|
|
45299
|
-
this.rules[1].opcodes[3] = {
|
|
45300
|
-
type: 2,
|
|
45301
|
-
children: [4, 5]
|
|
45302
|
-
}; // CAT
|
|
45303
|
-
this.rules[1].opcodes[4] = {
|
|
45304
45152
|
type: 4,
|
|
45305
45153
|
index: 2
|
|
45306
|
-
}; // RNM(path-segment)
|
|
45307
|
-
this.rules[1].opcodes[5] = {
|
|
45308
|
-
type: 4,
|
|
45309
|
-
index: 9
|
|
45310
45154
|
}; // RNM(slash)
|
|
45311
|
-
this.rules[
|
|
45155
|
+
this.rules[0].opcodes[6] = {
|
|
45312
45156
|
type: 3,
|
|
45313
45157
|
min: 0,
|
|
45314
45158
|
max: 1
|
|
45315
45159
|
}; // REP
|
|
45316
|
-
this.rules[
|
|
45160
|
+
this.rules[0].opcodes[7] = {
|
|
45317
45161
|
type: 4,
|
|
45318
|
-
index:
|
|
45162
|
+
index: 1
|
|
45319
45163
|
}; // RNM(path-segment)
|
|
45320
45164
|
|
|
45321
45165
|
/* path-segment */
|
|
45322
|
-
this.rules[
|
|
45323
|
-
this.rules[
|
|
45166
|
+
this.rules[1].opcodes = [];
|
|
45167
|
+
this.rules[1].opcodes[0] = {
|
|
45324
45168
|
type: 3,
|
|
45325
45169
|
min: 1,
|
|
45326
45170
|
max: Infinity
|
|
45327
45171
|
}; // REP
|
|
45328
|
-
this.rules[
|
|
45172
|
+
this.rules[1].opcodes[1] = {
|
|
45329
45173
|
type: 1,
|
|
45330
45174
|
children: [2, 3]
|
|
45331
45175
|
}; // ALT
|
|
45332
|
-
this.rules[
|
|
45176
|
+
this.rules[1].opcodes[2] = {
|
|
45333
45177
|
type: 4,
|
|
45334
|
-
index:
|
|
45178
|
+
index: 3
|
|
45335
45179
|
}; // RNM(path-literal)
|
|
45336
|
-
this.rules[
|
|
45337
|
-
type: 4,
|
|
45338
|
-
index: 11
|
|
45339
|
-
}; // RNM(template-expression)
|
|
45340
|
-
|
|
45341
|
-
/* query */
|
|
45342
|
-
this.rules[3].opcodes = [];
|
|
45343
|
-
this.rules[3].opcodes[0] = {
|
|
45344
|
-
type: 3,
|
|
45345
|
-
min: 0,
|
|
45346
|
-
max: Infinity
|
|
45347
|
-
}; // REP
|
|
45348
|
-
this.rules[3].opcodes[1] = {
|
|
45180
|
+
this.rules[1].opcodes[3] = {
|
|
45349
45181
|
type: 4,
|
|
45350
45182
|
index: 4
|
|
45351
|
-
}; // RNM(
|
|
45352
|
-
|
|
45353
|
-
/* query-literal */
|
|
45354
|
-
this.rules[4].opcodes = [];
|
|
45355
|
-
this.rules[4].opcodes[0] = {
|
|
45356
|
-
type: 3,
|
|
45357
|
-
min: 1,
|
|
45358
|
-
max: Infinity
|
|
45359
|
-
}; // REP
|
|
45360
|
-
this.rules[4].opcodes[1] = {
|
|
45361
|
-
type: 1,
|
|
45362
|
-
children: [2, 3, 4, 5, 6, 7, 8, 9, 10]
|
|
45363
|
-
}; // ALT
|
|
45364
|
-
this.rules[4].opcodes[2] = {
|
|
45365
|
-
type: 4,
|
|
45366
|
-
index: 13
|
|
45367
|
-
}; // RNM(unreserved)
|
|
45368
|
-
this.rules[4].opcodes[3] = {
|
|
45369
|
-
type: 4,
|
|
45370
|
-
index: 14
|
|
45371
|
-
}; // RNM(pct-encoded)
|
|
45372
|
-
this.rules[4].opcodes[4] = {
|
|
45373
|
-
type: 4,
|
|
45374
|
-
index: 15
|
|
45375
|
-
}; // RNM(sub-delims)
|
|
45376
|
-
this.rules[4].opcodes[5] = {
|
|
45377
|
-
type: 7,
|
|
45378
|
-
string: [58]
|
|
45379
|
-
}; // TLS
|
|
45380
|
-
this.rules[4].opcodes[6] = {
|
|
45381
|
-
type: 7,
|
|
45382
|
-
string: [64]
|
|
45383
|
-
}; // TLS
|
|
45384
|
-
this.rules[4].opcodes[7] = {
|
|
45385
|
-
type: 7,
|
|
45386
|
-
string: [47]
|
|
45387
|
-
}; // TLS
|
|
45388
|
-
this.rules[4].opcodes[8] = {
|
|
45389
|
-
type: 7,
|
|
45390
|
-
string: [63]
|
|
45391
|
-
}; // TLS
|
|
45392
|
-
this.rules[4].opcodes[9] = {
|
|
45393
|
-
type: 7,
|
|
45394
|
-
string: [38]
|
|
45395
|
-
}; // TLS
|
|
45396
|
-
this.rules[4].opcodes[10] = {
|
|
45397
|
-
type: 7,
|
|
45398
|
-
string: [61]
|
|
45399
|
-
}; // TLS
|
|
45400
|
-
|
|
45401
|
-
/* query-marker */
|
|
45402
|
-
this.rules[5].opcodes = [];
|
|
45403
|
-
this.rules[5].opcodes[0] = {
|
|
45404
|
-
type: 7,
|
|
45405
|
-
string: [63]
|
|
45406
|
-
}; // TLS
|
|
45407
|
-
|
|
45408
|
-
/* fragment */
|
|
45409
|
-
this.rules[6].opcodes = [];
|
|
45410
|
-
this.rules[6].opcodes[0] = {
|
|
45411
|
-
type: 3,
|
|
45412
|
-
min: 0,
|
|
45413
|
-
max: Infinity
|
|
45414
|
-
}; // REP
|
|
45415
|
-
this.rules[6].opcodes[1] = {
|
|
45416
|
-
type: 4,
|
|
45417
|
-
index: 7
|
|
45418
|
-
}; // RNM(fragment-literal)
|
|
45419
|
-
|
|
45420
|
-
/* fragment-literal */
|
|
45421
|
-
this.rules[7].opcodes = [];
|
|
45422
|
-
this.rules[7].opcodes[0] = {
|
|
45423
|
-
type: 3,
|
|
45424
|
-
min: 1,
|
|
45425
|
-
max: Infinity
|
|
45426
|
-
}; // REP
|
|
45427
|
-
this.rules[7].opcodes[1] = {
|
|
45428
|
-
type: 1,
|
|
45429
|
-
children: [2, 3, 4, 5, 6, 7, 8]
|
|
45430
|
-
}; // ALT
|
|
45431
|
-
this.rules[7].opcodes[2] = {
|
|
45432
|
-
type: 4,
|
|
45433
|
-
index: 13
|
|
45434
|
-
}; // RNM(unreserved)
|
|
45435
|
-
this.rules[7].opcodes[3] = {
|
|
45436
|
-
type: 4,
|
|
45437
|
-
index: 14
|
|
45438
|
-
}; // RNM(pct-encoded)
|
|
45439
|
-
this.rules[7].opcodes[4] = {
|
|
45440
|
-
type: 4,
|
|
45441
|
-
index: 15
|
|
45442
|
-
}; // RNM(sub-delims)
|
|
45443
|
-
this.rules[7].opcodes[5] = {
|
|
45444
|
-
type: 7,
|
|
45445
|
-
string: [58]
|
|
45446
|
-
}; // TLS
|
|
45447
|
-
this.rules[7].opcodes[6] = {
|
|
45448
|
-
type: 7,
|
|
45449
|
-
string: [64]
|
|
45450
|
-
}; // TLS
|
|
45451
|
-
this.rules[7].opcodes[7] = {
|
|
45452
|
-
type: 7,
|
|
45453
|
-
string: [47]
|
|
45454
|
-
}; // TLS
|
|
45455
|
-
this.rules[7].opcodes[8] = {
|
|
45456
|
-
type: 7,
|
|
45457
|
-
string: [63]
|
|
45458
|
-
}; // TLS
|
|
45459
|
-
|
|
45460
|
-
/* fragment-marker */
|
|
45461
|
-
this.rules[8].opcodes = [];
|
|
45462
|
-
this.rules[8].opcodes[0] = {
|
|
45463
|
-
type: 7,
|
|
45464
|
-
string: [35]
|
|
45465
|
-
}; // TLS
|
|
45183
|
+
}; // RNM(template-expression)
|
|
45466
45184
|
|
|
45467
45185
|
/* slash */
|
|
45468
|
-
this.rules[
|
|
45469
|
-
this.rules[
|
|
45186
|
+
this.rules[2].opcodes = [];
|
|
45187
|
+
this.rules[2].opcodes[0] = {
|
|
45470
45188
|
type: 7,
|
|
45471
45189
|
string: [47]
|
|
45472
45190
|
}; // TLS
|
|
45473
45191
|
|
|
45474
45192
|
/* path-literal */
|
|
45475
|
-
this.rules[
|
|
45476
|
-
this.rules[
|
|
45193
|
+
this.rules[3].opcodes = [];
|
|
45194
|
+
this.rules[3].opcodes[0] = {
|
|
45477
45195
|
type: 3,
|
|
45478
45196
|
min: 1,
|
|
45479
45197
|
max: Infinity
|
|
45480
45198
|
}; // REP
|
|
45481
|
-
this.rules[
|
|
45482
|
-
type: 1,
|
|
45483
|
-
children: [2, 3, 4, 5, 6]
|
|
45484
|
-
}; // ALT
|
|
45485
|
-
this.rules[10].opcodes[2] = {
|
|
45486
|
-
type: 4,
|
|
45487
|
-
index: 13
|
|
45488
|
-
}; // RNM(unreserved)
|
|
45489
|
-
this.rules[10].opcodes[3] = {
|
|
45490
|
-
type: 4,
|
|
45491
|
-
index: 14
|
|
45492
|
-
}; // RNM(pct-encoded)
|
|
45493
|
-
this.rules[10].opcodes[4] = {
|
|
45199
|
+
this.rules[3].opcodes[1] = {
|
|
45494
45200
|
type: 4,
|
|
45495
|
-
index:
|
|
45496
|
-
}; // RNM(
|
|
45497
|
-
this.rules[10].opcodes[5] = {
|
|
45498
|
-
type: 7,
|
|
45499
|
-
string: [58]
|
|
45500
|
-
}; // TLS
|
|
45501
|
-
this.rules[10].opcodes[6] = {
|
|
45502
|
-
type: 7,
|
|
45503
|
-
string: [64]
|
|
45504
|
-
}; // TLS
|
|
45201
|
+
index: 6
|
|
45202
|
+
}; // RNM(pchar)
|
|
45505
45203
|
|
|
45506
45204
|
/* template-expression */
|
|
45507
|
-
this.rules[
|
|
45508
|
-
this.rules[
|
|
45205
|
+
this.rules[4].opcodes = [];
|
|
45206
|
+
this.rules[4].opcodes[0] = {
|
|
45509
45207
|
type: 2,
|
|
45510
45208
|
children: [1, 2, 3]
|
|
45511
45209
|
}; // CAT
|
|
45512
|
-
this.rules[
|
|
45210
|
+
this.rules[4].opcodes[1] = {
|
|
45513
45211
|
type: 7,
|
|
45514
45212
|
string: [123]
|
|
45515
45213
|
}; // TLS
|
|
45516
|
-
this.rules[
|
|
45214
|
+
this.rules[4].opcodes[2] = {
|
|
45517
45215
|
type: 4,
|
|
45518
|
-
index:
|
|
45216
|
+
index: 5
|
|
45519
45217
|
}; // RNM(template-expression-param-name)
|
|
45520
|
-
this.rules[
|
|
45218
|
+
this.rules[4].opcodes[3] = {
|
|
45521
45219
|
type: 7,
|
|
45522
45220
|
string: [125]
|
|
45523
45221
|
}; // TLS
|
|
45524
45222
|
|
|
45525
45223
|
/* template-expression-param-name */
|
|
45526
|
-
this.rules[
|
|
45527
|
-
this.rules[
|
|
45224
|
+
this.rules[5].opcodes = [];
|
|
45225
|
+
this.rules[5].opcodes[0] = {
|
|
45528
45226
|
type: 3,
|
|
45529
45227
|
min: 1,
|
|
45530
45228
|
max: Infinity
|
|
45531
45229
|
}; // REP
|
|
45532
|
-
this.rules[
|
|
45230
|
+
this.rules[5].opcodes[1] = {
|
|
45533
45231
|
type: 1,
|
|
45534
|
-
children: [2, 3, 4
|
|
45232
|
+
children: [2, 3, 4]
|
|
45535
45233
|
}; // ALT
|
|
45536
|
-
this.rules[
|
|
45234
|
+
this.rules[5].opcodes[2] = {
|
|
45235
|
+
type: 5,
|
|
45236
|
+
min: 0,
|
|
45237
|
+
max: 121
|
|
45238
|
+
}; // TRG
|
|
45239
|
+
this.rules[5].opcodes[3] = {
|
|
45240
|
+
type: 6,
|
|
45241
|
+
string: [124]
|
|
45242
|
+
}; // TBS
|
|
45243
|
+
this.rules[5].opcodes[4] = {
|
|
45244
|
+
type: 5,
|
|
45245
|
+
min: 126,
|
|
45246
|
+
max: 1114111
|
|
45247
|
+
}; // TRG
|
|
45248
|
+
|
|
45249
|
+
/* pchar */
|
|
45250
|
+
this.rules[6].opcodes = [];
|
|
45251
|
+
this.rules[6].opcodes[0] = {
|
|
45252
|
+
type: 1,
|
|
45253
|
+
children: [1, 2, 3, 4, 5]
|
|
45254
|
+
}; // ALT
|
|
45255
|
+
this.rules[6].opcodes[1] = {
|
|
45537
45256
|
type: 4,
|
|
45538
|
-
index:
|
|
45257
|
+
index: 7
|
|
45539
45258
|
}; // RNM(unreserved)
|
|
45540
|
-
this.rules[
|
|
45259
|
+
this.rules[6].opcodes[2] = {
|
|
45541
45260
|
type: 4,
|
|
45542
|
-
index:
|
|
45261
|
+
index: 8
|
|
45543
45262
|
}; // RNM(pct-encoded)
|
|
45544
|
-
this.rules[
|
|
45263
|
+
this.rules[6].opcodes[3] = {
|
|
45545
45264
|
type: 4,
|
|
45546
|
-
index:
|
|
45265
|
+
index: 9
|
|
45547
45266
|
}; // RNM(sub-delims)
|
|
45548
|
-
this.rules[
|
|
45267
|
+
this.rules[6].opcodes[4] = {
|
|
45549
45268
|
type: 7,
|
|
45550
45269
|
string: [58]
|
|
45551
45270
|
}; // TLS
|
|
45552
|
-
this.rules[
|
|
45271
|
+
this.rules[6].opcodes[5] = {
|
|
45553
45272
|
type: 7,
|
|
45554
45273
|
string: [64]
|
|
45555
45274
|
}; // TLS
|
|
45556
45275
|
|
|
45557
45276
|
/* unreserved */
|
|
45558
|
-
this.rules[
|
|
45559
|
-
this.rules[
|
|
45277
|
+
this.rules[7].opcodes = [];
|
|
45278
|
+
this.rules[7].opcodes[0] = {
|
|
45560
45279
|
type: 1,
|
|
45561
45280
|
children: [1, 2, 3, 4, 5, 6]
|
|
45562
45281
|
}; // ALT
|
|
45563
|
-
this.rules[
|
|
45282
|
+
this.rules[7].opcodes[1] = {
|
|
45564
45283
|
type: 4,
|
|
45565
|
-
index:
|
|
45284
|
+
index: 10
|
|
45566
45285
|
}; // RNM(ALPHA)
|
|
45567
|
-
this.rules[
|
|
45286
|
+
this.rules[7].opcodes[2] = {
|
|
45568
45287
|
type: 4,
|
|
45569
|
-
index:
|
|
45288
|
+
index: 11
|
|
45570
45289
|
}; // RNM(DIGIT)
|
|
45571
|
-
this.rules[
|
|
45290
|
+
this.rules[7].opcodes[3] = {
|
|
45572
45291
|
type: 7,
|
|
45573
45292
|
string: [45]
|
|
45574
45293
|
}; // TLS
|
|
45575
|
-
this.rules[
|
|
45294
|
+
this.rules[7].opcodes[4] = {
|
|
45576
45295
|
type: 7,
|
|
45577
45296
|
string: [46]
|
|
45578
45297
|
}; // TLS
|
|
45579
|
-
this.rules[
|
|
45298
|
+
this.rules[7].opcodes[5] = {
|
|
45580
45299
|
type: 7,
|
|
45581
45300
|
string: [95]
|
|
45582
45301
|
}; // TLS
|
|
45583
|
-
this.rules[
|
|
45302
|
+
this.rules[7].opcodes[6] = {
|
|
45584
45303
|
type: 7,
|
|
45585
45304
|
string: [126]
|
|
45586
45305
|
}; // TLS
|
|
45587
45306
|
|
|
45588
45307
|
/* pct-encoded */
|
|
45589
|
-
this.rules[
|
|
45590
|
-
this.rules[
|
|
45308
|
+
this.rules[8].opcodes = [];
|
|
45309
|
+
this.rules[8].opcodes[0] = {
|
|
45591
45310
|
type: 2,
|
|
45592
45311
|
children: [1, 2, 3]
|
|
45593
45312
|
}; // CAT
|
|
45594
|
-
this.rules[
|
|
45313
|
+
this.rules[8].opcodes[1] = {
|
|
45595
45314
|
type: 7,
|
|
45596
45315
|
string: [37]
|
|
45597
45316
|
}; // TLS
|
|
45598
|
-
this.rules[
|
|
45317
|
+
this.rules[8].opcodes[2] = {
|
|
45599
45318
|
type: 4,
|
|
45600
|
-
index:
|
|
45319
|
+
index: 12
|
|
45601
45320
|
}; // RNM(HEXDIG)
|
|
45602
|
-
this.rules[
|
|
45321
|
+
this.rules[8].opcodes[3] = {
|
|
45603
45322
|
type: 4,
|
|
45604
|
-
index:
|
|
45323
|
+
index: 12
|
|
45605
45324
|
}; // RNM(HEXDIG)
|
|
45606
45325
|
|
|
45607
45326
|
/* sub-delims */
|
|
45608
|
-
this.rules[
|
|
45609
|
-
this.rules[
|
|
45327
|
+
this.rules[9].opcodes = [];
|
|
45328
|
+
this.rules[9].opcodes[0] = {
|
|
45610
45329
|
type: 1,
|
|
45611
45330
|
children: [1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11]
|
|
45612
45331
|
}; // ALT
|
|
45613
|
-
this.rules[
|
|
45332
|
+
this.rules[9].opcodes[1] = {
|
|
45614
45333
|
type: 7,
|
|
45615
45334
|
string: [33]
|
|
45616
45335
|
}; // TLS
|
|
45617
|
-
this.rules[
|
|
45336
|
+
this.rules[9].opcodes[2] = {
|
|
45618
45337
|
type: 7,
|
|
45619
45338
|
string: [36]
|
|
45620
45339
|
}; // TLS
|
|
45621
|
-
this.rules[
|
|
45340
|
+
this.rules[9].opcodes[3] = {
|
|
45622
45341
|
type: 7,
|
|
45623
45342
|
string: [38]
|
|
45624
45343
|
}; // TLS
|
|
45625
|
-
this.rules[
|
|
45344
|
+
this.rules[9].opcodes[4] = {
|
|
45626
45345
|
type: 7,
|
|
45627
45346
|
string: [39]
|
|
45628
45347
|
}; // TLS
|
|
45629
|
-
this.rules[
|
|
45348
|
+
this.rules[9].opcodes[5] = {
|
|
45630
45349
|
type: 7,
|
|
45631
45350
|
string: [40]
|
|
45632
45351
|
}; // TLS
|
|
45633
|
-
this.rules[
|
|
45352
|
+
this.rules[9].opcodes[6] = {
|
|
45634
45353
|
type: 7,
|
|
45635
45354
|
string: [41]
|
|
45636
45355
|
}; // TLS
|
|
45637
|
-
this.rules[
|
|
45356
|
+
this.rules[9].opcodes[7] = {
|
|
45638
45357
|
type: 7,
|
|
45639
45358
|
string: [42]
|
|
45640
45359
|
}; // TLS
|
|
45641
|
-
this.rules[
|
|
45360
|
+
this.rules[9].opcodes[8] = {
|
|
45642
45361
|
type: 7,
|
|
45643
45362
|
string: [43]
|
|
45644
45363
|
}; // TLS
|
|
45645
|
-
this.rules[
|
|
45364
|
+
this.rules[9].opcodes[9] = {
|
|
45646
45365
|
type: 7,
|
|
45647
45366
|
string: [44]
|
|
45648
45367
|
}; // TLS
|
|
45649
|
-
this.rules[
|
|
45368
|
+
this.rules[9].opcodes[10] = {
|
|
45650
45369
|
type: 7,
|
|
45651
45370
|
string: [59]
|
|
45652
45371
|
}; // TLS
|
|
45653
|
-
this.rules[
|
|
45372
|
+
this.rules[9].opcodes[11] = {
|
|
45654
45373
|
type: 7,
|
|
45655
45374
|
string: [61]
|
|
45656
45375
|
}; // TLS
|
|
45657
45376
|
|
|
45658
45377
|
/* ALPHA */
|
|
45659
|
-
this.rules[
|
|
45660
|
-
this.rules[
|
|
45378
|
+
this.rules[10].opcodes = [];
|
|
45379
|
+
this.rules[10].opcodes[0] = {
|
|
45661
45380
|
type: 1,
|
|
45662
45381
|
children: [1, 2]
|
|
45663
45382
|
}; // ALT
|
|
45664
|
-
this.rules[
|
|
45383
|
+
this.rules[10].opcodes[1] = {
|
|
45665
45384
|
type: 5,
|
|
45666
45385
|
min: 65,
|
|
45667
45386
|
max: 90
|
|
45668
45387
|
}; // TRG
|
|
45669
|
-
this.rules[
|
|
45388
|
+
this.rules[10].opcodes[2] = {
|
|
45670
45389
|
type: 5,
|
|
45671
45390
|
min: 97,
|
|
45672
45391
|
max: 122
|
|
45673
45392
|
}; // TRG
|
|
45674
45393
|
|
|
45675
45394
|
/* DIGIT */
|
|
45676
|
-
this.rules[
|
|
45677
|
-
this.rules[
|
|
45395
|
+
this.rules[11].opcodes = [];
|
|
45396
|
+
this.rules[11].opcodes[0] = {
|
|
45678
45397
|
type: 5,
|
|
45679
45398
|
min: 48,
|
|
45680
45399
|
max: 57
|
|
45681
45400
|
}; // TRG
|
|
45682
45401
|
|
|
45683
45402
|
/* HEXDIG */
|
|
45684
|
-
this.rules[
|
|
45685
|
-
this.rules[
|
|
45403
|
+
this.rules[12].opcodes = [];
|
|
45404
|
+
this.rules[12].opcodes[0] = {
|
|
45686
45405
|
type: 1,
|
|
45687
45406
|
children: [1, 2, 3, 4, 5, 6, 7]
|
|
45688
45407
|
}; // ALT
|
|
45689
|
-
this.rules[
|
|
45408
|
+
this.rules[12].opcodes[1] = {
|
|
45690
45409
|
type: 4,
|
|
45691
|
-
index:
|
|
45410
|
+
index: 11
|
|
45692
45411
|
}; // RNM(DIGIT)
|
|
45693
|
-
this.rules[
|
|
45412
|
+
this.rules[12].opcodes[2] = {
|
|
45694
45413
|
type: 7,
|
|
45695
45414
|
string: [97]
|
|
45696
45415
|
}; // TLS
|
|
45697
|
-
this.rules[
|
|
45416
|
+
this.rules[12].opcodes[3] = {
|
|
45698
45417
|
type: 7,
|
|
45699
45418
|
string: [98]
|
|
45700
45419
|
}; // TLS
|
|
45701
|
-
this.rules[
|
|
45420
|
+
this.rules[12].opcodes[4] = {
|
|
45702
45421
|
type: 7,
|
|
45703
45422
|
string: [99]
|
|
45704
45423
|
}; // TLS
|
|
45705
|
-
this.rules[
|
|
45424
|
+
this.rules[12].opcodes[5] = {
|
|
45706
45425
|
type: 7,
|
|
45707
45426
|
string: [100]
|
|
45708
45427
|
}; // TLS
|
|
45709
|
-
this.rules[
|
|
45428
|
+
this.rules[12].opcodes[6] = {
|
|
45710
45429
|
type: 7,
|
|
45711
45430
|
string: [101]
|
|
45712
45431
|
}; // TLS
|
|
45713
|
-
this.rules[
|
|
45432
|
+
this.rules[12].opcodes[7] = {
|
|
45714
45433
|
type: 7,
|
|
45715
45434
|
string: [102]
|
|
45716
45435
|
}; // TLS
|
|
@@ -45719,25 +45438,21 @@ function grammar() {
|
|
|
45719
45438
|
this.toString = function toString() {
|
|
45720
45439
|
let str = "";
|
|
45721
45440
|
str += "; OpenAPI Path Templating ABNF syntax\n";
|
|
45722
|
-
str += "path-template =
|
|
45723
|
-
str += "path = slash *( path-segment slash ) [ path-segment ]\n";
|
|
45441
|
+
str += "path-template = slash *( path-segment slash ) [ path-segment ]\n";
|
|
45724
45442
|
str += "path-segment = 1*( path-literal / template-expression )\n";
|
|
45725
|
-
str += "query = *( query-literal )\n";
|
|
45726
|
-
str += "query-literal = 1*( unreserved / pct-encoded / sub-delims / \":\" / \"@\" / \"/\" / \"?\" / \"&\" / \"=\" )\n";
|
|
45727
|
-
str += "query-marker = \"?\"\n";
|
|
45728
|
-
str += "fragment = *( fragment-literal )\n";
|
|
45729
|
-
str += "fragment-literal = 1*( unreserved / pct-encoded / sub-delims / \":\" / \"@\" / \"/\" / \"?\" )\n";
|
|
45730
|
-
str += "fragment-marker = \"#\"\n";
|
|
45731
45443
|
str += "slash = \"/\"\n";
|
|
45732
|
-
str += "path-literal = 1*
|
|
45444
|
+
str += "path-literal = 1*pchar\n";
|
|
45733
45445
|
str += "template-expression = \"{\" template-expression-param-name \"}\"\n";
|
|
45734
|
-
str += "template-expression-param-name = 1*(
|
|
45446
|
+
str += "template-expression-param-name = 1*( %x00-79 / %x7C / %x7E-10FFFF ) ; every UTF8 character except { and } (from OpenAPI)\n";
|
|
45735
45447
|
str += "\n";
|
|
45736
45448
|
str += "; Characters definitions (from RFC 3986)\n";
|
|
45449
|
+
str += "pchar = unreserved / pct-encoded / sub-delims / \":\" / \"@\"\n";
|
|
45737
45450
|
str += "unreserved = ALPHA / DIGIT / \"-\" / \".\" / \"_\" / \"~\"\n";
|
|
45738
45451
|
str += "pct-encoded = \"%\" HEXDIG HEXDIG\n";
|
|
45739
45452
|
str += "sub-delims = \"!\" / \"$\" / \"&\" / \"'\" / \"(\" / \")\"\n";
|
|
45740
45453
|
str += " / \"*\" / \"+\" / \",\" / \";\" / \"=\"\n";
|
|
45454
|
+
str += "\n";
|
|
45455
|
+
str += "; Characters definitions (from RFC 5234)\n";
|
|
45741
45456
|
str += "ALPHA = %x41-5A / %x61-7A ; A-Z / a-z\n";
|
|
45742
45457
|
str += "DIGIT = %x30-39 ; 0-9\n";
|
|
45743
45458
|
str += "HEXDIG = DIGIT / \"A\" / \"B\" / \"C\" / \"D\" / \"E\" / \"F\"\n";
|
|
@@ -45771,7 +45486,7 @@ const encodePathComponent = parameterValue => {
|
|
|
45771
45486
|
}
|
|
45772
45487
|
return encodeURIComponent(parameterValue).replace(/%5B/g, '[').replace(/%5D/g, ']');
|
|
45773
45488
|
};
|
|
45774
|
-
const significantTypes = ['slash', 'path-literal', '
|
|
45489
|
+
const significantTypes = ['slash', 'path-literal', 'template-expression-param-name'];
|
|
45775
45490
|
const resolve = (pathTemplate, parameters, options = {}) => {
|
|
45776
45491
|
const defaultOptions = {
|
|
45777
45492
|
encoder: encodePathComponent
|