diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..8e952a8 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +qseow-dev.code-workspace diff --git a/jwt-scratch/eng.js b/jwt-scratch/eng.js deleted file mode 100644 index a8037e0..0000000 --- a/jwt-scratch/eng.js +++ /dev/null @@ -1,46 +0,0 @@ -require("amd-loader"); - -define(function() { - return function() { - require(['qlik', 'enigma', 'autogenerated/qix/engine-api'], function(qlik, enigma, schema) { - //The base config with all details filled in - var config = { - schema: schema, - appId: "My Demo App.qvf", - session: { - host: "qseow.jprdonnelly.com", - port: 443, - prefix: "", - unsecure: true, - }, - } - //Now that we have a config, use that to connect to the //QIX service. - enigma.getService("qix", config).then(function(qlik) { - qlik.global.openApp(config.appId) - //Open App - qlik.global.openApp(config.appId).then(function(app) { - //Create SessionObject for FieldList - app.createSessionObject({ - qFieldListDef: { - qShowSystem: false, - qShowHidden: false, - qShowSrcTables: true, - qShowSemantic: true, - qShowDerivedFields: true - }, - qInfo: { - qId: "FieldList", - qType: "FieldList" - } - }).then(function(list) { - return list.getLayout(); - }).then(function(listLayout) { - return listLayout.qFieldList.qItems; - }).then(function(fieldItems) { - console.log(fieldItems) - }); - }) - }) - }) - } - }) diff --git a/jwt-scratch/jwt.js b/jwt-scratch/jwt.js deleted file mode 100644 index 5424b59..0000000 --- a/jwt-scratch/jwt.js +++ /dev/null @@ -1,59 +0,0 @@ -const fs = require('fs'); -const jwt = require('jsonwebtoken'); -const { http, https } = require('follow-redirects'); - -// Your Sense Enterprise installation hostname: -const senseHost = 'qseow.jprdonnelly.com'; - -// Your configured virtual proxy prefix for JWT authentication: -const proxyPrefix = 'jwt'; - -// The Sense Enterprise-configured user directory for the user you want to identify -// as: -const userDirectory = 'INTERNAL'; - -// The user to use when creating the session: -const userId = 'sa_api'; - -// The Sense Enterprise-configured JWT structure. Change the attributes to match -// your configuration: -const token = { - directory: userDirectory, - user: userId, -}; - -// Path to the private key used for JWT signing: -const privateKeyPath = './fort_private.key'; -const key = fs.readFileSync(path.resolve(__dirname, privateKeyPath)); - -// Sign the token using the RS256 algorithm: -const signedToken = jwt.sign(token, key, { algorithm: 'RS256' }); - -const options = { - hostname: 'qseow.browntown.local', - port: 443, - path: '/qrs/about?xrfkey=abcdefghijklmnop', - method: 'GET', - // agent: 'Windows', - // login: 'INTERNAL\SA_API', - password: '', - headers: { - 'X-Qlik-Xrfkey' : 'abcdefghijklmnop', - 'X-Qlik-User' : `UserDirectory=${encodeURIComponent('INTERNAL')}; UserId=${encodeURIComponent('sa_api')}`, - 'Authorization' : 'Bearer ${signedToken}'} - }, - // key: fs.readFileSync("client_key.pem"), - // cert: fs.readFileSync("client.pem"), - // ca: fs.readFileSync("root.pem"), - // rejectUnauthorized: false -}; - -https.get(options, function(res) { - console.log("Got response: " + res.statusCode); - res.on("data", function(chunk) { - console.log("BODY: " + chunk); - }); - }).on('error', function(e) { - con - sole.log("Got error: " + e.message); -}); diff --git a/jwt-scratch/client.pem b/jwt-scratch/keys/client.pem similarity index 100% rename from jwt-scratch/client.pem rename to jwt-scratch/keys/client.pem diff --git a/jwt-scratch/client_key.pem b/jwt-scratch/keys/client_key.pem similarity index 100% rename from jwt-scratch/client_key.pem rename to jwt-scratch/keys/client_key.pem diff --git a/jwt-scratch/fort_private.key b/jwt-scratch/keys/fort_private.key similarity index 100% rename from jwt-scratch/fort_private.key rename to jwt-scratch/keys/fort_private.key diff --git a/jwt-scratch/private.key b/jwt-scratch/keys/private.key similarity index 100% rename from jwt-scratch/private.key rename to jwt-scratch/keys/private.key diff --git a/jwt-scratch/public.key b/jwt-scratch/keys/public.key similarity index 100% rename from jwt-scratch/public.key rename to jwt-scratch/keys/public.key diff --git a/jwt-scratch/root.pem b/jwt-scratch/keys/root.pem similarity index 100% rename from jwt-scratch/root.pem rename to jwt-scratch/keys/root.pem diff --git a/jwt-scratch/server.pem b/jwt-scratch/keys/server.pem similarity index 100% rename from jwt-scratch/server.pem rename to jwt-scratch/keys/server.pem diff --git a/jwt-scratch/server_key.pem b/jwt-scratch/keys/server_key.pem similarity index 100% rename from jwt-scratch/server_key.pem rename to jwt-scratch/keys/server_key.pem diff --git a/jwt-scratch/az-token.js b/jwt-scratch/src/az/az-token.js similarity index 100% rename from jwt-scratch/az-token.js rename to jwt-scratch/src/az/az-token.js diff --git a/jwt-scratch/cfw-verifyjwt.js b/jwt-scratch/src/cf/cfw-verifyjwt.js similarity index 100% rename from jwt-scratch/cfw-verifyjwt.js rename to jwt-scratch/src/cf/cfw-verifyjwt.js diff --git a/jwt-scratch/src/js/.jwtE.js.swp b/jwt-scratch/src/js/.jwtE.js.swp new file mode 100644 index 0000000..676a257 Binary files /dev/null and b/jwt-scratch/src/js/.jwtE.js.swp differ diff --git a/jwt-scratch/jwtE.js b/jwt-scratch/src/js/jwtE.js similarity index 77% rename from jwt-scratch/jwtE.js rename to jwt-scratch/src/js/jwtE.js index 1f9feb7..e825798 100644 --- a/jwt-scratch/jwtE.js +++ b/jwt-scratch/src/js/jwtE.js @@ -27,7 +27,7 @@ const token = { }; // Path to the private key used for JWT signing: -const privateKeyPath = "./private.key"; +const privateKeyPath = "../../keys/private.key"; let key = fs.readFileSync(privateKeyPath, "utf8"); // Sign the token using the RS256 algorithm: @@ -40,7 +40,7 @@ let signedToken = jwt.sign(token, key, { algorithm: "RS256" }); const config = { schema, // url: `wss://${senseHost}/${proxyPrefix}/app/engineData`, - url: `https://${senseHost}/${proxyPrefix}/app/engineData`, + url: `wss://${senseHost}/${proxyPrefix}/app/engineData`, // Notice how the signed JWT is passed in the 'Authorization' header using the // 'Bearer' schema: createSocket: (url) => @@ -56,17 +56,17 @@ session .open() .then((global) => { console.log("Session was opened successfully"); - return global.getDocList().then((list) => { - const apps = list - .map((app) => `${app.qDocId} (${app.qTitle || "No title"})`) - .join(", "); - console.log( - `Apps on this Engine that the configured user can open: ${apps}` - ); - session.close(); - }); + // return global.getDocList().then((list) => { + // const apps = list + // .map((app) => `${app.qDocId} (${app.qTitle || "No title"})`) + // .join(", "); + // console.log( + // `Apps on this Engine that the configured user can open: ${apps}` + // ); + // session.close(); + // }); }) .catch((error) => { - console.log("Failed to open session and/or retrieve the app list:", error); + console.log("Failed to open session:", error); process.exit(1); }); diff --git a/jwt-scratch/src/js/node_modules/.bin/semver b/jwt-scratch/src/js/node_modules/.bin/semver new file mode 120000 index 0000000..317eb29 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/.bin/semver @@ -0,0 +1 @@ +../semver/bin/semver \ No newline at end of file diff --git a/jwt-scratch/src/js/node_modules/.yarn-integrity b/jwt-scratch/src/js/node_modules/.yarn-integrity new file mode 100644 index 0000000..985daf8 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/.yarn-integrity @@ -0,0 +1,16 @@ +{ + "systemParams": "linux-arm64-83", + "modulesFolders": [ + "node_modules" + ], + "flags": [], + "linkedModules": [], + "topLevelPatterns": [ + "uWebSockets.js@uNetworking/uWebSockets.js" + ], + "lockfileEntries": { + "uWebSockets.js@uNetworking/uWebSockets.js": "https://codeload.github.com/uNetworking/uWebSockets.js/tar.gz/9af80e10cec000fe6cdbd4037b2154e2ffa08b2d" + }, + "files": [], + "artifacts": {} +} \ No newline at end of file diff --git a/jwt-scratch/src/js/node_modules/buffer-equal-constant-time/.npmignore b/jwt-scratch/src/js/node_modules/buffer-equal-constant-time/.npmignore new file mode 100644 index 0000000..34e4f5c --- /dev/null +++ b/jwt-scratch/src/js/node_modules/buffer-equal-constant-time/.npmignore @@ -0,0 +1,2 @@ +.*.sw[mnop] +node_modules/ diff --git a/jwt-scratch/src/js/node_modules/buffer-equal-constant-time/.travis.yml b/jwt-scratch/src/js/node_modules/buffer-equal-constant-time/.travis.yml new file mode 100644 index 0000000..78e1c01 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/buffer-equal-constant-time/.travis.yml @@ -0,0 +1,4 @@ +language: node_js +node_js: +- "0.11" +- "0.10" diff --git a/jwt-scratch/src/js/node_modules/buffer-equal-constant-time/LICENSE.txt b/jwt-scratch/src/js/node_modules/buffer-equal-constant-time/LICENSE.txt new file mode 100644 index 0000000..9a064f3 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/buffer-equal-constant-time/LICENSE.txt @@ -0,0 +1,12 @@ +Copyright (c) 2013, GoInstant Inc., a salesforce.com company +All rights reserved. + +Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met: + +* Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer. + +* Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution. + +* Neither the name of salesforce.com, nor GoInstant, nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission. + +THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. diff --git a/jwt-scratch/src/js/node_modules/buffer-equal-constant-time/README.md b/jwt-scratch/src/js/node_modules/buffer-equal-constant-time/README.md new file mode 100644 index 0000000..4f227f5 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/buffer-equal-constant-time/README.md @@ -0,0 +1,50 @@ +# buffer-equal-constant-time + +Constant-time `Buffer` comparison for node.js. Should work with browserify too. + +[![Build Status](https://travis-ci.org/goinstant/buffer-equal-constant-time.png?branch=master)](https://travis-ci.org/goinstant/buffer-equal-constant-time) + +```sh + npm install buffer-equal-constant-time +``` + +# Usage + +```js + var bufferEq = require('buffer-equal-constant-time'); + + var a = new Buffer('asdf'); + var b = new Buffer('asdf'); + if (bufferEq(a,b)) { + // the same! + } else { + // different in at least one byte! + } +``` + +If you'd like to install an `.equal()` method onto the node.js `Buffer` and +`SlowBuffer` prototypes: + +```js + require('buffer-equal-constant-time').install(); + + var a = new Buffer('asdf'); + var b = new Buffer('asdf'); + if (a.equal(b)) { + // the same! + } else { + // different in at least one byte! + } +``` + +To get rid of the installed `.equal()` method, call `.restore()`: + +```js + require('buffer-equal-constant-time').restore(); +``` + +# Legal + +© 2013 GoInstant Inc., a salesforce.com company + +Licensed under the BSD 3-clause license. diff --git a/jwt-scratch/src/js/node_modules/buffer-equal-constant-time/index.js b/jwt-scratch/src/js/node_modules/buffer-equal-constant-time/index.js new file mode 100644 index 0000000..5462c1f --- /dev/null +++ b/jwt-scratch/src/js/node_modules/buffer-equal-constant-time/index.js @@ -0,0 +1,41 @@ +/*jshint node:true */ +'use strict'; +var Buffer = require('buffer').Buffer; // browserify +var SlowBuffer = require('buffer').SlowBuffer; + +module.exports = bufferEq; + +function bufferEq(a, b) { + + // shortcutting on type is necessary for correctness + if (!Buffer.isBuffer(a) || !Buffer.isBuffer(b)) { + return false; + } + + // buffer sizes should be well-known information, so despite this + // shortcutting, it doesn't leak any information about the *contents* of the + // buffers. + if (a.length !== b.length) { + return false; + } + + var c = 0; + for (var i = 0; i < a.length; i++) { + /*jshint bitwise:false */ + c |= a[i] ^ b[i]; // XOR + } + return c === 0; +} + +bufferEq.install = function() { + Buffer.prototype.equal = SlowBuffer.prototype.equal = function equal(that) { + return bufferEq(this, that); + }; +}; + +var origBufEqual = Buffer.prototype.equal; +var origSlowBufEqual = SlowBuffer.prototype.equal; +bufferEq.restore = function() { + Buffer.prototype.equal = origBufEqual; + SlowBuffer.prototype.equal = origSlowBufEqual; +}; diff --git a/jwt-scratch/src/js/node_modules/buffer-equal-constant-time/package.json b/jwt-scratch/src/js/node_modules/buffer-equal-constant-time/package.json new file mode 100644 index 0000000..79d2aa3 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/buffer-equal-constant-time/package.json @@ -0,0 +1,55 @@ +{ + "_from": "buffer-equal-constant-time@1.0.1", + "_id": "buffer-equal-constant-time@1.0.1", + "_inBundle": false, + "_integrity": "sha1-+OcRMvf/5uAaXJaXpMbz5I1cyBk=", + "_location": "/buffer-equal-constant-time", + "_phantomChildren": {}, + "_requested": { + "type": "version", + "registry": true, + "raw": "buffer-equal-constant-time@1.0.1", + "name": "buffer-equal-constant-time", + "escapedName": "buffer-equal-constant-time", + "rawSpec": "1.0.1", + "saveSpec": null, + "fetchSpec": "1.0.1" + }, + "_requiredBy": [ + "/jwa" + ], + "_resolved": "https://registry.npmjs.org/buffer-equal-constant-time/-/buffer-equal-constant-time-1.0.1.tgz", + "_shasum": "f8e71132f7ffe6e01a5c9697a4c6f3e48d5cc819", + "_spec": "buffer-equal-constant-time@1.0.1", + "_where": "/home/rock64/git/qseow-scripts/jwt-scratch/src/js/node_modules/jwa", + "author": { + "name": "GoInstant Inc., a salesforce.com company" + }, + "bugs": { + "url": "https://github.com/goinstant/buffer-equal-constant-time/issues" + }, + "bundleDependencies": false, + "deprecated": false, + "description": "Constant-time comparison of Buffers", + "devDependencies": { + "mocha": "~1.15.1" + }, + "homepage": "https://github.com/goinstant/buffer-equal-constant-time#readme", + "keywords": [ + "buffer", + "equal", + "constant-time", + "crypto" + ], + "license": "BSD-3-Clause", + "main": "index.js", + "name": "buffer-equal-constant-time", + "repository": { + "type": "git", + "url": "git+ssh://git@github.com/goinstant/buffer-equal-constant-time.git" + }, + "scripts": { + "test": "mocha test.js" + }, + "version": "1.0.1" +} diff --git a/jwt-scratch/src/js/node_modules/buffer-equal-constant-time/test.js b/jwt-scratch/src/js/node_modules/buffer-equal-constant-time/test.js new file mode 100644 index 0000000..0bc972d --- /dev/null +++ b/jwt-scratch/src/js/node_modules/buffer-equal-constant-time/test.js @@ -0,0 +1,42 @@ +/*jshint node:true */ +'use strict'; + +var bufferEq = require('./index'); +var assert = require('assert'); + +describe('buffer-equal-constant-time', function() { + var a = new Buffer('asdfasdf123456'); + var b = new Buffer('asdfasdf123456'); + var c = new Buffer('asdfasdf'); + + describe('bufferEq', function() { + it('says a == b', function() { + assert.strictEqual(bufferEq(a, b), true); + }); + + it('says a != c', function() { + assert.strictEqual(bufferEq(a, c), false); + }); + }); + + describe('install/restore', function() { + before(function() { + bufferEq.install(); + }); + after(function() { + bufferEq.restore(); + }); + + it('installed an .equal method', function() { + var SlowBuffer = require('buffer').SlowBuffer; + assert.ok(Buffer.prototype.equal); + assert.ok(SlowBuffer.prototype.equal); + }); + + it('infected existing Buffers', function() { + assert.strictEqual(a.equal(b), true); + assert.strictEqual(a.equal(c), false); + }); + }); + +}); diff --git a/jwt-scratch/src/js/node_modules/ecdsa-sig-formatter/CODEOWNERS b/jwt-scratch/src/js/node_modules/ecdsa-sig-formatter/CODEOWNERS new file mode 100644 index 0000000..4451d3d --- /dev/null +++ b/jwt-scratch/src/js/node_modules/ecdsa-sig-formatter/CODEOWNERS @@ -0,0 +1 @@ +* @omsmith diff --git a/jwt-scratch/src/js/node_modules/ecdsa-sig-formatter/LICENSE b/jwt-scratch/src/js/node_modules/ecdsa-sig-formatter/LICENSE new file mode 100644 index 0000000..8754ed6 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/ecdsa-sig-formatter/LICENSE @@ -0,0 +1,201 @@ +Apache License + Version 2.0, January 2004 + http://www.apache.org/licenses/ + + TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION + + 1. Definitions. + + "License" shall mean the terms and conditions for use, reproduction, + and distribution as defined by Sections 1 through 9 of this document. + + "Licensor" shall mean the copyright owner or entity authorized by + the copyright owner that is granting the License. + + "Legal Entity" shall mean the union of the acting entity and all + other entities that control, are controlled by, or are under common + control with that entity. For the purposes of this definition, + "control" means (i) the power, direct or indirect, to cause the + direction or management of such entity, whether by contract or + otherwise, or (ii) ownership of fifty percent (50%) or more of the + outstanding shares, or (iii) beneficial ownership of such entity. + + "You" (or "Your") shall mean an individual or Legal Entity + exercising permissions granted by this License. + + "Source" form shall mean the preferred form for making modifications, + including but not limited to software source code, documentation + source, and configuration files. + + "Object" form shall mean any form resulting from mechanical + transformation or translation of a Source form, including but + not limited to compiled object code, generated documentation, + and conversions to other media types. + + "Work" shall mean the work of authorship, whether in Source or + Object form, made available under the License, as indicated by a + copyright notice that is included in or attached to the work + (an example is provided in the Appendix below). + + "Derivative Works" shall mean any work, whether in Source or Object + form, that is based on (or derived from) the Work and for which the + editorial revisions, annotations, elaborations, or other modifications + represent, as a whole, an original work of authorship. For the purposes + of this License, Derivative Works shall not include works that remain + separable from, or merely link (or bind by name) to the interfaces of, + the Work and Derivative Works thereof. + + "Contribution" shall mean any work of authorship, including + the original version of the Work and any modifications or additions + to that Work or Derivative Works thereof, that is intentionally + submitted to Licensor for inclusion in the Work by the copyright owner + or by an individual or Legal Entity authorized to submit on behalf of + the copyright owner. For the purposes of this definition, "submitted" + means any form of electronic, verbal, or written communication sent + to the Licensor or its representatives, including but not limited to + communication on electronic mailing lists, source code control systems, + and issue tracking systems that are managed by, or on behalf of, the + Licensor for the purpose of discussing and improving the Work, but + excluding communication that is conspicuously marked or otherwise + designated in writing by the copyright owner as "Not a Contribution." + + "Contributor" shall mean Licensor and any individual or Legal Entity + on behalf of whom a Contribution has been received by Licensor and + subsequently incorporated within the Work. + + 2. Grant of Copyright License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + copyright license to reproduce, prepare Derivative Works of, + publicly display, publicly perform, sublicense, and distribute the + Work and such Derivative Works in Source or Object form. + + 3. Grant of Patent License. Subject to the terms and conditions of + this License, each Contributor hereby grants to You a perpetual, + worldwide, non-exclusive, no-charge, royalty-free, irrevocable + (except as stated in this section) patent license to make, have made, + use, offer to sell, sell, import, and otherwise transfer the Work, + where such license applies only to those patent claims licensable + by such Contributor that are necessarily infringed by their + Contribution(s) alone or by combination of their Contribution(s) + with the Work to which such Contribution(s) was submitted. If You + institute patent litigation against any entity (including a + cross-claim or counterclaim in a lawsuit) alleging that the Work + or a Contribution incorporated within the Work constitutes direct + or contributory patent infringement, then any patent licenses + granted to You under this License for that Work shall terminate + as of the date such litigation is filed. + + 4. Redistribution. You may reproduce and distribute copies of the + Work or Derivative Works thereof in any medium, with or without + modifications, and in Source or Object form, provided that You + meet the following conditions: + + (a) You must give any other recipients of the Work or + Derivative Works a copy of this License; and + + (b) You must cause any modified files to carry prominent notices + stating that You changed the files; and + + (c) You must retain, in the Source form of any Derivative Works + that You distribute, all copyright, patent, trademark, and + attribution notices from the Source form of the Work, + excluding those notices that do not pertain to any part of + the Derivative Works; and + + (d) If the Work includes a "NOTICE" text file as part of its + distribution, then any Derivative Works that You distribute must + include a readable copy of the attribution notices contained + within such NOTICE file, excluding those notices that do not + pertain to any part of the Derivative Works, in at least one + of the following places: within a NOTICE text file distributed + as part of the Derivative Works; within the Source form or + documentation, if provided along with the Derivative Works; or, + within a display generated by the Derivative Works, if and + wherever such third-party notices normally appear. The contents + of the NOTICE file are for informational purposes only and + do not modify the License. You may add Your own attribution + notices within Derivative Works that You distribute, alongside + or as an addendum to the NOTICE text from the Work, provided + that such additional attribution notices cannot be construed + as modifying the License. + + You may add Your own copyright statement to Your modifications and + may provide additional or different license terms and conditions + for use, reproduction, or distribution of Your modifications, or + for any such Derivative Works as a whole, provided Your use, + reproduction, and distribution of the Work otherwise complies with + the conditions stated in this License. + + 5. Submission of Contributions. Unless You explicitly state otherwise, + any Contribution intentionally submitted for inclusion in the Work + by You to the Licensor shall be under the terms and conditions of + this License, without any additional terms or conditions. + Notwithstanding the above, nothing herein shall supersede or modify + the terms of any separate license agreement you may have executed + with Licensor regarding such Contributions. + + 6. Trademarks. This License does not grant permission to use the trade + names, trademarks, service marks, or product names of the Licensor, + except as required for reasonable and customary use in describing the + origin of the Work and reproducing the content of the NOTICE file. + + 7. Disclaimer of Warranty. Unless required by applicable law or + agreed to in writing, Licensor provides the Work (and each + Contributor provides its Contributions) on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or + implied, including, without limitation, any warranties or conditions + of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A + PARTICULAR PURPOSE. You are solely responsible for determining the + appropriateness of using or redistributing the Work and assume any + risks associated with Your exercise of permissions under this License. + + 8. Limitation of Liability. In no event and under no legal theory, + whether in tort (including negligence), contract, or otherwise, + unless required by applicable law (such as deliberate and grossly + negligent acts) or agreed to in writing, shall any Contributor be + liable to You for damages, including any direct, indirect, special, + incidental, or consequential damages of any character arising as a + result of this License or out of the use or inability to use the + Work (including but not limited to damages for loss of goodwill, + work stoppage, computer failure or malfunction, or any and all + other commercial damages or losses), even if such Contributor + has been advised of the possibility of such damages. + + 9. Accepting Warranty or Additional Liability. While redistributing + the Work or Derivative Works thereof, You may choose to offer, + and charge a fee for, acceptance of support, warranty, indemnity, + or other liability obligations and/or rights consistent with this + License. However, in accepting such obligations, You may act only + on Your own behalf and on Your sole responsibility, not on behalf + of any other Contributor, and only if You agree to indemnify, + defend, and hold each Contributor harmless for any liability + incurred by, or claims asserted against, such Contributor by reason + of your accepting any such warranty or additional liability. + + END OF TERMS AND CONDITIONS + + APPENDIX: How to apply the Apache License to your work. + + To apply the Apache License to your work, attach the following + boilerplate notice, with the fields enclosed by brackets "{}" + replaced with your own identifying information. (Don't include + the brackets!) The text should be enclosed in the appropriate + comment syntax for the file format. We also recommend that a + file or class name and description of purpose be included on the + same "printed page" as the copyright notice for easier + identification within third-party archives. + + Copyright 2015 D2L Corporation + + Licensed under the Apache License, Version 2.0 (the "License"); + you may not use this file except in compliance with the License. + You may obtain a copy of the License at + + http://www.apache.org/licenses/LICENSE-2.0 + + Unless required by applicable law or agreed to in writing, software + distributed under the License is distributed on an "AS IS" BASIS, + WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + See the License for the specific language governing permissions and + limitations under the License. diff --git a/jwt-scratch/src/js/node_modules/ecdsa-sig-formatter/README.md b/jwt-scratch/src/js/node_modules/ecdsa-sig-formatter/README.md new file mode 100644 index 0000000..daa95d6 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/ecdsa-sig-formatter/README.md @@ -0,0 +1,65 @@ +# ecdsa-sig-formatter + +[![Build Status](https://travis-ci.org/Brightspace/node-ecdsa-sig-formatter.svg?branch=master)](https://travis-ci.org/Brightspace/node-ecdsa-sig-formatter) [![Coverage Status](https://coveralls.io/repos/Brightspace/node-ecdsa-sig-formatter/badge.svg)](https://coveralls.io/r/Brightspace/node-ecdsa-sig-formatter) + +Translate between JOSE and ASN.1/DER encodings for ECDSA signatures + +## Install +```sh +npm install ecdsa-sig-formatter --save +``` + +## Usage +```js +var format = require('ecdsa-sig-formatter'); + +var derSignature = '..'; // asn.1/DER encoded ecdsa signature + +var joseSignature = format.derToJose(derSignature); + +``` + +### API + +--- + +#### `.derToJose(Buffer|String signature, String alg)` -> `String` + +Convert the ASN.1/DER encoded signature to a JOSE-style concatenated signature. +Returns a _base64 url_ encoded `String`. + +* If _signature_ is a `String`, it should be _base64_ encoded +* _alg_ must be one of _ES256_, _ES384_ or _ES512_ + +--- + +#### `.joseToDer(Buffer|String signature, String alg)` -> `Buffer` + +Convert the JOSE-style concatenated signature to an ASN.1/DER encoded +signature. Returns a `Buffer` + +* If _signature_ is a `String`, it should be _base64 url_ encoded +* _alg_ must be one of _ES256_, _ES384_ or _ES512_ + +## Contributing + +1. **Fork** the repository. Committing directly against this repository is + highly discouraged. + +2. Make your modifications in a branch, updating and writing new unit tests + as necessary in the `spec` directory. + +3. Ensure that all tests pass with `npm test` + +4. `rebase` your changes against master. *Do not merge*. + +5. Submit a pull request to this repository. Wait for tests to run and someone + to chime in. + +### Code Style + +This repository is configured with [EditorConfig][EditorConfig] and +[ESLint][ESLint] rules. + +[EditorConfig]: http://editorconfig.org/ +[ESLint]: http://eslint.org diff --git a/jwt-scratch/src/js/node_modules/ecdsa-sig-formatter/package.json b/jwt-scratch/src/js/node_modules/ecdsa-sig-formatter/package.json new file mode 100644 index 0000000..922a3ff --- /dev/null +++ b/jwt-scratch/src/js/node_modules/ecdsa-sig-formatter/package.json @@ -0,0 +1,73 @@ +{ + "_from": "ecdsa-sig-formatter@1.0.11", + "_id": "ecdsa-sig-formatter@1.0.11", + "_inBundle": false, + "_integrity": "sha512-nagl3RYrbNv6kQkeJIpt6NJZy8twLB/2vtz6yN9Z4vRKHN4/QZJIEbqohALSgwKdnksuY3k5Addp5lg8sVoVcQ==", + "_location": "/ecdsa-sig-formatter", + "_phantomChildren": {}, + "_requested": { + "type": "version", + "registry": true, + "raw": "ecdsa-sig-formatter@1.0.11", + "name": "ecdsa-sig-formatter", + "escapedName": "ecdsa-sig-formatter", + "rawSpec": "1.0.11", + "saveSpec": null, + "fetchSpec": "1.0.11" + }, + "_requiredBy": [ + "/jwa" + ], + "_resolved": "https://registry.npmjs.org/ecdsa-sig-formatter/-/ecdsa-sig-formatter-1.0.11.tgz", + "_shasum": "ae0f0fa2d85045ef14a817daa3ce9acd0489e5bf", + "_spec": "ecdsa-sig-formatter@1.0.11", + "_where": "/home/rock64/git/qseow-scripts/jwt-scratch/src/js/node_modules/jwa", + "author": { + "name": "D2L Corporation" + }, + "bugs": { + "url": "https://github.com/Brightspace/node-ecdsa-sig-formatter/issues" + }, + "bundleDependencies": false, + "dependencies": { + "safe-buffer": "^5.0.1" + }, + "deprecated": false, + "description": "Translate ECDSA signatures between ASN.1/DER and JOSE-style concatenation", + "devDependencies": { + "bench": "^0.3.6", + "chai": "^3.5.0", + "coveralls": "^2.11.9", + "eslint": "^2.12.0", + "eslint-config-brightspace": "^0.2.1", + "istanbul": "^0.4.3", + "jwk-to-pem": "^1.2.5", + "mocha": "^2.5.3", + "native-crypto": "^1.7.0" + }, + "homepage": "https://github.com/Brightspace/node-ecdsa-sig-formatter#readme", + "keywords": [ + "ecdsa", + "der", + "asn.1", + "jwt", + "jwa", + "jsonwebtoken", + "jose" + ], + "license": "Apache-2.0", + "main": "src/ecdsa-sig-formatter.js", + "name": "ecdsa-sig-formatter", + "repository": { + "type": "git", + "url": "git+ssh://git@github.com/Brightspace/node-ecdsa-sig-formatter.git" + }, + "scripts": { + "check-style": "eslint .", + "pretest": "npm run check-style", + "report-cov": "cat ./coverage/lcov.info | coveralls", + "test": "istanbul cover --root src _mocha -- spec" + }, + "typings": "./src/ecdsa-sig-formatter.d.ts", + "version": "1.0.11" +} diff --git a/jwt-scratch/src/js/node_modules/ecdsa-sig-formatter/src/ecdsa-sig-formatter.d.ts b/jwt-scratch/src/js/node_modules/ecdsa-sig-formatter/src/ecdsa-sig-formatter.d.ts new file mode 100644 index 0000000..9693aa0 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/ecdsa-sig-formatter/src/ecdsa-sig-formatter.d.ts @@ -0,0 +1,17 @@ +/// + +declare module "ecdsa-sig-formatter" { + /** + * Convert the ASN.1/DER encoded signature to a JOSE-style concatenated signature. Returns a base64 url encoded String. + * If signature is a String, it should be base64 encoded + * alg must be one of ES256, ES384 or ES512 + */ + export function derToJose(signature: Buffer | string, alg: string): string; + + /** + * Convert the JOSE-style concatenated signature to an ASN.1/DER encoded signature. Returns a Buffer + * If signature is a String, it should be base64 url encoded + * alg must be one of ES256, ES384 or ES512 + */ + export function joseToDer(signature: Buffer | string, alg: string): Buffer +} diff --git a/jwt-scratch/src/js/node_modules/ecdsa-sig-formatter/src/ecdsa-sig-formatter.js b/jwt-scratch/src/js/node_modules/ecdsa-sig-formatter/src/ecdsa-sig-formatter.js new file mode 100644 index 0000000..38eeb9b --- /dev/null +++ b/jwt-scratch/src/js/node_modules/ecdsa-sig-formatter/src/ecdsa-sig-formatter.js @@ -0,0 +1,187 @@ +'use strict'; + +var Buffer = require('safe-buffer').Buffer; + +var getParamBytesForAlg = require('./param-bytes-for-alg'); + +var MAX_OCTET = 0x80, + CLASS_UNIVERSAL = 0, + PRIMITIVE_BIT = 0x20, + TAG_SEQ = 0x10, + TAG_INT = 0x02, + ENCODED_TAG_SEQ = (TAG_SEQ | PRIMITIVE_BIT) | (CLASS_UNIVERSAL << 6), + ENCODED_TAG_INT = TAG_INT | (CLASS_UNIVERSAL << 6); + +function base64Url(base64) { + return base64 + .replace(/=/g, '') + .replace(/\+/g, '-') + .replace(/\//g, '_'); +} + +function signatureAsBuffer(signature) { + if (Buffer.isBuffer(signature)) { + return signature; + } else if ('string' === typeof signature) { + return Buffer.from(signature, 'base64'); + } + + throw new TypeError('ECDSA signature must be a Base64 string or a Buffer'); +} + +function derToJose(signature, alg) { + signature = signatureAsBuffer(signature); + var paramBytes = getParamBytesForAlg(alg); + + // the DER encoded param should at most be the param size, plus a padding + // zero, since due to being a signed integer + var maxEncodedParamLength = paramBytes + 1; + + var inputLength = signature.length; + + var offset = 0; + if (signature[offset++] !== ENCODED_TAG_SEQ) { + throw new Error('Could not find expected "seq"'); + } + + var seqLength = signature[offset++]; + if (seqLength === (MAX_OCTET | 1)) { + seqLength = signature[offset++]; + } + + if (inputLength - offset < seqLength) { + throw new Error('"seq" specified length of "' + seqLength + '", only "' + (inputLength - offset) + '" remaining'); + } + + if (signature[offset++] !== ENCODED_TAG_INT) { + throw new Error('Could not find expected "int" for "r"'); + } + + var rLength = signature[offset++]; + + if (inputLength - offset - 2 < rLength) { + throw new Error('"r" specified length of "' + rLength + '", only "' + (inputLength - offset - 2) + '" available'); + } + + if (maxEncodedParamLength < rLength) { + throw new Error('"r" specified length of "' + rLength + '", max of "' + maxEncodedParamLength + '" is acceptable'); + } + + var rOffset = offset; + offset += rLength; + + if (signature[offset++] !== ENCODED_TAG_INT) { + throw new Error('Could not find expected "int" for "s"'); + } + + var sLength = signature[offset++]; + + if (inputLength - offset !== sLength) { + throw new Error('"s" specified length of "' + sLength + '", expected "' + (inputLength - offset) + '"'); + } + + if (maxEncodedParamLength < sLength) { + throw new Error('"s" specified length of "' + sLength + '", max of "' + maxEncodedParamLength + '" is acceptable'); + } + + var sOffset = offset; + offset += sLength; + + if (offset !== inputLength) { + throw new Error('Expected to consume entire buffer, but "' + (inputLength - offset) + '" bytes remain'); + } + + var rPadding = paramBytes - rLength, + sPadding = paramBytes - sLength; + + var dst = Buffer.allocUnsafe(rPadding + rLength + sPadding + sLength); + + for (offset = 0; offset < rPadding; ++offset) { + dst[offset] = 0; + } + signature.copy(dst, offset, rOffset + Math.max(-rPadding, 0), rOffset + rLength); + + offset = paramBytes; + + for (var o = offset; offset < o + sPadding; ++offset) { + dst[offset] = 0; + } + signature.copy(dst, offset, sOffset + Math.max(-sPadding, 0), sOffset + sLength); + + dst = dst.toString('base64'); + dst = base64Url(dst); + + return dst; +} + +function countPadding(buf, start, stop) { + var padding = 0; + while (start + padding < stop && buf[start + padding] === 0) { + ++padding; + } + + var needsSign = buf[start + padding] >= MAX_OCTET; + if (needsSign) { + --padding; + } + + return padding; +} + +function joseToDer(signature, alg) { + signature = signatureAsBuffer(signature); + var paramBytes = getParamBytesForAlg(alg); + + var signatureBytes = signature.length; + if (signatureBytes !== paramBytes * 2) { + throw new TypeError('"' + alg + '" signatures must be "' + paramBytes * 2 + '" bytes, saw "' + signatureBytes + '"'); + } + + var rPadding = countPadding(signature, 0, paramBytes); + var sPadding = countPadding(signature, paramBytes, signature.length); + var rLength = paramBytes - rPadding; + var sLength = paramBytes - sPadding; + + var rsBytes = 1 + 1 + rLength + 1 + 1 + sLength; + + var shortLength = rsBytes < MAX_OCTET; + + var dst = Buffer.allocUnsafe((shortLength ? 2 : 3) + rsBytes); + + var offset = 0; + dst[offset++] = ENCODED_TAG_SEQ; + if (shortLength) { + // Bit 8 has value "0" + // bits 7-1 give the length. + dst[offset++] = rsBytes; + } else { + // Bit 8 of first octet has value "1" + // bits 7-1 give the number of additional length octets. + dst[offset++] = MAX_OCTET | 1; + // length, base 256 + dst[offset++] = rsBytes & 0xff; + } + dst[offset++] = ENCODED_TAG_INT; + dst[offset++] = rLength; + if (rPadding < 0) { + dst[offset++] = 0; + offset += signature.copy(dst, offset, 0, paramBytes); + } else { + offset += signature.copy(dst, offset, rPadding, paramBytes); + } + dst[offset++] = ENCODED_TAG_INT; + dst[offset++] = sLength; + if (sPadding < 0) { + dst[offset++] = 0; + signature.copy(dst, offset, paramBytes); + } else { + signature.copy(dst, offset, paramBytes + sPadding); + } + + return dst; +} + +module.exports = { + derToJose: derToJose, + joseToDer: joseToDer +}; diff --git a/jwt-scratch/src/js/node_modules/ecdsa-sig-formatter/src/param-bytes-for-alg.js b/jwt-scratch/src/js/node_modules/ecdsa-sig-formatter/src/param-bytes-for-alg.js new file mode 100644 index 0000000..9fe67ac --- /dev/null +++ b/jwt-scratch/src/js/node_modules/ecdsa-sig-formatter/src/param-bytes-for-alg.js @@ -0,0 +1,23 @@ +'use strict'; + +function getParamSize(keySize) { + var result = ((keySize / 8) | 0) + (keySize % 8 === 0 ? 0 : 1); + return result; +} + +var paramBytesForAlg = { + ES256: getParamSize(256), + ES384: getParamSize(384), + ES512: getParamSize(521) +}; + +function getParamBytesForAlg(alg) { + var paramBytes = paramBytesForAlg[alg]; + if (paramBytes) { + return paramBytes; + } + + throw new Error('Unknown algorithm "' + alg + '"'); +} + +module.exports = getParamBytesForAlg; diff --git a/jwt-scratch/src/js/node_modules/enigma.js/CHANGELOG.md b/jwt-scratch/src/js/node_modules/enigma.js/CHANGELOG.md new file mode 100644 index 0000000..d1e1c90 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/enigma.js/CHANGELOG.md @@ -0,0 +1,166 @@ +# Changelog + +## 2.7.2 + +- fix massive arrays breaking the json patch + +## 2.7.1 + +- fix: corrected the "Socket closed" and "Socket error" to be true enigma errors (#739) + +## 2.7.0 + +- feat: added new schema, 12.612.0 +- fix: malformed api specification + +## 2.6.2 / 2.6.3 + +### Fixes + +- fix: no undefined error on closed resolver (#678) +- chore(deps): pdate minor and patch (#679) +- chore(deps): update qlikcore/engine docker tag to v12.515.0 (#680) + +## 2.6.1 + +### Fixes + +- chore(deps): update dependency rollup to v1.27.0 (#676) +- fix(session): no echo code on suspend in rpcClosed (#675) + +## 2.6.0 + +### New features + +- feat: send code and reason through suspend chain (#673) + +### Fixes + +- chore(deps): update dependency rollup to v1.26.4 (#671) +- chore(deps): update minor and patch (#670) +- chore(deps): update dependency rollup to v1.26.3 (#668) +- chore(deps): update minor and patch (#667) +- chore: dont generate source maps for error-codes (#666) +- fix(error-codes): wrong description (#664) + +## 2.5.0 + +### New features + +- Thrown errors now contain an error code (#661) + +### Fixes + +- prefer sessionid in session app creation methods (#662) + +## 2.4.1 + +- fix: allow code and reason on session close to pass through (#656) + +## 2.4.0 + +### New features + +- Traffic events on generated APIs which allows a developer to listen to handle-specific traffic for e.g. debugging purposes or tracking raw responses. See [documentation](https://github.com/qlik-oss/enigma.js/blob/master/docs/api.md#event-trafficsent-1). + +## 2.3.2 + +- Added `error.code` with value `-1` when requests are rejected due to closed socket. + +## 2.3.1 + +- API specification published. + +## 2.3.0 + +- New schema: 12.170.2 + +## 2.2.1 + +- Bugfix for single-parameter method calls when using arrays which would cause the named parameters logic to take over. + +## 2.2.0 + +- Expose `session.config`. See [documentation](https://github.com/qlik-oss/enigma.js/blob/master/docs/api.md#sessionconfig). +- Use `Promise.reject` instead of `throw` in the api and error response interceptors. +- Removed `bluebird` dependency in tests. +- Made `retry aborted` example more robust. + +## 2.1.1 + +- Bugfix for response interceptor execution order +- Bugfix for failed delta patching when falsy values are unchanged + +## 2.1.0 + +### New features + +- Possibility to add request interceptors. See [documentation](https://github.com/qlik-oss/enigma.js/blob/master/docs/api.md#requests). + +- Bugfix for delta flag (was unable to turn it off, regression from 2.0 rewrite) + +- New schema: 12.34.11 + +## 2.0.2 + +- Bugfix for suspended state when network caused a socket disconnect. + +## 2.0.1 + +- Bugfix for `suspendOnClose` configuration option when session is closed by network. + +## 2.0.0 + +This is a new major version and introduces some breaking changes. Please check the migration guide +and make sure you understand the impact on your application before upgrading. + +See [migration guide](https://github.com/qlik-oss/enigma.js/blob/master/docs/migrate-v1.md). + +### New features + +- Interceptor concept publicly available. See [documentation](https://github.com/qlik-oss/enigma.js/blob/master/docs/api.md#interceptors). +- Support for named QIX method parameters. See [documentation](https://github.com/qlik-oss/enigma.js/blob/master/docs/concepts.md#schemas-the-qix-interface). +- New optional module sense-utilities. See [documentation](https://github.com/qlik-oss/enigma.js/blob/master/docs/api.md#sense-utilities-api). + +### Notable changes + +- No more product-specific configuration, 23 settings down to 8. See [documentation](https://github.com/qlik-oss/enigma.js/blob/master/docs/api.md#configuration). +- Dropped enigma.js REST service. See [documentation](https://github.com/qlik-oss/enigma.js/blob/master/docs/migrate-v1.md#service-concept-dropped). +- File size is ~15 times smaller (around 7kb gzipped) +- Full control of session life-cycles. See [documentation](https://github.com/qlik-oss/enigma.js/blob/master/docs/api.md#session-api). + +## 1.2.1 + +- Bugfix related to suspend/resume, notification should be qSessionState (not qConnectedState). + +## 1.2.0 + +### Features +- Suspend/Resume: It is now possible to suspend an resume qix sessions. See [session.md](https://github.com/qlik-oss/enigma.js/blob/master/docs/qix/session.md#sessions). + +## 1.1.1 + +### Features + +- Logging (QIX/REST): It is now possible to (optionally) log traffic (request/response), this may be expanded to log other things in the future. See configuration entry `handleLog` for [QIX](docs/qix/configuration.md#config-object) and [REST](docs/rest/configuration.md#configuration). +- API types (QIX): All object APIs returned from enigma.js now exposes their generic type (e.g. `sheet`), and their "engine" type (e.g. `GenericObject`). They can be accessed using `api.genericType` and `api.type`. +- URL Parameters (QIX): You can now specify additional querystring parameters that should be added to the websocket URL by using `session.urlParams` configuration option. See [configuration documentation](docs/qix/configuration.md#configuration). +- New schema (QIX): A schema for version `3.2` has been added. +- Documentation (QIX): Added [documentation of the object API `.session` property](docs/qix/session.md), which (among other things) allows you to close apps. + +### Deprecations + +- Configuration (QIX): `config.session.reloadUri` in favor of `config.session.urlParams`. +- Configuration (QIX/REST): `config.unsecure` (default `false`) in favor of `config.secure` (default `true`). + +## 1.1.0 + +Broken release. Do not use. + +## 1.0.1 + +- Fix #5: Make / optional in prefix + +## 1.0.0 + +Initial public release. diff --git a/jwt-scratch/src/js/node_modules/enigma.js/LICENSE b/jwt-scratch/src/js/node_modules/enigma.js/LICENSE new file mode 100644 index 0000000..58480f7 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/enigma.js/LICENSE @@ -0,0 +1,21 @@ +The MIT License + +Copyright (c) 2016-present QlikTech International AB + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. \ No newline at end of file diff --git a/jwt-scratch/src/js/node_modules/enigma.js/README.md b/jwt-scratch/src/js/node_modules/enigma.js/README.md new file mode 100644 index 0000000..dd48113 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/enigma.js/README.md @@ -0,0 +1,120 @@ +![](enigma.png) + +[![CircleCI](https://circleci.com/gh/qlik-oss/enigma.js.svg?style=shield)](https://circleci.com/gh/qlik-oss/enigma.js) +[![Coverage Status](https://img.shields.io/coveralls/qlik-oss/enigma.js/master.svg)](https://coveralls.io/github/qlik-oss/enigma.js) + +enigma.js is a library that helps you communicate with Qlik QIX Engine. Examples of use may be building your own browser-based analytics tools, back-end services, or command-line scripts. + +--- + +- [Getting started](#getting-started) +- [High-level concepts](./docs/concepts.md#high-level-concepts) +- [API documentation](./docs/api.md#api-documentation) +- [API documentation for v1.x](https://github.com/qlik-oss/enigma.js/tree/v1.x/docs#overview) +- [Migrating from v1.x](./docs/migrate-v1.md#migrating-from-version-1x) +- [Contributing](./.github/CONTRIBUTING.md#contributing-to-enigmajs) +- [Releasing](./.github/CONTRIBUTING.md#releasing) +- [Runnable examples](./examples/README.md#runnable-examples) + +--- + +## Getting started + +### Prerequisites + +Before continuing, make sure that you have these tools installed: + +* Node.js >= 4.0 +* Git bash if on Windows + +And know of at least some of these web technologies: + +* JavaScript +* Promises +* Websockets + +### Schemas + +enigma.js use schemas as a source when generating the QIX Engine API. The exact +version of the schema you need is based on the QIX Engine version you want to +communicate with, as well as what you plan on using in the QIX Engine API. + +Keep in mind that before version `12.20.0` the schema version corresponds to the +Qlik Sense Enterprise version, and from `12.20.0` and forward, the schema version +is mapped to the QIX Engine API version. + +Read more: + +* [High-level concepts: Schemas](./docs/concepts.md#schemas-the-qix-interface) for more information about how they work. +* [schemas/](/schemas) for the available schemas. +* [API Insights on Qlik Sense Help](https://api-insights.qlik.com/#/manifest) to identify your QIX Engine API version. + +### Usage + +First off, install enigma.js and a WebSocket library: + +```sh +npm i -S enigma.js ws +``` + +Next, create a new file called `my-file.js` and put the following code into it: + +```js +const enigma = require('enigma.js'); +const WebSocket = require('ws'); +const schema = require('enigma.js/schemas/12.20.0.json'); + +// create a new session: +const session = enigma.create({ + schema, + url: 'ws://localhost:9076/app/engineData', + createSocket: url => new WebSocket(url), +}); + +// bind traffic events to log what is sent and received on the socket: +session.on('traffic:sent', data => console.log('sent:', data)); +session.on('traffic:received', data => console.log('received:', data)); + +// open the socket and eventually receive the QIX global API, and then close +// the session: +session.open() + .then((/*global*/) => console.log('We are connected!')) + .then(() => session.close()) + .then(() => console.log('Session closed')) + .catch(err => console.log('Something went wrong :(', err)); +``` + +And then run it: + +```sh +node my-file.js +``` + +You may need to adjust the code so the URL points towards your running QIX Engine. + +![/getting-started.gif](/getting-started.gif) + +You may also use a service like [unpkg](https://unpkg.com/#/) to test enigma.js directly in your browser without using Node.js for development purposes. + +Create a HTML file `index.html` and insert the following example content: + +```html + + +``` diff --git a/jwt-scratch/src/js/node_modules/enigma.js/enigma.js b/jwt-scratch/src/js/node_modules/enigma.js/enigma.js new file mode 100644 index 0000000..7b9b575 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/enigma.js/enigma.js @@ -0,0 +1,3263 @@ +/** + * enigma.js v2.7.2 + * Copyright (c) 2020 QlikTech International AB + * This library is licensed under MIT - See the LICENSE file for full details + */ + +(function (global, factory) { + typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() : + typeof define === 'function' && define.amd ? define(factory) : + (global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.enigma = factory()); +}(this, (function () { 'use strict'; + + /** + * Utility functions + */ + + var util = {}; + + util.isObject = function isObject(arg) { + return typeof arg === 'object' && arg !== null; + }; + + util.isNumber = function isNumber(arg) { + return typeof arg === 'number'; + }; + + util.isUndefined = function isUndefined(arg) { + return arg === void 0; + }; + + util.isFunction = function isFunction(arg){ + return typeof arg === 'function'; + }; + + + /** + * EventEmitter class + */ + + function EventEmitter() { + EventEmitter.init.call(this); + } + var nodeEventEmitter = EventEmitter; + + // Backwards-compat with node 0.10.x + EventEmitter.EventEmitter = EventEmitter; + + EventEmitter.prototype._events = undefined; + EventEmitter.prototype._maxListeners = undefined; + + // By default EventEmitters will print a warning if more than 10 listeners are + // added to it. This is a useful default which helps finding memory leaks. + EventEmitter.defaultMaxListeners = 10; + + EventEmitter.init = function() { + this._events = this._events || {}; + this._maxListeners = this._maxListeners || undefined; + }; + + // Obviously not all Emitters should be limited to 10. This function allows + // that to be increased. Set to zero for unlimited. + EventEmitter.prototype.setMaxListeners = function(n) { + if (!util.isNumber(n) || n < 0 || isNaN(n)) + throw TypeError('n must be a positive number'); + this._maxListeners = n; + return this; + }; + + EventEmitter.prototype.emit = function(type) { + var er, handler, len, args, i, listeners; + + if (!this._events) + this._events = {}; + + // If there is no 'error' event listener then throw. + if (type === 'error' && !this._events.error) { + er = arguments[1]; + if (er instanceof Error) { + throw er; // Unhandled 'error' event + } else { + throw Error('Uncaught, unspecified "error" event.'); + } + } + + handler = this._events[type]; + + if (util.isUndefined(handler)) + return false; + + if (util.isFunction(handler)) { + switch (arguments.length) { + // fast cases + case 1: + handler.call(this); + break; + case 2: + handler.call(this, arguments[1]); + break; + case 3: + handler.call(this, arguments[1], arguments[2]); + break; + // slower + default: + len = arguments.length; + args = new Array(len - 1); + for (i = 1; i < len; i++) + args[i - 1] = arguments[i]; + handler.apply(this, args); + } + } else if (util.isObject(handler)) { + len = arguments.length; + args = new Array(len - 1); + for (i = 1; i < len; i++) + args[i - 1] = arguments[i]; + + listeners = handler.slice(); + len = listeners.length; + for (i = 0; i < len; i++) + listeners[i].apply(this, args); + } + + return true; + }; + + EventEmitter.prototype.addListener = function(type, listener) { + var m; + + if (!util.isFunction(listener)) + throw TypeError('listener must be a function'); + + if (!this._events) + this._events = {}; + + // To avoid recursion in the case that type === "newListener"! Before + // adding it to the listeners, first emit "newListener". + if (this._events.newListener) + this.emit('newListener', type, + util.isFunction(listener.listener) ? + listener.listener : listener); + + if (!this._events[type]) + // Optimize the case of one listener. Don't need the extra array object. + this._events[type] = listener; + else if (util.isObject(this._events[type])) + // If we've already got an array, just append. + this._events[type].push(listener); + else + // Adding the second element, need to change to array. + this._events[type] = [this._events[type], listener]; + + // Check for listener leak + if (util.isObject(this._events[type]) && !this._events[type].warned) { + var m; + if (!util.isUndefined(this._maxListeners)) { + m = this._maxListeners; + } else { + m = EventEmitter.defaultMaxListeners; + } + + if (m && m > 0 && this._events[type].length > m) { + this._events[type].warned = true; + + if (util.isFunction(console.error)) { + console.error('(node) warning: possible EventEmitter memory ' + + 'leak detected. %d listeners added. ' + + 'Use emitter.setMaxListeners() to increase limit.', + this._events[type].length); + } + if (util.isFunction(console.trace)) + console.trace(); + } + } + + return this; + }; + + EventEmitter.prototype.on = EventEmitter.prototype.addListener; + + EventEmitter.prototype.once = function(type, listener) { + if (!util.isFunction(listener)) + throw TypeError('listener must be a function'); + + var fired = false; + + function g() { + this.removeListener(type, g); + + if (!fired) { + fired = true; + listener.apply(this, arguments); + } + } + + g.listener = listener; + this.on(type, g); + + return this; + }; + + // emits a 'removeListener' event iff the listener was removed + EventEmitter.prototype.removeListener = function(type, listener) { + var list, position, length, i; + + if (!util.isFunction(listener)) + throw TypeError('listener must be a function'); + + if (!this._events || !this._events[type]) + return this; + + list = this._events[type]; + length = list.length; + position = -1; + + if (list === listener || + (util.isFunction(list.listener) && list.listener === listener)) { + delete this._events[type]; + if (this._events.removeListener) + this.emit('removeListener', type, listener); + + } else if (util.isObject(list)) { + for (i = length; i-- > 0;) { + if (list[i] === listener || + (list[i].listener && list[i].listener === listener)) { + position = i; + break; + } + } + + if (position < 0) + return this; + + if (list.length === 1) { + list.length = 0; + delete this._events[type]; + } else { + list.splice(position, 1); + } + + if (this._events.removeListener) + this.emit('removeListener', type, listener); + } + + return this; + }; + + EventEmitter.prototype.removeAllListeners = function(type) { + var key, listeners; + + if (!this._events) + return this; + + // not listening for removeListener, no need to emit + if (!this._events.removeListener) { + if (arguments.length === 0) + this._events = {}; + else if (this._events[type]) + delete this._events[type]; + return this; + } + + // emit removeListener for all listeners on all events + if (arguments.length === 0) { + for (key in this._events) { + if (key === 'removeListener') continue; + this.removeAllListeners(key); + } + this.removeAllListeners('removeListener'); + this._events = {}; + return this; + } + + listeners = this._events[type]; + + if (util.isFunction(listeners)) { + this.removeListener(type, listeners); + } else if (Array.isArray(listeners)) { + // LIFO order + while (listeners.length) + this.removeListener(type, listeners[listeners.length - 1]); + } + delete this._events[type]; + + return this; + }; + + EventEmitter.prototype.listeners = function(type) { + var ret; + if (!this._events || !this._events[type]) + ret = []; + else if (util.isFunction(this._events[type])) + ret = [this._events[type]]; + else + ret = this._events[type].slice(); + return ret; + }; + + EventEmitter.listenerCount = function(emitter, type) { + var ret; + if (!emitter._events || !emitter._events[type]) + ret = 0; + else if (util.isFunction(emitter._events[type])) + ret = 1; + else + ret = emitter._events[type].length; + return ret; + }; + + /** + * @module EventEmitter + * @private + */ + + var Events = { + /** + * Function used to add event handling to objects passed in. + * @param {Object} obj Object instance that will get event handling. + */ + mixin: function mixin(obj) { + Object.keys(nodeEventEmitter.prototype).forEach(function (key) { + obj[key] = nodeEventEmitter.prototype[key]; + }); + nodeEventEmitter.init(obj); + } + }; + + function _typeof(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof = function _typeof(obj) { return typeof obj; }; } else { _typeof = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof(obj); } + + function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + + function _inherits(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf(subClass, superClass); } + + function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; } + + function _possibleConstructorReturn(self, call) { if (call && (_typeof(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized(self); } + + function _assertThisInitialized(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; } + + function _wrapNativeSuper(Class) { var _cache = typeof Map === "function" ? new Map() : undefined; _wrapNativeSuper = function _wrapNativeSuper(Class) { if (Class === null || !_isNativeFunction(Class)) return Class; if (typeof Class !== "function") { throw new TypeError("Super expression must either be null or a function"); } if (typeof _cache !== "undefined") { if (_cache.has(Class)) return _cache.get(Class); _cache.set(Class, Wrapper); } function Wrapper() { return _construct(Class, arguments, _getPrototypeOf(this).constructor); } Wrapper.prototype = Object.create(Class.prototype, { constructor: { value: Wrapper, enumerable: false, writable: true, configurable: true } }); return _setPrototypeOf(Wrapper, Class); }; return _wrapNativeSuper(Class); } + + function _construct(Parent, args, Class) { if (_isNativeReflectConstruct()) { _construct = Reflect.construct; } else { _construct = function _construct(Parent, args, Class) { var a = [null]; a.push.apply(a, args); var Constructor = Function.bind.apply(Parent, a); var instance = new Constructor(); if (Class) _setPrototypeOf(instance, Class.prototype); return instance; }; } return _construct.apply(null, arguments); } + + function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } } + + function _isNativeFunction(fn) { return Function.toString.call(fn).indexOf("[native code]") !== -1; } + + function _setPrototypeOf(o, p) { _setPrototypeOf = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf(o, p); } + + function _getPrototypeOf(o) { _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf(o); } + + /** + * Error containing a custom error code. + * @extends Error + * @property {number} code The error code as defined by `errorCodes` + * @property {boolean} enigmaError=true + */ + var EnigmaError = /*#__PURE__*/function (_Error) { + _inherits(EnigmaError, _Error); + + var _super = _createSuper(EnigmaError); + + function EnigmaError(name, code) { + var _this; + + _classCallCheck(this, EnigmaError); + + _this = _super.call(this, name); + _this.code = code; + _this.enigmaError = true; + return _this; + } + + return EnigmaError; + }( /*#__PURE__*/_wrapNativeSuper(Error)); + /** + * Create an enigmaError + * @private + * @param {Number} code A proper error code from `errorCodes` + * @param {String} name A message/name of the enigmaError. + * @returns {EnigmaError} + */ + + + function createEnigmaError(code, name) { + return new EnigmaError(name, code); + } + + /** + * This is a list of error codes that can be thrown from enigma.js API calls. + * @entry + * @see EnigmaError + * @enum + * @example Handling an enigma.js error + * const { NOT_CONNECTED } = require('enigma.js/error-codes'); + * try { + * const layout = await model.getLayout(); + * } catch (err) { + * if (err.code === NOT_CONNECTED) { + * console.log('Tried to communicate on a session that is closed'); + * } + * } + */ + var errorCodes = { + /** + * You're trying to send data on a socket that's not connected + * @type {number} + */ + NOT_CONNECTED: -1, + + /** + * The object you're trying to fetch does not exist + * @type {number} + */ + OBJECT_NOT_FOUND: -2, + + /** + * Unexpected RPC response, expected array of patches + * @type {number} + */ + EXPECTED_ARRAY_OF_PATCHES: -3, + + /** + * Patchee is not an object we can patch + * @type {number} + */ + PATCH_HAS_NO_PARENT: -4, + + /** + * This entry is already defined with another key + * @type {number} + */ + ENTRY_ALREADY_DEFINED: -5, + + /** + * You need to supply a configuration + * @type {number} + */ + NO_CONFIG_SUPPLIED: -6, + + /** + * There's no promise object available (polyfill required?) + * @type {number} + */ + PROMISE_REQUIRED: -7, + + /** + * The schema struct type you requested does not exist + * @type {number} + */ + SCHEMA_STRUCT_TYPE_NOT_FOUND: -8, + + /** + * Can't override this function + * @type {number} + */ + SCHEMA_MIXIN_CANT_OVERRIDE_FUNCTION: -9, + + /** + * Extend is not allowed for this mixin + * @type {number} + */ + SCHEMA_MIXIN_EXTEND_NOT_ALLOWED: -10, + + /** + * Session suspended - no interaction allowed + * @type {number} + */ + SESSION_SUSPENDED: -11, + + /** + * onlyIfAttached supplied, but you got SESSION_CREATED + * @type {number} + */ + SESSION_NOT_ATTACHED: -12 + }; + + function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); if (enumerableOnly) symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; }); keys.push.apply(keys, symbols); } return keys; } + + function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i] != null ? arguments[i] : {}; if (i % 2) { ownKeys(Object(source), true).forEach(function (key) { _defineProperty(target, key, source[key]); }); } else if (Object.getOwnPropertyDescriptors) { Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)); } else { ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } } return target; } + + function _defineProperty(obj, key, value) { if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; } + + function _classCallCheck$1(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + + function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } + + function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; } + var RPC_CLOSE_NORMAL = 1000; + var RPC_CLOSE_MANUAL_SUSPEND = 4000; + var cacheId = 0; + /** + * The QIX Engine session object + */ + + var Session = /*#__PURE__*/function () { + /** + * Handle all JSON-RPC notification event, 'notification:*. Or handle a specific JSON-RPC + * notification event, 'notification:OnConnected'. These events depend on the product you use QIX + * Engine from. + * @event Session#notification + * @type {Object} + * @example Bind the notification events + * // bind all notifications to console.log: + * session.on('notification:*', console.log); + * // bind a specific notification to console.log: + * session.on('notification:OnConnected', console.log); + */ + + /** + * Handle websocket messages. Generally used in debugging purposes. `traffic:*` will handle all + * websocket messages, `traffic:sent` will handle outgoing messages and `traffic:received` will + * handle incoming messages. + * @event Session#traffic + * @type {Object} + * @example Bind the traffic events + * // bind both in- and outbound traffic to console.log: + * session.on('traffic:*', console.log); + * // bind outbound traffic to console.log: + * session.on('traffic:sent', console.log); + * // bind inbound traffic to console.log: + * session.on('traffic:received', console.log); + */ + function Session(options) { + _classCallCheck$1(this, Session); + + var session = this; + Object.assign(session, options); + this.Promise = this.config.Promise; + this.definition = this.config.definition; + Events.mixin(session); + cacheId += 1; + session.id = cacheId; + session.rpc.on('socket-error', session.onRpcError.bind(session)); + session.rpc.on('closed', session.onRpcClosed.bind(session)); + session.rpc.on('message', session.onRpcMessage.bind(session)); + session.rpc.on('notification', session.onRpcNotification.bind(session)); + session.rpc.on('traffic', session.onRpcTraffic.bind(session)); + session.on('closed', function () { + return session.onSessionClosed(); + }); + } + /** + * Event handler for re-triggering error events from RPC. + * @private + * @emits socket-error + * @param {Error} err Webocket error event. + */ + + + _createClass(Session, [{ + key: "onRpcError", + value: function onRpcError(err) { + if (this.suspendResume.isSuspended) { + return; + } + + this.emit('socket-error', err); + } + /** + * Event handler for the RPC close event. + * @private + * @emits Session#suspended + * @emits Session#closed + * @param {Event} evt WebSocket close event. + */ + + }, { + key: "onRpcClosed", + value: function onRpcClosed(evt) { + var _this = this; + + /** + * Handle suspended state. This event is triggered in two cases (listed below). It is useful + * in scenarios where you for example want to block interaction in your application until you + * are resumed again. If config.suspendOnClose is true and there was a network disconnect + * (socked closed) or if you ran session.suspend(). + * @event Session#suspended + * @type {Object} + * @param {Object} evt Event object. + * @param {String} evt.initiator String indication what triggered the suspended state. Possible + * values network, manual. + * @example Handling session suspended + * session.on('suspended', () => { + * console.log('Session was suspended, retrying...'); + * session.resume(); + * }); + */ + if (this.suspendResume.isSuspended) { + return; + } + + if (evt.code === RPC_CLOSE_NORMAL || evt.code === RPC_CLOSE_MANUAL_SUSPEND) { + return; + } + + if (this.config.suspendOnClose) { + var code = evt.code, + reason = evt.reason; + this.suspendResume.suspend().then(function () { + return _this.emit('suspended', { + initiator: 'network', + code: code, + reason: reason + }); + }); + } else { + this.emit('closed', evt); + } + } + /** + * Event handler for the RPC message event. + * @private + * @param {Object} response JSONRPC response. + */ + + }, { + key: "onRpcMessage", + value: function onRpcMessage(response) { + var _this2 = this; + + if (this.suspendResume.isSuspended) { + return; + } + + if (response.change) { + response.change.forEach(function (handle) { + return _this2.emitHandleChanged(handle); + }); + } + + if (response.close) { + response.close.forEach(function (handle) { + return _this2.emitHandleClosed(handle); + }); + } + } + /** + * Event handler for the RPC notification event. + * @private + * @emits Session#notification + * @param {Object} response The JSONRPC notification. + */ + + }, { + key: "onRpcNotification", + value: function onRpcNotification(response) { + this.emit('notification:*', response.method, response.params); + this.emit("notification:".concat(response.method), response.params); + } + /** + * Event handler for the RPC traffic event. + * @private + * @emits Session#traffic + * @param {String} dir The traffic direction, sent or received. + * @param {Object} data JSONRPC request/response/WebSocket message. + * @param {Number} handle The associated handle. + */ + + }, { + key: "onRpcTraffic", + value: function onRpcTraffic(dir, data, handle) { + this.emit('traffic:*', dir, data); + this.emit("traffic:".concat(dir), data); + var api = this.apis.getApi(handle); + + if (api) { + api.emit('traffic:*', dir, data); + api.emit("traffic:".concat(dir), data); + } + } + /** + * Event handler for cleaning up API instances when a session has been closed. + * @private + * @emits API#closed + */ + + }, { + key: "onSessionClosed", + value: function onSessionClosed() { + this.apis.getApis().forEach(function (entry) { + entry.api.emit('closed'); + entry.api.removeAllListeners(); + }); + this.apis.clear(); + } + /** + * Function used to get an API for a backend object. + * @private + * @param {Object} args Arguments used to create object API. + * @param {Number} args.handle Handle of the backend object. + * @param {String} args.id ID of the backend object. + * @param {String} args.type QIX type of the backend object. Can for example + * be "Doc" or "GenericVariable". + * @param {String} args.genericType Custom type of the backend object, if defined in qInfo. + * @returns {Object} Returns the generated and possibly augmented API. + */ + + }, { + key: "getObjectApi", + value: function getObjectApi(args) { + var handle = args.handle, + id = args.id, + type = args.type, + genericType = args.genericType; + var api = this.apis.getApi(handle); + + if (api) { + return api; + } + + var factory = this.definition.generate(type); + api = factory(this, handle, id, genericType); + this.apis.add(handle, api); + return api; + } + /** + * Establishes the websocket against the configured URL and returns the Global instance. + * @emits Session#opened + * @returns {Promise} Eventually resolved if the connection was successful. + * @example Opening a sesssion + * session.open().then(() => { + * console.log('Session was opened'); + * }); + */ + + }, { + key: "open", + value: function open() { + var _this3 = this; + + /** + * Handle opened state. This event is triggered whenever the websocket is connected and + * ready for communication. + * @event Session#opened + * @type {Object} + * @example Bind the session opened event + * session.on('opened', () => { + * console.log('Session was opened'); + * }); + */ + if (!this.globalPromise) { + var args = { + handle: -1, + id: 'Global', + type: 'Global', + genericType: 'Global' + }; + this.globalPromise = this.rpc.open().then(function () { + return _this3.getObjectApi(args); + }).then(function (global) { + _this3.emit('opened'); + + return global; + }); + } + + return this.globalPromise; + } + /** + * Function used to send data on the RPC socket. + * @param {Object} request The request to be sent. (data and some meta info) + * @returns {Object} Returns a promise instance. + */ + + }, { + key: "send", + value: function send(request) { + var _this4 = this; + + if (this.suspendResume.isSuspended) { + return this.Promise.reject(createEnigmaError(errorCodes.SESSION_SUSPENDED, 'Session suspended')); + } + + request.id = this.rpc.createRequestId(); + var promise = this.intercept.executeRequests(this, this.Promise.resolve(request)).then(function (augmentedRequest) { + var data = _objectSpread(_objectSpread({}, _this4.config.protocol), augmentedRequest); // the outKey value is used by multiple-out interceptor, at some point + // we need to refactor that implementation and figure out how to transport + // this value without hijacking the JSONRPC request object: + + + delete data.outKey; + + var response = _this4.rpc.send(data); + + augmentedRequest.retry = function () { + return _this4.send(request); + }; + + return _this4.intercept.executeResponses(_this4, response, augmentedRequest); + }); + Session.addToPromiseChain(promise, 'requestId', request.id); + return promise; + } + /** + * Suspends the enigma.js session by closing the websocket and rejecting all method calls + * until is has been resumed again. + * @emits Session#suspended + * @param {Number} [code=4000] - The reason code for suspending the connection. + * @param {String} [reason=""] - The human readable string describing + * why the connection is suspended. + * @returns {Promise} Eventually resolved when the websocket has been closed. + * @example Suspending a session + * session.suspend().then(() => { + * console.log('Session was suspended'); + * }); + */ + + }, { + key: "suspend", + value: function suspend() { + var _this5 = this; + + var code = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 4000; + var reason = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : ''; + return this.suspendResume.suspend(code, reason).then(function () { + return _this5.emit('suspended', { + initiator: 'manual', + code: code, + reason: reason + }); + }); + } + /** + * Resumes a previously suspended enigma.js session by re-creating the websocket and, + * if possible, re-open the document as well as refreshing the internal cashes. If successful, + * changed events will be triggered on all generated APIs, and on the ones it was unable to + * restore, the closed event will be triggered. + * @emits Session#resumed + * @param {Boolean} onlyIfAttached If true, resume only if the session was re-attached properly. + * @returns {Promise} Eventually resolved when the websocket (and potentially the + * previously opened document, and generated APIs) has been restored, rejected when it fails any + * of those steps, or when onlyIfAttached is true and a new session was created. + * @example Resuming a session + * session.resume(true).then(() => { + * console.log('Session was resumed by re-attaching'); + * }); + */ + + }, { + key: "resume", + value: function resume(onlyIfAttached) { + var _this6 = this; + + /** + * Handle resumed state. This event is triggered when the session was properly resumed. It is + * useful in scenarios where you for example can close blocking modal dialogs and allow the user + * to interact with your application again. + * @event Session#resumed + * @type {Object} + * @example Handling session resumed + * session.on('resumed', () => { + * console.log('Session was resumed, we can close that "reconnecting" dialog now'); + * }); + */ + return this.suspendResume.resume(onlyIfAttached).then(function (value) { + _this6.emit('resumed'); + + return value; + }); + } + /** + * Closes the websocket and cleans up internal caches, also triggers the closed event + * on all generated APIs. Note that you have to manually invoke this when you want to + * close a session and config.suspendOnClose is true. + * @emits Session#closed + * @param {Number} [code=1000] - The reason code for closing the connection. + * @param {String} [reason=""] - The human readable string describing why the connection is closed. + * @returns {Promise} Eventually resolved when the websocket has been closed. + * @example Closing a session + * session.close().then(() => { + * console.log('Session was closed'); + * }); + */ + + }, { + key: "close", + value: function close() { + var _this7 = this; + + var code = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 1000; + var reason = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : ''; + + /** + * Handle closed state. This event is triggered when the underlying websocket is closed and + * config.suspendOnClose is false. + * @event Session#closed + * @type {Object} + * @example Handling session closed + * session.on('closed', () => { + * console.log('Session was closed, clean up!'); + * }); + */ + this.globalPromise = undefined; + return this.rpc.close(code, reason).then(function (evt) { + return _this7.emit('closed', evt); + }); + } + /** + * Given a handle, this function will emit the 'changed' event on the + * corresponding API instance. + * @private + * @param {Number} handle The handle of the API instance. + * @emits API#changed + */ + + }, { + key: "emitHandleChanged", + value: function emitHandleChanged(handle) { + var api = this.apis.getApi(handle); + + if (api) { + api.emit('changed'); + } + } + /** + * Given a handle, this function will emit the 'closed' event on the + * corresponding API instance. + * @private + * @param {Number} handle The handle of the API instance. + * @emits API#closed + */ + + }, { + key: "emitHandleClosed", + value: function emitHandleClosed(handle) { + var api = this.apis.getApi(handle); + + if (api) { + api.emit('closed'); + api.removeAllListeners(); + } + } + /** + * Function used to add info on the promise chain. + * @private + * @param {Promise} promise The promise to add info on. + * @param {String} name The property to add info on. + * @param {Any} value The info to add. + */ + + }], [{ + key: "addToPromiseChain", + value: function addToPromiseChain(promise, name, value) { + promise[name] = value; + var then = promise.then; + + promise.then = function patchedThen() { + for (var _len = arguments.length, params = new Array(_len), _key = 0; _key < _len; _key++) { + params[_key] = arguments[_key]; + } + + var chain = then.apply(this, params); + Session.addToPromiseChain(chain, name, value); + return chain; + }; + } + }]); + + return Session; + }(); + + function _classCallCheck$2(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + + function _defineProperties$1(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } + + function _createClass$1(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties$1(Constructor.prototype, protoProps); if (staticProps) _defineProperties$1(Constructor, staticProps); return Constructor; } + /** + * Key-value cache + * @private + */ + + var KeyValueCache = /*#__PURE__*/function () { + function KeyValueCache() { + _classCallCheck$2(this, KeyValueCache); + + this.entries = {}; + } + /** + * Adds an entry. + * @private + * @function KeyValueCache#add + * @param {String} key The key representing an entry. + * @param {*} entry The entry to be added. + */ + + + _createClass$1(KeyValueCache, [{ + key: "add", + value: function add(key, entry) { + key += ''; + + if (typeof this.entries[key] !== 'undefined') { + throw createEnigmaError(errorCodes.ENTRY_ALREADY_DEFINED, "Entry already defined with key ".concat(key)); + } + + this.entries[key] = entry; + } + /** + * Sets an entry. + * @private + * @function KeyValueCache#set + * @param {String} key The key representing an entry. + * @param {*} entry The entry. + */ + + }, { + key: "set", + value: function set(key, entry) { + key += ''; + this.entries[key] = entry; + } + /** + * Removes an entry. + * @private + * @function KeyValueCache#remove + * @param {String} key The key representing an entry. + */ + + }, { + key: "remove", + value: function remove(key) { + delete this.entries[key]; + } + /** + * Gets an entry. + * @private + * @function KeyValueCache#get + * @param {String} key The key representing an entry. + * @returns {*} The entry for the key. + */ + + }, { + key: "get", + value: function get(key) { + return this.entries[key]; + } + /** + * Gets a list of all entries. + * @private + * @function KeyValueCache#getAll + * @returns {Array} The list of entries including its `key` and `value` properties. + */ + + }, { + key: "getAll", + value: function getAll() { + var _this = this; + + return Object.keys(this.entries).map(function (key) { + return { + key: key, + value: _this.entries[key] + }; + }); + } + /** + * Gets a key for an entry. + * @private + * @function KeyValueCache#getKey + * @param {*} entry The entry to locate the key for. + * @returns {String} The key representing an entry. + */ + + }, { + key: "getKey", + value: function getKey(entry) { + var _this2 = this; + + return Object.keys(this.entries).filter(function (key) { + return _this2.entries[key] === entry; + })[0]; + } + /** + * Clears the cache of all entries. + * @private + * @function KeyValueCache#clear + */ + + }, { + key: "clear", + value: function clear() { + this.entries = {}; + } + }]); + + return KeyValueCache; + }(); + + function _classCallCheck$3(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + + function _defineProperties$2(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } + + function _createClass$2(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties$2(Constructor.prototype, protoProps); if (staticProps) _defineProperties$2(Constructor, staticProps); return Constructor; } + + function _typeof$1(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof$1 = function _typeof(obj) { return typeof obj; }; } else { _typeof$1 = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof$1(obj); } + var hasOwnProperty$1 = Object.prototype.hasOwnProperty; + /** + * Returns the camelCase counterpart of a symbol. + * @private + * @param {String} symbol The symbol. + * @return the camelCase counterpart. + */ + + function toCamelCase(symbol) { + return symbol.substring(0, 1).toLowerCase() + symbol.substring(1); + } + /** + * A facade function that allows parameters to be passed either by name + * (through an object), or by position (through an array). + * @private + * @param {Function} base The function that is being overriden. Will be + * called with parameters in array-form. + * @param {Object} defaults Parameter list and it's default values. + * @param {*} params The parameters. + */ + + + function namedParamFacade(base, defaults) { + for (var _len = arguments.length, params = new Array(_len > 2 ? _len - 2 : 0), _key = 2; _key < _len; _key++) { + params[_key - 2] = arguments[_key]; + } + + if (params.length === 1 && _typeof$1(params[0]) === 'object' && !Array.isArray(params[0])) { + var valid = Object.keys(params[0]).every(function (key) { + return hasOwnProperty$1.call(defaults, key); + }); + + if (valid) { + params = Object.keys(defaults).map(function (key) { + return params[0][key] || defaults[key]; + }); + } + } + + return base.apply(this, params); + } + /** + * Qix schema definition. + * @private + */ + + + var Schema = /*#__PURE__*/function () { + /** + * Create a new schema instance. + * @private + * @param {Configuration} config The configuration for QIX. + */ + function Schema(config) { + _classCallCheck$3(this, Schema); + + this.config = config; + this.Promise = config.Promise; + this.schema = config.schema; + this.mixins = new KeyValueCache(); + this.types = new KeyValueCache(); + } + + _createClass$2(Schema, [{ + key: "registerMixin", + value: function registerMixin(_ref) { + var _this = this; + + var types = _ref.types, + type = _ref.type, + extend = _ref.extend, + override = _ref.override, + init = _ref.init; + + if (!Array.isArray(types)) { + types = [types]; + } // to support a single type + + + if (type) { + types.push(type); + } + + var cached = { + extend: extend, + override: override, + init: init + }; + types.forEach(function (typeKey) { + var entryList = _this.mixins.get(typeKey); + + if (entryList) { + entryList.push(cached); + } else { + _this.mixins.add(typeKey, [cached]); + } + }); + } + /** + * Function used to generate a type definition. + * @private + * @param {String} type The type. + * @returns {{create: Function, def: Object}} Returns an object with a definition + * of the type and a create factory. + */ + + }, { + key: "generate", + value: function generate(type) { + var entry = this.types.get(type); + + if (entry) { + return entry; + } + + if (!this.schema.structs[type]) { + throw createEnigmaError(errorCodes.SCHEMA_STRUCT_TYPE_NOT_FOUND, "".concat(type, " not found")); + } + + var factory = this.generateApi(type, this.schema.structs[type]); + this.types.add(type, factory); + return factory; + } + /** + * Function used to generate an API definition for a given type. + * @private + * @param {String} type The type to generate. + * @param {Object} schema The schema describing the type. + * @returns {{create: (function(session:Object, handle:Number, id:String, + * customKey:String)), def: Object}} Returns the API definition. + */ + + }, { + key: "generateApi", + value: function generateApi(type, schema) { + var api = Object.create({}); + this.generateDefaultApi(api, schema); // Generate default + + this.mixinType(type, api); // Mixin default type + + this.mixinNamedParamFacade(api, schema); // Mixin named parameter support + + return function create(session, handle, id, customKey) { + var _this2 = this; + + var instance = Object.create(api); + Events.mixin(instance); // Always mixin event-emitter per instance + + Object.defineProperties(instance, { + session: { + enumerable: true, + value: session + }, + handle: { + enumerable: true, + value: handle, + writable: true + }, + id: { + enumerable: true, + value: id + }, + type: { + enumerable: true, + value: type + }, + genericType: { + enumerable: true, + value: customKey + } + }); + var mixinList = this.mixins.get(type) || []; + + if (customKey !== type) { + this.mixinType(customKey, instance); // Mixin custom types + + mixinList = mixinList.concat(this.mixins.get(customKey) || []); + } + + mixinList.forEach(function (mixin) { + if (typeof mixin.init === 'function') { + mixin.init({ + config: _this2.config, + api: instance + }); + } + }); + return instance; + }.bind(this); + } + /** + * Function used to generate the methods with the right handlers to the object + * API that is being generated. + * @private + * @param {Object} api The object API that is currently being generated. + * @param {Object} schema The API definition. + */ + + }, { + key: "generateDefaultApi", + value: function generateDefaultApi(api, schema) { + Object.keys(schema).forEach(function (method) { + var out = schema[method].Out; + var outKey = out.length === 1 ? out[0].Name : -1; + var fnName = toCamelCase(method); + + api[fnName] = function generatedMethod() { + for (var _len2 = arguments.length, params = new Array(_len2), _key2 = 0; _key2 < _len2; _key2++) { + params[_key2] = arguments[_key2]; + } + + return this.session.send({ + handle: this.handle, + method: method, + params: params, + outKey: outKey + }); + }; + }); + } + /** + * Function used to add mixin methods to a specified API. + * @private + * @param {String} type Used to specify which mixin should be woven in. + * @param {Object} api The object that will be woven. + */ + + }, { + key: "mixinType", + value: function mixinType(type, api) { + var mixinList = this.mixins.get(type); + + if (mixinList) { + mixinList.forEach(function (_ref2) { + var _ref2$extend = _ref2.extend, + extend = _ref2$extend === void 0 ? {} : _ref2$extend, + _ref2$override = _ref2.override, + override = _ref2$override === void 0 ? {} : _ref2$override; + Object.keys(override).forEach(function (key) { + if (typeof api[key] === 'function' && typeof override[key] === 'function') { + var baseFn = api[key]; + + api[key] = function wrappedFn() { + for (var _len3 = arguments.length, args = new Array(_len3), _key3 = 0; _key3 < _len3; _key3++) { + args[_key3] = arguments[_key3]; + } + + return override[key].apply(this, [baseFn.bind(this)].concat(args)); + }; + } else { + throw createEnigmaError(errorCodes.SCHEMA_MIXIN_CANT_OVERRIDE_FUNCTION, "No function to override. Type: ".concat(type, " function: ").concat(key)); + } + }); + Object.keys(extend).forEach(function (key) { + // handle overrides + if (typeof api[key] === 'function' && typeof extend[key] === 'function') { + throw createEnigmaError(errorCodes.SCHEMA_MIXIN_EXTEND_NOT_ALLOWED, "Extend is not allowed for this mixin. Type: ".concat(type, " function: ").concat(key)); + } else { + api[key] = extend[key]; + } + }); + }); + } + } + /** + * Function used to mixin the named parameter facade. + * @private + * @param {Object} api The object API that is currently being generated. + * @param {Object} schema The API definition. + */ + + }, { + key: "mixinNamedParamFacade", + value: function mixinNamedParamFacade(api, schema) { + Object.keys(schema).forEach(function (key) { + var fnName = toCamelCase(key); + var base = api[fnName]; + var defaults = schema[key].In.reduce(function (result, item) { + result[item.Name] = item.DefaultValue; + return result; + }, {}); + + api[fnName] = function namedParamWrapper() { + for (var _len4 = arguments.length, params = new Array(_len4), _key4 = 0; _key4 < _len4; _key4++) { + params[_key4] = arguments[_key4]; + } + + return namedParamFacade.apply(this, [base, defaults].concat(params)); + }; + }); + } + }]); + + return Schema; + }(); + + function _classCallCheck$4(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + + function _defineProperties$3(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } + + function _createClass$3(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties$3(Constructor.prototype, protoProps); if (staticProps) _defineProperties$3(Constructor, staticProps); return Constructor; } + /** + * Helper class for handling RPC calls + * @private + */ + + var RPCResolver = /*#__PURE__*/function () { + function RPCResolver(id, handle, resolve, reject) { + _classCallCheck$4(this, RPCResolver); + + Events.mixin(this); + this.id = id; + this.handle = handle; + this.resolve = resolve; + this.reject = reject; + } + + _createClass$3(RPCResolver, [{ + key: "resolveWith", + value: function resolveWith(data) { + this.resolve(data); + this.emit('resolved', this.id); + } + }, { + key: "rejectWith", + value: function rejectWith(err) { + this.reject(err); + this.emit('rejected', this.id); + } + }]); + + return RPCResolver; + }(); + + function _classCallCheck$5(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + + function _defineProperties$4(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } + + function _createClass$4(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties$4(Constructor.prototype, protoProps); if (staticProps) _defineProperties$4(Constructor, staticProps); return Constructor; } + /** + * This class handles remote procedure calls on a web socket. + * @private + */ + + var RPC = /*#__PURE__*/function () { + /** + * Create a new RPC instance. + * @private + * @param {Object} options The configuration options for this class. + * @param {Function} options.Promise The promise constructor to use. + * @param {String} options.url The complete websocket URL used to connect. + * @param {Function} options.createSocket The function callback to create a WebSocket. + */ + function RPC(options) { + _classCallCheck$5(this, RPC); + + Object.assign(this, options); + Events.mixin(this); + this.resolvers = {}; + this.requestId = 0; + this.openedPromise = undefined; + } + /** + * Opens a connection to the configured endpoint. + * @private + * @param {Boolean} force - ignores all previous and outstanding open calls if set to true. + * @returns {Object} A promise instance. + */ + + + _createClass$4(RPC, [{ + key: "open", + value: function open() { + var _this = this; + + var force = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false; + + if (!force && this.openedPromise) { + return this.openedPromise; + } + + try { + this.socket = this.createSocket(this.url); + } catch (err) { + return this.Promise.reject(err); + } + + this.socket.onopen = this.onOpen.bind(this); + this.socket.onclose = this.onClose.bind(this); + this.socket.onerror = this.onError.bind(this); + this.socket.onmessage = this.onMessage.bind(this); + this.openedPromise = new this.Promise(function (resolve, reject) { + return _this.registerResolver('opened', null, resolve, reject); + }); + this.closedPromise = new this.Promise(function (resolve, reject) { + return _this.registerResolver('closed', null, resolve, reject); + }); + return this.openedPromise; + } + /** + * Resolves the open promise when a connection is successfully established. + * @private + */ + + }, { + key: "onOpen", + value: function onOpen() { + var _this2 = this; + + this.resolvers.opened.resolveWith(function () { + return _this2.closedPromise; + }); + } + /** + * Resolves the close promise when a connection is closed. + * @private + * @param {Object} event - The event describing close. + */ + + }, { + key: "onClose", + value: function onClose(event) { + this.emit('closed', event); + + if (this.resolvers && this.resolvers.closed) { + this.resolvers.closed.resolveWith(event); + } + + this.rejectAllOutstandingResolvers(createEnigmaError(errorCodes.NOT_CONNECTED, 'Socket closed')); + } + /** + * Closes a connection. + * @private + * @param {Number} [code=1000] - The reason code for closing the connection. + * @param {String} [reason=""] - The human readable string describing why the connection is closed. + * @returns {Object} Returns a promise instance. + */ + + }, { + key: "close", + value: function close() { + var code = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 1000; + var reason = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : ''; + + if (this.socket) { + this.socket.close(code, reason); + this.socket = null; + } + + return this.closedPromise; + } + /** + * Emits an error event and rejects the open promise if an error is raised on the connection. + * @private + * @param {Object} event - The event describing the error. + */ + + }, { + key: "onError", + value: function onError(event) { + if (this.resolvers.opened) { + this.resolvers.opened.rejectWith(event); + } else { + // only emit errors after the initial open promise has been resolved, + // this makes it possible to catch early websocket errors as well + // as run-time ones: + this.emit('socket-error', event); + } + + this.rejectAllOutstandingResolvers(createEnigmaError(errorCodes.NOT_CONNECTED, 'Socket error')); + } + /** + * Parses the onMessage event on the connection and resolve the promise for the request. + * @private + * @param {Object} event - The event describing the message. + */ + + }, { + key: "onMessage", + value: function onMessage(event) { + var data = JSON.parse(event.data); + var resolver = this.resolvers[data.id] || {}; + this.emit('traffic', 'received', data, resolver.handle); + + if (typeof data.id !== 'undefined') { + this.emit('message', data); + this.resolvers[data.id].resolveWith(data); + } else { + this.emit(data.params ? 'notification' : 'message', data); + } + } + /** + * Rejects all outstanding resolvers. + * @private + * @param {Object} reason - The reject reason. + */ + + }, { + key: "rejectAllOutstandingResolvers", + value: function rejectAllOutstandingResolvers(reason) { + var _this3 = this; + + Object.keys(this.resolvers).forEach(function (id) { + if (id === 'opened' || id === 'closed') { + return; // "opened" and "closed" should not be handled here + } + + var resolver = _this3.resolvers[id]; + resolver.rejectWith(reason); + }); + } + /** + * Unregisters a resolver. + * @private + * @param {Number|String} id - The ID to unregister the resolver with. + */ + + }, { + key: "unregisterResolver", + value: function unregisterResolver(id) { + var resolver = this.resolvers[id]; + resolver.removeAllListeners(); + delete this.resolvers[id]; + } + /** + * Registers a resolver. + * @private + * @param {Number|String} id - The ID to register the resolver with. + * @param {Number} handle - The associated handle. + * @returns {Function} The promise executor function. + */ + + }, { + key: "registerResolver", + value: function registerResolver(id, handle, resolve, reject) { + var _this4 = this; + + var resolver = new RPCResolver(id, handle, resolve, reject); + this.resolvers[id] = resolver; + resolver.on('resolved', function (resolvedId) { + return _this4.unregisterResolver(resolvedId); + }); + resolver.on('rejected', function (rejectedId) { + return _this4.unregisterResolver(rejectedId); + }); + } + /** + * Sends data on the socket. + * @private + * @param {Object} data - The data to send. + * @returns {Object} A promise instance. + */ + + }, { + key: "send", + value: function send(data) { + var _this5 = this; + + if (!this.socket || this.socket.readyState !== this.socket.OPEN) { + var error = createEnigmaError(errorCodes.NOT_CONNECTED, 'Not connected'); + return this.Promise.reject(error); + } + + if (!data.id) { + data.id = this.createRequestId(); + } + + data.jsonrpc = '2.0'; + return new this.Promise(function (resolve, reject) { + _this5.socket.send(JSON.stringify(data)); + + _this5.emit('traffic', 'sent', data, data.handle); + + return _this5.registerResolver(data.id, data.handle, resolve, reject); + }); + } + }, { + key: "createRequestId", + value: function createRequestId() { + this.requestId += 1; + return this.requestId; + } + }]); + + return RPC; + }(); + + function _classCallCheck$6(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + + function _defineProperties$5(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } + + function _createClass$5(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties$5(Constructor.prototype, protoProps); if (staticProps) _defineProperties$5(Constructor, staticProps); return Constructor; } + var ON_ATTACHED_TIMEOUT_MS = 5000; + var RPC_CLOSE_MANUAL_SUSPEND$1 = 4000; + + var SuspendResume = /*#__PURE__*/function () { + /** + * Creates a new SuspendResume instance. + * @private + * @param {Object} options The configuration option for this class. + * @param {Promise} options.Promise The promise constructor to use. + * @param {RPC} options.rpc The RPC instance to use when communicating towards Engine. + * @param {ApiCache} options.apis The ApiCache instance to use. + */ + function SuspendResume(options) { + var _this = this; + + _classCallCheck$6(this, SuspendResume); + + Object.assign(this, options); + this.isSuspended = false; + this.rpc.on('traffic', function (dir, data) { + if (dir === 'sent' && data.method === 'OpenDoc') { + _this.openDocParams = data.params; + } + }); + } + /** + * Function used to restore the rpc connection. + * @private + * @param {Boolean} onlyIfAttached - if true, the returned promise will resolve + * only if the session can be re-attached. + * @returns {Object} Returns a promise instance. + */ + + + _createClass$5(SuspendResume, [{ + key: "restoreRpcConnection", + value: function restoreRpcConnection(onlyIfAttached) { + var _this2 = this; + + return this.reopen(ON_ATTACHED_TIMEOUT_MS).then(function (sessionState) { + if (sessionState === 'SESSION_CREATED' && onlyIfAttached) { + return _this2.Promise.reject(createEnigmaError(errorCodes.SESSION_NOT_ATTACHED, 'Not attached')); + } + + return _this2.Promise.resolve(); + }); + } + /** + * Function used to restore the global API. + * @private + * @param {Object} changed - A list where the restored APIs will be added. + * @returns {Object} Returns a promise instance. + */ + + }, { + key: "restoreGlobal", + value: function restoreGlobal(changed) { + var global = this.apis.getApisByType('Global').pop(); + changed.push(global.api); + return this.Promise.resolve(); + } + /** + * Function used to restore the doc API. + * @private + * @param {String} sessionState - The state of the session, attached or created. + * @param {Array} closed - A list where the closed of APIs APIs will be added. + * @param {Object} changed - A list where the restored APIs will be added. + * @returns {Object} Returns a promise instance. + */ + + }, { + key: "restoreDoc", + value: function restoreDoc(closed, changed) { + var _this3 = this; + + var doc = this.apis.getApisByType('Doc').pop(); + + if (!doc) { + return this.Promise.resolve(); + } + + return this.rpc.send({ + method: 'GetActiveDoc', + handle: -1, + params: [] + }).then(function (response) { + if (response.error && _this3.openDocParams) { + return _this3.rpc.send({ + method: 'OpenDoc', + handle: -1, + params: _this3.openDocParams + }); + } + + return response; + }).then(function (response) { + if (response.error) { + closed.push(doc.api); + return _this3.Promise.resolve(); + } + + var handle = response.result.qReturn.qHandle; + doc.api.handle = handle; + changed.push(doc.api); + return _this3.Promise.resolve(doc.api); + }); + } + /** + * Function used to restore the APIs on the doc. + * @private + * @param {Object} doc - The doc API on which the APIs we want to restore exist. + * @param {Array} closed - A list where the closed of APIs APIs will be added. + * @param {Object} changed - A list where the restored APIs will be added. + * @returns {Object} Returns a promise instance. + */ + + }, { + key: "restoreDocObjects", + value: function restoreDocObjects(doc, closed, changed) { + var _this4 = this; + + var tasks = []; + var apis = this.apis.getApis().map(function (entry) { + return entry.api; + }).filter(function (api) { + return api.type !== 'Global' && api.type !== 'Doc'; + }); + + if (!doc) { + apis.forEach(function (api) { + return closed.push(api); + }); + return this.Promise.resolve(); + } + + apis.forEach(function (api) { + var method = SuspendResume.buildGetMethodName(api.type); + + if (!method) { + closed.push(api); + } else { + var request = _this4.rpc.send({ + method: method, + handle: doc.handle, + params: [api.id] + }).then(function (response) { + if (response.error || !response.result.qReturn.qHandle) { + closed.push(api); + } else { + api.handle = response.result.qReturn.qHandle; + changed.push(api); + } + }); + + tasks.push(request); + } + }); + return this.Promise.all(tasks); + } + /** + * Set the instance as suspended. + * @private + * @param {Number} [code=4000] - The reason code for suspending the connection. + * @param {String} [reason=""] - The human readable string describing + * why the connection is suspended. + */ + + }, { + key: "suspend", + value: function suspend() { + var code = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : RPC_CLOSE_MANUAL_SUSPEND$1; + var reason = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : ''; + this.isSuspended = true; + return this.rpc.close(code, reason); + } + /** + * Resumes a previously suspended RPC connection, and refreshes the API cache. + * APIs unabled to be restored has their 'closed' + * event triggered, otherwise 'changed'. + * @private + * @emits API#changed + * @emits APIfunction@#closed + * @param {Boolean} onlyIfAttached if true, resume only if the session was re-attached. + * @returns {Promise} Eventually resolved if the RPC connection was successfully resumed, + * otherwise rejected. + */ + + }, { + key: "resume", + value: function resume(onlyIfAttached) { + var _this5 = this; + + var changed = []; + var closed = []; + return this.restoreRpcConnection(onlyIfAttached).then(function () { + return _this5.restoreGlobal(changed); + }).then(function () { + return _this5.restoreDoc(closed, changed); + }).then(function (doc) { + return _this5.restoreDocObjects(doc, closed, changed); + }).then(function () { + _this5.isSuspended = false; + + _this5.apis.clear(); + + closed.forEach(function (api) { + api.emit('closed'); + api.removeAllListeners(); + }); + changed.forEach(function (api) { + _this5.apis.add(api.handle, api); + + if (api.type !== 'Global') { + api.emit('changed'); + } + }); + })["catch"](function (err) { + return _this5.rpc.close().then(function () { + return _this5.Promise.reject(err); + }); + }); + } + /** + * Reopens the connection and waits for the OnConnected notification. + * @private + * @param {Number} timeout - The time to wait for the OnConnected notification. + * @returns {Object} A promise containing the session state (SESSION_CREATED or SESSION_ATTACHED). + */ + + }, { + key: "reopen", + value: function reopen(timeout) { + var _this6 = this; + + var timer; + var notificationResolve; + var notificationReceived = false; + var notificationPromise = new this.Promise(function (resolve) { + notificationResolve = resolve; + }); + + var waitForNotification = function waitForNotification() { + if (!notificationReceived) { + timer = setTimeout(function () { + return notificationResolve('SESSION_CREATED'); + }, timeout); + } + + return notificationPromise; + }; + + var onNotification = function onNotification(data) { + if (data.method !== 'OnConnected') return; + clearTimeout(timer); + notificationResolve(data.params.qSessionState); + notificationReceived = true; + }; + + this.rpc.on('notification', onNotification); + return this.rpc.open(true).then(waitForNotification).then(function (state) { + _this6.rpc.removeListener('notification', onNotification); + + return state; + })["catch"](function (err) { + _this6.rpc.removeListener('notification', onNotification); + + return _this6.Promise.reject(err); + }); + } + /** + * Function used to build the get method names for Doc APIs. + * @private + * @param {String} type - The API type. + * @returns {String} Returns the get method name, or undefined if the type cannot be restored. + */ + + }], [{ + key: "buildGetMethodName", + value: function buildGetMethodName(type) { + if (type === 'Field' || type === 'Variable') { + return null; + } + + if (type === 'GenericVariable') { + return 'GetVariableById'; + } + + return type.replace('Generic', 'Get'); + } + }]); + + return SuspendResume; + }(); + + var SUCCESS_KEY = 'qSuccess'; + function deltaRequestInterceptor(session, request) { + var delta = session.config.protocol.delta && request.outKey !== -1 && request.outKey !== SUCCESS_KEY; + + if (delta) { + request.delta = delta; + } + + return request; + } + + /** + * Response interceptor for generating APIs. Handles the quirks of engine not + * returning an error when an object is missing. + * @private + * @param {Session} session - The session the intercept is being executed on. + * @param {Object} request - The JSON-RPC request. + * @param {Object} response - The response. + * @returns {Object} - Returns the generated API + */ + + function apiResponseInterceptor(session, request, response) { + if (response.qHandle && response.qType) { + return session.getObjectApi({ + handle: response.qHandle, + type: response.qType, + id: response.qGenericId, + genericType: response.qGenericType + }); + } + + if (response.qHandle === null && response.qType === null) { + var error = createEnigmaError(errorCodes.OBJECT_NOT_FOUND, 'Object not found'); + return session.config.Promise.reject(error); + } + + return response; + } + + var hasOwn = Object.prototype.hasOwnProperty; + var toStr = Object.prototype.toString; + var defineProperty = Object.defineProperty; + var gOPD = Object.getOwnPropertyDescriptor; + + var isArray = function isArray(arr) { + if (typeof Array.isArray === 'function') { + return Array.isArray(arr); + } + + return toStr.call(arr) === '[object Array]'; + }; + + var isPlainObject = function isPlainObject(obj) { + if (!obj || toStr.call(obj) !== '[object Object]') { + return false; + } + + var hasOwnConstructor = hasOwn.call(obj, 'constructor'); + var hasIsPrototypeOf = obj.constructor && obj.constructor.prototype && hasOwn.call(obj.constructor.prototype, 'isPrototypeOf'); + // Not own constructor property must be Object + if (obj.constructor && !hasOwnConstructor && !hasIsPrototypeOf) { + return false; + } + + // Own properties are enumerated firstly, so to speed up, + // if last one is own, then all properties are own. + var key; + for (key in obj) { /**/ } + + return typeof key === 'undefined' || hasOwn.call(obj, key); + }; + + // If name is '__proto__', and Object.defineProperty is available, define __proto__ as an own property on target + var setProperty = function setProperty(target, options) { + if (defineProperty && options.name === '__proto__') { + defineProperty(target, options.name, { + enumerable: true, + configurable: true, + value: options.newValue, + writable: true + }); + } else { + target[options.name] = options.newValue; + } + }; + + // Return undefined instead of __proto__ if '__proto__' is not an own property + var getProperty = function getProperty(obj, name) { + if (name === '__proto__') { + if (!hasOwn.call(obj, name)) { + return void 0; + } else if (gOPD) { + // In early versions of node, obj['__proto__'] is buggy when obj has + // __proto__ as an own property. Object.getOwnPropertyDescriptor() works. + return gOPD(obj, name).value; + } + } + + return obj[name]; + }; + + var extend = function extend() { + var options, name, src, copy, copyIsArray, clone; + var target = arguments[0]; + var i = 1; + var length = arguments.length; + var deep = false; + + // Handle a deep copy situation + if (typeof target === 'boolean') { + deep = target; + target = arguments[1] || {}; + // skip the boolean and the target + i = 2; + } + if (target == null || (typeof target !== 'object' && typeof target !== 'function')) { + target = {}; + } + + for (; i < length; ++i) { + options = arguments[i]; + // Only deal with non-null/undefined values + if (options != null) { + // Extend the base object + for (name in options) { + src = getProperty(target, name); + copy = getProperty(options, name); + + // Prevent never-ending loop + if (target !== copy) { + // Recurse if we're merging plain objects or arrays + if (deep && copy && (isPlainObject(copy) || (copyIsArray = isArray(copy)))) { + if (copyIsArray) { + copyIsArray = false; + clone = src && isArray(src) ? src : []; + } else { + clone = src && isPlainObject(src) ? src : {}; + } + + // Never move original objects, clone them + setProperty(target, { name: name, newValue: extend(deep, clone, copy) }); + + // Don't bring in undefined values + } else if (typeof copy !== 'undefined') { + setProperty(target, { name: name, newValue: copy }); + } + } + } + } + } + + // Return the modified object + return target; + }; + + function _toConsumableArray(arr) { return _arrayWithoutHoles(arr) || _iterableToArray(arr) || _unsupportedIterableToArray(arr) || _nonIterableSpread(); } + + function _nonIterableSpread() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } + + function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); } + + function _iterableToArray(iter) { if (typeof Symbol !== "undefined" && Symbol.iterator in Object(iter)) return Array.from(iter); } + + function _arrayWithoutHoles(arr) { if (Array.isArray(arr)) return _arrayLikeToArray(arr); } + + function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; } + + function _typeof$2(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof$2 = function _typeof(obj) { return typeof obj; }; } else { _typeof$2 = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof$2(obj); } + var extend$1 = extend.bind(null, true); + var JSONPatch = {}; + var isArray$1 = Array.isArray; + + function isObject(v) { + return v != null && !Array.isArray(v) && _typeof$2(v) === 'object'; + } + + function isUndef(v) { + return typeof v === 'undefined'; + } + + function isFunction(v) { + return typeof v === 'function'; + } + /** + * Generate an exact duplicate (with no references) of a specific value. + * + * @private + * @param {Object} The value to duplicate + * @returns {Object} a unique, duplicated value + */ + + + function generateValue(val) { + if (val) { + return extend$1({}, { + val: val + }).val; + } + + return val; + } + /** + * An additional type checker used to determine if the property is of internal + * use or not a type that can be translated into JSON (like functions). + * + * @private + * @param {Object} obj The object which has the property to check + * @param {String} The property name to check + * @returns {Boolean} Whether the property is deemed special or not + */ + + + function isSpecialProperty(obj, key) { + return isFunction(obj[key]) || key.substring(0, 2) === '$$' || key.substring(0, 1) === '_'; + } + /** + * Finds the parent object from a JSON-Pointer ("/foo/bar/baz" = "bar" is "baz" parent), + * also creates the object structure needed. + * + * @private + * @param {Object} data The root object to traverse through + * @param {String} The JSON-Pointer string to use when traversing + * @returns {Object} The parent object + */ + + + function getParent(data, str) { + var seperator = '/'; + var parts = str.substring(1).split(seperator).slice(0, -1); + var numPart; + parts.forEach(function (part, i) { + if (i === parts.length) { + return; + } + + numPart = +part; + var newPart = !isNaN(numPart) ? [] : {}; + data[numPart || part] = isUndef(data[numPart || part]) ? newPart : data[part]; + data = data[numPart || part]; + }); + return data; + } + /** + * Cleans an object of all its properties, unless they're deemed special or + * cannot be removed by configuration. + * + * @private + * @param {Object} obj The object to clean + */ + + + function emptyObject(obj) { + Object.keys(obj).forEach(function (key) { + var config = Object.getOwnPropertyDescriptor(obj, key); + + if (config.configurable && !isSpecialProperty(obj, key)) { + delete obj[key]; + } + }); + } + /** + * Compare an object with another, could be object, array, number, string, bool. + * @private + * @param {Object} a The first object to compare + * @param {Object} a The second object to compare + * @returns {Boolean} Whether the objects are identical + */ + + + function compare(a, b) { + var isIdentical = true; + + if (isObject(a) && isObject(b)) { + if (Object.keys(a).length !== Object.keys(b).length) { + return false; + } + + Object.keys(a).forEach(function (key) { + if (!compare(a[key], b[key])) { + isIdentical = false; + } + }); + return isIdentical; + } + + if (isArray$1(a) && isArray$1(b)) { + if (a.length !== b.length) { + return false; + } + + for (var i = 0, l = a.length; i < l; i += 1) { + if (!compare(a[i], b[i])) { + return false; + } + } + + return true; + } + + return a === b; + } + /** + * Generates patches by comparing two arrays. + * + * @private + * @param {Array} oldA The old (original) array, which will be patched + * @param {Array} newA The new array, which will be used to compare against + * @returns {Array} An array of patches (if any) + */ + + + function patchArray(original, newA, basePath) { + var patches = []; + var oldA = original.slice(); + var tmpIdx = -1; + + function findIndex(a, id, idx) { + if (a[idx] && isUndef(a[idx].qInfo)) { + return null; + } + + if (a[idx] && a[idx].qInfo.qId === id) { + // shortcut if identical + return idx; + } + + for (var ii = 0, ll = a.length; ii < ll; ii += 1) { + if (a[ii] && a[ii].qInfo.qId === id) { + return ii; + } + } + + return -1; + } + + if (compare(newA, oldA)) { + // array is unchanged + return patches; + } + + if (!isUndef(newA[0]) && isUndef(newA[0].qInfo)) { + // we cannot create patches without unique identifiers, replace array... + patches.push({ + op: 'replace', + path: basePath, + value: newA + }); + return patches; + } + + for (var i = oldA.length - 1; i >= 0; i -= 1) { + tmpIdx = findIndex(newA, oldA[i].qInfo && oldA[i].qInfo.qId, i); + + if (tmpIdx === -1) { + patches.push({ + op: 'remove', + path: "".concat(basePath, "/").concat(i) + }); + oldA.splice(i, 1); + } else { + patches = patches.concat(JSONPatch.generate(oldA[i], newA[tmpIdx], "".concat(basePath, "/").concat(i))); + } + } + + for (var _i = 0, l = newA.length; _i < l; _i += 1) { + tmpIdx = findIndex(oldA, newA[_i].qInfo && newA[_i].qInfo.qId); + + if (tmpIdx === -1) { + patches.push({ + op: 'add', + path: "".concat(basePath, "/").concat(_i), + value: newA[_i] + }); + oldA.splice(_i, 0, newA[_i]); + } else if (tmpIdx !== _i) { + patches.push({ + op: 'move', + path: "".concat(basePath, "/").concat(_i), + from: "".concat(basePath, "/").concat(tmpIdx) + }); + oldA.splice(_i, 0, oldA.splice(tmpIdx, 1)[0]); + } + } + + return patches; + } + /** + * Generate an array of JSON-Patch:es following the JSON-Patch Specification Draft. + * + * See [specification draft](http://tools.ietf.org/html/draft-ietf-appsawg-json-patch-10) + * + * Does NOT currently generate patches for arrays (will replace them) + * @private + * @param {Object} original The object to patch to + * @param {Object} newData The object to patch from + * @param {String} [basePath] The base path to use when generating the paths for + * the patches (normally not used) + * @returns {Array} An array of patches + */ + + + JSONPatch.generate = function generate(original, newData, basePath) { + basePath = basePath || ''; + var patches = []; + Object.keys(newData).forEach(function (key) { + var val = generateValue(newData[key]); + var oldVal = original[key]; + var tmpPath = "".concat(basePath, "/").concat(key); + + if (compare(val, oldVal) || isSpecialProperty(newData, key)) { + return; + } + + if (isUndef(oldVal)) { + // property does not previously exist + patches.push({ + op: 'add', + path: tmpPath, + value: val + }); + } else if (isObject(val) && isObject(oldVal)) { + // we need to generate sub-patches for this, since it already exist + patches = patches.concat(JSONPatch.generate(oldVal, val, tmpPath)); + } else if (isArray$1(val) && isArray$1(oldVal)) { + patches = patches.concat(patchArray(oldVal, val, tmpPath)); + } else { + // it's a simple property (bool, string, number) + patches.push({ + op: 'replace', + path: "".concat(basePath, "/").concat(key), + value: val + }); + } + }); + Object.keys(original).forEach(function (key) { + if (isUndef(newData[key]) && !isSpecialProperty(original, key)) { + // this property does not exist anymore + patches.push({ + op: 'remove', + path: "".concat(basePath, "/").concat(key) + }); + } + }); + return patches; + }; + /** + * Apply a list of patches to an object. + * @private + * @param {Object} original The object to patch + * @param {Array} patches The list of patches to apply + */ + + + JSONPatch.apply = function apply(original, patches) { + patches.forEach(function (patch) { + var parent = getParent(original, patch.path); + var key = patch.path.split('/').splice(-1)[0]; + var target = key && isNaN(+key) ? parent[key] : parent[+key] || parent; + var from = patch.from ? patch.from.split('/').splice(-1)[0] : null; + + if (patch.path === '/') { + parent = null; + target = original; + } + + if (patch.op === 'add' || patch.op === 'replace') { + if (isArray$1(parent)) { + // trust indexes from patches, so don't replace the index if it's an add + if (key === '-') { + key = parent.length; + } + + parent.splice(+key, patch.op === 'add' ? 0 : 1, patch.value); + } else if (isArray$1(target) && isArray$1(patch.value)) { + // keep array reference if possible... + target.length = 0; + var chunkSize = 1000; + + for (var i = 0; i < patch.value.length; i += chunkSize) { + var _target; + + var chunk = patch.value.slice(i, i + chunkSize); + + (_target = target).push.apply(_target, _toConsumableArray(chunk)); + } + } else if (isObject(target) && isObject(patch.value)) { + // keep object reference if possible... + emptyObject(target); + extend$1(target, patch.value); + } else if (!parent) { + throw createEnigmaError(errorCodes.PATCH_HAS_NO_PARENT, 'Patchee is not an object we can patch'); + } else { + // simple value + parent[key] = patch.value; + } + } else if (patch.op === 'move') { + var oldParent = getParent(original, patch.from); + + if (isArray$1(parent)) { + parent.splice(+key, 0, oldParent.splice(+from, 1)[0]); + } else { + parent[key] = oldParent[from]; + delete oldParent[from]; + } + } else if (patch.op === 'remove') { + if (isArray$1(parent)) { + parent.splice(+key, 1); + } else { + delete parent[key]; + } + } + }); + }; + /** + * Deep clone an object. + * @private + * @param {Object} obj The object to clone + * @returns {Object} A new object identical to the `obj` + */ + + + JSONPatch.clone = function clone(obj) { + return extend$1({}, obj); + }; + /** + * Creates a JSON-patch. + * @private + * @param {String} op The operation of the patch. Available values: "add", "remove", "move" + * @param {Object} [val] The value to set the `path` to. If `op` is `move`, `val` + * is the "from JSON-path" path + * @param {String} path The JSON-path for the property to change (e.g. "/qHyperCubeDef/columnOrder") + * @returns {Object} A patch following the JSON-patch specification + */ + + + JSONPatch.createPatch = function createPatch(op, val, path) { + var patch = { + op: op.toLowerCase(), + path: path + }; + + if (patch.op === 'move') { + patch.from = val; + } else if (typeof val !== 'undefined') { + patch.value = val; + } + + return patch; + }; + /** + * Apply the differences of two objects (keeping references if possible). + * Identical to running `JSONPatch.apply(original, JSONPatch.generate(original, newData));` + * @private + * @param {Object} original The object to update/patch + * @param {Object} newData the object to diff against + * + * @example + * var obj1 = { foo: [1,2,3], bar: { baz: true, qux: 1 } }; + * var obj2 = { foo: [4,5,6], bar: { baz: false } }; + * JSONPatch.updateObject(obj1, obj2); + * // => { foo: [4,5,6], bar: { baz: false } }; + */ + + + JSONPatch.updateObject = function updateObject(original, newData) { + if (!Object.keys(original).length) { + extend$1(original, newData); + return; + } + + JSONPatch.apply(original, JSONPatch.generate(original, newData)); + }; + + function _typeof$3(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof$3 = function _typeof(obj) { return typeof obj; }; } else { _typeof$3 = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof$3(obj); } + var sessions = {}; + /** + * Function to make sure we release handle caches when they are closed. + * @private + * @param {Session} session The session instance to listen on. + */ + + var bindSession = function bindSession(session) { + if (!sessions[session.id]) { + var cache = {}; + sessions[session.id] = cache; + session.on('traffic:received', function (data) { + return data.close && data.close.forEach(function (handle) { + return delete cache[handle]; + }); + }); + session.on('closed', function () { + return delete sessions[session.id]; + }); + } + }; + /** + * Simple function that ensures the session events has been bound, and returns + * either an existing key-value cache or creates one for the specified handle. + * @private + * @param {Session} session The session that owns the handle. + * @param {Number} handle The object handle to retrieve the cache for. + * @returns {KeyValueCache} The cache instance. + */ + + + var getHandleCache = function getHandleCache(session, handle) { + bindSession(session); + var cache = sessions[session.id]; + + if (!cache[handle]) { + cache[handle] = new KeyValueCache(); + } + + return cache[handle]; + }; + /** + * Function used to apply a list of patches and return the patched value. + * @private + * @param {Session} session The session. + * @param {Number} handle The object handle. + * @param {String} cacheId The cacheId. + * @param {Array} patches The patches. + * @returns {Object} Returns the patched value. + */ + + + var patchValue = function patchValue(session, handle, cacheId, patches) { + var cache = getHandleCache(session, handle); + var entry = cache.get(cacheId); + + if (typeof entry === 'undefined') { + entry = Array.isArray(patches[0].value) ? [] : {}; + } + + if (patches.length) { + if (patches[0].path === '/' && _typeof$3(patches[0].value) !== 'object') { + // 'plain' values on root path is not supported (no object reference), + // so we simply store the value directly: + entry = patches[0].value; + } else { + JSONPatch.apply(entry, patches); + } + + cache.set(cacheId, entry); + } + + return entry; + }; + /** + * Process delta interceptor. + * @private + * @param {Session} session The session the intercept is being executed on. + * @param {Object} request The JSON-RPC request. + * @param {Object} response The response. + * @returns {Object} Returns the patched response + */ + + + function deltaResponseInterceptor(session, request, response) { + var delta = response.delta, + result = response.result; + + if (delta) { + // when delta is on the response data is expected to be an array of patches: + Object.keys(result).forEach(function (key) { + if (!Array.isArray(result[key])) { + throw createEnigmaError(errorCodes.EXPECTED_ARRAY_OF_PATCHES, 'Unexpected RPC response, expected array of patches'); + } + + result[key] = patchValue(session, request.handle, "".concat(request.method, "-").concat(key), result[key]); + }); // return a cloned response object to avoid patched object references: + + return JSON.parse(JSON.stringify(response)); + } + + return response; + } // export object reference for testing purposes: + + deltaResponseInterceptor.sessions = sessions; + + /** + * Process error interceptor. + * @private + * @param {Session} session - The session the intercept is being executed on. + * @param {Object} request - The JSON-RPC request. + * @param {Object} response - The response. + * @returns {Object} - Returns the defined error for an error, else the response. + */ + function errorResponseInterceptor(session, request, response) { + if (typeof response.error !== 'undefined') { + var data = response.error; + var error = new Error(data.message); + error.code = data.code; + error.parameter = data.parameter; + return session.config.Promise.reject(error); + } + + return response; + } + + var RETURN_KEY = 'qReturn'; + /** + * Picks out the result "out" parameter based on the QIX method+schema, with + * some specific handling for some methods that breaks the predictable protocol. + * @private + * @param {Session} session - The session the intercept is being executed on. + * @param {Object} request - The JSON-RPC request. + * @param {Object} response - The response. + * @returns {Object} - Returns the result property on the response + */ + + function outParamResponseInterceptor(session, request, response) { + if (request.method === 'CreateSessionApp' || request.method === 'CreateSessionAppFromApp') { + // this method returns multiple out params that we need + // to normalize before processing the response further: + response[RETURN_KEY].qGenericId = response.qSessionAppId || response[RETURN_KEY].qGenericId; + } else if (request.method === 'GetInteract') { + // this method returns a qReturn value when it should only return + // meta.outKey: + delete response[RETURN_KEY]; + } + + if (hasOwnProperty.call(response, RETURN_KEY)) { + return response[RETURN_KEY]; + } + + if (request.outKey !== -1) { + return response[request.outKey]; + } + + return response; + } + + /** + * Process result interceptor. + * @private + * @param {Session} session - The session the intercept is being executed on. + * @param {Object} request - The JSON-RPC request. + * @param {Object} response - The response. + * @returns {Object} - Returns the result property on the response + */ + function resultResponseInterceptor(session, request, response) { + return response.result; + } + + function _toConsumableArray$1(arr) { return _arrayWithoutHoles$1(arr) || _iterableToArray$1(arr) || _unsupportedIterableToArray$1(arr) || _nonIterableSpread$1(); } + + function _nonIterableSpread$1() { throw new TypeError("Invalid attempt to spread non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } + + function _unsupportedIterableToArray$1(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray$1(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray$1(o, minLen); } + + function _iterableToArray$1(iter) { if (typeof Symbol !== "undefined" && Symbol.iterator in Object(iter)) return Array.from(iter); } + + function _arrayWithoutHoles$1(arr) { if (Array.isArray(arr)) return _arrayLikeToArray$1(arr); } + + function _arrayLikeToArray$1(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) { arr2[i] = arr[i]; } return arr2; } + + function _classCallCheck$7(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + + function _defineProperties$6(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } + + function _createClass$6(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties$6(Constructor.prototype, protoProps); if (staticProps) _defineProperties$6(Constructor, staticProps); return Constructor; } + /** + * Interceptors is a concept similar to mixins, but run on a lower level. The interceptor concept + * can augment either the requests (i.e. before sent to QIX Engine), or the responses (i.e. after + * QIX Engine has sent a response). The interceptor promises runs in parallel to the regular + * promises used in enigma.js, which means that it can be really useful when you want to normalize + * behaviors in your application. + * @interface Interceptor + */ + + /** + * @class InterceptorRequest + * @implements {Interceptor} + * @example Implement a request interceptor + * const enigma = require('enigma.js'); + * const WebSocket = require('ws'); + * const schema = require('enigma.js/schemas/12.20.0.json'); + * + * const session = enigma.create({ + * schema, + * url: 'ws://localhost:9076/app/engineData', + * createSocket: (url) => new WebSocket(url), + * requestInterceptors: [{ + * onFulfilled: function logRequest(sessionReference, request) { + * console.log('Request being sent', request); + * return request; + * } + * }, + * }); + */ + + /** + * @class InterceptorResponse + * @implements {Interceptor} + * @example Implement a request interceptor + * const enigma = require('enigma.js'); + * const WebSocket = require('ws'); + * const schema = require('enigma.js/schemas/12.20.0.json'); + * + * const session = enigma.create({ + * schema, + * url: 'ws://localhost:9076/app/engineData', + * createSocket: (url) => new WebSocket(url), + * responseInterceptors: [{ + * onRejected: function logError(sessionReference, request, error) { + * console.log('Error returned from QIX engine', error, 'Originating request:', request); + * // throw error so it's continued to be rejected: + * throw error; + * } + * }, + * }); + */ + + /** + * This method is invoked when a request is about to be sent to QIX Engine. + * @function InterceptorRequest#onFulfilled + * @param {Session} session The session executing the interceptor. + * @param {Object} request The JSON-RPC request that will be sent. + */ + + /** + * This method is invoked when a previous interceptor has rejected the + * promise, use this to handle for example errors before they are sent into mixins. + * @function InterceptorResponse#onRejected + * @param {Session} session The session executing the interceptor. You may use .retry() to retry + * sending it to QIX Engine. + * @param {Object} request The JSON-RPC request resulting in this error. + * @param {Object} error Whatever the previous interceptor is rejected with. + */ + + /** + * This method is invoked when a promise has been successfully resolved, + * use this to modify the result or reject the promise chain before it is sent + * to mixins. + * @function InterceptorResponse#onFulfilled + * @param {Session} session The session executing the interceptor. + * @param {Object} request The JSON-RPC request resulting in this response. + * @param {Object} result Whatever the previous interceptor is resolved with. + */ + + var Intercept = /*#__PURE__*/function () { + /** + * Create a new Intercept instance. + * @private + * @param {Object} options The configuration options for this class. + * @param {Promise} options.Promise The promise constructor to use. + * @param {ApiCache} options.apis The ApiCache instance to use. + * @param {Array} [options.request] The additional request interceptors to use. + * @param {Array} [options.response] The additional response interceptors to use. + */ + function Intercept(options) { + _classCallCheck$7(this, Intercept); + + Object.assign(this, options); + this.request = [{ + onFulfilled: deltaRequestInterceptor + }].concat(_toConsumableArray$1(this.request || [])); + this.response = [{ + onFulfilled: errorResponseInterceptor + }, { + onFulfilled: deltaResponseInterceptor + }, { + onFulfilled: resultResponseInterceptor + }, { + onFulfilled: outParamResponseInterceptor + }].concat(_toConsumableArray$1(this.response || []), [{ + onFulfilled: apiResponseInterceptor + }]); + } + /** + * Execute the request interceptor queue, each interceptor will get the result from + * the previous interceptor. + * @private + * @param {Session} session The session instance to execute against. + * @param {Promise} promise The promise to chain on to. + * @returns {Promise} + */ + + + _createClass$6(Intercept, [{ + key: "executeRequests", + value: function executeRequests(session, promise) { + var _this = this; + + return this.request.reduce(function (interception, interceptor) { + var intercept = interceptor.onFulfilled && interceptor.onFulfilled.bind(_this, session); + return interception.then(intercept); + }, promise); + } + /** + * Execute the response interceptor queue, each interceptor will get the result from + * the previous interceptor. + * @private + * @param {Session} session The session instance to execute against. + * @param {Promise} promise The promise to chain on to. + * @param {Object} request The JSONRPC request object for the intercepted response. + * @returns {Promise} + */ + + }, { + key: "executeResponses", + value: function executeResponses(session, promise, request) { + var _this2 = this; + + return this.response.reduce(function (interception, interceptor) { + return interception.then(interceptor.onFulfilled && interceptor.onFulfilled.bind(_this2, session, request), interceptor.onRejected && interceptor.onRejected.bind(_this2, session, request)); + }, promise); + } + }]); + + return Intercept; + }(); + + function _typeof$4(obj) { "@babel/helpers - typeof"; if (typeof Symbol === "function" && typeof Symbol.iterator === "symbol") { _typeof$4 = function _typeof(obj) { return typeof obj; }; } else { _typeof$4 = function _typeof(obj) { return obj && typeof Symbol === "function" && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }; } return _typeof$4(obj); } + + function _classCallCheck$8(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + + function _defineProperties$7(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } + + function _createClass$7(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties$7(Constructor.prototype, protoProps); if (staticProps) _defineProperties$7(Constructor, staticProps); return Constructor; } + + function _get(target, property, receiver) { if (typeof Reflect !== "undefined" && Reflect.get) { _get = Reflect.get; } else { _get = function _get(target, property, receiver) { var base = _superPropBase(target, property); if (!base) return; var desc = Object.getOwnPropertyDescriptor(base, property); if (desc.get) { return desc.get.call(receiver); } return desc.value; }; } return _get(target, property, receiver || target); } + + function _superPropBase(object, property) { while (!Object.prototype.hasOwnProperty.call(object, property)) { object = _getPrototypeOf$1(object); if (object === null) break; } return object; } + + function _inherits$1(subClass, superClass) { if (typeof superClass !== "function" && superClass !== null) { throw new TypeError("Super expression must either be null or a function"); } subClass.prototype = Object.create(superClass && superClass.prototype, { constructor: { value: subClass, writable: true, configurable: true } }); if (superClass) _setPrototypeOf$1(subClass, superClass); } + + function _setPrototypeOf$1(o, p) { _setPrototypeOf$1 = Object.setPrototypeOf || function _setPrototypeOf(o, p) { o.__proto__ = p; return o; }; return _setPrototypeOf$1(o, p); } + + function _createSuper$1(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct$1(); return function _createSuperInternal() { var Super = _getPrototypeOf$1(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf$1(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn$1(this, result); }; } + + function _possibleConstructorReturn$1(self, call) { if (call && (_typeof$4(call) === "object" || typeof call === "function")) { return call; } return _assertThisInitialized$1(self); } + + function _assertThisInitialized$1(self) { if (self === void 0) { throw new ReferenceError("this hasn't been initialised - super() hasn't been called"); } return self; } + + function _isNativeReflectConstruct$1() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Date.prototype.toString.call(Reflect.construct(Date, [], function () {})); return true; } catch (e) { return false; } } + + function _getPrototypeOf$1(o) { _getPrototypeOf$1 = Object.setPrototypeOf ? Object.getPrototypeOf : function _getPrototypeOf(o) { return o.__proto__ || Object.getPrototypeOf(o); }; return _getPrototypeOf$1(o); } + /** + * API cache for instances of QIX types, e.g. GenericObject. + * @private + * @extends KeyValueCache + */ + + var ApiCache = /*#__PURE__*/function (_KeyValueCache) { + _inherits$1(ApiCache, _KeyValueCache); + + var _super = _createSuper$1(ApiCache); + + function ApiCache() { + _classCallCheck$8(this, ApiCache); + + return _super.apply(this, arguments); + } + + _createClass$7(ApiCache, [{ + key: "add", + + /** + * Adds an API. + * @private + * @function ApiCache#add + * @param {Number} handle - The handle for the API. + * @param {*} api - The API. + * @returns {{api: *}} The entry. + */ + value: function add(handle, api) { + var _this = this; + + var entry = { + api: api + }; + + _get(_getPrototypeOf$1(ApiCache.prototype), "add", this).call(this, handle.toString(), entry); + + api.on('closed', function () { + return _this.remove(handle); + }); + return entry; + } + /** + * Gets an API. + * @private + * @function ApiCache#getApi + * @param {Number} handle - The handle for the API. + * @returns {*} The API for the handle. + */ + + }, { + key: "getApi", + value: function getApi(handle) { + var entry = typeof handle !== 'undefined' ? this.get(handle.toString()) : undefined; + return entry && entry.api; + } + /** + * Gets a list of APIs. + * @private + * @function ApiCache#getApis + * @returns {Array} The list of entries including `handle` and `api` properties for each entry. + */ + + }, { + key: "getApis", + value: function getApis() { + return _get(_getPrototypeOf$1(ApiCache.prototype), "getAll", this).call(this).map(function (entry) { + return { + handle: entry.key, + api: entry.value.api + }; + }); + } + /** + * Gets a list of APIs with a given type. + * @private + * @function ApiCache#getApisByType + * @param {String} type - The type of APIs to get. + * @returns {Array} The list of entries including `handle` and `api` properties for each entry. + */ + + }, { + key: "getApisByType", + value: function getApisByType(type) { + return this.getApis().filter(function (entry) { + return entry.api.type === type; + }); + } + }]); + + return ApiCache; + }(KeyValueCache); + + function _classCallCheck$9(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + + function _defineProperties$8(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } + + function _createClass$8(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties$8(Constructor.prototype, protoProps); if (staticProps) _defineProperties$8(Constructor, staticProps); return Constructor; } + /** + * The enigma.js configuration object. + * @interface Configuration + * @property {Object} schema Object containing the specification for the API to generate. + * Corresponds to a specific version of the QIX Engine API. + * @property {String} url String containing a proper websocket URL to QIX Engine. + * @property {Function} [createSocket] A function to use when instantiating the WebSocket, + * mandatory for Node.js. + * @property {Object} [Promise] ES6-compatible Promise library. + * @property {Boolean} [suspendOnClose=false] Set to true if the session should be suspended + * instead of closed when the websocket is closed. + * @property {Array} [mixins=[]] Mixins to extend/augment the QIX Engine API. Mixins + * are applied in the array order. + * @property {Array} [requestInterceptors=[]] Interceptors for augmenting requests before they + * are sent to QIX Engine. Interceptors are applied in the array order. + * @property {Array} [responseInterceptors=[]] Interceptors for augmenting responses before they + * are passed into mixins and end-users. Interceptors are applied in the array order. + * @property {Object} [protocol={}] An object containing additional JSON-RPC request parameters. + * @property {Boolean} [protocol.delta=true] Set to false to disable the use of the + * bandwidth-reducing delta protocol. + * @example Example defining a configuration object + * const enigma = require('enigma.js'); + * const WebSocket = require('ws'); + * const bluebird = require('bluebird'); + * const schema = require('enigma.js/schemas/12.20.0.json'); + * + * const config = { + * schema, + * url: 'ws://localhost:4848/app/engineData', + * createSocket: url => new WebSocket(url), + * Promise: bluebird, + * suspendOnClose: true, + * mixins: [{ types: ['Global'], init: () => console.log('Mixin ran') }], + * protocol: { delta: false }, + * }; + * + * enigma.create(config).open().then((global) => { + * // global === QIX global interface + * process.exit(0); + * }); + */ + + /** + * The mixin concept allows you to add or override QIX Engine API functionality. A mixin is + * basically a JavaScript object describing which types it modifies, and a list of functions + * for extending and overriding the API for those types. + * + * QIX Engine types like for example GenericObject, Doc, GenericBookmark, are supported but + * also custom GenericObject types such as barchart, story and myCustomType. An API will get + * both their generic type as well as custom type mixins applied. + * + * Mixins that are bound to several different types can find the current API type in the + * `genericType` or `type` members. `this.type` would for instance return `GenericObject` and + * `this.genericType` would return `barchart`. + * + * See the Mixins examples on how to use it, below is an outline of what the mixin API consists of. + * + * @interface Mixin + * @property {String|Array} types String or array of strings containing the API-types that + * will be mixed in. + * @property {Object} [extend] Object literal containing the methods that will be extended on the + * specified API. + * @property {Object} [override] Object literal containing the methods to override existing methods. + * @property {Function} [init] Init function that, if defined, will run when an API is instantiated. + * It runs with Promise and API object as parameters + */ + + /** + * The API for generated APIs depends on the QIX Engine schema you pass into your Configuration, and + * on what QIX struct the API has. + * + * All API calls made using the generated APIs will return promises which are either resolved or + * rejected depending on how the QIX Engine responds. + * + * @interface API + * @property {String} id Contains the unique identifier for this API. + * @property {String} type Contains the schema class name for this API. + * @property {String} genericType Corresponds to the qInfo.qType property on the generic object's + * properties object. + * @property {Session} session Contains a reference to the session that this API belongs to. + * @property {Number} handle Contains the handle QIX Engine assigned to the API. Used interally in + * enigma.js for caches and JSON-RPC requests. + * @example Example using `global` and `generic object` struct APIs + * global.openDoc('my-document.qvf').then((doc) => { + * doc.createObject({ qInfo: { qType: 'my-object' } }).then(api => { }); + * doc.getObject('object-id').then(api => { }); + * doc.getBookmark('bookmark-id').then(api => { }); + * }); + */ + + /** + * Handle changes on the API. The changed event is triggered whenever enigma.js or QIX Engine has + * identified potential changes on the underlying properties or hypercubes and you should re-fetch + * your data. + * @event API#changed + * @type {Object} + * @example Bind the `changed` event + * api.on('changed', () => { + * api.getLayout().then(layout => { }); + * }); + */ + + /** + * Handle closed API. The closed event is triggered whenever QIX Engine considers an API closed. + * It usually means that it no longer exist in the QIX Engine document or session. + * @event API#closed + * @type {Object} + * @example Bind the `closed` event + * api.on('closed', () => { + * console.log(api.id, 'was closed'); + * }); + */ + + /** + * Handle JSON-RPC requests/responses for this API. Generally used in debugging purposes. + * `traffic:*` will handle all websocket messages, `traffic:sent` will handle outgoing messages + * and `traffic:received` will handle incoming messages. + * @event API#traffic + * @type {Object} + * @example Bind the traffic events + * // bind both in- and outbound traffic to console.log: + * api.on('traffic:*', console.log); + * // bind outbound traffic to console.log: + * api.on('traffic:sent', console.log); + * // bind inbound traffic to console.log: + * api.on('traffic:received', console.log); + */ + + var Enigma = /*#__PURE__*/function () { + function Enigma() { + _classCallCheck$9(this, Enigma); + } + + _createClass$8(Enigma, null, [{ + key: "getSession", + + /** + * Function used to get a session. + * @private + * @param {Configuration} config The configuration object for this session. + * @returns {Session} Returns a session instance. + */ + value: function getSession(config) { + var createSocket = config.createSocket, + Promise = config.Promise, + requestInterceptors = config.requestInterceptors, + responseInterceptors = config.responseInterceptors, + url = config.url; + var apis = new ApiCache(); + var intercept = new Intercept({ + apis: apis, + Promise: Promise, + request: requestInterceptors, + response: responseInterceptors + }); + var rpc = new RPC({ + createSocket: createSocket, + Promise: Promise, + url: url + }); + var suspendResume = new SuspendResume({ + apis: apis, + Promise: Promise, + rpc: rpc + }); + var session = new Session({ + apis: apis, + config: config, + intercept: intercept, + rpc: rpc, + suspendResume: suspendResume + }); + return session; + } + /** + * Function used to configure defaults. + * @private + * @param {Configuration} config The configuration object for how to connect + * and retrieve end QIX APIs. + */ + + }, { + key: "configureDefaults", + value: function configureDefaults(config) { + if (!config) { + throw createEnigmaError(errorCodes.NO_CONFIG_SUPPLIED, 'You need to supply a configuration.'); + } // eslint-disable-next-line no-restricted-globals + + + if (!config.Promise && typeof Promise === 'undefined') { + throw createEnigmaError(errorCodes.PROMISE_REQUIRED, 'Your environment has no Promise implementation. You must provide a Promise implementation in the config.'); + } + + if (typeof config.createSocket !== 'function' && typeof WebSocket === 'function') { + // eslint-disable-next-line no-undef + config.createSocket = function (url) { + return new WebSocket(url); + }; + } + + if (typeof config.suspendOnClose === 'undefined') { + config.suspendOnClose = false; + } + + config.protocol = config.protocol || {}; + config.protocol.delta = typeof config.protocol.delta !== 'undefined' ? config.protocol.delta : true; // eslint-disable-next-line no-restricted-globals + + config.Promise = config.Promise || Promise; + config.mixins = config.mixins || []; + config.definition = config.definition || new Schema(config); + } + /** + * Function used to create a QIX session. + * @entry + * @param {Configuration} config The configuration object for the QIX session. + * @returns {Session} Returns a new QIX session. + * @example Example minimal session creation + * const enigma = require('enigma.js'); + * const schema = require('enigma.js/schemas/12.20.0.json'); + * const WebSocket = require('ws'); + * const config = { + * schema, + * url: 'ws://localhost:9076/app/engineData', + * createSocket: url => new WebSocket(url), + * }; + * const session = enigma.create(config); + */ + + }, { + key: "create", + value: function create(config) { + Enigma.configureDefaults(config); + config.mixins.forEach(function (mixin) { + config.definition.registerMixin(mixin); + }); + return Enigma.getSession(config); + } + }]); + + return Enigma; + }(); + + return Enigma; + +}))); +//# sourceMappingURL=enigma.js.map diff --git a/jwt-scratch/src/js/node_modules/enigma.js/enigma.js.map b/jwt-scratch/src/js/node_modules/enigma.js/enigma.js.map new file mode 100644 index 0000000..7db111f --- /dev/null +++ b/jwt-scratch/src/js/node_modules/enigma.js/enigma.js.map @@ -0,0 +1 @@ +{"version":3,"file":"enigma.js","sources":["node_modules/node-event-emitter/index.js","src/event-emitter.js","src/error.js","src/error-codes.js","src/session.js","src/key-value-cache.js","src/schema.js","src/rpc-resolver.js","src/rpc.js","src/suspend-resume.js","src/interceptors/delta-request-interceptor.js","src/interceptors/api-response-interceptor.js","node_modules/extend/index.js","src/json-patch.js","src/interceptors/delta-response-interceptor.js","src/interceptors/error-response-interceptor.js","src/interceptors/out-param-response-interceptor.js","src/interceptors/result-response-interceptor.js","src/intercept.js","src/api-cache.js","src/enigma.js"],"sourcesContent":["/**\n * Utility functions\n */\n\nvar util = {};\n\nutil.isObject = function isObject(arg) {\n return typeof arg === 'object' && arg !== null;\n}\n\nutil.isNumber = function isNumber(arg) {\n return typeof arg === 'number';\n}\n\nutil.isUndefined = function isUndefined(arg) {\n return arg === void 0;\n}\n\nutil.isFunction = function isFunction(arg){\n return typeof arg === 'function';\n}\n\n\n/**\n * EventEmitter class\n */\n\nfunction EventEmitter() {\n EventEmitter.init.call(this);\n}\nmodule.exports = EventEmitter;\n\n// Backwards-compat with node 0.10.x\nEventEmitter.EventEmitter = EventEmitter;\n\nEventEmitter.prototype._events = undefined;\nEventEmitter.prototype._maxListeners = undefined;\n\n// By default EventEmitters will print a warning if more than 10 listeners are\n// added to it. This is a useful default which helps finding memory leaks.\nEventEmitter.defaultMaxListeners = 10;\n\nEventEmitter.init = function() {\n this._events = this._events || {};\n this._maxListeners = this._maxListeners || undefined;\n};\n\n// Obviously not all Emitters should be limited to 10. This function allows\n// that to be increased. Set to zero for unlimited.\nEventEmitter.prototype.setMaxListeners = function(n) {\n if (!util.isNumber(n) || n < 0 || isNaN(n))\n throw TypeError('n must be a positive number');\n this._maxListeners = n;\n return this;\n};\n\nEventEmitter.prototype.emit = function(type) {\n var er, handler, len, args, i, listeners;\n\n if (!this._events)\n this._events = {};\n\n // If there is no 'error' event listener then throw.\n if (type === 'error' && !this._events.error) {\n er = arguments[1];\n if (er instanceof Error) {\n throw er; // Unhandled 'error' event\n } else {\n throw Error('Uncaught, unspecified \"error\" event.');\n }\n return false;\n }\n\n handler = this._events[type];\n\n if (util.isUndefined(handler))\n return false;\n\n if (util.isFunction(handler)) {\n switch (arguments.length) {\n // fast cases\n case 1:\n handler.call(this);\n break;\n case 2:\n handler.call(this, arguments[1]);\n break;\n case 3:\n handler.call(this, arguments[1], arguments[2]);\n break;\n // slower\n default:\n len = arguments.length;\n args = new Array(len - 1);\n for (i = 1; i < len; i++)\n args[i - 1] = arguments[i];\n handler.apply(this, args);\n }\n } else if (util.isObject(handler)) {\n len = arguments.length;\n args = new Array(len - 1);\n for (i = 1; i < len; i++)\n args[i - 1] = arguments[i];\n\n listeners = handler.slice();\n len = listeners.length;\n for (i = 0; i < len; i++)\n listeners[i].apply(this, args);\n }\n\n return true;\n};\n\nEventEmitter.prototype.addListener = function(type, listener) {\n var m;\n\n if (!util.isFunction(listener))\n throw TypeError('listener must be a function');\n\n if (!this._events)\n this._events = {};\n\n // To avoid recursion in the case that type === \"newListener\"! Before\n // adding it to the listeners, first emit \"newListener\".\n if (this._events.newListener)\n this.emit('newListener', type,\n util.isFunction(listener.listener) ?\n listener.listener : listener);\n\n if (!this._events[type])\n // Optimize the case of one listener. Don't need the extra array object.\n this._events[type] = listener;\n else if (util.isObject(this._events[type]))\n // If we've already got an array, just append.\n this._events[type].push(listener);\n else\n // Adding the second element, need to change to array.\n this._events[type] = [this._events[type], listener];\n\n // Check for listener leak\n if (util.isObject(this._events[type]) && !this._events[type].warned) {\n var m;\n if (!util.isUndefined(this._maxListeners)) {\n m = this._maxListeners;\n } else {\n m = EventEmitter.defaultMaxListeners;\n }\n\n if (m && m > 0 && this._events[type].length > m) {\n this._events[type].warned = true;\n\n if (util.isFunction(console.error)) {\n console.error('(node) warning: possible EventEmitter memory ' +\n 'leak detected. %d listeners added. ' +\n 'Use emitter.setMaxListeners() to increase limit.',\n this._events[type].length);\n }\n if (util.isFunction(console.trace))\n console.trace();\n }\n }\n\n return this;\n};\n\nEventEmitter.prototype.on = EventEmitter.prototype.addListener;\n\nEventEmitter.prototype.once = function(type, listener) {\n if (!util.isFunction(listener))\n throw TypeError('listener must be a function');\n\n var fired = false;\n\n function g() {\n this.removeListener(type, g);\n\n if (!fired) {\n fired = true;\n listener.apply(this, arguments);\n }\n }\n\n g.listener = listener;\n this.on(type, g);\n\n return this;\n};\n\n// emits a 'removeListener' event iff the listener was removed\nEventEmitter.prototype.removeListener = function(type, listener) {\n var list, position, length, i;\n\n if (!util.isFunction(listener))\n throw TypeError('listener must be a function');\n\n if (!this._events || !this._events[type])\n return this;\n\n list = this._events[type];\n length = list.length;\n position = -1;\n\n if (list === listener ||\n (util.isFunction(list.listener) && list.listener === listener)) {\n delete this._events[type];\n if (this._events.removeListener)\n this.emit('removeListener', type, listener);\n\n } else if (util.isObject(list)) {\n for (i = length; i-- > 0;) {\n if (list[i] === listener ||\n (list[i].listener && list[i].listener === listener)) {\n position = i;\n break;\n }\n }\n\n if (position < 0)\n return this;\n\n if (list.length === 1) {\n list.length = 0;\n delete this._events[type];\n } else {\n list.splice(position, 1);\n }\n\n if (this._events.removeListener)\n this.emit('removeListener', type, listener);\n }\n\n return this;\n};\n\nEventEmitter.prototype.removeAllListeners = function(type) {\n var key, listeners;\n\n if (!this._events)\n return this;\n\n // not listening for removeListener, no need to emit\n if (!this._events.removeListener) {\n if (arguments.length === 0)\n this._events = {};\n else if (this._events[type])\n delete this._events[type];\n return this;\n }\n\n // emit removeListener for all listeners on all events\n if (arguments.length === 0) {\n for (key in this._events) {\n if (key === 'removeListener') continue;\n this.removeAllListeners(key);\n }\n this.removeAllListeners('removeListener');\n this._events = {};\n return this;\n }\n\n listeners = this._events[type];\n\n if (util.isFunction(listeners)) {\n this.removeListener(type, listeners);\n } else if (Array.isArray(listeners)) {\n // LIFO order\n while (listeners.length)\n this.removeListener(type, listeners[listeners.length - 1]);\n }\n delete this._events[type];\n\n return this;\n};\n\nEventEmitter.prototype.listeners = function(type) {\n var ret;\n if (!this._events || !this._events[type])\n ret = [];\n else if (util.isFunction(this._events[type]))\n ret = [this._events[type]];\n else\n ret = this._events[type].slice();\n return ret;\n};\n\nEventEmitter.listenerCount = function(emitter, type) {\n var ret;\n if (!emitter._events || !emitter._events[type])\n ret = 0;\n else if (util.isFunction(emitter._events[type]))\n ret = 1;\n else\n ret = emitter._events[type].length;\n return ret;\n};\n","import EventEmitter from 'node-event-emitter';\n\n/**\n* @module EventEmitter\n* @private\n*/\nexport default {\n\n /**\n * Function used to add event handling to objects passed in.\n * @param {Object} obj Object instance that will get event handling.\n */\n mixin: (obj) => {\n Object.keys(EventEmitter.prototype).forEach((key) => {\n obj[key] = EventEmitter.prototype[key];\n });\n EventEmitter.init(obj);\n },\n};\n","/**\n * Error containing a custom error code.\n * @extends Error\n * @property {number} code The error code as defined by `errorCodes`\n * @property {boolean} enigmaError=true\n */\nclass EnigmaError extends Error {\n constructor(name, code) {\n super(name);\n this.code = code;\n this.enigmaError = true;\n }\n}\n\n/**\n * Create an enigmaError\n * @private\n * @param {Number} code A proper error code from `errorCodes`\n * @param {String} name A message/name of the enigmaError.\n * @returns {EnigmaError}\n */\nexport default function createEnigmaError(code, name) {\n return new EnigmaError(name, code);\n}\n","/**\n * This is a list of error codes that can be thrown from enigma.js API calls.\n * @entry\n * @see EnigmaError\n * @enum\n * @example Handling an enigma.js error\n * const { NOT_CONNECTED } = require('enigma.js/error-codes');\n * try {\n * const layout = await model.getLayout();\n * } catch (err) {\n * if (err.code === NOT_CONNECTED) {\n * console.log('Tried to communicate on a session that is closed');\n * }\n * }\n */\nconst errorCodes = {\n /**\n * You're trying to send data on a socket that's not connected\n * @type {number}\n */\n NOT_CONNECTED: -1,\n /**\n * The object you're trying to fetch does not exist\n * @type {number}\n */\n OBJECT_NOT_FOUND: -2,\n /**\n * Unexpected RPC response, expected array of patches\n * @type {number}\n */\n EXPECTED_ARRAY_OF_PATCHES: -3,\n /**\n * Patchee is not an object we can patch\n * @type {number}\n */\n PATCH_HAS_NO_PARENT: -4,\n /**\n * This entry is already defined with another key\n * @type {number}\n */\n ENTRY_ALREADY_DEFINED: -5,\n /**\n * You need to supply a configuration\n * @type {number}\n */\n NO_CONFIG_SUPPLIED: -6,\n /**\n * There's no promise object available (polyfill required?)\n * @type {number}\n */\n PROMISE_REQUIRED: -7,\n /**\n * The schema struct type you requested does not exist\n * @type {number}\n */\n SCHEMA_STRUCT_TYPE_NOT_FOUND: -8,\n /**\n * Can't override this function\n * @type {number}\n */\n SCHEMA_MIXIN_CANT_OVERRIDE_FUNCTION: -9,\n /**\n * Extend is not allowed for this mixin\n * @type {number}\n */\n SCHEMA_MIXIN_EXTEND_NOT_ALLOWED: -10,\n /**\n * Session suspended - no interaction allowed\n * @type {number}\n */\n SESSION_SUSPENDED: -11,\n /**\n * onlyIfAttached supplied, but you got SESSION_CREATED\n * @type {number}\n */\n SESSION_NOT_ATTACHED: -12,\n};\n\nexport default errorCodes;\n","import EventEmitter from './event-emitter';\n\nimport createEnigmaError from './error';\nimport errorCodes from './error-codes';\n\nconst RPC_CLOSE_NORMAL = 1000;\nconst RPC_CLOSE_MANUAL_SUSPEND = 4000;\n\nlet cacheId = 0;\n\n/**\n * The QIX Engine session object\n */\nclass Session {\n /**\n * Handle all JSON-RPC notification event, 'notification:*. Or handle a specific JSON-RPC\n * notification event, 'notification:OnConnected'. These events depend on the product you use QIX\n * Engine from.\n * @event Session#notification\n * @type {Object}\n * @example Bind the notification events\n * // bind all notifications to console.log:\n * session.on('notification:*', console.log);\n * // bind a specific notification to console.log:\n * session.on('notification:OnConnected', console.log);\n */\n\n /**\n * Handle websocket messages. Generally used in debugging purposes. `traffic:*` will handle all\n * websocket messages, `traffic:sent` will handle outgoing messages and `traffic:received` will\n * handle incoming messages.\n * @event Session#traffic\n * @type {Object}\n * @example Bind the traffic events\n * // bind both in- and outbound traffic to console.log:\n * session.on('traffic:*', console.log);\n * // bind outbound traffic to console.log:\n * session.on('traffic:sent', console.log);\n * // bind inbound traffic to console.log:\n * session.on('traffic:received', console.log);\n */\n\n constructor(options) {\n const session = this;\n Object.assign(session, options);\n this.Promise = this.config.Promise;\n this.definition = this.config.definition;\n EventEmitter.mixin(session);\n cacheId += 1;\n session.id = cacheId;\n session.rpc.on('socket-error', session.onRpcError.bind(session));\n session.rpc.on('closed', session.onRpcClosed.bind(session));\n session.rpc.on('message', session.onRpcMessage.bind(session));\n session.rpc.on('notification', session.onRpcNotification.bind(session));\n session.rpc.on('traffic', session.onRpcTraffic.bind(session));\n session.on('closed', () => session.onSessionClosed());\n }\n\n /**\n * Event handler for re-triggering error events from RPC.\n * @private\n * @emits socket-error\n * @param {Error} err Webocket error event.\n */\n onRpcError(err) {\n if (this.suspendResume.isSuspended) {\n return;\n }\n this.emit('socket-error', err);\n }\n\n /**\n * Event handler for the RPC close event.\n * @private\n * @emits Session#suspended\n * @emits Session#closed\n * @param {Event} evt WebSocket close event.\n */\n onRpcClosed(evt) {\n /**\n * Handle suspended state. This event is triggered in two cases (listed below). It is useful\n * in scenarios where you for example want to block interaction in your application until you\n * are resumed again. If config.suspendOnClose is true and there was a network disconnect\n * (socked closed) or if you ran session.suspend().\n * @event Session#suspended\n * @type {Object}\n * @param {Object} evt Event object.\n * @param {String} evt.initiator String indication what triggered the suspended state. Possible\n * values network, manual.\n * @example Handling session suspended\n * session.on('suspended', () => {\n * console.log('Session was suspended, retrying...');\n * session.resume();\n * });\n */\n if (this.suspendResume.isSuspended) {\n return;\n }\n if (evt.code === RPC_CLOSE_NORMAL || evt.code === RPC_CLOSE_MANUAL_SUSPEND) {\n return;\n }\n if (this.config.suspendOnClose) {\n const { code, reason } = evt;\n this.suspendResume.suspend().then(() => this.emit('suspended', {\n initiator: 'network',\n code,\n reason,\n }));\n } else {\n this.emit('closed', evt);\n }\n }\n\n /**\n * Event handler for the RPC message event.\n * @private\n * @param {Object} response JSONRPC response.\n */\n onRpcMessage(response) {\n if (this.suspendResume.isSuspended) {\n return;\n }\n if (response.change) {\n response.change.forEach((handle) => this.emitHandleChanged(handle));\n }\n if (response.close) {\n response.close.forEach((handle) => this.emitHandleClosed(handle));\n }\n }\n\n /**\n * Event handler for the RPC notification event.\n * @private\n * @emits Session#notification\n * @param {Object} response The JSONRPC notification.\n */\n onRpcNotification(response) {\n this.emit('notification:*', response.method, response.params);\n this.emit(`notification:${response.method}`, response.params);\n }\n\n /**\n * Event handler for the RPC traffic event.\n * @private\n * @emits Session#traffic\n * @param {String} dir The traffic direction, sent or received.\n * @param {Object} data JSONRPC request/response/WebSocket message.\n * @param {Number} handle The associated handle.\n */\n onRpcTraffic(dir, data, handle) {\n this.emit('traffic:*', dir, data);\n this.emit(`traffic:${dir}`, data);\n const api = this.apis.getApi(handle);\n if (api) {\n api.emit('traffic:*', dir, data);\n api.emit(`traffic:${dir}`, data);\n }\n }\n\n /**\n * Event handler for cleaning up API instances when a session has been closed.\n * @private\n * @emits API#closed\n */\n onSessionClosed() {\n this.apis.getApis().forEach((entry) => {\n entry.api.emit('closed');\n entry.api.removeAllListeners();\n });\n this.apis.clear();\n }\n\n /**\n * Function used to get an API for a backend object.\n * @private\n * @param {Object} args Arguments used to create object API.\n * @param {Number} args.handle Handle of the backend object.\n * @param {String} args.id ID of the backend object.\n * @param {String} args.type QIX type of the backend object. Can for example\n * be \"Doc\" or \"GenericVariable\".\n * @param {String} args.genericType Custom type of the backend object, if defined in qInfo.\n * @returns {Object} Returns the generated and possibly augmented API.\n */\n getObjectApi(args) {\n const {\n handle, id, type, genericType,\n } = args;\n let api = this.apis.getApi(handle);\n if (api) {\n return api;\n }\n const factory = this.definition.generate(type);\n api = factory(this, handle, id, genericType);\n this.apis.add(handle, api);\n return api;\n }\n\n /**\n * Establishes the websocket against the configured URL and returns the Global instance.\n * @emits Session#opened\n * @returns {Promise} Eventually resolved if the connection was successful.\n * @example Opening a sesssion\n * session.open().then(() => {\n * console.log('Session was opened');\n * });\n */\n open() {\n /**\n * Handle opened state. This event is triggered whenever the websocket is connected and\n * ready for communication.\n * @event Session#opened\n * @type {Object}\n * @example Bind the session opened event\n * session.on('opened', () => {\n * console.log('Session was opened');\n * });\n */\n if (!this.globalPromise) {\n const args = {\n handle: -1,\n id: 'Global',\n type: 'Global',\n genericType: 'Global',\n };\n this.globalPromise = this.rpc.open()\n .then(() => this.getObjectApi(args))\n .then((global) => {\n this.emit('opened');\n return global;\n });\n }\n return this.globalPromise;\n }\n\n /**\n * Function used to send data on the RPC socket.\n * @param {Object} request The request to be sent. (data and some meta info)\n * @returns {Object} Returns a promise instance.\n */\n send(request) {\n if (this.suspendResume.isSuspended) {\n return this.Promise.reject(createEnigmaError(errorCodes.SESSION_SUSPENDED, 'Session suspended'));\n }\n request.id = this.rpc.createRequestId();\n const promise = this.intercept.executeRequests(this, this.Promise.resolve(request))\n .then((augmentedRequest) => {\n const data = { ...this.config.protocol, ...augmentedRequest };\n // the outKey value is used by multiple-out interceptor, at some point\n // we need to refactor that implementation and figure out how to transport\n // this value without hijacking the JSONRPC request object:\n delete data.outKey;\n const response = this.rpc.send(data);\n augmentedRequest.retry = () => this.send(request);\n return this.intercept.executeResponses(this, response, augmentedRequest);\n });\n Session.addToPromiseChain(promise, 'requestId', request.id);\n return promise;\n }\n\n /**\n * Suspends the enigma.js session by closing the websocket and rejecting all method calls\n * until is has been resumed again.\n * @emits Session#suspended\n * @param {Number} [code=4000] - The reason code for suspending the connection.\n * @param {String} [reason=\"\"] - The human readable string describing\n * why the connection is suspended.\n * @returns {Promise} Eventually resolved when the websocket has been closed.\n * @example Suspending a session\n * session.suspend().then(() => {\n * console.log('Session was suspended');\n * });\n */\n suspend(code = 4000, reason = '') {\n return this.suspendResume.suspend(code, reason)\n .then(() => this.emit('suspended', { initiator: 'manual', code, reason }));\n }\n\n /**\n * Resumes a previously suspended enigma.js session by re-creating the websocket and,\n * if possible, re-open the document as well as refreshing the internal cashes. If successful,\n * changed events will be triggered on all generated APIs, and on the ones it was unable to\n * restore, the closed event will be triggered.\n * @emits Session#resumed\n * @param {Boolean} onlyIfAttached If true, resume only if the session was re-attached properly.\n * @returns {Promise} Eventually resolved when the websocket (and potentially the\n * previously opened document, and generated APIs) has been restored, rejected when it fails any\n * of those steps, or when onlyIfAttached is true and a new session was created.\n * @example Resuming a session\n * session.resume(true).then(() => {\n * console.log('Session was resumed by re-attaching');\n * });\n */\n resume(onlyIfAttached) {\n /**\n * Handle resumed state. This event is triggered when the session was properly resumed. It is\n * useful in scenarios where you for example can close blocking modal dialogs and allow the user\n * to interact with your application again.\n * @event Session#resumed\n * @type {Object}\n * @example Handling session resumed\n * session.on('resumed', () => {\n * console.log('Session was resumed, we can close that \"reconnecting\" dialog now');\n * });\n */\n return this.suspendResume.resume(onlyIfAttached).then((value) => {\n this.emit('resumed');\n return value;\n });\n }\n\n /**\n * Closes the websocket and cleans up internal caches, also triggers the closed event\n * on all generated APIs. Note that you have to manually invoke this when you want to\n * close a session and config.suspendOnClose is true.\n * @emits Session#closed\n * @param {Number} [code=1000] - The reason code for closing the connection.\n * @param {String} [reason=\"\"] - The human readable string describing why the connection is closed.\n * @returns {Promise} Eventually resolved when the websocket has been closed.\n * @example Closing a session\n * session.close().then(() => {\n * console.log('Session was closed');\n * });\n */\n close(code = 1000, reason = '') {\n /**\n * Handle closed state. This event is triggered when the underlying websocket is closed and\n * config.suspendOnClose is false.\n * @event Session#closed\n * @type {Object}\n * @example Handling session closed\n * session.on('closed', () => {\n * console.log('Session was closed, clean up!');\n * });\n */\n this.globalPromise = undefined;\n return this.rpc.close(code, reason).then((evt) => this.emit('closed', evt));\n }\n\n /**\n * Given a handle, this function will emit the 'changed' event on the\n * corresponding API instance.\n * @private\n * @param {Number} handle The handle of the API instance.\n * @emits API#changed\n */\n emitHandleChanged(handle) {\n const api = this.apis.getApi(handle);\n if (api) {\n api.emit('changed');\n }\n }\n\n /**\n * Given a handle, this function will emit the 'closed' event on the\n * corresponding API instance.\n * @private\n * @param {Number} handle The handle of the API instance.\n * @emits API#closed\n */\n emitHandleClosed(handle) {\n const api = this.apis.getApi(handle);\n if (api) {\n api.emit('closed');\n api.removeAllListeners();\n }\n }\n\n /**\n * Function used to add info on the promise chain.\n * @private\n * @param {Promise} promise The promise to add info on.\n * @param {String} name The property to add info on.\n * @param {Any} value The info to add.\n */\n static addToPromiseChain(promise, name, value) {\n promise[name] = value;\n const { then } = promise;\n promise.then = function patchedThen(...params) {\n const chain = then.apply(this, params);\n Session.addToPromiseChain(chain, name, value);\n return chain;\n };\n }\n}\n\nexport default Session;\n","import createEnigmaError from './error';\nimport errorCodes from './error-codes';\n\n/**\n* Key-value cache\n* @private\n*/\nclass KeyValueCache {\n constructor() {\n this.entries = {};\n }\n\n /**\n * Adds an entry.\n * @private\n * @function KeyValueCache#add\n * @param {String} key The key representing an entry.\n * @param {*} entry The entry to be added.\n */\n add(key, entry) {\n key += '';\n if (typeof this.entries[key] !== 'undefined') {\n throw createEnigmaError(errorCodes.ENTRY_ALREADY_DEFINED, `Entry already defined with key ${key}`);\n }\n this.entries[key] = entry;\n }\n\n /**\n * Sets an entry.\n * @private\n * @function KeyValueCache#set\n * @param {String} key The key representing an entry.\n * @param {*} entry The entry.\n */\n set(key, entry) {\n key += '';\n this.entries[key] = entry;\n }\n\n /**\n * Removes an entry.\n * @private\n * @function KeyValueCache#remove\n * @param {String} key The key representing an entry.\n */\n remove(key) {\n delete this.entries[key];\n }\n\n /**\n * Gets an entry.\n * @private\n * @function KeyValueCache#get\n * @param {String} key The key representing an entry.\n * @returns {*} The entry for the key.\n */\n get(key) {\n return this.entries[key];\n }\n\n /**\n * Gets a list of all entries.\n * @private\n * @function KeyValueCache#getAll\n * @returns {Array} The list of entries including its `key` and `value` properties.\n */\n getAll() {\n return Object.keys(this.entries).map((key) => ({\n key,\n value: this.entries[key],\n }));\n }\n\n /**\n * Gets a key for an entry.\n * @private\n * @function KeyValueCache#getKey\n * @param {*} entry The entry to locate the key for.\n * @returns {String} The key representing an entry.\n */\n getKey(entry) {\n return Object.keys(this.entries).filter((key) => this.entries[key] === entry)[0];\n }\n\n /**\n * Clears the cache of all entries.\n * @private\n * @function KeyValueCache#clear\n */\n clear() {\n this.entries = {};\n }\n}\n\nexport default KeyValueCache;\n","import KeyValueCache from './key-value-cache';\nimport Events from './event-emitter';\n\nimport createEnigmaError from './error';\nimport errorCodes from './error-codes';\n\nconst { hasOwnProperty } = Object.prototype;\n\n/**\n* Returns the camelCase counterpart of a symbol.\n* @private\n* @param {String} symbol The symbol.\n* @return the camelCase counterpart.\n*/\nfunction toCamelCase(symbol) {\n return symbol.substring(0, 1).toLowerCase() + symbol.substring(1);\n}\n\n/**\n * A facade function that allows parameters to be passed either by name\n * (through an object), or by position (through an array).\n * @private\n * @param {Function} base The function that is being overriden. Will be\n * called with parameters in array-form.\n * @param {Object} defaults Parameter list and it's default values.\n * @param {*} params The parameters.\n */\nfunction namedParamFacade(base, defaults, ...params) {\n if (params.length === 1 && typeof params[0] === 'object' && !Array.isArray(params[0])) {\n const valid = Object.keys(params[0]).every((key) => hasOwnProperty.call(defaults, key));\n if (valid) {\n params = Object.keys(defaults).map((key) => params[0][key] || defaults[key]);\n }\n }\n return base.apply(this, params);\n}\n\n/**\n* Qix schema definition.\n* @private\n*/\nclass Schema {\n /**\n * Create a new schema instance.\n * @private\n * @param {Configuration} config The configuration for QIX.\n */\n constructor(config) {\n this.config = config;\n this.Promise = config.Promise;\n this.schema = config.schema;\n this.mixins = new KeyValueCache();\n this.types = new KeyValueCache();\n }\n\n registerMixin({\n types, type, extend, override, init,\n }) {\n if (!Array.isArray(types)) {\n types = [types];\n }\n // to support a single type\n if (type) {\n types.push(type);\n }\n const cached = { extend, override, init };\n types.forEach((typeKey) => {\n const entryList = this.mixins.get(typeKey);\n if (entryList) {\n entryList.push(cached);\n } else {\n this.mixins.add(typeKey, [cached]);\n }\n });\n }\n\n /**\n * Function used to generate a type definition.\n * @private\n * @param {String} type The type.\n * @returns {{create: Function, def: Object}} Returns an object with a definition\n * of the type and a create factory.\n */\n generate(type) {\n const entry = this.types.get(type);\n if (entry) {\n return entry;\n }\n if (!this.schema.structs[type]) {\n throw createEnigmaError(errorCodes.SCHEMA_STRUCT_TYPE_NOT_FOUND, `${type} not found`);\n }\n const factory = this.generateApi(type, this.schema.structs[type]);\n this.types.add(type, factory);\n return factory;\n }\n\n /**\n * Function used to generate an API definition for a given type.\n * @private\n * @param {String} type The type to generate.\n * @param {Object} schema The schema describing the type.\n * @returns {{create: (function(session:Object, handle:Number, id:String,\n * customKey:String)), def: Object}} Returns the API definition.\n */\n generateApi(type, schema) {\n const api = Object.create({});\n\n this.generateDefaultApi(api, schema); // Generate default\n this.mixinType(type, api); // Mixin default type\n this.mixinNamedParamFacade(api, schema); // Mixin named parameter support\n\n return function create(session, handle, id, customKey) {\n const instance = Object.create(api);\n\n Events.mixin(instance); // Always mixin event-emitter per instance\n\n Object.defineProperties(instance, {\n session: {\n enumerable: true,\n value: session,\n },\n handle: {\n enumerable: true,\n value: handle,\n writable: true,\n },\n id: {\n enumerable: true,\n value: id,\n },\n type: {\n enumerable: true,\n value: type,\n },\n genericType: {\n enumerable: true,\n value: customKey,\n },\n });\n\n let mixinList = this.mixins.get(type) || [];\n if (customKey !== type) {\n this.mixinType(customKey, instance); // Mixin custom types\n mixinList = mixinList.concat(this.mixins.get(customKey) || []);\n }\n mixinList.forEach((mixin) => {\n if (typeof mixin.init === 'function') {\n mixin.init({ config: this.config, api: instance });\n }\n });\n\n return instance;\n }.bind(this);\n }\n\n /**\n * Function used to generate the methods with the right handlers to the object\n * API that is being generated.\n * @private\n * @param {Object} api The object API that is currently being generated.\n * @param {Object} schema The API definition.\n */\n generateDefaultApi(api, schema) {\n Object.keys(schema).forEach((method) => {\n const out = schema[method].Out;\n const outKey = out.length === 1 ? out[0].Name : -1;\n const fnName = toCamelCase(method);\n\n api[fnName] = function generatedMethod(...params) {\n return this.session.send({\n handle: this.handle,\n method,\n params,\n outKey,\n });\n };\n });\n }\n\n /**\n * Function used to add mixin methods to a specified API.\n * @private\n * @param {String} type Used to specify which mixin should be woven in.\n * @param {Object} api The object that will be woven.\n */\n mixinType(type, api) {\n const mixinList = this.mixins.get(type);\n if (mixinList) {\n mixinList.forEach(({ extend = {}, override = {} }) => {\n Object.keys(override).forEach((key) => {\n if (typeof api[key] === 'function' && typeof override[key] === 'function') {\n const baseFn = api[key];\n api[key] = function wrappedFn(...args) {\n return override[key].apply(this, [baseFn.bind(this), ...args]);\n };\n } else {\n throw createEnigmaError(errorCodes.SCHEMA_MIXIN_CANT_OVERRIDE_FUNCTION, `No function to override. Type: ${type} function: ${key}`);\n }\n });\n Object.keys(extend).forEach((key) => {\n // handle overrides\n if (typeof api[key] === 'function' && typeof extend[key] === 'function') {\n throw createEnigmaError(errorCodes.SCHEMA_MIXIN_EXTEND_NOT_ALLOWED, `Extend is not allowed for this mixin. Type: ${type} function: ${key}`);\n } else {\n api[key] = extend[key];\n }\n });\n });\n }\n }\n\n /**\n * Function used to mixin the named parameter facade.\n * @private\n * @param {Object} api The object API that is currently being generated.\n * @param {Object} schema The API definition.\n */\n mixinNamedParamFacade(api, schema) {\n Object.keys(schema).forEach((key) => {\n const fnName = toCamelCase(key);\n const base = api[fnName];\n const defaults = schema[key].In.reduce((result, item) => {\n result[item.Name] = item.DefaultValue;\n return result;\n }, {});\n\n api[fnName] = function namedParamWrapper(...params) {\n return namedParamFacade.apply(this, [base, defaults, ...params]);\n };\n });\n }\n}\n\nexport default Schema;\n","import Events from './event-emitter';\n\n/**\n * Helper class for handling RPC calls\n * @private\n */\nclass RPCResolver {\n constructor(id, handle, resolve, reject) {\n Events.mixin(this);\n this.id = id;\n this.handle = handle;\n this.resolve = resolve;\n this.reject = reject;\n }\n\n resolveWith(data) {\n this.resolve(data);\n this.emit('resolved', this.id);\n }\n\n rejectWith(err) {\n this.reject(err);\n this.emit('rejected', this.id);\n }\n}\n\nexport default RPCResolver;\n","import Events from './event-emitter';\nimport RPCResolver from './rpc-resolver';\n\nimport createEnigmaError from './error';\nimport errorCodes from './error-codes';\n\n/**\n* This class handles remote procedure calls on a web socket.\n* @private\n*/\nclass RPC {\n /**\n * Create a new RPC instance.\n * @private\n * @param {Object} options The configuration options for this class.\n * @param {Function} options.Promise The promise constructor to use.\n * @param {String} options.url The complete websocket URL used to connect.\n * @param {Function} options.createSocket The function callback to create a WebSocket.\n */\n constructor(options) {\n Object.assign(this, options);\n Events.mixin(this);\n this.resolvers = {};\n this.requestId = 0;\n this.openedPromise = undefined;\n }\n\n /**\n * Opens a connection to the configured endpoint.\n * @private\n * @param {Boolean} force - ignores all previous and outstanding open calls if set to true.\n * @returns {Object} A promise instance.\n */\n open(force = false) {\n if (!force && this.openedPromise) {\n return this.openedPromise;\n }\n\n try {\n this.socket = this.createSocket(this.url);\n } catch (err) {\n return this.Promise.reject(err);\n }\n\n this.socket.onopen = this.onOpen.bind(this);\n this.socket.onclose = this.onClose.bind(this);\n this.socket.onerror = this.onError.bind(this);\n this.socket.onmessage = this.onMessage.bind(this);\n this.openedPromise = new this.Promise((resolve, reject) => this.registerResolver('opened', null, resolve, reject));\n this.closedPromise = new this.Promise((resolve, reject) => this.registerResolver('closed', null, resolve, reject));\n return this.openedPromise;\n }\n\n /**\n * Resolves the open promise when a connection is successfully established.\n * @private\n */\n onOpen() {\n this.resolvers.opened.resolveWith(() => this.closedPromise);\n }\n\n /**\n * Resolves the close promise when a connection is closed.\n * @private\n * @param {Object} event - The event describing close.\n */\n onClose(event) {\n this.emit('closed', event);\n if (this.resolvers && this.resolvers.closed) {\n this.resolvers.closed.resolveWith(event);\n }\n this.rejectAllOutstandingResolvers(createEnigmaError(errorCodes.NOT_CONNECTED, 'Socket closed'));\n }\n\n /**\n * Closes a connection.\n * @private\n * @param {Number} [code=1000] - The reason code for closing the connection.\n * @param {String} [reason=\"\"] - The human readable string describing why the connection is closed.\n * @returns {Object} Returns a promise instance.\n */\n close(code = 1000, reason = '') {\n if (this.socket) {\n this.socket.close(code, reason);\n this.socket = null;\n }\n return this.closedPromise;\n }\n\n /**\n * Emits an error event and rejects the open promise if an error is raised on the connection.\n * @private\n * @param {Object} event - The event describing the error.\n */\n onError(event) {\n if (this.resolvers.opened) {\n this.resolvers.opened.rejectWith(event);\n } else {\n // only emit errors after the initial open promise has been resolved,\n // this makes it possible to catch early websocket errors as well\n // as run-time ones:\n this.emit('socket-error', event);\n }\n this.rejectAllOutstandingResolvers(createEnigmaError(errorCodes.NOT_CONNECTED, 'Socket error'));\n }\n\n /**\n * Parses the onMessage event on the connection and resolve the promise for the request.\n * @private\n * @param {Object} event - The event describing the message.\n */\n onMessage(event) {\n const data = JSON.parse(event.data);\n const resolver = this.resolvers[data.id] || {};\n this.emit('traffic', 'received', data, resolver.handle);\n if (typeof data.id !== 'undefined') {\n this.emit('message', data);\n this.resolvers[data.id].resolveWith(data);\n } else {\n this.emit(data.params ? 'notification' : 'message', data);\n }\n }\n\n /**\n * Rejects all outstanding resolvers.\n * @private\n * @param {Object} reason - The reject reason.\n */\n rejectAllOutstandingResolvers(reason) {\n Object.keys(this.resolvers).forEach((id) => {\n if (id === 'opened' || id === 'closed') {\n return; // \"opened\" and \"closed\" should not be handled here\n }\n const resolver = this.resolvers[id];\n resolver.rejectWith(reason);\n });\n }\n\n /**\n * Unregisters a resolver.\n * @private\n * @param {Number|String} id - The ID to unregister the resolver with.\n */\n unregisterResolver(id) {\n const resolver = this.resolvers[id];\n resolver.removeAllListeners();\n delete this.resolvers[id];\n }\n\n /**\n * Registers a resolver.\n * @private\n * @param {Number|String} id - The ID to register the resolver with.\n * @param {Number} handle - The associated handle.\n * @returns {Function} The promise executor function.\n */\n registerResolver(id, handle, resolve, reject) {\n const resolver = new RPCResolver(id, handle, resolve, reject);\n this.resolvers[id] = resolver;\n resolver.on('resolved', (resolvedId) => this.unregisterResolver(resolvedId));\n resolver.on('rejected', (rejectedId) => this.unregisterResolver(rejectedId));\n }\n\n /**\n * Sends data on the socket.\n * @private\n * @param {Object} data - The data to send.\n * @returns {Object} A promise instance.\n */\n send(data) {\n if (!this.socket || this.socket.readyState !== this.socket.OPEN) {\n const error = createEnigmaError(errorCodes.NOT_CONNECTED, 'Not connected');\n return this.Promise.reject(error);\n }\n if (!data.id) {\n data.id = this.createRequestId();\n }\n data.jsonrpc = '2.0';\n return new this.Promise((resolve, reject) => {\n this.socket.send(JSON.stringify(data));\n this.emit('traffic', 'sent', data, data.handle);\n return this.registerResolver(data.id, data.handle, resolve, reject);\n });\n }\n\n createRequestId() {\n this.requestId += 1;\n return this.requestId;\n }\n}\n\nexport default RPC;\n","import createEnigmaError from './error';\nimport errorCodes from './error-codes';\n\nconst ON_ATTACHED_TIMEOUT_MS = 5000;\nconst RPC_CLOSE_MANUAL_SUSPEND = 4000;\n\nclass SuspendResume {\n /**\n * Creates a new SuspendResume instance.\n * @private\n * @param {Object} options The configuration option for this class.\n * @param {Promise} options.Promise The promise constructor to use.\n * @param {RPC} options.rpc The RPC instance to use when communicating towards Engine.\n * @param {ApiCache} options.apis The ApiCache instance to use.\n */\n constructor(options) {\n Object.assign(this, options);\n this.isSuspended = false;\n this.rpc.on('traffic', (dir, data) => {\n if (dir === 'sent' && data.method === 'OpenDoc') {\n this.openDocParams = data.params;\n }\n });\n }\n\n /**\n * Function used to restore the rpc connection.\n * @private\n * @param {Boolean} onlyIfAttached - if true, the returned promise will resolve\n * only if the session can be re-attached.\n * @returns {Object} Returns a promise instance.\n */\n restoreRpcConnection(onlyIfAttached) {\n return this.reopen(ON_ATTACHED_TIMEOUT_MS).then((sessionState) => {\n if (sessionState === 'SESSION_CREATED' && onlyIfAttached) {\n return this.Promise.reject(createEnigmaError(errorCodes.SESSION_NOT_ATTACHED, 'Not attached'));\n }\n return this.Promise.resolve();\n });\n }\n\n /**\n * Function used to restore the global API.\n * @private\n * @param {Object} changed - A list where the restored APIs will be added.\n * @returns {Object} Returns a promise instance.\n */\n restoreGlobal(changed) {\n const global = this.apis.getApisByType('Global').pop();\n changed.push(global.api);\n return this.Promise.resolve();\n }\n\n /**\n * Function used to restore the doc API.\n * @private\n * @param {String} sessionState - The state of the session, attached or created.\n * @param {Array} closed - A list where the closed of APIs APIs will be added.\n * @param {Object} changed - A list where the restored APIs will be added.\n * @returns {Object} Returns a promise instance.\n */\n restoreDoc(closed, changed) {\n const doc = this.apis.getApisByType('Doc').pop();\n\n if (!doc) {\n return this.Promise.resolve();\n }\n\n return this.rpc.send({\n method: 'GetActiveDoc',\n handle: -1,\n params: [],\n }).then((response) => {\n if (response.error && this.openDocParams) {\n return this.rpc.send({\n method: 'OpenDoc',\n handle: -1,\n params: this.openDocParams,\n });\n }\n return response;\n }).then((response) => {\n if (response.error) {\n closed.push(doc.api);\n return this.Promise.resolve();\n }\n const handle = response.result.qReturn.qHandle;\n doc.api.handle = handle;\n changed.push(doc.api);\n return this.Promise.resolve(doc.api);\n });\n }\n\n /**\n * Function used to restore the APIs on the doc.\n * @private\n * @param {Object} doc - The doc API on which the APIs we want to restore exist.\n * @param {Array} closed - A list where the closed of APIs APIs will be added.\n * @param {Object} changed - A list where the restored APIs will be added.\n * @returns {Object} Returns a promise instance.\n */\n restoreDocObjects(doc, closed, changed) {\n const tasks = [];\n const apis = this.apis.getApis()\n .map((entry) => entry.api)\n .filter((api) => api.type !== 'Global' && api.type !== 'Doc');\n\n if (!doc) {\n apis.forEach((api) => closed.push(api));\n return this.Promise.resolve();\n }\n\n apis.forEach((api) => {\n const method = SuspendResume.buildGetMethodName(api.type);\n\n if (!method) {\n closed.push(api);\n } else {\n const request = this.rpc.send({\n method,\n handle: doc.handle,\n params: [api.id],\n }).then((response) => {\n if (response.error || !response.result.qReturn.qHandle) {\n closed.push(api);\n } else {\n api.handle = response.result.qReturn.qHandle;\n changed.push(api);\n }\n });\n tasks.push(request);\n }\n });\n return this.Promise.all(tasks);\n }\n\n /**\n * Set the instance as suspended.\n * @private\n * @param {Number} [code=4000] - The reason code for suspending the connection.\n * @param {String} [reason=\"\"] - The human readable string describing\n * why the connection is suspended.\n */\n suspend(code = RPC_CLOSE_MANUAL_SUSPEND, reason = '') {\n this.isSuspended = true;\n return this.rpc.close(code, reason);\n }\n\n /**\n * Resumes a previously suspended RPC connection, and refreshes the API cache.\n * APIs unabled to be restored has their 'closed'\n * event triggered, otherwise 'changed'.\n * @private\n * @emits API#changed\n * @emits APIfunction@#closed\n * @param {Boolean} onlyIfAttached if true, resume only if the session was re-attached.\n * @returns {Promise} Eventually resolved if the RPC connection was successfully resumed,\n * otherwise rejected.\n */\n resume(onlyIfAttached) {\n const changed = [];\n const closed = [];\n\n return this.restoreRpcConnection(onlyIfAttached)\n .then(() => this.restoreGlobal(changed))\n .then(() => this.restoreDoc(closed, changed))\n .then((doc) => this.restoreDocObjects(doc, closed, changed))\n .then(() => {\n this.isSuspended = false;\n this.apis.clear();\n closed.forEach((api) => {\n api.emit('closed');\n api.removeAllListeners();\n });\n changed.forEach((api) => {\n this.apis.add(api.handle, api);\n if (api.type !== 'Global') {\n api.emit('changed');\n }\n });\n })\n .catch((err) => this.rpc.close().then(() => this.Promise.reject(err)));\n }\n\n /**\n * Reopens the connection and waits for the OnConnected notification.\n * @private\n * @param {Number} timeout - The time to wait for the OnConnected notification.\n * @returns {Object} A promise containing the session state (SESSION_CREATED or SESSION_ATTACHED).\n */\n reopen(timeout) {\n let timer;\n let notificationResolve;\n let notificationReceived = false;\n const notificationPromise = new this.Promise((resolve) => { notificationResolve = resolve; });\n\n const waitForNotification = () => {\n if (!notificationReceived) {\n timer = setTimeout(() => notificationResolve('SESSION_CREATED'), timeout);\n }\n return notificationPromise;\n };\n\n const onNotification = (data) => {\n if (data.method !== 'OnConnected') return;\n clearTimeout(timer);\n notificationResolve(data.params.qSessionState);\n notificationReceived = true;\n };\n\n this.rpc.on('notification', onNotification);\n\n return this.rpc.open(true)\n .then(waitForNotification)\n .then((state) => {\n this.rpc.removeListener('notification', onNotification);\n return state;\n })\n .catch((err) => {\n this.rpc.removeListener('notification', onNotification);\n return this.Promise.reject(err);\n });\n }\n\n /**\n * Function used to build the get method names for Doc APIs.\n * @private\n * @param {String} type - The API type.\n * @returns {String} Returns the get method name, or undefined if the type cannot be restored.\n */\n static buildGetMethodName(type) {\n if (type === 'Field' || type === 'Variable') {\n return null;\n }\n if (type === 'GenericVariable') {\n return 'GetVariableById';\n }\n return type.replace('Generic', 'Get');\n }\n}\n\nexport default SuspendResume;\n","const SUCCESS_KEY = 'qSuccess';\n\nexport default function deltaRequestInterceptor(session, request) {\n const delta = session.config.protocol.delta\n && request.outKey !== -1\n && request.outKey !== SUCCESS_KEY;\n if (delta) {\n request.delta = delta;\n }\n return request;\n}\n","import createEnigmaError from '../error';\nimport errorCodes from '../error-codes';\n\n/**\n* Response interceptor for generating APIs. Handles the quirks of engine not\n* returning an error when an object is missing.\n* @private\n* @param {Session} session - The session the intercept is being executed on.\n* @param {Object} request - The JSON-RPC request.\n* @param {Object} response - The response.\n* @returns {Object} - Returns the generated API\n*/\nexport default function apiResponseInterceptor(session, request, response) {\n if (response.qHandle && response.qType) {\n return session.getObjectApi({\n handle: response.qHandle,\n type: response.qType,\n id: response.qGenericId,\n genericType: response.qGenericType,\n });\n }\n if (response.qHandle === null && response.qType === null) {\n const error = createEnigmaError(errorCodes.OBJECT_NOT_FOUND, 'Object not found');\n return session.config.Promise.reject(error);\n }\n return response;\n}\n","'use strict';\n\nvar hasOwn = Object.prototype.hasOwnProperty;\nvar toStr = Object.prototype.toString;\nvar defineProperty = Object.defineProperty;\nvar gOPD = Object.getOwnPropertyDescriptor;\n\nvar isArray = function isArray(arr) {\n\tif (typeof Array.isArray === 'function') {\n\t\treturn Array.isArray(arr);\n\t}\n\n\treturn toStr.call(arr) === '[object Array]';\n};\n\nvar isPlainObject = function isPlainObject(obj) {\n\tif (!obj || toStr.call(obj) !== '[object Object]') {\n\t\treturn false;\n\t}\n\n\tvar hasOwnConstructor = hasOwn.call(obj, 'constructor');\n\tvar hasIsPrototypeOf = obj.constructor && obj.constructor.prototype && hasOwn.call(obj.constructor.prototype, 'isPrototypeOf');\n\t// Not own constructor property must be Object\n\tif (obj.constructor && !hasOwnConstructor && !hasIsPrototypeOf) {\n\t\treturn false;\n\t}\n\n\t// Own properties are enumerated firstly, so to speed up,\n\t// if last one is own, then all properties are own.\n\tvar key;\n\tfor (key in obj) { /**/ }\n\n\treturn typeof key === 'undefined' || hasOwn.call(obj, key);\n};\n\n// If name is '__proto__', and Object.defineProperty is available, define __proto__ as an own property on target\nvar setProperty = function setProperty(target, options) {\n\tif (defineProperty && options.name === '__proto__') {\n\t\tdefineProperty(target, options.name, {\n\t\t\tenumerable: true,\n\t\t\tconfigurable: true,\n\t\t\tvalue: options.newValue,\n\t\t\twritable: true\n\t\t});\n\t} else {\n\t\ttarget[options.name] = options.newValue;\n\t}\n};\n\n// Return undefined instead of __proto__ if '__proto__' is not an own property\nvar getProperty = function getProperty(obj, name) {\n\tif (name === '__proto__') {\n\t\tif (!hasOwn.call(obj, name)) {\n\t\t\treturn void 0;\n\t\t} else if (gOPD) {\n\t\t\t// In early versions of node, obj['__proto__'] is buggy when obj has\n\t\t\t// __proto__ as an own property. Object.getOwnPropertyDescriptor() works.\n\t\t\treturn gOPD(obj, name).value;\n\t\t}\n\t}\n\n\treturn obj[name];\n};\n\nmodule.exports = function extend() {\n\tvar options, name, src, copy, copyIsArray, clone;\n\tvar target = arguments[0];\n\tvar i = 1;\n\tvar length = arguments.length;\n\tvar deep = false;\n\n\t// Handle a deep copy situation\n\tif (typeof target === 'boolean') {\n\t\tdeep = target;\n\t\ttarget = arguments[1] || {};\n\t\t// skip the boolean and the target\n\t\ti = 2;\n\t}\n\tif (target == null || (typeof target !== 'object' && typeof target !== 'function')) {\n\t\ttarget = {};\n\t}\n\n\tfor (; i < length; ++i) {\n\t\toptions = arguments[i];\n\t\t// Only deal with non-null/undefined values\n\t\tif (options != null) {\n\t\t\t// Extend the base object\n\t\t\tfor (name in options) {\n\t\t\t\tsrc = getProperty(target, name);\n\t\t\t\tcopy = getProperty(options, name);\n\n\t\t\t\t// Prevent never-ending loop\n\t\t\t\tif (target !== copy) {\n\t\t\t\t\t// Recurse if we're merging plain objects or arrays\n\t\t\t\t\tif (deep && copy && (isPlainObject(copy) || (copyIsArray = isArray(copy)))) {\n\t\t\t\t\t\tif (copyIsArray) {\n\t\t\t\t\t\t\tcopyIsArray = false;\n\t\t\t\t\t\t\tclone = src && isArray(src) ? src : [];\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tclone = src && isPlainObject(src) ? src : {};\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t// Never move original objects, clone them\n\t\t\t\t\t\tsetProperty(target, { name: name, newValue: extend(deep, clone, copy) });\n\n\t\t\t\t\t// Don't bring in undefined values\n\t\t\t\t\t} else if (typeof copy !== 'undefined') {\n\t\t\t\t\t\tsetProperty(target, { name: name, newValue: copy });\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\t// Return the modified object\n\treturn target;\n};\n","import originalExtend from 'extend';\n\nimport createEnigmaError from './error';\nimport errorCodes from './error-codes';\n\nconst extend = originalExtend.bind(null, true);\nconst JSONPatch = {};\nconst { isArray } = Array;\nfunction isObject(v) { return v != null && !Array.isArray(v) && typeof v === 'object'; }\nfunction isUndef(v) { return typeof v === 'undefined'; }\nfunction isFunction(v) { return typeof v === 'function'; }\n\n/**\n* Generate an exact duplicate (with no references) of a specific value.\n*\n* @private\n* @param {Object} The value to duplicate\n* @returns {Object} a unique, duplicated value\n*/\nfunction generateValue(val) {\n if (val) {\n return extend({}, { val }).val;\n }\n return val;\n}\n\n/**\n* An additional type checker used to determine if the property is of internal\n* use or not a type that can be translated into JSON (like functions).\n*\n* @private\n* @param {Object} obj The object which has the property to check\n* @param {String} The property name to check\n* @returns {Boolean} Whether the property is deemed special or not\n*/\nfunction isSpecialProperty(obj, key) {\n return isFunction(obj[key])\n || key.substring(0, 2) === '$$'\n || key.substring(0, 1) === '_';\n}\n\n/**\n* Finds the parent object from a JSON-Pointer (\"/foo/bar/baz\" = \"bar\" is \"baz\" parent),\n* also creates the object structure needed.\n*\n* @private\n* @param {Object} data The root object to traverse through\n* @param {String} The JSON-Pointer string to use when traversing\n* @returns {Object} The parent object\n*/\nfunction getParent(data, str) {\n const seperator = '/';\n const parts = str.substring(1).split(seperator).slice(0, -1);\n let numPart;\n\n parts.forEach((part, i) => {\n if (i === parts.length) {\n return;\n }\n numPart = +part;\n const newPart = !isNaN(numPart) ? [] : {};\n data[numPart || part] = isUndef(data[numPart || part])\n ? newPart\n : data[part];\n data = data[numPart || part];\n });\n\n return data;\n}\n\n/**\n* Cleans an object of all its properties, unless they're deemed special or\n* cannot be removed by configuration.\n*\n* @private\n* @param {Object} obj The object to clean\n*/\nfunction emptyObject(obj) {\n Object.keys(obj).forEach((key) => {\n const config = Object.getOwnPropertyDescriptor(obj, key);\n\n if (config.configurable && !isSpecialProperty(obj, key)) {\n delete obj[key];\n }\n });\n}\n\n/**\n* Compare an object with another, could be object, array, number, string, bool.\n* @private\n* @param {Object} a The first object to compare\n* @param {Object} a The second object to compare\n* @returns {Boolean} Whether the objects are identical\n*/\nfunction compare(a, b) {\n let isIdentical = true;\n\n if (isObject(a) && isObject(b)) {\n if (Object.keys(a).length !== Object.keys(b).length) {\n return false;\n }\n Object.keys(a).forEach((key) => {\n if (!compare(a[key], b[key])) {\n isIdentical = false;\n }\n });\n return isIdentical;\n }\n if (isArray(a) && isArray(b)) {\n if (a.length !== b.length) {\n return false;\n }\n for (let i = 0, l = a.length; i < l; i += 1) {\n if (!compare(a[i], b[i])) {\n return false;\n }\n }\n return true;\n }\n return a === b;\n}\n\n/**\n* Generates patches by comparing two arrays.\n*\n* @private\n* @param {Array} oldA The old (original) array, which will be patched\n* @param {Array} newA The new array, which will be used to compare against\n* @returns {Array} An array of patches (if any)\n*/\nfunction patchArray(original, newA, basePath) {\n let patches = [];\n const oldA = original.slice();\n let tmpIdx = -1;\n\n function findIndex(a, id, idx) {\n if (a[idx] && isUndef(a[idx].qInfo)) {\n return null;\n }\n if (a[idx] && a[idx].qInfo.qId === id) {\n // shortcut if identical\n return idx;\n }\n for (let ii = 0, ll = a.length; ii < ll; ii += 1) {\n if (a[ii] && a[ii].qInfo.qId === id) {\n return ii;\n }\n }\n return -1;\n }\n\n if (compare(newA, oldA)) {\n // array is unchanged\n return patches;\n }\n\n if (!isUndef(newA[0]) && isUndef(newA[0].qInfo)) {\n // we cannot create patches without unique identifiers, replace array...\n patches.push({\n op: 'replace',\n path: basePath,\n value: newA,\n });\n return patches;\n }\n\n for (let i = oldA.length - 1; i >= 0; i -= 1) {\n tmpIdx = findIndex(newA, oldA[i].qInfo && oldA[i].qInfo.qId, i);\n if (tmpIdx === -1) {\n patches.push({\n op: 'remove',\n path: `${basePath}/${i}`,\n });\n oldA.splice(i, 1);\n } else {\n patches = patches.concat(JSONPatch.generate(oldA[i], newA[tmpIdx], `${basePath}/${i}`));\n }\n }\n\n for (let i = 0, l = newA.length; i < l; i += 1) {\n tmpIdx = findIndex(oldA, newA[i].qInfo && newA[i].qInfo.qId);\n if (tmpIdx === -1) {\n patches.push({\n op: 'add',\n path: `${basePath}/${i}`,\n value: newA[i],\n });\n oldA.splice(i, 0, newA[i]);\n } else if (tmpIdx !== i) {\n patches.push({\n op: 'move',\n path: `${basePath}/${i}`,\n from: `${basePath}/${tmpIdx}`,\n });\n oldA.splice(i, 0, oldA.splice(tmpIdx, 1)[0]);\n }\n }\n return patches;\n}\n\n/**\n* Generate an array of JSON-Patch:es following the JSON-Patch Specification Draft.\n*\n* See [specification draft](http://tools.ietf.org/html/draft-ietf-appsawg-json-patch-10)\n*\n* Does NOT currently generate patches for arrays (will replace them)\n* @private\n* @param {Object} original The object to patch to\n* @param {Object} newData The object to patch from\n* @param {String} [basePath] The base path to use when generating the paths for\n* the patches (normally not used)\n* @returns {Array} An array of patches\n*/\nJSONPatch.generate = function generate(original, newData, basePath) {\n basePath = basePath || '';\n let patches = [];\n\n Object.keys(newData).forEach((key) => {\n const val = generateValue(newData[key]);\n const oldVal = original[key];\n const tmpPath = `${basePath}/${key}`;\n\n if (compare(val, oldVal) || isSpecialProperty(newData, key)) {\n return;\n }\n if (isUndef(oldVal)) {\n // property does not previously exist\n patches.push({\n op: 'add',\n path: tmpPath,\n value: val,\n });\n } else if (isObject(val) && isObject(oldVal)) {\n // we need to generate sub-patches for this, since it already exist\n patches = patches.concat(JSONPatch.generate(oldVal, val, tmpPath));\n } else if (isArray(val) && isArray(oldVal)) {\n patches = patches.concat(patchArray(oldVal, val, tmpPath));\n } else {\n // it's a simple property (bool, string, number)\n patches.push({\n op: 'replace',\n path: `${basePath}/${key}`,\n value: val,\n });\n }\n });\n\n Object.keys(original).forEach((key) => {\n if (isUndef(newData[key]) && !isSpecialProperty(original, key)) {\n // this property does not exist anymore\n patches.push({\n op: 'remove',\n path: `${basePath}/${key}`,\n });\n }\n });\n\n return patches;\n};\n\n/**\n* Apply a list of patches to an object.\n* @private\n* @param {Object} original The object to patch\n* @param {Array} patches The list of patches to apply\n*/\nJSONPatch.apply = function apply(original, patches) {\n patches.forEach((patch) => {\n let parent = getParent(original, patch.path);\n let key = patch.path.split('/').splice(-1)[0];\n let target = key && isNaN(+key) ? parent[key] : parent[+key] || parent;\n const from = patch.from ? patch.from.split('/').splice(-1)[0] : null;\n\n if (patch.path === '/') {\n parent = null;\n target = original;\n }\n\n if (patch.op === 'add' || patch.op === 'replace') {\n if (isArray(parent)) {\n // trust indexes from patches, so don't replace the index if it's an add\n if (key === '-') {\n key = parent.length;\n }\n parent.splice(+key, patch.op === 'add' ? 0 : 1, patch.value);\n } else if (isArray(target) && isArray(patch.value)) {\n // keep array reference if possible...\n target.length = 0;\n\n const chunkSize = 1000;\n for (let i = 0; i < patch.value.length; i += chunkSize) {\n const chunk = patch.value.slice(i, i + chunkSize);\n target.push(...chunk);\n }\n } else if (isObject(target) && isObject(patch.value)) {\n // keep object reference if possible...\n emptyObject(target);\n extend(target, patch.value);\n } else if (!parent) {\n throw createEnigmaError(errorCodes.PATCH_HAS_NO_PARENT, 'Patchee is not an object we can patch');\n } else {\n // simple value\n parent[key] = patch.value;\n }\n } else if (patch.op === 'move') {\n const oldParent = getParent(original, patch.from);\n if (isArray(parent)) {\n parent.splice(+key, 0, oldParent.splice(+from, 1)[0]);\n } else {\n parent[key] = oldParent[from];\n delete oldParent[from];\n }\n } else if (patch.op === 'remove') {\n if (isArray(parent)) {\n parent.splice(+key, 1);\n } else {\n delete parent[key];\n }\n }\n });\n};\n\n/**\n* Deep clone an object.\n* @private\n* @param {Object} obj The object to clone\n* @returns {Object} A new object identical to the `obj`\n*/\nJSONPatch.clone = function clone(obj) {\n return extend({}, obj);\n};\n\n/**\n* Creates a JSON-patch.\n* @private\n* @param {String} op The operation of the patch. Available values: \"add\", \"remove\", \"move\"\n* @param {Object} [val] The value to set the `path` to. If `op` is `move`, `val`\n* is the \"from JSON-path\" path\n* @param {String} path The JSON-path for the property to change (e.g. \"/qHyperCubeDef/columnOrder\")\n* @returns {Object} A patch following the JSON-patch specification\n*/\nJSONPatch.createPatch = function createPatch(op, val, path) {\n const patch = {\n op: op.toLowerCase(),\n path,\n };\n if (patch.op === 'move') {\n patch.from = val;\n } else if (typeof val !== 'undefined') {\n patch.value = val;\n }\n return patch;\n};\n\n/**\n* Apply the differences of two objects (keeping references if possible).\n* Identical to running `JSONPatch.apply(original, JSONPatch.generate(original, newData));`\n* @private\n* @param {Object} original The object to update/patch\n* @param {Object} newData the object to diff against\n*\n* @example\n* var obj1 = { foo: [1,2,3], bar: { baz: true, qux: 1 } };\n* var obj2 = { foo: [4,5,6], bar: { baz: false } };\n* JSONPatch.updateObject(obj1, obj2);\n* // => { foo: [4,5,6], bar: { baz: false } };\n*/\nJSONPatch.updateObject = function updateObject(original, newData) {\n if (!Object.keys(original).length) {\n extend(original, newData);\n return;\n }\n JSONPatch.apply(original, JSONPatch.generate(original, newData));\n};\n\nexport default JSONPatch;\n","import JSONPatch from '../json-patch';\nimport KeyValueCache from '../key-value-cache';\n\nimport createEnigmaError from '../error';\nimport errorCodes from '../error-codes';\n\nconst sessions = {};\n\n/**\n* Function to make sure we release handle caches when they are closed.\n* @private\n* @param {Session} session The session instance to listen on.\n*/\nconst bindSession = (session) => {\n if (!sessions[session.id]) {\n const cache = {};\n sessions[session.id] = cache;\n session.on('traffic:received', (data) => data.close && data.close.forEach((handle) => delete cache[handle]));\n session.on('closed', () => delete sessions[session.id]);\n }\n};\n\n/**\n* Simple function that ensures the session events has been bound, and returns\n* either an existing key-value cache or creates one for the specified handle.\n* @private\n* @param {Session} session The session that owns the handle.\n* @param {Number} handle The object handle to retrieve the cache for.\n* @returns {KeyValueCache} The cache instance.\n*/\nconst getHandleCache = (session, handle) => {\n bindSession(session);\n const cache = sessions[session.id];\n if (!cache[handle]) {\n cache[handle] = new KeyValueCache();\n }\n return cache[handle];\n};\n\n/**\n* Function used to apply a list of patches and return the patched value.\n* @private\n* @param {Session} session The session.\n* @param {Number} handle The object handle.\n* @param {String} cacheId The cacheId.\n* @param {Array} patches The patches.\n* @returns {Object} Returns the patched value.\n*/\nconst patchValue = (session, handle, cacheId, patches) => {\n const cache = getHandleCache(session, handle);\n let entry = cache.get(cacheId);\n if (typeof entry === 'undefined') {\n entry = Array.isArray(patches[0].value) ? [] : {};\n }\n if (patches.length) {\n if (patches[0].path === '/' && typeof patches[0].value !== 'object') {\n // 'plain' values on root path is not supported (no object reference),\n // so we simply store the value directly:\n entry = patches[0].value;\n } else {\n JSONPatch.apply(entry, patches);\n }\n cache.set(cacheId, entry);\n }\n return entry;\n};\n\n/**\n* Process delta interceptor.\n* @private\n* @param {Session} session The session the intercept is being executed on.\n* @param {Object} request The JSON-RPC request.\n* @param {Object} response The response.\n* @returns {Object} Returns the patched response\n*/\nexport default function deltaResponseInterceptor(session, request, response) {\n const { delta, result } = response;\n if (delta) {\n // when delta is on the response data is expected to be an array of patches:\n Object.keys(result).forEach((key) => {\n if (!Array.isArray(result[key])) {\n throw createEnigmaError(errorCodes.EXPECTED_ARRAY_OF_PATCHES, 'Unexpected RPC response, expected array of patches');\n }\n result[key] = patchValue(session, request.handle, `${request.method}-${key}`, result[key]);\n });\n // return a cloned response object to avoid patched object references:\n return JSON.parse(JSON.stringify(response));\n }\n return response;\n}\n\n// export object reference for testing purposes:\ndeltaResponseInterceptor.sessions = sessions;\n","/**\n* Process error interceptor.\n* @private\n* @param {Session} session - The session the intercept is being executed on.\n* @param {Object} request - The JSON-RPC request.\n* @param {Object} response - The response.\n* @returns {Object} - Returns the defined error for an error, else the response.\n*/\nexport default function errorResponseInterceptor(session, request, response) {\n if (typeof response.error !== 'undefined') {\n const data = response.error;\n const error = new Error(data.message);\n error.code = data.code;\n error.parameter = data.parameter;\n return session.config.Promise.reject(error);\n }\n return response;\n}\n","const RETURN_KEY = 'qReturn';\n\n/**\n* Picks out the result \"out\" parameter based on the QIX method+schema, with\n* some specific handling for some methods that breaks the predictable protocol.\n* @private\n* @param {Session} session - The session the intercept is being executed on.\n* @param {Object} request - The JSON-RPC request.\n* @param {Object} response - The response.\n* @returns {Object} - Returns the result property on the response\n*/\nexport default function outParamResponseInterceptor(session, request, response) {\n if (request.method === 'CreateSessionApp' || request.method === 'CreateSessionAppFromApp') {\n // this method returns multiple out params that we need\n // to normalize before processing the response further:\n response[RETURN_KEY].qGenericId = response.qSessionAppId || response[RETURN_KEY].qGenericId;\n } else if (request.method === 'GetInteract') {\n // this method returns a qReturn value when it should only return\n // meta.outKey:\n delete response[RETURN_KEY];\n }\n\n if (hasOwnProperty.call(response, RETURN_KEY)) {\n return response[RETURN_KEY];\n }\n if (request.outKey !== -1) {\n return response[request.outKey];\n }\n\n return response;\n}\n","/**\n* Process result interceptor.\n* @private\n* @param {Session} session - The session the intercept is being executed on.\n* @param {Object} request - The JSON-RPC request.\n* @param {Object} response - The response.\n* @returns {Object} - Returns the result property on the response\n*/\nexport default function resultResponseInterceptor(session, request, response) {\n return response.result;\n}\n","import deltaRequest from './interceptors/delta-request-interceptor';\nimport apiResponse from './interceptors/api-response-interceptor';\nimport deltaResponse from './interceptors/delta-response-interceptor';\nimport errorResponse from './interceptors/error-response-interceptor';\nimport outParamResponse from './interceptors/out-param-response-interceptor';\nimport resultResponse from './interceptors/result-response-interceptor';\n\n/**\n * Interceptors is a concept similar to mixins, but run on a lower level. The interceptor concept\n * can augment either the requests (i.e. before sent to QIX Engine), or the responses (i.e. after\n * QIX Engine has sent a response). The interceptor promises runs in parallel to the regular\n * promises used in enigma.js, which means that it can be really useful when you want to normalize\n * behaviors in your application.\n * @interface Interceptor\n */\n\n/**\n * @class InterceptorRequest\n * @implements {Interceptor}\n * @example Implement a request interceptor\n * const enigma = require('enigma.js');\n * const WebSocket = require('ws');\n * const schema = require('enigma.js/schemas/12.20.0.json');\n *\n * const session = enigma.create({\n * schema,\n * url: 'ws://localhost:9076/app/engineData',\n * createSocket: (url) => new WebSocket(url),\n * requestInterceptors: [{\n * onFulfilled: function logRequest(sessionReference, request) {\n * console.log('Request being sent', request);\n * return request;\n * }\n * },\n * });\n */\n\n/**\n * @class InterceptorResponse\n * @implements {Interceptor}\n * @example Implement a request interceptor\n * const enigma = require('enigma.js');\n * const WebSocket = require('ws');\n * const schema = require('enigma.js/schemas/12.20.0.json');\n *\n * const session = enigma.create({\n * schema,\n * url: 'ws://localhost:9076/app/engineData',\n * createSocket: (url) => new WebSocket(url),\n * responseInterceptors: [{\n * onRejected: function logError(sessionReference, request, error) {\n * console.log('Error returned from QIX engine', error, 'Originating request:', request);\n * // throw error so it's continued to be rejected:\n * throw error;\n * }\n * },\n * });\n */\n\n/**\n * This method is invoked when a request is about to be sent to QIX Engine.\n * @function InterceptorRequest#onFulfilled\n * @param {Session} session The session executing the interceptor.\n * @param {Object} request The JSON-RPC request that will be sent.\n */\n\n/**\n * This method is invoked when a previous interceptor has rejected the\n * promise, use this to handle for example errors before they are sent into mixins.\n * @function InterceptorResponse#onRejected\n * @param {Session} session The session executing the interceptor. You may use .retry() to retry\n * sending it to QIX Engine.\n * @param {Object} request The JSON-RPC request resulting in this error.\n * @param {Object} error Whatever the previous interceptor is rejected with.\n */\n\n/**\n * This method is invoked when a promise has been successfully resolved,\n * use this to modify the result or reject the promise chain before it is sent\n * to mixins.\n * @function InterceptorResponse#onFulfilled\n * @param {Session} session The session executing the interceptor.\n * @param {Object} request The JSON-RPC request resulting in this response.\n * @param {Object} result Whatever the previous interceptor is resolved with.\n */\nclass Intercept {\n /**\n * Create a new Intercept instance.\n * @private\n * @param {Object} options The configuration options for this class.\n * @param {Promise} options.Promise The promise constructor to use.\n * @param {ApiCache} options.apis The ApiCache instance to use.\n * @param {Array} [options.request] The additional request interceptors to use.\n * @param {Array} [options.response] The additional response interceptors to use.\n */\n constructor(options) {\n Object.assign(this, options);\n this.request = [{ onFulfilled: deltaRequest }, ...this.request || []];\n this.response = [\n { onFulfilled: errorResponse },\n { onFulfilled: deltaResponse },\n { onFulfilled: resultResponse },\n { onFulfilled: outParamResponse },\n ...this.response || [],\n { onFulfilled: apiResponse },\n ];\n }\n\n /**\n * Execute the request interceptor queue, each interceptor will get the result from\n * the previous interceptor.\n * @private\n * @param {Session} session The session instance to execute against.\n * @param {Promise} promise The promise to chain on to.\n * @returns {Promise}\n */\n executeRequests(session, promise) {\n return this.request.reduce((interception, interceptor) => {\n const intercept = interceptor.onFulfilled\n && interceptor.onFulfilled.bind(this, session);\n return interception.then(intercept);\n }, promise);\n }\n\n /**\n * Execute the response interceptor queue, each interceptor will get the result from\n * the previous interceptor.\n * @private\n * @param {Session} session The session instance to execute against.\n * @param {Promise} promise The promise to chain on to.\n * @param {Object} request The JSONRPC request object for the intercepted response.\n * @returns {Promise}\n */\n executeResponses(session, promise, request) {\n return this.response.reduce((interception, interceptor) => interception.then(\n interceptor.onFulfilled && interceptor.onFulfilled.bind(this, session, request),\n interceptor.onRejected && interceptor.onRejected.bind(this, session, request),\n ), promise);\n }\n}\n\nexport default Intercept;\n","import KeyValueCache from './key-value-cache';\n\n/**\n* API cache for instances of QIX types, e.g. GenericObject.\n* @private\n* @extends KeyValueCache\n*/\nclass ApiCache extends KeyValueCache {\n /**\n * Adds an API.\n * @private\n * @function ApiCache#add\n * @param {Number} handle - The handle for the API.\n * @param {*} api - The API.\n * @returns {{api: *}} The entry.\n */\n add(handle, api) {\n const entry = { api };\n super.add(handle.toString(), entry);\n api.on('closed', () => this.remove(handle));\n return entry;\n }\n\n /**\n * Gets an API.\n * @private\n * @function ApiCache#getApi\n * @param {Number} handle - The handle for the API.\n * @returns {*} The API for the handle.\n */\n getApi(handle) {\n const entry = typeof handle !== 'undefined' ? this.get(handle.toString()) : undefined;\n return entry && entry.api;\n }\n\n /**\n * Gets a list of APIs.\n * @private\n * @function ApiCache#getApis\n * @returns {Array} The list of entries including `handle` and `api` properties for each entry.\n */\n getApis() {\n return super.getAll().map((entry) => ({\n handle: entry.key,\n api: entry.value.api,\n }));\n }\n\n /**\n * Gets a list of APIs with a given type.\n * @private\n * @function ApiCache#getApisByType\n * @param {String} type - The type of APIs to get.\n * @returns {Array} The list of entries including `handle` and `api` properties for each entry.\n */\n getApisByType(type) {\n return this.getApis().filter((entry) => entry.api.type === type);\n }\n}\n\nexport default ApiCache;\n","import Session from './session';\nimport Schema from './schema';\nimport RPC from './rpc';\nimport SuspendResume from './suspend-resume';\nimport Intercept from './intercept';\nimport ApiCache from './api-cache';\n\nimport createEnigmaError from './error';\nimport errorCodes from './error-codes';\n\n/**\n * The enigma.js configuration object.\n * @interface Configuration\n * @property {Object} schema Object containing the specification for the API to generate.\n * Corresponds to a specific version of the QIX Engine API.\n * @property {String} url String containing a proper websocket URL to QIX Engine.\n * @property {Function} [createSocket] A function to use when instantiating the WebSocket,\n * mandatory for Node.js.\n * @property {Object} [Promise] ES6-compatible Promise library.\n * @property {Boolean} [suspendOnClose=false] Set to true if the session should be suspended\n * instead of closed when the websocket is closed.\n * @property {Array} [mixins=[]] Mixins to extend/augment the QIX Engine API. Mixins\n * are applied in the array order.\n * @property {Array} [requestInterceptors=[]] Interceptors for augmenting requests before they\n * are sent to QIX Engine. Interceptors are applied in the array order.\n * @property {Array} [responseInterceptors=[]] Interceptors for augmenting responses before they\n * are passed into mixins and end-users. Interceptors are applied in the array order.\n * @property {Object} [protocol={}] An object containing additional JSON-RPC request parameters.\n * @property {Boolean} [protocol.delta=true] Set to false to disable the use of the\n * bandwidth-reducing delta protocol.\n * @example Example defining a configuration object\n * const enigma = require('enigma.js');\n * const WebSocket = require('ws');\n * const bluebird = require('bluebird');\n * const schema = require('enigma.js/schemas/12.20.0.json');\n *\n * const config = {\n * schema,\n * url: 'ws://localhost:4848/app/engineData',\n * createSocket: url => new WebSocket(url),\n * Promise: bluebird,\n * suspendOnClose: true,\n * mixins: [{ types: ['Global'], init: () => console.log('Mixin ran') }],\n * protocol: { delta: false },\n * };\n *\n * enigma.create(config).open().then((global) => {\n * // global === QIX global interface\n * process.exit(0);\n * });\n */\n\n/**\n * The mixin concept allows you to add or override QIX Engine API functionality. A mixin is\n * basically a JavaScript object describing which types it modifies, and a list of functions\n * for extending and overriding the API for those types.\n *\n * QIX Engine types like for example GenericObject, Doc, GenericBookmark, are supported but\n * also custom GenericObject types such as barchart, story and myCustomType. An API will get\n * both their generic type as well as custom type mixins applied.\n *\n * Mixins that are bound to several different types can find the current API type in the\n * `genericType` or `type` members. `this.type` would for instance return `GenericObject` and\n * `this.genericType` would return `barchart`.\n *\n * See the Mixins examples on how to use it, below is an outline of what the mixin API consists of.\n *\n * @interface Mixin\n * @property {String|Array} types String or array of strings containing the API-types that\n * will be mixed in.\n * @property {Object} [extend] Object literal containing the methods that will be extended on the\n * specified API.\n * @property {Object} [override] Object literal containing the methods to override existing methods.\n * @property {Function} [init] Init function that, if defined, will run when an API is instantiated.\n * It runs with Promise and API object as parameters\n */\n\n/**\n * The API for generated APIs depends on the QIX Engine schema you pass into your Configuration, and\n * on what QIX struct the API has.\n *\n * All API calls made using the generated APIs will return promises which are either resolved or\n * rejected depending on how the QIX Engine responds.\n *\n * @interface API\n * @property {String} id Contains the unique identifier for this API.\n * @property {String} type Contains the schema class name for this API.\n * @property {String} genericType Corresponds to the qInfo.qType property on the generic object's\n * properties object.\n * @property {Session} session Contains a reference to the session that this API belongs to.\n * @property {Number} handle Contains the handle QIX Engine assigned to the API. Used interally in\n * enigma.js for caches and JSON-RPC requests.\n * @example Example using `global` and `generic object` struct APIs\n * global.openDoc('my-document.qvf').then((doc) => {\n * doc.createObject({ qInfo: { qType: 'my-object' } }).then(api => { });\n * doc.getObject('object-id').then(api => { });\n * doc.getBookmark('bookmark-id').then(api => { });\n * });\n */\n\n/**\n * Handle changes on the API. The changed event is triggered whenever enigma.js or QIX Engine has\n * identified potential changes on the underlying properties or hypercubes and you should re-fetch\n * your data.\n * @event API#changed\n * @type {Object}\n * @example Bind the `changed` event\n * api.on('changed', () => {\n * api.getLayout().then(layout => { });\n * });\n */\n\n/**\n * Handle closed API. The closed event is triggered whenever QIX Engine considers an API closed.\n * It usually means that it no longer exist in the QIX Engine document or session.\n * @event API#closed\n * @type {Object}\n * @example Bind the `closed` event\n * api.on('closed', () => {\n * console.log(api.id, 'was closed');\n * });\n */\n\n/**\n * Handle JSON-RPC requests/responses for this API. Generally used in debugging purposes.\n * `traffic:*` will handle all websocket messages, `traffic:sent` will handle outgoing messages\n * and `traffic:received` will handle incoming messages.\n * @event API#traffic\n * @type {Object}\n * @example Bind the traffic events\n * // bind both in- and outbound traffic to console.log:\n * api.on('traffic:*', console.log);\n * // bind outbound traffic to console.log:\n * api.on('traffic:sent', console.log);\n * // bind inbound traffic to console.log:\n * api.on('traffic:received', console.log);\n */\n\nclass Enigma {\n /**\n * Function used to get a session.\n * @private\n * @param {Configuration} config The configuration object for this session.\n * @returns {Session} Returns a session instance.\n */\n static getSession(config) {\n const {\n createSocket,\n Promise,\n requestInterceptors,\n responseInterceptors,\n url,\n } = config;\n const apis = new ApiCache();\n const intercept = new Intercept({\n apis,\n Promise,\n request: requestInterceptors,\n response: responseInterceptors,\n });\n const rpc = new RPC({ createSocket, Promise, url });\n const suspendResume = new SuspendResume({ apis, Promise, rpc });\n const session = new Session({\n apis,\n config,\n intercept,\n rpc,\n suspendResume,\n });\n return session;\n }\n\n /**\n * Function used to configure defaults.\n * @private\n * @param {Configuration} config The configuration object for how to connect\n * and retrieve end QIX APIs.\n */\n static configureDefaults(config) {\n if (!config) {\n throw createEnigmaError(errorCodes.NO_CONFIG_SUPPLIED, 'You need to supply a configuration.');\n }\n\n // eslint-disable-next-line no-restricted-globals\n if (!config.Promise && typeof Promise === 'undefined') {\n throw createEnigmaError(errorCodes.PROMISE_REQUIRED, 'Your environment has no Promise implementation. You must provide a Promise implementation in the config.');\n }\n\n if (typeof config.createSocket !== 'function' && typeof WebSocket === 'function') {\n // eslint-disable-next-line no-undef\n config.createSocket = (url) => new WebSocket(url);\n }\n\n if (typeof config.suspendOnClose === 'undefined') {\n config.suspendOnClose = false;\n }\n\n config.protocol = config.protocol || {};\n config.protocol.delta = typeof config.protocol.delta !== 'undefined' ? config.protocol.delta : true;\n // eslint-disable-next-line no-restricted-globals\n config.Promise = config.Promise || Promise;\n config.mixins = config.mixins || [];\n config.definition = config.definition || new Schema(config);\n }\n\n /**\n * Function used to create a QIX session.\n * @entry\n * @param {Configuration} config The configuration object for the QIX session.\n * @returns {Session} Returns a new QIX session.\n * @example Example minimal session creation\n * const enigma = require('enigma.js');\n * const schema = require('enigma.js/schemas/12.20.0.json');\n * const WebSocket = require('ws');\n * const config = {\n * schema,\n * url: 'ws://localhost:9076/app/engineData',\n * createSocket: url => new WebSocket(url),\n * };\n * const session = enigma.create(config);\n */\n static create(config) {\n Enigma.configureDefaults(config);\n config.mixins.forEach((mixin) => {\n config.definition.registerMixin(mixin);\n });\n return Enigma.getSession(config);\n }\n}\n\nexport default Enigma;\n"],"names":["mixin","obj","Object","keys","EventEmitter","prototype","forEach","key","init","EnigmaError","name","code","enigmaError","Error","createEnigmaError","errorCodes","NOT_CONNECTED","OBJECT_NOT_FOUND","EXPECTED_ARRAY_OF_PATCHES","PATCH_HAS_NO_PARENT","ENTRY_ALREADY_DEFINED","NO_CONFIG_SUPPLIED","PROMISE_REQUIRED","SCHEMA_STRUCT_TYPE_NOT_FOUND","SCHEMA_MIXIN_CANT_OVERRIDE_FUNCTION","SCHEMA_MIXIN_EXTEND_NOT_ALLOWED","SESSION_SUSPENDED","SESSION_NOT_ATTACHED","RPC_CLOSE_NORMAL","RPC_CLOSE_MANUAL_SUSPEND","cacheId","Session","options","session","assign","Promise","config","definition","id","rpc","on","onRpcError","bind","onRpcClosed","onRpcMessage","onRpcNotification","onRpcTraffic","onSessionClosed","err","suspendResume","isSuspended","emit","evt","suspendOnClose","reason","suspend","then","initiator","response","change","handle","emitHandleChanged","close","emitHandleClosed","method","params","dir","data","api","apis","getApi","getApis","entry","removeAllListeners","clear","args","type","genericType","factory","generate","add","globalPromise","open","getObjectApi","global","request","reject","createRequestId","promise","intercept","executeRequests","resolve","augmentedRequest","protocol","outKey","send","retry","executeResponses","addToPromiseChain","onlyIfAttached","resume","value","undefined","patchedThen","chain","apply","KeyValueCache","entries","map","filter","hasOwnProperty","toCamelCase","symbol","substring","toLowerCase","namedParamFacade","base","defaults","length","_typeof","Array","isArray","valid","every","call","Schema","schema","mixins","types","extend","override","push","cached","typeKey","entryList","get","structs","generateApi","create","generateDefaultApi","mixinType","mixinNamedParamFacade","customKey","instance","Events","defineProperties","enumerable","writable","mixinList","concat","out","Out","Name","fnName","generatedMethod","baseFn","wrappedFn","In","reduce","result","item","DefaultValue","namedParamWrapper","RPCResolver","RPC","resolvers","requestId","openedPromise","force","socket","createSocket","url","onopen","onOpen","onclose","onClose","onerror","onError","onmessage","onMessage","registerResolver","closedPromise","opened","resolveWith","event","closed","rejectAllOutstandingResolvers","rejectWith","JSON","parse","resolver","resolvedId","unregisterResolver","rejectedId","readyState","OPEN","error","jsonrpc","stringify","ON_ATTACHED_TIMEOUT_MS","SuspendResume","openDocParams","reopen","sessionState","changed","getApisByType","pop","doc","qReturn","qHandle","tasks","buildGetMethodName","all","restoreRpcConnection","restoreGlobal","restoreDoc","restoreDocObjects","timeout","timer","notificationResolve","notificationReceived","notificationPromise","waitForNotification","setTimeout","onNotification","clearTimeout","qSessionState","state","removeListener","replace","SUCCESS_KEY","deltaRequestInterceptor","delta","apiResponseInterceptor","qType","qGenericId","qGenericType","originalExtend","JSONPatch","isObject","v","isUndef","isFunction","generateValue","val","isSpecialProperty","getParent","str","seperator","parts","split","slice","numPart","part","i","newPart","isNaN","emptyObject","getOwnPropertyDescriptor","configurable","compare","a","b","isIdentical","l","patchArray","original","newA","basePath","patches","oldA","tmpIdx","findIndex","idx","qInfo","qId","ii","ll","op","path","splice","from","newData","oldVal","tmpPath","patch","parent","target","chunkSize","chunk","oldParent","clone","createPatch","updateObject","sessions","bindSession","cache","getHandleCache","patchValue","set","deltaResponseInterceptor","errorResponseInterceptor","message","parameter","RETURN_KEY","outParamResponseInterceptor","qSessionAppId","resultResponseInterceptor","Intercept","onFulfilled","deltaRequest","errorResponse","deltaResponse","resultResponse","outParamResponse","apiResponse","interception","interceptor","onRejected","ApiCache","toString","remove","Enigma","requestInterceptors","responseInterceptors","WebSocket","configureDefaults","registerMixin","getSession"],"mappings":";;;;;;;;;;;;EAAA;;;;EAIA,IAAI,IAAI,GAAG,EAAE,CAAC;;EAEd,IAAI,CAAC,QAAQ,GAAG,SAAS,QAAQ,CAAC,GAAG,EAAE;IACrC,OAAO,OAAO,GAAG,KAAK,QAAQ,IAAI,GAAG,KAAK,IAAI,CAAC;IAChD;;EAED,IAAI,CAAC,QAAQ,GAAG,SAAS,QAAQ,CAAC,GAAG,EAAE;I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AACC,UAAP,GAAoBD,MAAM,CAACC,UAAP,IAAqB,IAAIwF,MAAJ,CAAWzF,MAAX,CAAzC;EACD;EAED;;;;;;;;;;;;;;;;;;;6BAgBcA,QAAQ;EACpB8R,MAAAA,MAAM,CAACI,iBAAP,CAAyBlS,MAAzB;EACAA,MAAAA,MAAM,CAAC2F,MAAP,CAAczH,OAAd,CAAsB,UAACN,KAAD,EAAW;EAC/BoC,QAAAA,MAAM,CAACC,UAAP,CAAkBkS,aAAlB,CAAgCvU,KAAhC;EACD,OAFD;EAGA,aAAOkU,MAAM,CAACM,UAAP,CAAkBpS,MAAlB,CAAP;EACD;;;;;;;;"} \ No newline at end of file diff --git a/jwt-scratch/src/js/node_modules/enigma.js/enigma.min.js b/jwt-scratch/src/js/node_modules/enigma.js/enigma.min.js new file mode 100644 index 0000000..2282515 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/enigma.js/enigma.min.js @@ -0,0 +1,2 @@ +!function(e,t){"object"==typeof exports&&"undefined"!=typeof module?module.exports=t():"function"==typeof define&&define.amd?define(t):(e="undefined"!=typeof globalThis?globalThis:e||self).enigma=t()}(this,function(){"use strict";var c={};function r(){r.init.call(this)}c.isObject=function(e){return"object"==typeof e&&null!==e},c.isNumber=function(e){return"number"==typeof e},c.isUndefined=function(e){return void 0===e},c.isFunction=function(e){return"function"==typeof e};var n=r;(r.EventEmitter=r).prototype._events=void 0,r.prototype._maxListeners=void 0,r.defaultMaxListeners=10,r.init=function(){this._events=this._events||{},this._maxListeners=this._maxListeners||void 0},r.prototype.setMaxListeners=function(e){if(!c.isNumber(e)||e<0||isNaN(e))throw TypeError("n must be a positive number");return this._maxListeners=e,this},r.prototype.emit=function(e){var t,n,r,i,o,s;if(this._events||(this._events={}),"error"===e&&!this._events.error)throw(t=arguments[1])instanceof Error?t:Error('Uncaught, unspecified "error" event.');if(n=this._events[e],c.isUndefined(n))return!1;if(c.isFunction(n))switch(arguments.length){case 1:n.call(this);break;case 2:n.call(this,arguments[1]);break;case 3:n.call(this,arguments[1],arguments[2]);break;default:for(r=arguments.length,i=new Array(r-1),o=1;on&&(this._events[e].warned=!0,c.isFunction(console.error)&&console.error("(node) warning: possible EventEmitter memory leak detected. %d listeners added. Use emitter.setMaxListeners() to increase limit.",this._events[e].length),c.isFunction(console.trace)&&console.trace()));return this},r.prototype.once=function(e,t){if(!c.isFunction(t))throw TypeError("listener must be a function");var n=!1;function r(){this.removeListener(e,r),n||(n=!0,t.apply(this,arguments))}return r.listener=t,this.on(e,r),this},r.prototype.removeListener=function(e,t){var n,r,i,o;if(!c.isFunction(t))throw TypeError("listener must be a function");if(!this._events||!this._events[e])return this;if(i=(n=this._events[e]).length,r=-1,n===t||c.isFunction(n.listener)&&n.listener===t)delete this._events[e],this._events.removeListener&&this.emit("removeListener",e,t);else if(c.isObject(n)){for(o=i;0e.length)&&(t=e.length);for(var n=0,r=new Array(t);ne.length)&&(t=e.length);for(var n=0,r=new Array(t);n 0 && this._events[type].length > m) {\n this._events[type].warned = true;\n\n if (util.isFunction(console.error)) {\n console.error('(node) warning: possible EventEmitter memory ' +\n 'leak detected. %d listeners added. ' +\n 'Use emitter.setMaxListeners() to increase limit.',\n this._events[type].length);\n }\n if (util.isFunction(console.trace))\n console.trace();\n }\n }\n\n return this;\n};\n\nEventEmitter.prototype.on = EventEmitter.prototype.addListener;\n\nEventEmitter.prototype.once = function(type, listener) {\n if (!util.isFunction(listener))\n throw TypeError('listener must be a function');\n\n var fired = false;\n\n function g() {\n this.removeListener(type, g);\n\n if (!fired) {\n fired = true;\n listener.apply(this, arguments);\n }\n }\n\n g.listener = listener;\n this.on(type, g);\n\n return this;\n};\n\n// emits a 'removeListener' event iff the listener was removed\nEventEmitter.prototype.removeListener = function(type, listener) {\n var list, position, length, i;\n\n if (!util.isFunction(listener))\n throw TypeError('listener must be a function');\n\n if (!this._events || !this._events[type])\n return this;\n\n list = this._events[type];\n length = list.length;\n position = -1;\n\n if (list === listener ||\n (util.isFunction(list.listener) && list.listener === listener)) {\n delete this._events[type];\n if (this._events.removeListener)\n this.emit('removeListener', type, listener);\n\n } else if (util.isObject(list)) {\n for (i = length; i-- > 0;) {\n if (list[i] === listener ||\n (list[i].listener && list[i].listener === listener)) {\n position = i;\n break;\n }\n }\n\n if (position < 0)\n return this;\n\n if (list.length === 1) {\n list.length = 0;\n delete this._events[type];\n } else {\n list.splice(position, 1);\n }\n\n if (this._events.removeListener)\n this.emit('removeListener', type, listener);\n }\n\n return this;\n};\n\nEventEmitter.prototype.removeAllListeners = function(type) {\n var key, listeners;\n\n if (!this._events)\n return this;\n\n // not listening for removeListener, no need to emit\n if (!this._events.removeListener) {\n if (arguments.length === 0)\n this._events = {};\n else if (this._events[type])\n delete this._events[type];\n return this;\n }\n\n // emit removeListener for all listeners on all events\n if (arguments.length === 0) {\n for (key in this._events) {\n if (key === 'removeListener') continue;\n this.removeAllListeners(key);\n }\n this.removeAllListeners('removeListener');\n this._events = {};\n return this;\n }\n\n listeners = this._events[type];\n\n if (util.isFunction(listeners)) {\n this.removeListener(type, listeners);\n } else if (Array.isArray(listeners)) {\n // LIFO order\n while (listeners.length)\n this.removeListener(type, listeners[listeners.length - 1]);\n }\n delete this._events[type];\n\n return this;\n};\n\nEventEmitter.prototype.listeners = function(type) {\n var ret;\n if (!this._events || !this._events[type])\n ret = [];\n else if (util.isFunction(this._events[type]))\n ret = [this._events[type]];\n else\n ret = this._events[type].slice();\n return ret;\n};\n\nEventEmitter.listenerCount = function(emitter, type) {\n var ret;\n if (!emitter._events || !emitter._events[type])\n ret = 0;\n else if (util.isFunction(emitter._events[type]))\n ret = 1;\n else\n ret = emitter._events[type].length;\n return ret;\n};\n","import EventEmitter from 'node-event-emitter';\n\n/**\n* @module EventEmitter\n* @private\n*/\nexport default {\n\n /**\n * Function used to add event handling to objects passed in.\n * @param {Object} obj Object instance that will get event handling.\n */\n mixin: (obj) => {\n Object.keys(EventEmitter.prototype).forEach((key) => {\n obj[key] = EventEmitter.prototype[key];\n });\n EventEmitter.init(obj);\n },\n};\n","/**\n * Error containing a custom error code.\n * @extends Error\n * @property {number} code The error code as defined by `errorCodes`\n * @property {boolean} enigmaError=true\n */\nclass EnigmaError extends Error {\n constructor(name, code) {\n super(name);\n this.code = code;\n this.enigmaError = true;\n }\n}\n\n/**\n * Create an enigmaError\n * @private\n * @param {Number} code A proper error code from `errorCodes`\n * @param {String} name A message/name of the enigmaError.\n * @returns {EnigmaError}\n */\nexport default function createEnigmaError(code, name) {\n return new EnigmaError(name, code);\n}\n","/**\n * This is a list of error codes that can be thrown from enigma.js API calls.\n * @entry\n * @see EnigmaError\n * @enum\n * @example Handling an enigma.js error\n * const { NOT_CONNECTED } = require('enigma.js/error-codes');\n * try {\n * const layout = await model.getLayout();\n * } catch (err) {\n * if (err.code === NOT_CONNECTED) {\n * console.log('Tried to communicate on a session that is closed');\n * }\n * }\n */\nconst errorCodes = {\n /**\n * You're trying to send data on a socket that's not connected\n * @type {number}\n */\n NOT_CONNECTED: -1,\n /**\n * The object you're trying to fetch does not exist\n * @type {number}\n */\n OBJECT_NOT_FOUND: -2,\n /**\n * Unexpected RPC response, expected array of patches\n * @type {number}\n */\n EXPECTED_ARRAY_OF_PATCHES: -3,\n /**\n * Patchee is not an object we can patch\n * @type {number}\n */\n PATCH_HAS_NO_PARENT: -4,\n /**\n * This entry is already defined with another key\n * @type {number}\n */\n ENTRY_ALREADY_DEFINED: -5,\n /**\n * You need to supply a configuration\n * @type {number}\n */\n NO_CONFIG_SUPPLIED: -6,\n /**\n * There's no promise object available (polyfill required?)\n * @type {number}\n */\n PROMISE_REQUIRED: -7,\n /**\n * The schema struct type you requested does not exist\n * @type {number}\n */\n SCHEMA_STRUCT_TYPE_NOT_FOUND: -8,\n /**\n * Can't override this function\n * @type {number}\n */\n SCHEMA_MIXIN_CANT_OVERRIDE_FUNCTION: -9,\n /**\n * Extend is not allowed for this mixin\n * @type {number}\n */\n SCHEMA_MIXIN_EXTEND_NOT_ALLOWED: -10,\n /**\n * Session suspended - no interaction allowed\n * @type {number}\n */\n SESSION_SUSPENDED: -11,\n /**\n * onlyIfAttached supplied, but you got SESSION_CREATED\n * @type {number}\n */\n SESSION_NOT_ATTACHED: -12,\n};\n\nexport default errorCodes;\n","import EventEmitter from './event-emitter';\n\nimport createEnigmaError from './error';\nimport errorCodes from './error-codes';\n\nconst RPC_CLOSE_NORMAL = 1000;\nconst RPC_CLOSE_MANUAL_SUSPEND = 4000;\n\nlet cacheId = 0;\n\n/**\n * The QIX Engine session object\n */\nclass Session {\n /**\n * Handle all JSON-RPC notification event, 'notification:*. Or handle a specific JSON-RPC\n * notification event, 'notification:OnConnected'. These events depend on the product you use QIX\n * Engine from.\n * @event Session#notification\n * @type {Object}\n * @example Bind the notification events\n * // bind all notifications to console.log:\n * session.on('notification:*', console.log);\n * // bind a specific notification to console.log:\n * session.on('notification:OnConnected', console.log);\n */\n\n /**\n * Handle websocket messages. Generally used in debugging purposes. `traffic:*` will handle all\n * websocket messages, `traffic:sent` will handle outgoing messages and `traffic:received` will\n * handle incoming messages.\n * @event Session#traffic\n * @type {Object}\n * @example Bind the traffic events\n * // bind both in- and outbound traffic to console.log:\n * session.on('traffic:*', console.log);\n * // bind outbound traffic to console.log:\n * session.on('traffic:sent', console.log);\n * // bind inbound traffic to console.log:\n * session.on('traffic:received', console.log);\n */\n\n constructor(options) {\n const session = this;\n Object.assign(session, options);\n this.Promise = this.config.Promise;\n this.definition = this.config.definition;\n EventEmitter.mixin(session);\n cacheId += 1;\n session.id = cacheId;\n session.rpc.on('socket-error', session.onRpcError.bind(session));\n session.rpc.on('closed', session.onRpcClosed.bind(session));\n session.rpc.on('message', session.onRpcMessage.bind(session));\n session.rpc.on('notification', session.onRpcNotification.bind(session));\n session.rpc.on('traffic', session.onRpcTraffic.bind(session));\n session.on('closed', () => session.onSessionClosed());\n }\n\n /**\n * Event handler for re-triggering error events from RPC.\n * @private\n * @emits socket-error\n * @param {Error} err Webocket error event.\n */\n onRpcError(err) {\n if (this.suspendResume.isSuspended) {\n return;\n }\n this.emit('socket-error', err);\n }\n\n /**\n * Event handler for the RPC close event.\n * @private\n * @emits Session#suspended\n * @emits Session#closed\n * @param {Event} evt WebSocket close event.\n */\n onRpcClosed(evt) {\n /**\n * Handle suspended state. This event is triggered in two cases (listed below). It is useful\n * in scenarios where you for example want to block interaction in your application until you\n * are resumed again. If config.suspendOnClose is true and there was a network disconnect\n * (socked closed) or if you ran session.suspend().\n * @event Session#suspended\n * @type {Object}\n * @param {Object} evt Event object.\n * @param {String} evt.initiator String indication what triggered the suspended state. Possible\n * values network, manual.\n * @example Handling session suspended\n * session.on('suspended', () => {\n * console.log('Session was suspended, retrying...');\n * session.resume();\n * });\n */\n if (this.suspendResume.isSuspended) {\n return;\n }\n if (evt.code === RPC_CLOSE_NORMAL || evt.code === RPC_CLOSE_MANUAL_SUSPEND) {\n return;\n }\n if (this.config.suspendOnClose) {\n const { code, reason } = evt;\n this.suspendResume.suspend().then(() => this.emit('suspended', {\n initiator: 'network',\n code,\n reason,\n }));\n } else {\n this.emit('closed', evt);\n }\n }\n\n /**\n * Event handler for the RPC message event.\n * @private\n * @param {Object} response JSONRPC response.\n */\n onRpcMessage(response) {\n if (this.suspendResume.isSuspended) {\n return;\n }\n if (response.change) {\n response.change.forEach((handle) => this.emitHandleChanged(handle));\n }\n if (response.close) {\n response.close.forEach((handle) => this.emitHandleClosed(handle));\n }\n }\n\n /**\n * Event handler for the RPC notification event.\n * @private\n * @emits Session#notification\n * @param {Object} response The JSONRPC notification.\n */\n onRpcNotification(response) {\n this.emit('notification:*', response.method, response.params);\n this.emit(`notification:${response.method}`, response.params);\n }\n\n /**\n * Event handler for the RPC traffic event.\n * @private\n * @emits Session#traffic\n * @param {String} dir The traffic direction, sent or received.\n * @param {Object} data JSONRPC request/response/WebSocket message.\n * @param {Number} handle The associated handle.\n */\n onRpcTraffic(dir, data, handle) {\n this.emit('traffic:*', dir, data);\n this.emit(`traffic:${dir}`, data);\n const api = this.apis.getApi(handle);\n if (api) {\n api.emit('traffic:*', dir, data);\n api.emit(`traffic:${dir}`, data);\n }\n }\n\n /**\n * Event handler for cleaning up API instances when a session has been closed.\n * @private\n * @emits API#closed\n */\n onSessionClosed() {\n this.apis.getApis().forEach((entry) => {\n entry.api.emit('closed');\n entry.api.removeAllListeners();\n });\n this.apis.clear();\n }\n\n /**\n * Function used to get an API for a backend object.\n * @private\n * @param {Object} args Arguments used to create object API.\n * @param {Number} args.handle Handle of the backend object.\n * @param {String} args.id ID of the backend object.\n * @param {String} args.type QIX type of the backend object. Can for example\n * be \"Doc\" or \"GenericVariable\".\n * @param {String} args.genericType Custom type of the backend object, if defined in qInfo.\n * @returns {Object} Returns the generated and possibly augmented API.\n */\n getObjectApi(args) {\n const {\n handle, id, type, genericType,\n } = args;\n let api = this.apis.getApi(handle);\n if (api) {\n return api;\n }\n const factory = this.definition.generate(type);\n api = factory(this, handle, id, genericType);\n this.apis.add(handle, api);\n return api;\n }\n\n /**\n * Establishes the websocket against the configured URL and returns the Global instance.\n * @emits Session#opened\n * @returns {Promise} Eventually resolved if the connection was successful.\n * @example Opening a sesssion\n * session.open().then(() => {\n * console.log('Session was opened');\n * });\n */\n open() {\n /**\n * Handle opened state. This event is triggered whenever the websocket is connected and\n * ready for communication.\n * @event Session#opened\n * @type {Object}\n * @example Bind the session opened event\n * session.on('opened', () => {\n * console.log('Session was opened');\n * });\n */\n if (!this.globalPromise) {\n const args = {\n handle: -1,\n id: 'Global',\n type: 'Global',\n genericType: 'Global',\n };\n this.globalPromise = this.rpc.open()\n .then(() => this.getObjectApi(args))\n .then((global) => {\n this.emit('opened');\n return global;\n });\n }\n return this.globalPromise;\n }\n\n /**\n * Function used to send data on the RPC socket.\n * @param {Object} request The request to be sent. (data and some meta info)\n * @returns {Object} Returns a promise instance.\n */\n send(request) {\n if (this.suspendResume.isSuspended) {\n return this.Promise.reject(createEnigmaError(errorCodes.SESSION_SUSPENDED, 'Session suspended'));\n }\n request.id = this.rpc.createRequestId();\n const promise = this.intercept.executeRequests(this, this.Promise.resolve(request))\n .then((augmentedRequest) => {\n const data = { ...this.config.protocol, ...augmentedRequest };\n // the outKey value is used by multiple-out interceptor, at some point\n // we need to refactor that implementation and figure out how to transport\n // this value without hijacking the JSONRPC request object:\n delete data.outKey;\n const response = this.rpc.send(data);\n augmentedRequest.retry = () => this.send(request);\n return this.intercept.executeResponses(this, response, augmentedRequest);\n });\n Session.addToPromiseChain(promise, 'requestId', request.id);\n return promise;\n }\n\n /**\n * Suspends the enigma.js session by closing the websocket and rejecting all method calls\n * until is has been resumed again.\n * @emits Session#suspended\n * @param {Number} [code=4000] - The reason code for suspending the connection.\n * @param {String} [reason=\"\"] - The human readable string describing\n * why the connection is suspended.\n * @returns {Promise} Eventually resolved when the websocket has been closed.\n * @example Suspending a session\n * session.suspend().then(() => {\n * console.log('Session was suspended');\n * });\n */\n suspend(code = 4000, reason = '') {\n return this.suspendResume.suspend(code, reason)\n .then(() => this.emit('suspended', { initiator: 'manual', code, reason }));\n }\n\n /**\n * Resumes a previously suspended enigma.js session by re-creating the websocket and,\n * if possible, re-open the document as well as refreshing the internal cashes. If successful,\n * changed events will be triggered on all generated APIs, and on the ones it was unable to\n * restore, the closed event will be triggered.\n * @emits Session#resumed\n * @param {Boolean} onlyIfAttached If true, resume only if the session was re-attached properly.\n * @returns {Promise} Eventually resolved when the websocket (and potentially the\n * previously opened document, and generated APIs) has been restored, rejected when it fails any\n * of those steps, or when onlyIfAttached is true and a new session was created.\n * @example Resuming a session\n * session.resume(true).then(() => {\n * console.log('Session was resumed by re-attaching');\n * });\n */\n resume(onlyIfAttached) {\n /**\n * Handle resumed state. This event is triggered when the session was properly resumed. It is\n * useful in scenarios where you for example can close blocking modal dialogs and allow the user\n * to interact with your application again.\n * @event Session#resumed\n * @type {Object}\n * @example Handling session resumed\n * session.on('resumed', () => {\n * console.log('Session was resumed, we can close that \"reconnecting\" dialog now');\n * });\n */\n return this.suspendResume.resume(onlyIfAttached).then((value) => {\n this.emit('resumed');\n return value;\n });\n }\n\n /**\n * Closes the websocket and cleans up internal caches, also triggers the closed event\n * on all generated APIs. Note that you have to manually invoke this when you want to\n * close a session and config.suspendOnClose is true.\n * @emits Session#closed\n * @param {Number} [code=1000] - The reason code for closing the connection.\n * @param {String} [reason=\"\"] - The human readable string describing why the connection is closed.\n * @returns {Promise} Eventually resolved when the websocket has been closed.\n * @example Closing a session\n * session.close().then(() => {\n * console.log('Session was closed');\n * });\n */\n close(code = 1000, reason = '') {\n /**\n * Handle closed state. This event is triggered when the underlying websocket is closed and\n * config.suspendOnClose is false.\n * @event Session#closed\n * @type {Object}\n * @example Handling session closed\n * session.on('closed', () => {\n * console.log('Session was closed, clean up!');\n * });\n */\n this.globalPromise = undefined;\n return this.rpc.close(code, reason).then((evt) => this.emit('closed', evt));\n }\n\n /**\n * Given a handle, this function will emit the 'changed' event on the\n * corresponding API instance.\n * @private\n * @param {Number} handle The handle of the API instance.\n * @emits API#changed\n */\n emitHandleChanged(handle) {\n const api = this.apis.getApi(handle);\n if (api) {\n api.emit('changed');\n }\n }\n\n /**\n * Given a handle, this function will emit the 'closed' event on the\n * corresponding API instance.\n * @private\n * @param {Number} handle The handle of the API instance.\n * @emits API#closed\n */\n emitHandleClosed(handle) {\n const api = this.apis.getApi(handle);\n if (api) {\n api.emit('closed');\n api.removeAllListeners();\n }\n }\n\n /**\n * Function used to add info on the promise chain.\n * @private\n * @param {Promise} promise The promise to add info on.\n * @param {String} name The property to add info on.\n * @param {Any} value The info to add.\n */\n static addToPromiseChain(promise, name, value) {\n promise[name] = value;\n const { then } = promise;\n promise.then = function patchedThen(...params) {\n const chain = then.apply(this, params);\n Session.addToPromiseChain(chain, name, value);\n return chain;\n };\n }\n}\n\nexport default Session;\n","import createEnigmaError from './error';\nimport errorCodes from './error-codes';\n\n/**\n* Key-value cache\n* @private\n*/\nclass KeyValueCache {\n constructor() {\n this.entries = {};\n }\n\n /**\n * Adds an entry.\n * @private\n * @function KeyValueCache#add\n * @param {String} key The key representing an entry.\n * @param {*} entry The entry to be added.\n */\n add(key, entry) {\n key += '';\n if (typeof this.entries[key] !== 'undefined') {\n throw createEnigmaError(errorCodes.ENTRY_ALREADY_DEFINED, `Entry already defined with key ${key}`);\n }\n this.entries[key] = entry;\n }\n\n /**\n * Sets an entry.\n * @private\n * @function KeyValueCache#set\n * @param {String} key The key representing an entry.\n * @param {*} entry The entry.\n */\n set(key, entry) {\n key += '';\n this.entries[key] = entry;\n }\n\n /**\n * Removes an entry.\n * @private\n * @function KeyValueCache#remove\n * @param {String} key The key representing an entry.\n */\n remove(key) {\n delete this.entries[key];\n }\n\n /**\n * Gets an entry.\n * @private\n * @function KeyValueCache#get\n * @param {String} key The key representing an entry.\n * @returns {*} The entry for the key.\n */\n get(key) {\n return this.entries[key];\n }\n\n /**\n * Gets a list of all entries.\n * @private\n * @function KeyValueCache#getAll\n * @returns {Array} The list of entries including its `key` and `value` properties.\n */\n getAll() {\n return Object.keys(this.entries).map((key) => ({\n key,\n value: this.entries[key],\n }));\n }\n\n /**\n * Gets a key for an entry.\n * @private\n * @function KeyValueCache#getKey\n * @param {*} entry The entry to locate the key for.\n * @returns {String} The key representing an entry.\n */\n getKey(entry) {\n return Object.keys(this.entries).filter((key) => this.entries[key] === entry)[0];\n }\n\n /**\n * Clears the cache of all entries.\n * @private\n * @function KeyValueCache#clear\n */\n clear() {\n this.entries = {};\n }\n}\n\nexport default KeyValueCache;\n","import KeyValueCache from './key-value-cache';\nimport Events from './event-emitter';\n\nimport createEnigmaError from './error';\nimport errorCodes from './error-codes';\n\nconst { hasOwnProperty } = Object.prototype;\n\n/**\n* Returns the camelCase counterpart of a symbol.\n* @private\n* @param {String} symbol The symbol.\n* @return the camelCase counterpart.\n*/\nfunction toCamelCase(symbol) {\n return symbol.substring(0, 1).toLowerCase() + symbol.substring(1);\n}\n\n/**\n * A facade function that allows parameters to be passed either by name\n * (through an object), or by position (through an array).\n * @private\n * @param {Function} base The function that is being overriden. Will be\n * called with parameters in array-form.\n * @param {Object} defaults Parameter list and it's default values.\n * @param {*} params The parameters.\n */\nfunction namedParamFacade(base, defaults, ...params) {\n if (params.length === 1 && typeof params[0] === 'object' && !Array.isArray(params[0])) {\n const valid = Object.keys(params[0]).every((key) => hasOwnProperty.call(defaults, key));\n if (valid) {\n params = Object.keys(defaults).map((key) => params[0][key] || defaults[key]);\n }\n }\n return base.apply(this, params);\n}\n\n/**\n* Qix schema definition.\n* @private\n*/\nclass Schema {\n /**\n * Create a new schema instance.\n * @private\n * @param {Configuration} config The configuration for QIX.\n */\n constructor(config) {\n this.config = config;\n this.Promise = config.Promise;\n this.schema = config.schema;\n this.mixins = new KeyValueCache();\n this.types = new KeyValueCache();\n }\n\n registerMixin({\n types, type, extend, override, init,\n }) {\n if (!Array.isArray(types)) {\n types = [types];\n }\n // to support a single type\n if (type) {\n types.push(type);\n }\n const cached = { extend, override, init };\n types.forEach((typeKey) => {\n const entryList = this.mixins.get(typeKey);\n if (entryList) {\n entryList.push(cached);\n } else {\n this.mixins.add(typeKey, [cached]);\n }\n });\n }\n\n /**\n * Function used to generate a type definition.\n * @private\n * @param {String} type The type.\n * @returns {{create: Function, def: Object}} Returns an object with a definition\n * of the type and a create factory.\n */\n generate(type) {\n const entry = this.types.get(type);\n if (entry) {\n return entry;\n }\n if (!this.schema.structs[type]) {\n throw createEnigmaError(errorCodes.SCHEMA_STRUCT_TYPE_NOT_FOUND, `${type} not found`);\n }\n const factory = this.generateApi(type, this.schema.structs[type]);\n this.types.add(type, factory);\n return factory;\n }\n\n /**\n * Function used to generate an API definition for a given type.\n * @private\n * @param {String} type The type to generate.\n * @param {Object} schema The schema describing the type.\n * @returns {{create: (function(session:Object, handle:Number, id:String,\n * customKey:String)), def: Object}} Returns the API definition.\n */\n generateApi(type, schema) {\n const api = Object.create({});\n\n this.generateDefaultApi(api, schema); // Generate default\n this.mixinType(type, api); // Mixin default type\n this.mixinNamedParamFacade(api, schema); // Mixin named parameter support\n\n return function create(session, handle, id, customKey) {\n const instance = Object.create(api);\n\n Events.mixin(instance); // Always mixin event-emitter per instance\n\n Object.defineProperties(instance, {\n session: {\n enumerable: true,\n value: session,\n },\n handle: {\n enumerable: true,\n value: handle,\n writable: true,\n },\n id: {\n enumerable: true,\n value: id,\n },\n type: {\n enumerable: true,\n value: type,\n },\n genericType: {\n enumerable: true,\n value: customKey,\n },\n });\n\n let mixinList = this.mixins.get(type) || [];\n if (customKey !== type) {\n this.mixinType(customKey, instance); // Mixin custom types\n mixinList = mixinList.concat(this.mixins.get(customKey) || []);\n }\n mixinList.forEach((mixin) => {\n if (typeof mixin.init === 'function') {\n mixin.init({ config: this.config, api: instance });\n }\n });\n\n return instance;\n }.bind(this);\n }\n\n /**\n * Function used to generate the methods with the right handlers to the object\n * API that is being generated.\n * @private\n * @param {Object} api The object API that is currently being generated.\n * @param {Object} schema The API definition.\n */\n generateDefaultApi(api, schema) {\n Object.keys(schema).forEach((method) => {\n const out = schema[method].Out;\n const outKey = out.length === 1 ? out[0].Name : -1;\n const fnName = toCamelCase(method);\n\n api[fnName] = function generatedMethod(...params) {\n return this.session.send({\n handle: this.handle,\n method,\n params,\n outKey,\n });\n };\n });\n }\n\n /**\n * Function used to add mixin methods to a specified API.\n * @private\n * @param {String} type Used to specify which mixin should be woven in.\n * @param {Object} api The object that will be woven.\n */\n mixinType(type, api) {\n const mixinList = this.mixins.get(type);\n if (mixinList) {\n mixinList.forEach(({ extend = {}, override = {} }) => {\n Object.keys(override).forEach((key) => {\n if (typeof api[key] === 'function' && typeof override[key] === 'function') {\n const baseFn = api[key];\n api[key] = function wrappedFn(...args) {\n return override[key].apply(this, [baseFn.bind(this), ...args]);\n };\n } else {\n throw createEnigmaError(errorCodes.SCHEMA_MIXIN_CANT_OVERRIDE_FUNCTION, `No function to override. Type: ${type} function: ${key}`);\n }\n });\n Object.keys(extend).forEach((key) => {\n // handle overrides\n if (typeof api[key] === 'function' && typeof extend[key] === 'function') {\n throw createEnigmaError(errorCodes.SCHEMA_MIXIN_EXTEND_NOT_ALLOWED, `Extend is not allowed for this mixin. Type: ${type} function: ${key}`);\n } else {\n api[key] = extend[key];\n }\n });\n });\n }\n }\n\n /**\n * Function used to mixin the named parameter facade.\n * @private\n * @param {Object} api The object API that is currently being generated.\n * @param {Object} schema The API definition.\n */\n mixinNamedParamFacade(api, schema) {\n Object.keys(schema).forEach((key) => {\n const fnName = toCamelCase(key);\n const base = api[fnName];\n const defaults = schema[key].In.reduce((result, item) => {\n result[item.Name] = item.DefaultValue;\n return result;\n }, {});\n\n api[fnName] = function namedParamWrapper(...params) {\n return namedParamFacade.apply(this, [base, defaults, ...params]);\n };\n });\n }\n}\n\nexport default Schema;\n","import Events from './event-emitter';\n\n/**\n * Helper class for handling RPC calls\n * @private\n */\nclass RPCResolver {\n constructor(id, handle, resolve, reject) {\n Events.mixin(this);\n this.id = id;\n this.handle = handle;\n this.resolve = resolve;\n this.reject = reject;\n }\n\n resolveWith(data) {\n this.resolve(data);\n this.emit('resolved', this.id);\n }\n\n rejectWith(err) {\n this.reject(err);\n this.emit('rejected', this.id);\n }\n}\n\nexport default RPCResolver;\n","import Events from './event-emitter';\nimport RPCResolver from './rpc-resolver';\n\nimport createEnigmaError from './error';\nimport errorCodes from './error-codes';\n\n/**\n* This class handles remote procedure calls on a web socket.\n* @private\n*/\nclass RPC {\n /**\n * Create a new RPC instance.\n * @private\n * @param {Object} options The configuration options for this class.\n * @param {Function} options.Promise The promise constructor to use.\n * @param {String} options.url The complete websocket URL used to connect.\n * @param {Function} options.createSocket The function callback to create a WebSocket.\n */\n constructor(options) {\n Object.assign(this, options);\n Events.mixin(this);\n this.resolvers = {};\n this.requestId = 0;\n this.openedPromise = undefined;\n }\n\n /**\n * Opens a connection to the configured endpoint.\n * @private\n * @param {Boolean} force - ignores all previous and outstanding open calls if set to true.\n * @returns {Object} A promise instance.\n */\n open(force = false) {\n if (!force && this.openedPromise) {\n return this.openedPromise;\n }\n\n try {\n this.socket = this.createSocket(this.url);\n } catch (err) {\n return this.Promise.reject(err);\n }\n\n this.socket.onopen = this.onOpen.bind(this);\n this.socket.onclose = this.onClose.bind(this);\n this.socket.onerror = this.onError.bind(this);\n this.socket.onmessage = this.onMessage.bind(this);\n this.openedPromise = new this.Promise((resolve, reject) => this.registerResolver('opened', null, resolve, reject));\n this.closedPromise = new this.Promise((resolve, reject) => this.registerResolver('closed', null, resolve, reject));\n return this.openedPromise;\n }\n\n /**\n * Resolves the open promise when a connection is successfully established.\n * @private\n */\n onOpen() {\n this.resolvers.opened.resolveWith(() => this.closedPromise);\n }\n\n /**\n * Resolves the close promise when a connection is closed.\n * @private\n * @param {Object} event - The event describing close.\n */\n onClose(event) {\n this.emit('closed', event);\n if (this.resolvers && this.resolvers.closed) {\n this.resolvers.closed.resolveWith(event);\n }\n this.rejectAllOutstandingResolvers(createEnigmaError(errorCodes.NOT_CONNECTED, 'Socket closed'));\n }\n\n /**\n * Closes a connection.\n * @private\n * @param {Number} [code=1000] - The reason code for closing the connection.\n * @param {String} [reason=\"\"] - The human readable string describing why the connection is closed.\n * @returns {Object} Returns a promise instance.\n */\n close(code = 1000, reason = '') {\n if (this.socket) {\n this.socket.close(code, reason);\n this.socket = null;\n }\n return this.closedPromise;\n }\n\n /**\n * Emits an error event and rejects the open promise if an error is raised on the connection.\n * @private\n * @param {Object} event - The event describing the error.\n */\n onError(event) {\n if (this.resolvers.opened) {\n this.resolvers.opened.rejectWith(event);\n } else {\n // only emit errors after the initial open promise has been resolved,\n // this makes it possible to catch early websocket errors as well\n // as run-time ones:\n this.emit('socket-error', event);\n }\n this.rejectAllOutstandingResolvers(createEnigmaError(errorCodes.NOT_CONNECTED, 'Socket error'));\n }\n\n /**\n * Parses the onMessage event on the connection and resolve the promise for the request.\n * @private\n * @param {Object} event - The event describing the message.\n */\n onMessage(event) {\n const data = JSON.parse(event.data);\n const resolver = this.resolvers[data.id] || {};\n this.emit('traffic', 'received', data, resolver.handle);\n if (typeof data.id !== 'undefined') {\n this.emit('message', data);\n this.resolvers[data.id].resolveWith(data);\n } else {\n this.emit(data.params ? 'notification' : 'message', data);\n }\n }\n\n /**\n * Rejects all outstanding resolvers.\n * @private\n * @param {Object} reason - The reject reason.\n */\n rejectAllOutstandingResolvers(reason) {\n Object.keys(this.resolvers).forEach((id) => {\n if (id === 'opened' || id === 'closed') {\n return; // \"opened\" and \"closed\" should not be handled here\n }\n const resolver = this.resolvers[id];\n resolver.rejectWith(reason);\n });\n }\n\n /**\n * Unregisters a resolver.\n * @private\n * @param {Number|String} id - The ID to unregister the resolver with.\n */\n unregisterResolver(id) {\n const resolver = this.resolvers[id];\n resolver.removeAllListeners();\n delete this.resolvers[id];\n }\n\n /**\n * Registers a resolver.\n * @private\n * @param {Number|String} id - The ID to register the resolver with.\n * @param {Number} handle - The associated handle.\n * @returns {Function} The promise executor function.\n */\n registerResolver(id, handle, resolve, reject) {\n const resolver = new RPCResolver(id, handle, resolve, reject);\n this.resolvers[id] = resolver;\n resolver.on('resolved', (resolvedId) => this.unregisterResolver(resolvedId));\n resolver.on('rejected', (rejectedId) => this.unregisterResolver(rejectedId));\n }\n\n /**\n * Sends data on the socket.\n * @private\n * @param {Object} data - The data to send.\n * @returns {Object} A promise instance.\n */\n send(data) {\n if (!this.socket || this.socket.readyState !== this.socket.OPEN) {\n const error = createEnigmaError(errorCodes.NOT_CONNECTED, 'Not connected');\n return this.Promise.reject(error);\n }\n if (!data.id) {\n data.id = this.createRequestId();\n }\n data.jsonrpc = '2.0';\n return new this.Promise((resolve, reject) => {\n this.socket.send(JSON.stringify(data));\n this.emit('traffic', 'sent', data, data.handle);\n return this.registerResolver(data.id, data.handle, resolve, reject);\n });\n }\n\n createRequestId() {\n this.requestId += 1;\n return this.requestId;\n }\n}\n\nexport default RPC;\n","import createEnigmaError from './error';\nimport errorCodes from './error-codes';\n\nconst ON_ATTACHED_TIMEOUT_MS = 5000;\nconst RPC_CLOSE_MANUAL_SUSPEND = 4000;\n\nclass SuspendResume {\n /**\n * Creates a new SuspendResume instance.\n * @private\n * @param {Object} options The configuration option for this class.\n * @param {Promise} options.Promise The promise constructor to use.\n * @param {RPC} options.rpc The RPC instance to use when communicating towards Engine.\n * @param {ApiCache} options.apis The ApiCache instance to use.\n */\n constructor(options) {\n Object.assign(this, options);\n this.isSuspended = false;\n this.rpc.on('traffic', (dir, data) => {\n if (dir === 'sent' && data.method === 'OpenDoc') {\n this.openDocParams = data.params;\n }\n });\n }\n\n /**\n * Function used to restore the rpc connection.\n * @private\n * @param {Boolean} onlyIfAttached - if true, the returned promise will resolve\n * only if the session can be re-attached.\n * @returns {Object} Returns a promise instance.\n */\n restoreRpcConnection(onlyIfAttached) {\n return this.reopen(ON_ATTACHED_TIMEOUT_MS).then((sessionState) => {\n if (sessionState === 'SESSION_CREATED' && onlyIfAttached) {\n return this.Promise.reject(createEnigmaError(errorCodes.SESSION_NOT_ATTACHED, 'Not attached'));\n }\n return this.Promise.resolve();\n });\n }\n\n /**\n * Function used to restore the global API.\n * @private\n * @param {Object} changed - A list where the restored APIs will be added.\n * @returns {Object} Returns a promise instance.\n */\n restoreGlobal(changed) {\n const global = this.apis.getApisByType('Global').pop();\n changed.push(global.api);\n return this.Promise.resolve();\n }\n\n /**\n * Function used to restore the doc API.\n * @private\n * @param {String} sessionState - The state of the session, attached or created.\n * @param {Array} closed - A list where the closed of APIs APIs will be added.\n * @param {Object} changed - A list where the restored APIs will be added.\n * @returns {Object} Returns a promise instance.\n */\n restoreDoc(closed, changed) {\n const doc = this.apis.getApisByType('Doc').pop();\n\n if (!doc) {\n return this.Promise.resolve();\n }\n\n return this.rpc.send({\n method: 'GetActiveDoc',\n handle: -1,\n params: [],\n }).then((response) => {\n if (response.error && this.openDocParams) {\n return this.rpc.send({\n method: 'OpenDoc',\n handle: -1,\n params: this.openDocParams,\n });\n }\n return response;\n }).then((response) => {\n if (response.error) {\n closed.push(doc.api);\n return this.Promise.resolve();\n }\n const handle = response.result.qReturn.qHandle;\n doc.api.handle = handle;\n changed.push(doc.api);\n return this.Promise.resolve(doc.api);\n });\n }\n\n /**\n * Function used to restore the APIs on the doc.\n * @private\n * @param {Object} doc - The doc API on which the APIs we want to restore exist.\n * @param {Array} closed - A list where the closed of APIs APIs will be added.\n * @param {Object} changed - A list where the restored APIs will be added.\n * @returns {Object} Returns a promise instance.\n */\n restoreDocObjects(doc, closed, changed) {\n const tasks = [];\n const apis = this.apis.getApis()\n .map((entry) => entry.api)\n .filter((api) => api.type !== 'Global' && api.type !== 'Doc');\n\n if (!doc) {\n apis.forEach((api) => closed.push(api));\n return this.Promise.resolve();\n }\n\n apis.forEach((api) => {\n const method = SuspendResume.buildGetMethodName(api.type);\n\n if (!method) {\n closed.push(api);\n } else {\n const request = this.rpc.send({\n method,\n handle: doc.handle,\n params: [api.id],\n }).then((response) => {\n if (response.error || !response.result.qReturn.qHandle) {\n closed.push(api);\n } else {\n api.handle = response.result.qReturn.qHandle;\n changed.push(api);\n }\n });\n tasks.push(request);\n }\n });\n return this.Promise.all(tasks);\n }\n\n /**\n * Set the instance as suspended.\n * @private\n * @param {Number} [code=4000] - The reason code for suspending the connection.\n * @param {String} [reason=\"\"] - The human readable string describing\n * why the connection is suspended.\n */\n suspend(code = RPC_CLOSE_MANUAL_SUSPEND, reason = '') {\n this.isSuspended = true;\n return this.rpc.close(code, reason);\n }\n\n /**\n * Resumes a previously suspended RPC connection, and refreshes the API cache.\n * APIs unabled to be restored has their 'closed'\n * event triggered, otherwise 'changed'.\n * @private\n * @emits API#changed\n * @emits APIfunction@#closed\n * @param {Boolean} onlyIfAttached if true, resume only if the session was re-attached.\n * @returns {Promise} Eventually resolved if the RPC connection was successfully resumed,\n * otherwise rejected.\n */\n resume(onlyIfAttached) {\n const changed = [];\n const closed = [];\n\n return this.restoreRpcConnection(onlyIfAttached)\n .then(() => this.restoreGlobal(changed))\n .then(() => this.restoreDoc(closed, changed))\n .then((doc) => this.restoreDocObjects(doc, closed, changed))\n .then(() => {\n this.isSuspended = false;\n this.apis.clear();\n closed.forEach((api) => {\n api.emit('closed');\n api.removeAllListeners();\n });\n changed.forEach((api) => {\n this.apis.add(api.handle, api);\n if (api.type !== 'Global') {\n api.emit('changed');\n }\n });\n })\n .catch((err) => this.rpc.close().then(() => this.Promise.reject(err)));\n }\n\n /**\n * Reopens the connection and waits for the OnConnected notification.\n * @private\n * @param {Number} timeout - The time to wait for the OnConnected notification.\n * @returns {Object} A promise containing the session state (SESSION_CREATED or SESSION_ATTACHED).\n */\n reopen(timeout) {\n let timer;\n let notificationResolve;\n let notificationReceived = false;\n const notificationPromise = new this.Promise((resolve) => { notificationResolve = resolve; });\n\n const waitForNotification = () => {\n if (!notificationReceived) {\n timer = setTimeout(() => notificationResolve('SESSION_CREATED'), timeout);\n }\n return notificationPromise;\n };\n\n const onNotification = (data) => {\n if (data.method !== 'OnConnected') return;\n clearTimeout(timer);\n notificationResolve(data.params.qSessionState);\n notificationReceived = true;\n };\n\n this.rpc.on('notification', onNotification);\n\n return this.rpc.open(true)\n .then(waitForNotification)\n .then((state) => {\n this.rpc.removeListener('notification', onNotification);\n return state;\n })\n .catch((err) => {\n this.rpc.removeListener('notification', onNotification);\n return this.Promise.reject(err);\n });\n }\n\n /**\n * Function used to build the get method names for Doc APIs.\n * @private\n * @param {String} type - The API type.\n * @returns {String} Returns the get method name, or undefined if the type cannot be restored.\n */\n static buildGetMethodName(type) {\n if (type === 'Field' || type === 'Variable') {\n return null;\n }\n if (type === 'GenericVariable') {\n return 'GetVariableById';\n }\n return type.replace('Generic', 'Get');\n }\n}\n\nexport default SuspendResume;\n","const SUCCESS_KEY = 'qSuccess';\n\nexport default function deltaRequestInterceptor(session, request) {\n const delta = session.config.protocol.delta\n && request.outKey !== -1\n && request.outKey !== SUCCESS_KEY;\n if (delta) {\n request.delta = delta;\n }\n return request;\n}\n","import createEnigmaError from '../error';\nimport errorCodes from '../error-codes';\n\n/**\n* Response interceptor for generating APIs. Handles the quirks of engine not\n* returning an error when an object is missing.\n* @private\n* @param {Session} session - The session the intercept is being executed on.\n* @param {Object} request - The JSON-RPC request.\n* @param {Object} response - The response.\n* @returns {Object} - Returns the generated API\n*/\nexport default function apiResponseInterceptor(session, request, response) {\n if (response.qHandle && response.qType) {\n return session.getObjectApi({\n handle: response.qHandle,\n type: response.qType,\n id: response.qGenericId,\n genericType: response.qGenericType,\n });\n }\n if (response.qHandle === null && response.qType === null) {\n const error = createEnigmaError(errorCodes.OBJECT_NOT_FOUND, 'Object not found');\n return session.config.Promise.reject(error);\n }\n return response;\n}\n","'use strict';\n\nvar hasOwn = Object.prototype.hasOwnProperty;\nvar toStr = Object.prototype.toString;\nvar defineProperty = Object.defineProperty;\nvar gOPD = Object.getOwnPropertyDescriptor;\n\nvar isArray = function isArray(arr) {\n\tif (typeof Array.isArray === 'function') {\n\t\treturn Array.isArray(arr);\n\t}\n\n\treturn toStr.call(arr) === '[object Array]';\n};\n\nvar isPlainObject = function isPlainObject(obj) {\n\tif (!obj || toStr.call(obj) !== '[object Object]') {\n\t\treturn false;\n\t}\n\n\tvar hasOwnConstructor = hasOwn.call(obj, 'constructor');\n\tvar hasIsPrototypeOf = obj.constructor && obj.constructor.prototype && hasOwn.call(obj.constructor.prototype, 'isPrototypeOf');\n\t// Not own constructor property must be Object\n\tif (obj.constructor && !hasOwnConstructor && !hasIsPrototypeOf) {\n\t\treturn false;\n\t}\n\n\t// Own properties are enumerated firstly, so to speed up,\n\t// if last one is own, then all properties are own.\n\tvar key;\n\tfor (key in obj) { /**/ }\n\n\treturn typeof key === 'undefined' || hasOwn.call(obj, key);\n};\n\n// If name is '__proto__', and Object.defineProperty is available, define __proto__ as an own property on target\nvar setProperty = function setProperty(target, options) {\n\tif (defineProperty && options.name === '__proto__') {\n\t\tdefineProperty(target, options.name, {\n\t\t\tenumerable: true,\n\t\t\tconfigurable: true,\n\t\t\tvalue: options.newValue,\n\t\t\twritable: true\n\t\t});\n\t} else {\n\t\ttarget[options.name] = options.newValue;\n\t}\n};\n\n// Return undefined instead of __proto__ if '__proto__' is not an own property\nvar getProperty = function getProperty(obj, name) {\n\tif (name === '__proto__') {\n\t\tif (!hasOwn.call(obj, name)) {\n\t\t\treturn void 0;\n\t\t} else if (gOPD) {\n\t\t\t// In early versions of node, obj['__proto__'] is buggy when obj has\n\t\t\t// __proto__ as an own property. Object.getOwnPropertyDescriptor() works.\n\t\t\treturn gOPD(obj, name).value;\n\t\t}\n\t}\n\n\treturn obj[name];\n};\n\nmodule.exports = function extend() {\n\tvar options, name, src, copy, copyIsArray, clone;\n\tvar target = arguments[0];\n\tvar i = 1;\n\tvar length = arguments.length;\n\tvar deep = false;\n\n\t// Handle a deep copy situation\n\tif (typeof target === 'boolean') {\n\t\tdeep = target;\n\t\ttarget = arguments[1] || {};\n\t\t// skip the boolean and the target\n\t\ti = 2;\n\t}\n\tif (target == null || (typeof target !== 'object' && typeof target !== 'function')) {\n\t\ttarget = {};\n\t}\n\n\tfor (; i < length; ++i) {\n\t\toptions = arguments[i];\n\t\t// Only deal with non-null/undefined values\n\t\tif (options != null) {\n\t\t\t// Extend the base object\n\t\t\tfor (name in options) {\n\t\t\t\tsrc = getProperty(target, name);\n\t\t\t\tcopy = getProperty(options, name);\n\n\t\t\t\t// Prevent never-ending loop\n\t\t\t\tif (target !== copy) {\n\t\t\t\t\t// Recurse if we're merging plain objects or arrays\n\t\t\t\t\tif (deep && copy && (isPlainObject(copy) || (copyIsArray = isArray(copy)))) {\n\t\t\t\t\t\tif (copyIsArray) {\n\t\t\t\t\t\t\tcopyIsArray = false;\n\t\t\t\t\t\t\tclone = src && isArray(src) ? src : [];\n\t\t\t\t\t\t} else {\n\t\t\t\t\t\t\tclone = src && isPlainObject(src) ? src : {};\n\t\t\t\t\t\t}\n\n\t\t\t\t\t\t// Never move original objects, clone them\n\t\t\t\t\t\tsetProperty(target, { name: name, newValue: extend(deep, clone, copy) });\n\n\t\t\t\t\t// Don't bring in undefined values\n\t\t\t\t\t} else if (typeof copy !== 'undefined') {\n\t\t\t\t\t\tsetProperty(target, { name: name, newValue: copy });\n\t\t\t\t\t}\n\t\t\t\t}\n\t\t\t}\n\t\t}\n\t}\n\n\t// Return the modified object\n\treturn target;\n};\n","import originalExtend from 'extend';\n\nimport createEnigmaError from './error';\nimport errorCodes from './error-codes';\n\nconst extend = originalExtend.bind(null, true);\nconst JSONPatch = {};\nconst { isArray } = Array;\nfunction isObject(v) { return v != null && !Array.isArray(v) && typeof v === 'object'; }\nfunction isUndef(v) { return typeof v === 'undefined'; }\nfunction isFunction(v) { return typeof v === 'function'; }\n\n/**\n* Generate an exact duplicate (with no references) of a specific value.\n*\n* @private\n* @param {Object} The value to duplicate\n* @returns {Object} a unique, duplicated value\n*/\nfunction generateValue(val) {\n if (val) {\n return extend({}, { val }).val;\n }\n return val;\n}\n\n/**\n* An additional type checker used to determine if the property is of internal\n* use or not a type that can be translated into JSON (like functions).\n*\n* @private\n* @param {Object} obj The object which has the property to check\n* @param {String} The property name to check\n* @returns {Boolean} Whether the property is deemed special or not\n*/\nfunction isSpecialProperty(obj, key) {\n return isFunction(obj[key])\n || key.substring(0, 2) === '$$'\n || key.substring(0, 1) === '_';\n}\n\n/**\n* Finds the parent object from a JSON-Pointer (\"/foo/bar/baz\" = \"bar\" is \"baz\" parent),\n* also creates the object structure needed.\n*\n* @private\n* @param {Object} data The root object to traverse through\n* @param {String} The JSON-Pointer string to use when traversing\n* @returns {Object} The parent object\n*/\nfunction getParent(data, str) {\n const seperator = '/';\n const parts = str.substring(1).split(seperator).slice(0, -1);\n let numPart;\n\n parts.forEach((part, i) => {\n if (i === parts.length) {\n return;\n }\n numPart = +part;\n const newPart = !isNaN(numPart) ? [] : {};\n data[numPart || part] = isUndef(data[numPart || part])\n ? newPart\n : data[part];\n data = data[numPart || part];\n });\n\n return data;\n}\n\n/**\n* Cleans an object of all its properties, unless they're deemed special or\n* cannot be removed by configuration.\n*\n* @private\n* @param {Object} obj The object to clean\n*/\nfunction emptyObject(obj) {\n Object.keys(obj).forEach((key) => {\n const config = Object.getOwnPropertyDescriptor(obj, key);\n\n if (config.configurable && !isSpecialProperty(obj, key)) {\n delete obj[key];\n }\n });\n}\n\n/**\n* Compare an object with another, could be object, array, number, string, bool.\n* @private\n* @param {Object} a The first object to compare\n* @param {Object} a The second object to compare\n* @returns {Boolean} Whether the objects are identical\n*/\nfunction compare(a, b) {\n let isIdentical = true;\n\n if (isObject(a) && isObject(b)) {\n if (Object.keys(a).length !== Object.keys(b).length) {\n return false;\n }\n Object.keys(a).forEach((key) => {\n if (!compare(a[key], b[key])) {\n isIdentical = false;\n }\n });\n return isIdentical;\n }\n if (isArray(a) && isArray(b)) {\n if (a.length !== b.length) {\n return false;\n }\n for (let i = 0, l = a.length; i < l; i += 1) {\n if (!compare(a[i], b[i])) {\n return false;\n }\n }\n return true;\n }\n return a === b;\n}\n\n/**\n* Generates patches by comparing two arrays.\n*\n* @private\n* @param {Array} oldA The old (original) array, which will be patched\n* @param {Array} newA The new array, which will be used to compare against\n* @returns {Array} An array of patches (if any)\n*/\nfunction patchArray(original, newA, basePath) {\n let patches = [];\n const oldA = original.slice();\n let tmpIdx = -1;\n\n function findIndex(a, id, idx) {\n if (a[idx] && isUndef(a[idx].qInfo)) {\n return null;\n }\n if (a[idx] && a[idx].qInfo.qId === id) {\n // shortcut if identical\n return idx;\n }\n for (let ii = 0, ll = a.length; ii < ll; ii += 1) {\n if (a[ii] && a[ii].qInfo.qId === id) {\n return ii;\n }\n }\n return -1;\n }\n\n if (compare(newA, oldA)) {\n // array is unchanged\n return patches;\n }\n\n if (!isUndef(newA[0]) && isUndef(newA[0].qInfo)) {\n // we cannot create patches without unique identifiers, replace array...\n patches.push({\n op: 'replace',\n path: basePath,\n value: newA,\n });\n return patches;\n }\n\n for (let i = oldA.length - 1; i >= 0; i -= 1) {\n tmpIdx = findIndex(newA, oldA[i].qInfo && oldA[i].qInfo.qId, i);\n if (tmpIdx === -1) {\n patches.push({\n op: 'remove',\n path: `${basePath}/${i}`,\n });\n oldA.splice(i, 1);\n } else {\n patches = patches.concat(JSONPatch.generate(oldA[i], newA[tmpIdx], `${basePath}/${i}`));\n }\n }\n\n for (let i = 0, l = newA.length; i < l; i += 1) {\n tmpIdx = findIndex(oldA, newA[i].qInfo && newA[i].qInfo.qId);\n if (tmpIdx === -1) {\n patches.push({\n op: 'add',\n path: `${basePath}/${i}`,\n value: newA[i],\n });\n oldA.splice(i, 0, newA[i]);\n } else if (tmpIdx !== i) {\n patches.push({\n op: 'move',\n path: `${basePath}/${i}`,\n from: `${basePath}/${tmpIdx}`,\n });\n oldA.splice(i, 0, oldA.splice(tmpIdx, 1)[0]);\n }\n }\n return patches;\n}\n\n/**\n* Generate an array of JSON-Patch:es following the JSON-Patch Specification Draft.\n*\n* See [specification draft](http://tools.ietf.org/html/draft-ietf-appsawg-json-patch-10)\n*\n* Does NOT currently generate patches for arrays (will replace them)\n* @private\n* @param {Object} original The object to patch to\n* @param {Object} newData The object to patch from\n* @param {String} [basePath] The base path to use when generating the paths for\n* the patches (normally not used)\n* @returns {Array} An array of patches\n*/\nJSONPatch.generate = function generate(original, newData, basePath) {\n basePath = basePath || '';\n let patches = [];\n\n Object.keys(newData).forEach((key) => {\n const val = generateValue(newData[key]);\n const oldVal = original[key];\n const tmpPath = `${basePath}/${key}`;\n\n if (compare(val, oldVal) || isSpecialProperty(newData, key)) {\n return;\n }\n if (isUndef(oldVal)) {\n // property does not previously exist\n patches.push({\n op: 'add',\n path: tmpPath,\n value: val,\n });\n } else if (isObject(val) && isObject(oldVal)) {\n // we need to generate sub-patches for this, since it already exist\n patches = patches.concat(JSONPatch.generate(oldVal, val, tmpPath));\n } else if (isArray(val) && isArray(oldVal)) {\n patches = patches.concat(patchArray(oldVal, val, tmpPath));\n } else {\n // it's a simple property (bool, string, number)\n patches.push({\n op: 'replace',\n path: `${basePath}/${key}`,\n value: val,\n });\n }\n });\n\n Object.keys(original).forEach((key) => {\n if (isUndef(newData[key]) && !isSpecialProperty(original, key)) {\n // this property does not exist anymore\n patches.push({\n op: 'remove',\n path: `${basePath}/${key}`,\n });\n }\n });\n\n return patches;\n};\n\n/**\n* Apply a list of patches to an object.\n* @private\n* @param {Object} original The object to patch\n* @param {Array} patches The list of patches to apply\n*/\nJSONPatch.apply = function apply(original, patches) {\n patches.forEach((patch) => {\n let parent = getParent(original, patch.path);\n let key = patch.path.split('/').splice(-1)[0];\n let target = key && isNaN(+key) ? parent[key] : parent[+key] || parent;\n const from = patch.from ? patch.from.split('/').splice(-1)[0] : null;\n\n if (patch.path === '/') {\n parent = null;\n target = original;\n }\n\n if (patch.op === 'add' || patch.op === 'replace') {\n if (isArray(parent)) {\n // trust indexes from patches, so don't replace the index if it's an add\n if (key === '-') {\n key = parent.length;\n }\n parent.splice(+key, patch.op === 'add' ? 0 : 1, patch.value);\n } else if (isArray(target) && isArray(patch.value)) {\n // keep array reference if possible...\n target.length = 0;\n\n const chunkSize = 1000;\n for (let i = 0; i < patch.value.length; i += chunkSize) {\n const chunk = patch.value.slice(i, i + chunkSize);\n target.push(...chunk);\n }\n } else if (isObject(target) && isObject(patch.value)) {\n // keep object reference if possible...\n emptyObject(target);\n extend(target, patch.value);\n } else if (!parent) {\n throw createEnigmaError(errorCodes.PATCH_HAS_NO_PARENT, 'Patchee is not an object we can patch');\n } else {\n // simple value\n parent[key] = patch.value;\n }\n } else if (patch.op === 'move') {\n const oldParent = getParent(original, patch.from);\n if (isArray(parent)) {\n parent.splice(+key, 0, oldParent.splice(+from, 1)[0]);\n } else {\n parent[key] = oldParent[from];\n delete oldParent[from];\n }\n } else if (patch.op === 'remove') {\n if (isArray(parent)) {\n parent.splice(+key, 1);\n } else {\n delete parent[key];\n }\n }\n });\n};\n\n/**\n* Deep clone an object.\n* @private\n* @param {Object} obj The object to clone\n* @returns {Object} A new object identical to the `obj`\n*/\nJSONPatch.clone = function clone(obj) {\n return extend({}, obj);\n};\n\n/**\n* Creates a JSON-patch.\n* @private\n* @param {String} op The operation of the patch. Available values: \"add\", \"remove\", \"move\"\n* @param {Object} [val] The value to set the `path` to. If `op` is `move`, `val`\n* is the \"from JSON-path\" path\n* @param {String} path The JSON-path for the property to change (e.g. \"/qHyperCubeDef/columnOrder\")\n* @returns {Object} A patch following the JSON-patch specification\n*/\nJSONPatch.createPatch = function createPatch(op, val, path) {\n const patch = {\n op: op.toLowerCase(),\n path,\n };\n if (patch.op === 'move') {\n patch.from = val;\n } else if (typeof val !== 'undefined') {\n patch.value = val;\n }\n return patch;\n};\n\n/**\n* Apply the differences of two objects (keeping references if possible).\n* Identical to running `JSONPatch.apply(original, JSONPatch.generate(original, newData));`\n* @private\n* @param {Object} original The object to update/patch\n* @param {Object} newData the object to diff against\n*\n* @example\n* var obj1 = { foo: [1,2,3], bar: { baz: true, qux: 1 } };\n* var obj2 = { foo: [4,5,6], bar: { baz: false } };\n* JSONPatch.updateObject(obj1, obj2);\n* // => { foo: [4,5,6], bar: { baz: false } };\n*/\nJSONPatch.updateObject = function updateObject(original, newData) {\n if (!Object.keys(original).length) {\n extend(original, newData);\n return;\n }\n JSONPatch.apply(original, JSONPatch.generate(original, newData));\n};\n\nexport default JSONPatch;\n","import JSONPatch from '../json-patch';\nimport KeyValueCache from '../key-value-cache';\n\nimport createEnigmaError from '../error';\nimport errorCodes from '../error-codes';\n\nconst sessions = {};\n\n/**\n* Function to make sure we release handle caches when they are closed.\n* @private\n* @param {Session} session The session instance to listen on.\n*/\nconst bindSession = (session) => {\n if (!sessions[session.id]) {\n const cache = {};\n sessions[session.id] = cache;\n session.on('traffic:received', (data) => data.close && data.close.forEach((handle) => delete cache[handle]));\n session.on('closed', () => delete sessions[session.id]);\n }\n};\n\n/**\n* Simple function that ensures the session events has been bound, and returns\n* either an existing key-value cache or creates one for the specified handle.\n* @private\n* @param {Session} session The session that owns the handle.\n* @param {Number} handle The object handle to retrieve the cache for.\n* @returns {KeyValueCache} The cache instance.\n*/\nconst getHandleCache = (session, handle) => {\n bindSession(session);\n const cache = sessions[session.id];\n if (!cache[handle]) {\n cache[handle] = new KeyValueCache();\n }\n return cache[handle];\n};\n\n/**\n* Function used to apply a list of patches and return the patched value.\n* @private\n* @param {Session} session The session.\n* @param {Number} handle The object handle.\n* @param {String} cacheId The cacheId.\n* @param {Array} patches The patches.\n* @returns {Object} Returns the patched value.\n*/\nconst patchValue = (session, handle, cacheId, patches) => {\n const cache = getHandleCache(session, handle);\n let entry = cache.get(cacheId);\n if (typeof entry === 'undefined') {\n entry = Array.isArray(patches[0].value) ? [] : {};\n }\n if (patches.length) {\n if (patches[0].path === '/' && typeof patches[0].value !== 'object') {\n // 'plain' values on root path is not supported (no object reference),\n // so we simply store the value directly:\n entry = patches[0].value;\n } else {\n JSONPatch.apply(entry, patches);\n }\n cache.set(cacheId, entry);\n }\n return entry;\n};\n\n/**\n* Process delta interceptor.\n* @private\n* @param {Session} session The session the intercept is being executed on.\n* @param {Object} request The JSON-RPC request.\n* @param {Object} response The response.\n* @returns {Object} Returns the patched response\n*/\nexport default function deltaResponseInterceptor(session, request, response) {\n const { delta, result } = response;\n if (delta) {\n // when delta is on the response data is expected to be an array of patches:\n Object.keys(result).forEach((key) => {\n if (!Array.isArray(result[key])) {\n throw createEnigmaError(errorCodes.EXPECTED_ARRAY_OF_PATCHES, 'Unexpected RPC response, expected array of patches');\n }\n result[key] = patchValue(session, request.handle, `${request.method}-${key}`, result[key]);\n });\n // return a cloned response object to avoid patched object references:\n return JSON.parse(JSON.stringify(response));\n }\n return response;\n}\n\n// export object reference for testing purposes:\ndeltaResponseInterceptor.sessions = sessions;\n","const RETURN_KEY = 'qReturn';\n\n/**\n* Picks out the result \"out\" parameter based on the QIX method+schema, with\n* some specific handling for some methods that breaks the predictable protocol.\n* @private\n* @param {Session} session - The session the intercept is being executed on.\n* @param {Object} request - The JSON-RPC request.\n* @param {Object} response - The response.\n* @returns {Object} - Returns the result property on the response\n*/\nexport default function outParamResponseInterceptor(session, request, response) {\n if (request.method === 'CreateSessionApp' || request.method === 'CreateSessionAppFromApp') {\n // this method returns multiple out params that we need\n // to normalize before processing the response further:\n response[RETURN_KEY].qGenericId = response.qSessionAppId || response[RETURN_KEY].qGenericId;\n } else if (request.method === 'GetInteract') {\n // this method returns a qReturn value when it should only return\n // meta.outKey:\n delete response[RETURN_KEY];\n }\n\n if (hasOwnProperty.call(response, RETURN_KEY)) {\n return response[RETURN_KEY];\n }\n if (request.outKey !== -1) {\n return response[request.outKey];\n }\n\n return response;\n}\n","import deltaRequest from './interceptors/delta-request-interceptor';\nimport apiResponse from './interceptors/api-response-interceptor';\nimport deltaResponse from './interceptors/delta-response-interceptor';\nimport errorResponse from './interceptors/error-response-interceptor';\nimport outParamResponse from './interceptors/out-param-response-interceptor';\nimport resultResponse from './interceptors/result-response-interceptor';\n\n/**\n * Interceptors is a concept similar to mixins, but run on a lower level. The interceptor concept\n * can augment either the requests (i.e. before sent to QIX Engine), or the responses (i.e. after\n * QIX Engine has sent a response). The interceptor promises runs in parallel to the regular\n * promises used in enigma.js, which means that it can be really useful when you want to normalize\n * behaviors in your application.\n * @interface Interceptor\n */\n\n/**\n * @class InterceptorRequest\n * @implements {Interceptor}\n * @example Implement a request interceptor\n * const enigma = require('enigma.js');\n * const WebSocket = require('ws');\n * const schema = require('enigma.js/schemas/12.20.0.json');\n *\n * const session = enigma.create({\n * schema,\n * url: 'ws://localhost:9076/app/engineData',\n * createSocket: (url) => new WebSocket(url),\n * requestInterceptors: [{\n * onFulfilled: function logRequest(sessionReference, request) {\n * console.log('Request being sent', request);\n * return request;\n * }\n * },\n * });\n */\n\n/**\n * @class InterceptorResponse\n * @implements {Interceptor}\n * @example Implement a request interceptor\n * const enigma = require('enigma.js');\n * const WebSocket = require('ws');\n * const schema = require('enigma.js/schemas/12.20.0.json');\n *\n * const session = enigma.create({\n * schema,\n * url: 'ws://localhost:9076/app/engineData',\n * createSocket: (url) => new WebSocket(url),\n * responseInterceptors: [{\n * onRejected: function logError(sessionReference, request, error) {\n * console.log('Error returned from QIX engine', error, 'Originating request:', request);\n * // throw error so it's continued to be rejected:\n * throw error;\n * }\n * },\n * });\n */\n\n/**\n * This method is invoked when a request is about to be sent to QIX Engine.\n * @function InterceptorRequest#onFulfilled\n * @param {Session} session The session executing the interceptor.\n * @param {Object} request The JSON-RPC request that will be sent.\n */\n\n/**\n * This method is invoked when a previous interceptor has rejected the\n * promise, use this to handle for example errors before they are sent into mixins.\n * @function InterceptorResponse#onRejected\n * @param {Session} session The session executing the interceptor. You may use .retry() to retry\n * sending it to QIX Engine.\n * @param {Object} request The JSON-RPC request resulting in this error.\n * @param {Object} error Whatever the previous interceptor is rejected with.\n */\n\n/**\n * This method is invoked when a promise has been successfully resolved,\n * use this to modify the result or reject the promise chain before it is sent\n * to mixins.\n * @function InterceptorResponse#onFulfilled\n * @param {Session} session The session executing the interceptor.\n * @param {Object} request The JSON-RPC request resulting in this response.\n * @param {Object} result Whatever the previous interceptor is resolved with.\n */\nclass Intercept {\n /**\n * Create a new Intercept instance.\n * @private\n * @param {Object} options The configuration options for this class.\n * @param {Promise} options.Promise The promise constructor to use.\n * @param {ApiCache} options.apis The ApiCache instance to use.\n * @param {Array} [options.request] The additional request interceptors to use.\n * @param {Array} [options.response] The additional response interceptors to use.\n */\n constructor(options) {\n Object.assign(this, options);\n this.request = [{ onFulfilled: deltaRequest }, ...this.request || []];\n this.response = [\n { onFulfilled: errorResponse },\n { onFulfilled: deltaResponse },\n { onFulfilled: resultResponse },\n { onFulfilled: outParamResponse },\n ...this.response || [],\n { onFulfilled: apiResponse },\n ];\n }\n\n /**\n * Execute the request interceptor queue, each interceptor will get the result from\n * the previous interceptor.\n * @private\n * @param {Session} session The session instance to execute against.\n * @param {Promise} promise The promise to chain on to.\n * @returns {Promise}\n */\n executeRequests(session, promise) {\n return this.request.reduce((interception, interceptor) => {\n const intercept = interceptor.onFulfilled\n && interceptor.onFulfilled.bind(this, session);\n return interception.then(intercept);\n }, promise);\n }\n\n /**\n * Execute the response interceptor queue, each interceptor will get the result from\n * the previous interceptor.\n * @private\n * @param {Session} session The session instance to execute against.\n * @param {Promise} promise The promise to chain on to.\n * @param {Object} request The JSONRPC request object for the intercepted response.\n * @returns {Promise}\n */\n executeResponses(session, promise, request) {\n return this.response.reduce((interception, interceptor) => interception.then(\n interceptor.onFulfilled && interceptor.onFulfilled.bind(this, session, request),\n interceptor.onRejected && interceptor.onRejected.bind(this, session, request),\n ), promise);\n }\n}\n\nexport default Intercept;\n","/**\n* Process error interceptor.\n* @private\n* @param {Session} session - The session the intercept is being executed on.\n* @param {Object} request - The JSON-RPC request.\n* @param {Object} response - The response.\n* @returns {Object} - Returns the defined error for an error, else the response.\n*/\nexport default function errorResponseInterceptor(session, request, response) {\n if (typeof response.error !== 'undefined') {\n const data = response.error;\n const error = new Error(data.message);\n error.code = data.code;\n error.parameter = data.parameter;\n return session.config.Promise.reject(error);\n }\n return response;\n}\n","/**\n* Process result interceptor.\n* @private\n* @param {Session} session - The session the intercept is being executed on.\n* @param {Object} request - The JSON-RPC request.\n* @param {Object} response - The response.\n* @returns {Object} - Returns the result property on the response\n*/\nexport default function resultResponseInterceptor(session, request, response) {\n return response.result;\n}\n","import KeyValueCache from './key-value-cache';\n\n/**\n* API cache for instances of QIX types, e.g. GenericObject.\n* @private\n* @extends KeyValueCache\n*/\nclass ApiCache extends KeyValueCache {\n /**\n * Adds an API.\n * @private\n * @function ApiCache#add\n * @param {Number} handle - The handle for the API.\n * @param {*} api - The API.\n * @returns {{api: *}} The entry.\n */\n add(handle, api) {\n const entry = { api };\n super.add(handle.toString(), entry);\n api.on('closed', () => this.remove(handle));\n return entry;\n }\n\n /**\n * Gets an API.\n * @private\n * @function ApiCache#getApi\n * @param {Number} handle - The handle for the API.\n * @returns {*} The API for the handle.\n */\n getApi(handle) {\n const entry = typeof handle !== 'undefined' ? this.get(handle.toString()) : undefined;\n return entry && entry.api;\n }\n\n /**\n * Gets a list of APIs.\n * @private\n * @function ApiCache#getApis\n * @returns {Array} The list of entries including `handle` and `api` properties for each entry.\n */\n getApis() {\n return super.getAll().map((entry) => ({\n handle: entry.key,\n api: entry.value.api,\n }));\n }\n\n /**\n * Gets a list of APIs with a given type.\n * @private\n * @function ApiCache#getApisByType\n * @param {String} type - The type of APIs to get.\n * @returns {Array} The list of entries including `handle` and `api` properties for each entry.\n */\n getApisByType(type) {\n return this.getApis().filter((entry) => entry.api.type === type);\n }\n}\n\nexport default ApiCache;\n","import Session from './session';\nimport Schema from './schema';\nimport RPC from './rpc';\nimport SuspendResume from './suspend-resume';\nimport Intercept from './intercept';\nimport ApiCache from './api-cache';\n\nimport createEnigmaError from './error';\nimport errorCodes from './error-codes';\n\n/**\n * The enigma.js configuration object.\n * @interface Configuration\n * @property {Object} schema Object containing the specification for the API to generate.\n * Corresponds to a specific version of the QIX Engine API.\n * @property {String} url String containing a proper websocket URL to QIX Engine.\n * @property {Function} [createSocket] A function to use when instantiating the WebSocket,\n * mandatory for Node.js.\n * @property {Object} [Promise] ES6-compatible Promise library.\n * @property {Boolean} [suspendOnClose=false] Set to true if the session should be suspended\n * instead of closed when the websocket is closed.\n * @property {Array} [mixins=[]] Mixins to extend/augment the QIX Engine API. Mixins\n * are applied in the array order.\n * @property {Array} [requestInterceptors=[]] Interceptors for augmenting requests before they\n * are sent to QIX Engine. Interceptors are applied in the array order.\n * @property {Array} [responseInterceptors=[]] Interceptors for augmenting responses before they\n * are passed into mixins and end-users. Interceptors are applied in the array order.\n * @property {Object} [protocol={}] An object containing additional JSON-RPC request parameters.\n * @property {Boolean} [protocol.delta=true] Set to false to disable the use of the\n * bandwidth-reducing delta protocol.\n * @example Example defining a configuration object\n * const enigma = require('enigma.js');\n * const WebSocket = require('ws');\n * const bluebird = require('bluebird');\n * const schema = require('enigma.js/schemas/12.20.0.json');\n *\n * const config = {\n * schema,\n * url: 'ws://localhost:4848/app/engineData',\n * createSocket: url => new WebSocket(url),\n * Promise: bluebird,\n * suspendOnClose: true,\n * mixins: [{ types: ['Global'], init: () => console.log('Mixin ran') }],\n * protocol: { delta: false },\n * };\n *\n * enigma.create(config).open().then((global) => {\n * // global === QIX global interface\n * process.exit(0);\n * });\n */\n\n/**\n * The mixin concept allows you to add or override QIX Engine API functionality. A mixin is\n * basically a JavaScript object describing which types it modifies, and a list of functions\n * for extending and overriding the API for those types.\n *\n * QIX Engine types like for example GenericObject, Doc, GenericBookmark, are supported but\n * also custom GenericObject types such as barchart, story and myCustomType. An API will get\n * both their generic type as well as custom type mixins applied.\n *\n * Mixins that are bound to several different types can find the current API type in the\n * `genericType` or `type` members. `this.type` would for instance return `GenericObject` and\n * `this.genericType` would return `barchart`.\n *\n * See the Mixins examples on how to use it, below is an outline of what the mixin API consists of.\n *\n * @interface Mixin\n * @property {String|Array} types String or array of strings containing the API-types that\n * will be mixed in.\n * @property {Object} [extend] Object literal containing the methods that will be extended on the\n * specified API.\n * @property {Object} [override] Object literal containing the methods to override existing methods.\n * @property {Function} [init] Init function that, if defined, will run when an API is instantiated.\n * It runs with Promise and API object as parameters\n */\n\n/**\n * The API for generated APIs depends on the QIX Engine schema you pass into your Configuration, and\n * on what QIX struct the API has.\n *\n * All API calls made using the generated APIs will return promises which are either resolved or\n * rejected depending on how the QIX Engine responds.\n *\n * @interface API\n * @property {String} id Contains the unique identifier for this API.\n * @property {String} type Contains the schema class name for this API.\n * @property {String} genericType Corresponds to the qInfo.qType property on the generic object's\n * properties object.\n * @property {Session} session Contains a reference to the session that this API belongs to.\n * @property {Number} handle Contains the handle QIX Engine assigned to the API. Used interally in\n * enigma.js for caches and JSON-RPC requests.\n * @example Example using `global` and `generic object` struct APIs\n * global.openDoc('my-document.qvf').then((doc) => {\n * doc.createObject({ qInfo: { qType: 'my-object' } }).then(api => { });\n * doc.getObject('object-id').then(api => { });\n * doc.getBookmark('bookmark-id').then(api => { });\n * });\n */\n\n/**\n * Handle changes on the API. The changed event is triggered whenever enigma.js or QIX Engine has\n * identified potential changes on the underlying properties or hypercubes and you should re-fetch\n * your data.\n * @event API#changed\n * @type {Object}\n * @example Bind the `changed` event\n * api.on('changed', () => {\n * api.getLayout().then(layout => { });\n * });\n */\n\n/**\n * Handle closed API. The closed event is triggered whenever QIX Engine considers an API closed.\n * It usually means that it no longer exist in the QIX Engine document or session.\n * @event API#closed\n * @type {Object}\n * @example Bind the `closed` event\n * api.on('closed', () => {\n * console.log(api.id, 'was closed');\n * });\n */\n\n/**\n * Handle JSON-RPC requests/responses for this API. Generally used in debugging purposes.\n * `traffic:*` will handle all websocket messages, `traffic:sent` will handle outgoing messages\n * and `traffic:received` will handle incoming messages.\n * @event API#traffic\n * @type {Object}\n * @example Bind the traffic events\n * // bind both in- and outbound traffic to console.log:\n * api.on('traffic:*', console.log);\n * // bind outbound traffic to console.log:\n * api.on('traffic:sent', console.log);\n * // bind inbound traffic to console.log:\n * api.on('traffic:received', console.log);\n */\n\nclass Enigma {\n /**\n * Function used to get a session.\n * @private\n * @param {Configuration} config The configuration object for this session.\n * @returns {Session} Returns a session instance.\n */\n static getSession(config) {\n const {\n createSocket,\n Promise,\n requestInterceptors,\n responseInterceptors,\n url,\n } = config;\n const apis = new ApiCache();\n const intercept = new Intercept({\n apis,\n Promise,\n request: requestInterceptors,\n response: responseInterceptors,\n });\n const rpc = new RPC({ createSocket, Promise, url });\n const suspendResume = new SuspendResume({ apis, Promise, rpc });\n const session = new Session({\n apis,\n config,\n intercept,\n rpc,\n suspendResume,\n });\n return session;\n }\n\n /**\n * Function used to configure defaults.\n * @private\n * @param {Configuration} config The configuration object for how to connect\n * and retrieve end QIX APIs.\n */\n static configureDefaults(config) {\n if (!config) {\n throw createEnigmaError(errorCodes.NO_CONFIG_SUPPLIED, 'You need to supply a configuration.');\n }\n\n // eslint-disable-next-line no-restricted-globals\n if (!config.Promise && typeof Promise === 'undefined') {\n throw createEnigmaError(errorCodes.PROMISE_REQUIRED, 'Your environment has no Promise implementation. You must provide a Promise implementation in the config.');\n }\n\n if (typeof config.createSocket !== 'function' && typeof WebSocket === 'function') {\n // eslint-disable-next-line no-undef\n config.createSocket = (url) => new WebSocket(url);\n }\n\n if (typeof config.suspendOnClose === 'undefined') {\n config.suspendOnClose = false;\n }\n\n config.protocol = config.protocol || {};\n config.protocol.delta = typeof config.protocol.delta !== 'undefined' ? config.protocol.delta : true;\n // eslint-disable-next-line no-restricted-globals\n config.Promise = config.Promise || Promise;\n config.mixins = config.mixins || [];\n config.definition = config.definition || new Schema(config);\n }\n\n /**\n * Function used to create a QIX session.\n * @entry\n * @param {Configuration} config The configuration object for the QIX session.\n * @returns {Session} Returns a new QIX session.\n * @example Example minimal session creation\n * const enigma = require('enigma.js');\n * const schema = require('enigma.js/schemas/12.20.0.json');\n * const WebSocket = require('ws');\n * const config = {\n * schema,\n * url: 'ws://localhost:9076/app/engineData',\n * createSocket: url => new WebSocket(url),\n * };\n * const session = enigma.create(config);\n */\n static create(config) {\n Enigma.configureDefaults(config);\n config.mixins.forEach((mixin) => {\n config.definition.registerMixin(mixin);\n });\n return Enigma.getSession(config);\n }\n}\n\nexport default Enigma;\n"],"names":["util","EventEmitter","init","call","this","isObject","arg","isNumber","isUndefined","isFunction","prototype","_events","undefined","_maxListeners","defaultMaxListeners","setMaxListeners","n","isNaN","TypeError","emit","type","er","handler","len","args","i","listeners","error","arguments","Error","length","Array","apply","slice","on","addListener","listener","m","newListener","push","warned","console","trace","once","fired","g","removeListener","list","position","splice","removeAllListeners","key","isArray","listenerCount","emitter","obj","Object","keys","forEach","EnigmaError","name","code","enigmaError","createEnigmaError","errorCodes","NOT_CONNECTED","OBJECT_NOT_FOUND","EXPECTED_ARRAY_OF_PATCHES","PATCH_HAS_NO_PARENT","ENTRY_ALREADY_DEFINED","NO_CONFIG_SUPPLIED","PROMISE_REQUIRED","SCHEMA_STRUCT_TYPE_NOT_FOUND","SCHEMA_MIXIN_CANT_OVERRIDE_FUNCTION","SCHEMA_MIXIN_EXTEND_NOT_ALLOWED","SESSION_SUSPENDED","SESSION_NOT_ATTACHED","cacheId","Session","options","session","assign","Promise","config","definition","id","rpc","onRpcError","bind","onRpcClosed","onRpcMessage","onRpcNotification","onRpcTraffic","onSessionClosed","promise","value","then","params","chain","addToPromiseChain","err","suspendResume","isSuspended","evt","suspendOnClose","reason","suspend","_this","initiator","response","change","handle","_this2","emitHandleChanged","close","emitHandleClosed","method","dir","data","api","apis","getApi","getApis","entry","clear","genericType","generate","factory","add","globalPromise","open","_this3","getObjectApi","global","request","reject","createRequestId","intercept","executeRequests","resolve","augmentedRequest","_this4","protocol","outKey","send","retry","executeResponses","_this5","onlyIfAttached","resume","_this6","_this7","KeyValueCache","entries","map","filter","hasOwnProperty","toCamelCase","symbol","substring","toLowerCase","Schema","schema","mixins","types","extend","override","cached","typeKey","entryList","get","structs","generateApi","create","generateDefaultApi","mixinType","mixinNamedParamFacade","customKey","instance","Events","defineProperties","enumerable","writable","mixinList","concat","mixin","out","Out","Name","fnName","baseFn","base","defaults","In","reduce","result","item","DefaultValue","_typeof","every","RPCResolver","RPC","resolvers","requestId","openedPromise","socket","createSocket","url","onopen","onOpen","onclose","onClose","onerror","onError","onmessage","onMessage","registerResolver","closedPromise","opened","resolveWith","event","closed","rejectAllOutstandingResolvers","rejectWith","JSON","parse","resolver","resolvedId","unregisterResolver","rejectedId","readyState","OPEN","jsonrpc","stringify","SuspendResume","openDocParams","replace","reopen","sessionState","changed","getApisByType","pop","doc","qReturn","qHandle","tasks","buildGetMethodName","all","restoreRpcConnection","restoreGlobal","restoreDoc","restoreDocObjects","timeout","timer","notificationResolve","notificationReceived","notificationPromise","onNotification","clearTimeout","qSessionState","setTimeout","state","SUCCESS_KEY","apiResponseInterceptor","qType","qGenericId","qGenericType","hasOwn","toStr","toString","defineProperty","gOPD","getOwnPropertyDescriptor","arr","isPlainObject","hasOwnConstructor","hasIsPrototypeOf","constructor","setProperty","target","configurable","newValue","getProperty","src","copy","copyIsArray","clone","deep","JSONPatch","v","isUndef","isSpecialProperty","getParent","str","numPart","parts","split","part","newPart","compare","a","b","isIdentical","l","original","newData","basePath","patches","val","oldVal","tmpPath","op","path","newA","oldA","tmpIdx","findIndex","idx","qInfo","qId","ii","ll","from","patchArray","patch","parent","chunk","oldParent","createPatch","updateObject","sessions","getHandleCache","cache","bindSession","patchValue","set","deltaResponseInterceptor","delta","RETURN_KEY","Intercept","onFulfilled","message","parameter","deltaResponse","qSessionAppId","apiResponse","interception","interceptor","onRejected","ApiCache","remove","_get","requestInterceptors","responseInterceptors","WebSocket","Enigma","configureDefaults","registerMixin","getSession"],"mappings":"sOAIA,IAAIA,EAAO,GAuBX,SAASC,IACPA,EAAaC,KAAKC,KAAKC,MAtBzBJ,EAAKK,SAAW,SAAkBC,GAChC,MAAsB,iBAARA,GAA4B,OAARA,GAGpCN,EAAKO,SAAW,SAAkBD,GAChC,MAAsB,iBAARA,GAGhBN,EAAKQ,YAAc,SAAqBF,GACtC,YAAe,IAARA,GAGTN,EAAKS,WAAa,SAAoBH,GACpC,MAAsB,mBAARA,GAWhB,MAAiBL,GAGjBA,EAAaA,aAAeA,GAEfS,UAAUC,aAAUC,EACjCX,EAAaS,UAAUG,mBAAgBD,EAIvCX,EAAaa,oBAAsB,GAEnCb,EAAaC,KAAO,WAClBE,KAAKO,QAAUP,KAAKO,SAAW,GAC/BP,KAAKS,cAAgBT,KAAKS,oBAAiBD,GAK7CX,EAAaS,UAAUK,gBAAkB,SAASC,GAChD,IAAKhB,EAAKO,SAASS,IAAMA,EAAI,GAAKC,MAAMD,GACtC,MAAME,UAAU,+BAElB,OADAd,KAAKS,cAAgBG,EACdZ,MAGTH,EAAaS,UAAUS,KAAO,SAASC,GACrC,IAAIC,EAAIC,EAASC,EAAKC,EAAMC,EAAGC,EAM/B,GAJKtB,KAAKO,UACRP,KAAKO,QAAU,IAGJ,UAATS,IAAqBhB,KAAKO,QAAQgB,MAEpC,MADAN,EAAKO,UAAU,cACGC,MACVR,EAEAQ,MAAM,wCAOhB,GAFAP,EAAUlB,KAAKO,QAAQS,GAEnBpB,EAAKQ,YAAYc,GACnB,OAAO,EAET,GAAItB,EAAKS,WAAWa,GAClB,OAAQM,UAAUE,QAEhB,KAAK,EACHR,EAAQnB,KAAKC,MACb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AOD,SAA8B,oBAAZA,cACtBnB,EAAkBC,EAAWO,iBAAkB,4GAGpB,mBAAxBY,EAAO2H,cAAoD,mBAAdoJ,YAEtD/Q,EAAO2H,aAAe,SAACC,UAAQ,IAAImJ,UAAUnJ,UAGV,IAA1B5H,EAAOqB,iBAChBrB,EAAOqB,gBAAiB,GAG1BrB,EAAO2D,SAAW3D,EAAO2D,UAAY,GACrC3D,EAAO2D,SAASmM,WAAyC,IAA1B9P,EAAO2D,SAASmM,OAAwB9P,EAAO2D,SAASmM,MAEvF9P,EAAOD,QAAUC,EAAOD,SAAWA,QACnCC,EAAOgF,OAAShF,EAAOgF,QAAU,GACjChF,EAAOC,WAAaD,EAAOC,YAAc,IAAI6E,EAAO9E,kCAmBxCA,UACZgR,EAAOC,kBAAkBjR,GACzBA,EAAOgF,OAAOzG,QAAQ,SAAC+H,GACrBtG,EAAOC,WAAWiR,cAAc5K,KAE3B0K,EAAOG,WAAWnR"} \ No newline at end of file diff --git a/jwt-scratch/src/js/node_modules/enigma.js/error-codes.js b/jwt-scratch/src/js/node_modules/enigma.js/error-codes.js new file mode 100644 index 0000000..53d2e3b --- /dev/null +++ b/jwt-scratch/src/js/node_modules/enigma.js/error-codes.js @@ -0,0 +1,104 @@ +/** + * enigma.js v2.7.2 + * Copyright (c) 2020 QlikTech International AB + * This library is licensed under MIT - See the LICENSE file for full details + */ + +(function (global, factory) { + typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() : + typeof define === 'function' && define.amd ? define(factory) : + (global = typeof globalThis !== 'undefined' ? globalThis : global || self, global['error-codes'] = factory()); +}(this, (function () { 'use strict'; + + /** + * This is a list of error codes that can be thrown from enigma.js API calls. + * @entry + * @see EnigmaError + * @enum + * @example Handling an enigma.js error + * const { NOT_CONNECTED } = require('enigma.js/error-codes'); + * try { + * const layout = await model.getLayout(); + * } catch (err) { + * if (err.code === NOT_CONNECTED) { + * console.log('Tried to communicate on a session that is closed'); + * } + * } + */ + var errorCodes = { + /** + * You're trying to send data on a socket that's not connected + * @type {number} + */ + NOT_CONNECTED: -1, + + /** + * The object you're trying to fetch does not exist + * @type {number} + */ + OBJECT_NOT_FOUND: -2, + + /** + * Unexpected RPC response, expected array of patches + * @type {number} + */ + EXPECTED_ARRAY_OF_PATCHES: -3, + + /** + * Patchee is not an object we can patch + * @type {number} + */ + PATCH_HAS_NO_PARENT: -4, + + /** + * This entry is already defined with another key + * @type {number} + */ + ENTRY_ALREADY_DEFINED: -5, + + /** + * You need to supply a configuration + * @type {number} + */ + NO_CONFIG_SUPPLIED: -6, + + /** + * There's no promise object available (polyfill required?) + * @type {number} + */ + PROMISE_REQUIRED: -7, + + /** + * The schema struct type you requested does not exist + * @type {number} + */ + SCHEMA_STRUCT_TYPE_NOT_FOUND: -8, + + /** + * Can't override this function + * @type {number} + */ + SCHEMA_MIXIN_CANT_OVERRIDE_FUNCTION: -9, + + /** + * Extend is not allowed for this mixin + * @type {number} + */ + SCHEMA_MIXIN_EXTEND_NOT_ALLOWED: -10, + + /** + * Session suspended - no interaction allowed + * @type {number} + */ + SESSION_SUSPENDED: -11, + + /** + * onlyIfAttached supplied, but you got SESSION_CREATED + * @type {number} + */ + SESSION_NOT_ATTACHED: -12 + }; + + return errorCodes; + +}))); diff --git a/jwt-scratch/src/js/node_modules/enigma.js/package.json b/jwt-scratch/src/js/node_modules/enigma.js/package.json new file mode 100644 index 0000000..345b2a2 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/enigma.js/package.json @@ -0,0 +1,100 @@ +{ + "_from": "enigma.js", + "_id": "enigma.js@2.7.2", + "_inBundle": false, + "_integrity": "sha512-MATvu3+DqV3NGkdKM5uYJT8VLBkQeWgvNqiHsOXO/ChcMezwrKpr4gcn+gx/sqnACX9yaoFi02ECbs8rCZ+aIQ==", + "_location": "/enigma.js", + "_phantomChildren": {}, + "_requested": { + "type": "tag", + "registry": true, + "raw": "enigma.js", + "name": "enigma.js", + "escapedName": "enigma.js", + "rawSpec": "", + "saveSpec": null, + "fetchSpec": "latest" + }, + "_requiredBy": [ + "#USER", + "/" + ], + "_resolved": "https://registry.npmjs.org/enigma.js/-/enigma.js-2.7.2.tgz", + "_shasum": "94426f574fdec59eccba233d370a3176b9e45e05", + "_spec": "enigma.js", + "_where": "/home/rock64/git/qseow-scripts/jwt-scratch/src/js", + "author": { + "name": "QlikTech International AB" + }, + "bugs": { + "url": "https://github.com/qlik-oss/enigma.js/issues" + }, + "bundleDependencies": false, + "deprecated": false, + "description": "JavaScript library for consuming Qlik backend services", + "devDependencies": { + "@after-work.js/aw": "6.0.13", + "@after-work.js/transform": "6.0.13", + "@babel/core": "7.11.4", + "@babel/plugin-transform-modules-commonjs": "7.10.4", + "@babel/preset-env": "7.11.0", + "@joseph184/rollup-plugin-node-builtins": "2.1.4", + "babel-plugin-istanbul": "6.0.0", + "coveralls": "3.1.0", + "cross-env": "7.0.2", + "eslint": "7.7.0", + "eslint-config-airbnb-base": "14.2.0", + "eslint-plugin-import": "2.22.0", + "extend": "3.0.2", + "jsdoc": "3.6.5", + "node-event-emitter": "0.0.1", + "querystring": "0.2.0", + "rimraf": "3.0.2", + "rollup": "2.26.4", + "rollup-plugin-babel": "4.4.0", + "rollup-plugin-commonjs": "10.1.0", + "rollup-plugin-filesize": "9.0.2", + "rollup-plugin-license": "2.2.0", + "rollup-plugin-node-globals": "1.4.0", + "rollup-plugin-node-resolve": "5.2.0", + "rollup-plugin-uglify": "6.0.4", + "scriptappy-from-jsdoc": "0.7.0", + "ws": "7.3.1" + }, + "files": [ + "/enigma.js", + "/enigma.js.map", + "/enigma.min.js", + "/enigma.min.js.map", + "/sense-utilities.js", + "/sense-utilities.js.map", + "/sense-utilities.min.js", + "/sense-utilities.min.js.map", + "/error-codes.js", + "/schemas" + ], + "homepage": "https://github.com/qlik-oss/enigma.js#readme", + "license": "MIT", + "main": "enigma.js", + "name": "enigma.js", + "repository": { + "type": "git", + "url": "git+https://github.com/qlik-oss/enigma.js.git" + }, + "scripts": { + "build": "rollup -c && cross-env NODE_ENV=production rollup -c", + "jsdoc": "rimraf ./jsdoc && jsdoc ./src -c ./jsdoc-config.json -r -d ./jsdoc", + "lint": "eslint .", + "preversion": "npm run test && npm run test:integration", + "scriptappy": "jsdoc ./src -c ./jsdoc-config.json -r ./package.json -X | scriptappy-from-jsdoc -c spec.config.js", + "test": "aw -c test/aw.config.json", + "test:component": "aw -c test/aw.config.json --glob test/component/**/*.spec.js", + "test:component:watch": "aw -c test/aw.config.json --glob test/component/**/*.spec.js -w", + "test:integration": "aw -c test/aw.config.json --glob test/integration/**/*.spec.js --mocha.timeout 5000", + "test:unit": "aw -c test/aw.config.json --glob test/unit/{,**/}*.spec.js", + "test:unit:watch": "aw -c test/aw.config.json --glob test/unit/{,**/}*.spec.js -w", + "test:watch": "aw -c test/aw.config.json -w", + "version": "npm run build && npm run scriptappy" + }, + "version": "2.7.2" +} diff --git a/jwt-scratch/src/js/node_modules/enigma.js/schemas/12.170.2.json b/jwt-scratch/src/js/node_modules/enigma.js/schemas/12.170.2.json new file mode 100644 index 0000000..9ac9dad --- /dev/null +++ b/jwt-scratch/src/js/node_modules/enigma.js/schemas/12.170.2.json @@ -0,0 +1,1648 @@ +{ + "structs": { + "Field":{ + "GetCardinal": { + "In": [], + "Out": [] + }, + "GetAndMode": { + "In": [], + "Out": [] + }, + "SelectValues": { + "In": [{ "Name": "qFieldValues","DefaultValue": [{"qText": "", "qIsNumeric": false, "qNumber": 0}] }, { "Name": "qToggleMode","DefaultValue": false, "Optional": true }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Select": { + "In": [{ "Name": "qMatch","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qExcludedValuesMode","DefaultValue": 0, "Optional": true }], + "Out": [] + }, + "ToggleSelect": { + "In": [{ "Name": "qMatch","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qExcludedValuesMode","DefaultValue": 0, "Optional": true }], + "Out": [] + }, + "ClearAllButThis": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectPossible": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectExcluded": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectAll": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Lock": { + "In": [], + "Out": [] + }, + "Unlock": { + "In": [], + "Out": [] + }, + "GetNxProperties": { + "In": [], + "Out": [{ "Name": "qProperties" }] + }, + "SetNxProperties": { + "In": [{ "Name": "qProperties","DefaultValue": {"qOneAndOnlyOne": false} }], + "Out": [] + }, + "SetAndMode": { + "In": [{ "Name": "qAndMode","DefaultValue": false }], + "Out": [] + }, + "SelectAlternative": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "LowLevelSelect": { + "In": [{ "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Clear": { + "In": [], + "Out": [] + } + }, + "Variable":{ + "GetContent": { + "In": [], + "Out": [{ "Name": "qContent" }] + }, + "GetRawContent": { + "In": [], + "Out": [] + }, + "SetContent": { + "In": [{ "Name": "qContent","DefaultValue": "" }, { "Name": "qUpdateMRU","DefaultValue": false }], + "Out": [] + }, + "ForceContent": { + "In": [{ "Name": "qs","DefaultValue": "" }, { "Name": "qd","DefaultValue": 0 }], + "Out": [] + }, + "GetNxProperties": { + "In": [], + "Out": [{ "Name": "qProperties" }] + }, + "SetNxProperties": { + "In": [{ "Name": "qProperties","DefaultValue": {"qName": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qUsePredefListedValues": false, "qPreDefinedList": [""]} }], + "Out": [] + } + }, + "GenericObject":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "GetListObjectData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeReducedData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qZoomFactor","DefaultValue": 0 }, { "Name": "qReductionMode","DefaultValue": 0 }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubePivotData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeStackData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qMaxNbrCells","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeContinuousData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qOptions","DefaultValue": {"qStart": 0, "qEnd": 0, "qNbrPoints": 0, "qMaxNbrTicks": 0, "qMaxNumberLines": 0} }, { "Name": "qReverseSort","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qDataPages" }, { "Name": "qAxisData" }] + }, + "GetHyperCubeTreeData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qNodeOptions","DefaultValue": {"qMaxNbrOfNodes": 0, "qTreeNodes": [{"qArea": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qAllValues": false}], "qTreeLevels": {"qLeft": 0, "qDepth": 0}}, "Optional": true }], + "Out": [{ "Name": "qNodes" }] + }, + "GetHyperCubeBinnedData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qViewport","DefaultValue": {"qWidth": 0, "qHeight": 0, "qZoomLevel": 0} }, { "Name": "qDataRanges","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qMaxNbrCells","DefaultValue": 0 }, { "Name": "qQueryLevel","DefaultValue": 0 }, { "Name": "qBinningMethod","DefaultValue": 0 }], + "Out": [{ "Name": "qDataPages" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }, { "Name": "qSoftPatch","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "ClearSoftPatches": { + "In": [], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetEffectiveProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "SetFullPropertyTree": { + "In": [{ "Name": "qPropEntry","DefaultValue": {"qProperty": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}}, "qChildren": [], "qEmbeddedSnapshotRef": null} }], + "Out": [] + }, + "GetFullPropertyTree": { + "In": [], + "Out": [{ "Name": "qPropEntry" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "ClearSelections": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "ExportData": { + "In": [{ "Name": "qFileType","DefaultValue": 0 }, { "Name": "qPath","DefaultValue": "", "Optional": true }, { "Name": "qFileName","DefaultValue": "", "Optional": true }, { "Name": "qExportState","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qUrl" }, { "Name": "qWarnings" }] + }, + "SelectListObjectValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectPossible": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectExcluded": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectAlternative": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectAll": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectContinuousRange": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SearchListObjectFor": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qMatch","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "AbortListObjectSearch": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [] + }, + "AcceptListObjectSearch": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "ExpandLeft": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "ExpandTop": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "CollapseLeft": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "CollapseTop": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "DrillUp": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qDimNo","DefaultValue": 0 }, { "Name": "qNbrSteps","DefaultValue": 0 }], + "Out": [] + }, + "Lock": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "Unlock": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "SelectHyperCubeValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qDimNo","DefaultValue": 0 }, { "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectHyperCubeCells": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRowIndices","DefaultValue": [0] }, { "Name": "qColIndices","DefaultValue": [0] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectPivotCells": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSelections","DefaultValue": [{"qType": 0, "qCol": 0, "qRow": 0}] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "RangeSelectHyperCubeValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qRange": {"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}, "qMeasureIx": 0}] }, { "Name": "qColumnsToSelect","DefaultValue": [0], "Optional": true }, { "Name": "qOrMode","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "MultiRangeSelectHyperCubeValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qRanges": [{"qRange": {"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}, "qMeasureIx": 0}], "qColumnsToSelect": [0]}] }, { "Name": "qOrMode","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "MultiRangeSelectTreeDataValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qRanges": [{"qRange": {"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}, "qMeasureIx": 0, "qDimensionIx": 0}]}] }, { "Name": "qOrMode","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectHyperCubeContinuousRange": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qRange": {"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}, "qDimIx": 0}] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetChild": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetChildInfos": { + "In": [], + "Out": [{ "Name": "qInfos" }] + }, + "CreateChild": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }, { "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyChild": { + "In": [{ "Name": "qId","DefaultValue": "" }, { "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "DestroyAllChildren": { + "In": [{ "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [] + }, + "SetChildArrayOrder": { + "In": [{ "Name": "qIds","DefaultValue": [""] }], + "Out": [] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "CopyFrom": { + "In": [{ "Name": "qFromId","DefaultValue": "" }], + "Out": [] + }, + "BeginSelections": { + "In": [{ "Name": "qPaths","DefaultValue": [""] }], + "Out": [] + }, + "EndSelections": { + "In": [{ "Name": "qAccept","DefaultValue": false }], + "Out": [] + }, + "ResetMadeSelections": { + "In": [], + "Out": [] + }, + "EmbedSnapshotObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetSnapshotObject": { + "In": [], + "Out": [] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + }, + "Approve": { + "In": [], + "Out": [] + }, + "UnApprove": { + "In": [], + "Out": [] + } + }, + "GenericDimension":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDim": {"qGrouping": 0, "qFieldDefs": [""], "qFieldLabels": [""], "qLabelExpression": ""}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetDimension": { + "In": [], + "Out": [{ "Name": "qDim" }] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + }, + "Approve": { + "In": [], + "Out": [] + }, + "UnApprove": { + "In": [], + "Out": [] + } + }, + "GenericBookmark":{ + "GetFieldValues": { + "In": [{ "Name": "qField","DefaultValue": "" }, { "Name": "qGetExcludedValues","DefaultValue": false }, { "Name": "qDataPage","DefaultValue": {"qStartIndex": 0, "qEndIndex": 0} }], + "Out": [{ "Name": "qFieldValues" }] + }, + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "Apply": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + }, + "Approve": { + "In": [], + "Out": [] + }, + "UnApprove": { + "In": [], + "Out": [] + } + }, + "GenericVariable":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "SetStringValue": { + "In": [{ "Name": "qVal","DefaultValue": "" }], + "Out": [] + }, + "SetNumValue": { + "In": [{ "Name": "qVal","DefaultValue": 0 }], + "Out": [] + }, + "SetDualValue": { + "In": [{ "Name": "qText","DefaultValue": "" }, { "Name": "qNum","DefaultValue": 0 }], + "Out": [] + } + }, + "GenericMeasure":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMeasure": {"qLabel": "", "qDef": "", "qGrouping": 0, "qExpressions": [""], "qActiveExpression": 0, "qLabelExpression": ""}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetMeasure": { + "In": [], + "Out": [{ "Name": "qMeasure" }] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + }, + "Approve": { + "In": [], + "Out": [] + }, + "UnApprove": { + "In": [], + "Out": [] + } + }, + "Doc":{ + "GetField": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }, { "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "GetFieldDescription": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }], + "Out": [] + }, + "GetVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "GetLooselyCoupledVector": { + "In": [], + "Out": [{ "Name": "qv" }] + }, + "SetLooselyCoupledVector": { + "In": [{ "Name": "qv","DefaultValue": [0] }], + "Out": [] + }, + "Evaluate": { + "In": [{ "Name": "qExpression","DefaultValue": "" }], + "Out": [] + }, + "EvaluateEx": { + "In": [{ "Name": "qExpression","DefaultValue": "" }], + "Out": [{ "Name": "qValue" }] + }, + "ClearAll": { + "In": [{ "Name": "qLockedAlso","DefaultValue": false, "Optional": true }, { "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "LockAll": { + "In": [{ "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "UnlockAll": { + "In": [{ "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "Back": { + "In": [], + "Out": [] + }, + "Forward": { + "In": [], + "Out": [] + }, + "CreateVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "RemoveVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "GetLocaleInfo": { + "In": [], + "Out": [] + }, + "GetTablesAndKeys": { + "In": [{ "Name": "qWindowSize","DefaultValue": {"qcx": 0, "qcy": 0} }, { "Name": "qNullSize","DefaultValue": {"qcx": 0, "qcy": 0} }, { "Name": "qCellHeight","DefaultValue": 0 }, { "Name": "qSyntheticMode","DefaultValue": false }, { "Name": "qIncludeSysVars","DefaultValue": false }], + "Out": [{ "Name": "qtr" }, { "Name": "qk" }] + }, + "GetViewDlgSaveInfo": { + "In": [], + "Out": [] + }, + "SetViewDlgSaveInfo": { + "In": [{ "Name": "qInfo","DefaultValue": {"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCtlInfo": {"qInternalView": {"qTables": [{"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCaption": ""}], "qBroomPoints": [{"qPos": {"qx": 0, "qy": 0}, "qTable": "", "qFields": [""]}], "qConnectionPoints": [{"qPos": {"qx": 0, "qy": 0}, "qFields": [""]}], "qZoomFactor": 0}, "qSourceView": {"qTables": [{"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCaption": ""}], "qBroomPoints": [{"qPos": {"qx": 0, "qy": 0}, "qTable": "", "qFields": [""]}], "qConnectionPoints": [{"qPos": {"qx": 0, "qy": 0}, "qFields": [""]}], "qZoomFactor": 0}}, "qMode": 0} }], + "Out": [] + }, + "GetEmptyScript": { + "In": [{ "Name": "qLocalizedMainSection","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "DoReload": { + "In": [{ "Name": "qMode","DefaultValue": 0, "Optional": true }, { "Name": "qPartial","DefaultValue": false, "Optional": true }, { "Name": "qDebug","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "GetScriptBreakpoints": { + "In": [], + "Out": [{ "Name": "qBreakpoints" }] + }, + "SetScriptBreakpoints": { + "In": [{ "Name": "qBreakpoints","DefaultValue": [{"qbufferName": "", "qlineIx": 0, "qEnabled": false}] }], + "Out": [] + }, + "GetScript": { + "In": [], + "Out": [{ "Name": "qScript" }] + }, + "GetTextMacros": { + "In": [], + "Out": [{ "Name": "qMacros" }] + }, + "SetFetchLimit": { + "In": [{ "Name": "qLimit","DefaultValue": 0 }], + "Out": [] + }, + "DoSave": { + "In": [{ "Name": "qFileName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "GetTableData": { + "In": [{ "Name": "qOffset","DefaultValue": 0 }, { "Name": "qRows","DefaultValue": 0 }, { "Name": "qSyntheticMode","DefaultValue": false }, { "Name": "qTableName","DefaultValue": "" }], + "Out": [{ "Name": "qData" }] + }, + "GetAppLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "SetAppProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qTitle": "", "qLastReloadTime": "", "qMigrationHash": "", "qSavedInProductVersion": "", "qThumbnail": {"qUrl": ""}} }], + "Out": [] + }, + "GetAppProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetLineage": { + "In": [], + "Out": [{ "Name": "qLineage" }] + }, + "CreateSessionObject": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }], + "Out": [] + }, + "DestroySessionObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CreateObject": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetObjects": { + "In": [{ "Name": "qOptions","DefaultValue": {"qTypes": [""], "qIncludeSessionObjects": false, "qData": {}} }], + "Out": [{ "Name": "qList" }] + }, + "GetBookmarks": { + "In": [{ "Name": "qOptions","DefaultValue": {"qTypes": [""], "qData": {}} }], + "Out": [{ "Name": "qList" }] + }, + "CloneObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qDraftId" }] + }, + "CommitDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "DestroyDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }, { "Name": "qSourceId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "Undo": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "Redo": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "ClearUndoBuffer": { + "In": [], + "Out": [] + }, + "CreateDimension": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDim": {"qGrouping": 0, "qFieldDefs": [""], "qFieldLabels": [""], "qLabelExpression": ""}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "CloneDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateMeasure": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMeasure": {"qLabel": "", "qDef": "", "qGrouping": 0, "qExpressions": [""], "qActiveExpression": 0, "qLabelExpression": ""}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "CloneMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateSessionVariable": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [] + }, + "DestroySessionVariable": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CreateVariableEx": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyVariableById": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "DestroyVariableByName": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetVariableById": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetVariableByName": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "MigrateVariables": { + "In": [], + "Out": [] + }, + "MigrateDerivedFields": { + "In": [], + "Out": [] + }, + "CheckExpression": { + "In": [{ "Name": "qExpr","DefaultValue": "" }, { "Name": "qLabels","DefaultValue": [""], "Optional": true }], + "Out": [{ "Name": "qErrorMsg" }, { "Name": "qBadFieldNames" }, { "Name": "qDangerousFieldNames" }] + }, + "CheckNumberOrExpression": { + "In": [{ "Name": "qExpr","DefaultValue": "" }], + "Out": [{ "Name": "qErrorMsg" }, { "Name": "qBadFieldNames" }] + }, + "AddAlternateState": { + "In": [{ "Name": "qStateName","DefaultValue": "" }], + "Out": [] + }, + "RemoveAlternateState": { + "In": [{ "Name": "qStateName","DefaultValue": "" }], + "Out": [] + }, + "CreateBookmark": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "ApplyBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CloneBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "AddFieldFromExpression": { + "In": [{ "Name": "qName","DefaultValue": "" }, { "Name": "qExpr","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetFieldOnTheFlyByName": { + "In": [{ "Name": "qReadableName","DefaultValue": "" }], + "Out": [{ "Name": "qName" }] + }, + "GetAllInfos": { + "In": [], + "Out": [{ "Name": "qInfos" }] + }, + "Resume": { + "In": [], + "Out": [] + }, + "AbortModal": { + "In": [{ "Name": "qAccept","DefaultValue": false }], + "Out": [] + }, + "Publish": { + "In": [{ "Name": "qStreamId","DefaultValue": "" }, { "Name": "qName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + }, + "GetMatchingFields": { + "In": [{ "Name": "qTags","DefaultValue": [""] }, { "Name": "qMatchingFieldMode","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qFieldNames" }] + }, + "FindMatchingFields": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }, { "Name": "qTags","DefaultValue": [""] }], + "Out": [{ "Name": "qFieldNames" }] + }, + "Scramble": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }], + "Out": [] + }, + "SaveObjects": { + "In": [], + "Out": [] + }, + "GetAssociationScores": { + "In": [{ "Name": "qTable1","DefaultValue": "" }, { "Name": "qTable2","DefaultValue": "" }], + "Out": [{ "Name": "qScore" }] + }, + "GetMediaList": { + "In": [], + "Out": [{ "Name": "qList" }] + }, + "GetContentLibraries": { + "In": [], + "Out": [{ "Name": "qList" }] + }, + "GetLibraryContent": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [{ "Name": "qList" }] + }, + "DoReloadEx": { + "In": [{ "Name": "qParams","DefaultValue": {"qMode": 0, "qPartial": false, "qDebug": false}, "Optional": true }], + "Out": [{ "Name": "qResult" }] + }, + "BackCount": { + "In": [], + "Out": [] + }, + "ForwardCount": { + "In": [], + "Out": [] + }, + "ExportReducedData": { + "In": [{ "Name": "qOptions","DefaultValue": {"qBookmarkId": "", "qExpires": 0}, "Optional": true }], + "Out": [{ "Name": "qDownloadInfo" }] + }, + "SetScript": { + "In": [{ "Name": "qScript","DefaultValue": "" }], + "Out": [] + }, + "CheckScriptSyntax": { + "In": [], + "Out": [{ "Name": "qErrors" }] + }, + "GetFavoriteVariables": { + "In": [], + "Out": [{ "Name": "qNames" }] + }, + "SetFavoriteVariables": { + "In": [{ "Name": "qNames","DefaultValue": [""] }], + "Out": [] + }, + "GetIncludeFileContent": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [{ "Name": "qContent" }] + }, + "CreateConnection": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }], + "Out": [{ "Name": "qConnectionId" }] + }, + "ModifyConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }, { "Name": "qOverrideCredentials","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "DeleteConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [] + }, + "GetConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qConnection" }] + }, + "GetConnections": { + "In": [], + "Out": [{ "Name": "qConnections" }] + }, + "GetDatabaseInfo": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qInfo" }] + }, + "GetDatabases": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qDatabases" }] + }, + "GetDatabaseOwners": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qOwners" }] + }, + "GetDatabaseTables": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qTables" }] + }, + "GetDatabaseTableFields": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qFields" }] + }, + "GetDatabaseTablePreview": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }, { "Name": "qTable","DefaultValue": "" }, { "Name": "qConditions","DefaultValue": {"qType": 0, "qWherePredicate": ""}, "Optional": true }], + "Out": [{ "Name": "qPreview" }, { "Name": "qRowCount" }] + }, + "GetFolderItemsForConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qFolderItems" }] + }, + "GuessFileType": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qDataFormat" }] + }, + "GetFileTables": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }], + "Out": [{ "Name": "qTables" }] + }, + "GetFileTableFields": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qFields" }, { "Name": "qFormatSpec" }] + }, + "GetFileTablePreview": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qPreview" }, { "Name": "qFormatSpec" }] + }, + "GetFileTablesEx": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }], + "Out": [{ "Name": "qTables" }] + }, + "SendGenericCommandToCustomConnector": { + "In": [{ "Name": "qProvider","DefaultValue": "" }, { "Name": "qCommand","DefaultValue": "" }, { "Name": "qMethod","DefaultValue": "" }, { "Name": "qParameters","DefaultValue": [""] }, { "Name": "qAppendConnection","DefaultValue": "" }], + "Out": [{ "Name": "qResult" }] + }, + "SearchSuggest": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0, "qCharEncoding": 0, "qAttributes": [""]} }, { "Name": "qTerms","DefaultValue": [""] }], + "Out": [{ "Name": "qResult" }] + }, + "SearchAssociations": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0, "qCharEncoding": 0, "qAttributes": [""]} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qPage","DefaultValue": {"qOffset": 0, "qCount": 0, "qMaxNbrFieldMatches": 0, "qGroupOptions": [{"qGroupType": 0, "qOffset": 0, "qCount": 0}], "qGroupItemOptions": [{"qGroupItemType": 0, "qOffset": 0, "qCount": 0}]} }], + "Out": [{ "Name": "qResults" }] + }, + "SelectAssociations": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0, "qCharEncoding": 0, "qAttributes": [""]} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qMatchIx","DefaultValue": 0 }, { "Name": "qSoftLock","DefaultValue": null, "Optional": true }], + "Out": [] + }, + "SearchResults": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0, "qCharEncoding": 0, "qAttributes": [""]} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qPage","DefaultValue": {"qOffset": 0, "qCount": 0, "qMaxNbrFieldMatches": 0, "qGroupOptions": [{"qGroupType": 0, "qOffset": 0, "qCount": 0}], "qGroupItemOptions": [{"qGroupItemType": 0, "qOffset": 0, "qCount": 0}]} }], + "Out": [{ "Name": "qResult" }] + }, + "SearchObjects": { + "In": [{ "Name": "qOptions","DefaultValue": {"qAttributes": [""], "qCharEncoding": 0} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qPage","DefaultValue": {"qOffset": 0, "qCount": 0, "qMaxNbrFieldMatches": 0, "qGroupOptions": [{"qGroupType": 0, "qOffset": 0, "qCount": 0}], "qGroupItemOptions": [{"qGroupItemType": 0, "qOffset": 0, "qCount": 0}]} }], + "Out": [{ "Name": "qResult" }] + }, + "GetScriptEx": { + "In": [], + "Out": [{ "Name": "qScript" }] + } + }, + "Global":{ + "AbortRequest": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [] + }, + "AbortAll": { + "In": [], + "Out": [] + }, + "GetProgress": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [{ "Name": "qProgressData" }] + }, + "QvVersion": { + "In": [], + "Out": [] + }, + "OSVersion": { + "In": [], + "Out": [] + }, + "OSName": { + "In": [], + "Out": [] + }, + "QTProduct": { + "In": [], + "Out": [] + }, + "GetDocList": { + "In": [], + "Out": [{ "Name": "qDocList" }] + }, + "GetInteract": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [{ "Name": "qDef" }] + }, + "InteractDone": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }, { "Name": "qDef","DefaultValue": {"qType": 0, "qTitle": "", "qMsg": "", "qButtons": 0, "qLine": "", "qOldLineNr": 0, "qNewLineNr": 0, "qPath": "", "qHidden": false, "qResult": 0, "qInput": ""} }], + "Out": [] + }, + "GetAuthenticatedUser": { + "In": [], + "Out": [] + }, + "CreateDocEx": { + "In": [{ "Name": "qDocName","DefaultValue": "" }, { "Name": "qUserName","DefaultValue": "", "Optional": true }, { "Name": "qPassword","DefaultValue": "", "Optional": true }, { "Name": "qSerial","DefaultValue": "", "Optional": true }, { "Name": "qLocalizedScriptMainSection","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qDocId" }] + }, + "GetActiveDoc": { + "In": [], + "Out": [] + }, + "AllowCreateApp": { + "In": [], + "Out": [] + }, + "CreateApp": { + "In": [{ "Name": "qAppName","DefaultValue": "" }, { "Name": "qLocalizedScriptMainSection","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qSuccess" }, { "Name": "qAppId" }] + }, + "DeleteApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "IsDesktopMode": { + "In": [], + "Out": [] + }, + "GetConfiguration": { + "In": [], + "Out": [{ "Name": "qConfig" }] + }, + "CancelRequest": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [] + }, + "ShutdownProcess": { + "In": [], + "Out": [] + }, + "ReloadExtensionList": { + "In": [], + "Out": [] + }, + "ReplaceAppFromID": { + "In": [{ "Name": "qTargetAppId","DefaultValue": "" }, { "Name": "qSrcAppID","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "ReplaceAppFromPath": { + "In": [{ "Name": "qTargetAppId","DefaultValue": "" }, { "Name": "qSrcPath","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }, { "Name": "qNoData","DefaultValue": false }], + "Out": [] + }, + "CopyApp": { + "In": [{ "Name": "qTargetAppId","DefaultValue": "" }, { "Name": "qSrcAppId","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "ImportApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qSrcPath","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "ImportAppEx": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qSrcPath","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }, { "Name": "qExcludeConnections","DefaultValue": false }], + "Out": [] + }, + "ExportApp": { + "In": [{ "Name": "qTargetPath","DefaultValue": "" }, { "Name": "qSrcAppId","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }, { "Name": "qNoData","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "PublishApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qName","DefaultValue": "" }, { "Name": "qStreamId","DefaultValue": "" }], + "Out": [] + }, + "IsPersonalMode": { + "In": [], + "Out": [] + }, + "GetUniqueID": { + "In": [], + "Out": [{ "Name": "qUniqueID" }] + }, + "OpenDoc": { + "In": [{ "Name": "qDocName","DefaultValue": "" }, { "Name": "qUserName","DefaultValue": "", "Optional": true }, { "Name": "qPassword","DefaultValue": "", "Optional": true }, { "Name": "qSerial","DefaultValue": "", "Optional": true }, { "Name": "qNoData","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "CreateSessionApp": { + "In": [], + "Out": [{ "Name": "qSessionAppId" }] + }, + "CreateSessionAppFromApp": { + "In": [{ "Name": "qSrcAppId","DefaultValue": "" }], + "Out": [{ "Name": "qSessionAppId" }] + }, + "ProductVersion": { + "In": [], + "Out": [] + }, + "GetAppEntry": { + "In": [{ "Name": "qAppID","DefaultValue": "" }], + "Out": [{ "Name": "qEntry" }] + }, + "ConfigureReload": { + "In": [{ "Name": "qCancelOnScriptError","DefaultValue": false }, { "Name": "qUseErrorData","DefaultValue": false }, { "Name": "qInteractOnError","DefaultValue": false }], + "Out": [] + }, + "CancelReload": { + "In": [], + "Out": [] + }, + "GetBNF": { + "In": [{ "Name": "qBnfType","DefaultValue": 0 }], + "Out": [{ "Name": "qBnfDefs" }] + }, + "GetFunctions": { + "In": [{ "Name": "qGroup","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qFunctions" }] + }, + "GetOdbcDsns": { + "In": [], + "Out": [{ "Name": "qOdbcDsns" }] + }, + "GetOleDbProviders": { + "In": [], + "Out": [{ "Name": "qOleDbProviders" }] + }, + "GetDatabasesFromConnectionString": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }], + "Out": [{ "Name": "qDatabases" }] + }, + "IsValidConnectionString": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }], + "Out": [] + }, + "GetDefaultAppFolder": { + "In": [], + "Out": [{ "Name": "qPath" }] + }, + "GetMyDocumentsFolder": { + "In": [], + "Out": [{ "Name": "qFolder" }] + }, + "GetLogicalDriveStrings": { + "In": [], + "Out": [{ "Name": "qDrives" }] + }, + "GetFolderItemsForPath": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [{ "Name": "qFolderItems" }] + }, + "GetSupportedCodePages": { + "In": [], + "Out": [{ "Name": "qCodePages" }] + }, + "GetCustomConnectors": { + "In": [{ "Name": "qReloadList","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qConnectors" }] + }, + "GetStreamList": { + "In": [], + "Out": [{ "Name": "qStreamList" }] + }, + "EngineVersion": { + "In": [], + "Out": [{ "Name": "qVersion" }] + }, + "GetBaseBNF": { + "In": [{ "Name": "qBnfType","DefaultValue": 0 }], + "Out": [{ "Name": "qBnfDefs" }, { "Name": "qBnfHash" }] + }, + "GetBaseBNFHash": { + "In": [{ "Name": "qBnfType","DefaultValue": 0 }], + "Out": [{ "Name": "qBnfHash" }] + }, + "GetBaseBNFString": { + "In": [{ "Name": "qBnfType","DefaultValue": 0 }], + "Out": [{ "Name": "qBnfStr" }, { "Name": "qBnfHash" }] + } + } + }, + "enums": { + "LocalizedMessageCode": { + "LOCMSG_SCRIPTEDITOR_EMPTY_MESSAGE": 0, + "LOCMSG_SCRIPTEDITOR_PROGRESS_SAVING_STARTED": 1, + "LOCMSG_SCRIPTEDITOR_PROGRESS_BYTES_LEFT": 2, + "LOCMSG_SCRIPTEDITOR_PROGRESS_STORING_TABLES": 3, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_ROWS_SO_FAR": 4, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECTED": 5, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECTING_TO": 6, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECT_FAILED": 7, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_ROWISH": 8, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_COLUMNAR": 9, + "LOCMSG_SCRIPTEDITOR_ERROR": 10, + "LOCMSG_SCRIPTEDITOR_DONE": 11, + "LOCMSG_SCRIPTEDITOR_LOAD_EXTERNAL_DATA": 12, + "LOCMSG_SCRIPTEDITOR_PROGRESS_OLD_QVD_ISLOADING": 13, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_LOADING": 14, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_BUFFERED": 15, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_PREPARING": 16, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_APPENDING": 17, + "LOCMSG_SCRIPTEDITOR_REMOVE_SYNTHETIC": 18, + "LOCMSG_SCRIPTEDITOR_PENDING_LINKEDTABLE_FETCHING": 19, + "LOCMSG_SCRIPTEDITOR_RELOAD": 20, + "LOCMSG_SCRIPTEDITOR_LINES_FETCHED": 21, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_START": 22, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_FIELD": 23, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_SUCCESS": 24, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_FAILURE": 25, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_STARTABORT": 26, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_ENDABORT": 27, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_TIMEOUT": 28, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_OUTOFMEMORY": 29 + }, + "LocalizedErrorCode": { + "LOCERR_INTERNAL_ERROR": -128, + "LOCERR_GENERIC_UNKNOWN": -1, + "LOCERR_GENERIC_OK": 0, + "LOCERR_GENERIC_NOT_SET": 1, + "LOCERR_GENERIC_NOT_FOUND": 2, + "LOCERR_GENERIC_ALREADY_EXISTS": 3, + "LOCERR_GENERIC_INVALID_PATH": 4, + "LOCERR_GENERIC_ACCESS_DENIED": 5, + "LOCERR_GENERIC_OUT_OF_MEMORY": 6, + "LOCERR_GENERIC_NOT_INITIALIZED": 7, + "LOCERR_GENERIC_INVALID_PARAMETERS": 8, + "LOCERR_GENERIC_EMPTY_PARAMETERS": 9, + "LOCERR_GENERIC_INTERNAL_ERROR": 10, + "LOCERR_GENERIC_CORRUPT_DATA": 11, + "LOCERR_GENERIC_MEMORY_INCONSISTENCY": 12, + "LOCERR_GENERIC_INVISIBLE_OWNER_ABORT": 13, + "LOCERR_GENERIC_PROHIBIT_VALIDATE": 14, + "LOCERR_GENERIC_ABORTED": 15, + "LOCERR_GENERIC_CONNECTION_LOST": 16, + "LOCERR_GENERIC_UNSUPPORTED_IN_PRODUCT_VERSION": 17, + "LOCERR_GENERIC_REST_CONNECTION_FAILURE": 18, + "LOCERR_GENERIC_MEMORY_LIMIT_REACHED": 19, + "LOCERR_HTTP_400": 400, + "LOCERR_HTTP_401": 401, + "LOCERR_HTTP_402": 402, + "LOCERR_HTTP_403": 403, + "LOCERR_HTTP_404": 404, + "LOCERR_HTTP_405": 405, + "LOCERR_HTTP_406": 406, + "LOCERR_HTTP_407": 407, + "LOCERR_HTTP_408": 408, + "LOCERR_HTTP_409": 409, + "LOCERR_HTTP_410": 410, + "LOCERR_HTTP_411": 411, + "LOCERR_HTTP_412": 412, + "LOCERR_HTTP_413": 413, + "LOCERR_HTTP_414": 414, + "LOCERR_HTTP_415": 415, + "LOCERR_HTTP_416": 416, + "LOCERR_HTTP_417": 417, + "LOCERR_HTTP_422": 422, + "LOCERR_HTTP_429": 429, + "LOCERR_HTTP_500": 500, + "LOCERR_HTTP_501": 501, + "LOCERR_HTTP_502": 502, + "LOCERR_HTTP_503": 503, + "LOCERR_HTTP_504": 504, + "LOCERR_HTTP_505": 505, + "LOCERR_HTTP_509": 509, + "LOCERR_HTTP_COULD_NOT_RESOLVE_HOST": 700, + "LOCERR_APP_ALREADY_EXISTS": 1000, + "LOCERR_APP_INVALID_NAME": 1001, + "LOCERR_APP_ALREADY_OPEN": 1002, + "LOCERR_APP_NOT_FOUND": 1003, + "LOCERR_APP_IMPORT_FAILED": 1004, + "LOCERR_APP_SAVE_FAILED": 1005, + "LOCERR_APP_CREATE_FAILED": 1006, + "LOCERR_APP_INVALID": 1007, + "LOCERR_APP_CONNECT_FAILED": 1008, + "LOCERR_APP_ALREADY_OPEN_IN_DIFFERENT_MODE": 1009, + "LOCERR_APP_MIGRATION_COULD_NOT_CONTACT_MIGRATION_SERVICE": 1010, + "LOCERR_APP_MIGRATION_COULD_NOT_START_MIGRATION": 1011, + "LOCERR_APP_MIGRATION_FAILURE": 1012, + "LOCERR_APP_SCRIPT_MISSING": 1013, + "LOCERR_APP_EXPORT_FAILED": 1014, + "LOCERR_CONNECTION_ALREADY_EXISTS": 2000, + "LOCERR_CONNECTION_NOT_FOUND": 2001, + "LOCERR_CONNECTION_FAILED_TO_LOAD": 2002, + "LOCERR_CONNECTION_FAILED_TO_IMPORT": 2003, + "LOCERR_CONNECTION_NAME_IS_INVALID": 2004, + "LOCERR_CONNECTOR_NO_FILE_STREAMING_SUPPORT": 2300, + "LOCERR_CONNECTOR_FILESIZE_EXCEEDED_BUFFER_SIZE": 2301, + "LOCERR_FILE_ACCESS_DENIED": 3000, + "LOCERR_FILE_NAME_INVALID": 3001, + "LOCERR_FILE_CORRUPT": 3002, + "LOCERR_FILE_NOT_FOUND": 3003, + "LOCERR_FILE_FORMAT_UNSUPPORTED": 3004, + "LOCERR_FILE_OPENED_IN_UNSUPPORTED_MODE": 3005, + "LOCERR_FILE_TABLE_NOT_FOUND": 3006, + "LOCERR_USER_ACCESS_DENIED": 4000, + "LOCERR_USER_IMPERSONATION_FAILED": 4001, + "LOCERR_SERVER_OUT_OF_SESSION_AND_USER_CALS": 5000, + "LOCERR_SERVER_OUT_OF_SESSION_CALS": 5001, + "LOCERR_SERVER_OUT_OF_USAGE_CALS": 5002, + "LOCERR_SERVER_OUT_OF_CALS": 5003, + "LOCERR_SERVER_OUT_OF_NAMED_CALS": 5004, + "LOCERR_SERVER_OFF_DUTY": 5005, + "LOCERR_SERVER_BUSY": 5006, + "LOCERR_SERVER_LICENSE_EXPIRED": 5007, + "LOCERR_SERVER_AJAX_DISABLED": 5008, + "LOCERR_HC_INVALID_OBJECT": 6000, + "LOCERR_HC_RESULT_TOO_LARGE": 6001, + "LOCERR_HC_INVALID_OBJECT_STATE": 6002, + "LOCERR_HC_MODAL_OBJECT_ERROR": 6003, + "LOCERR_CALC_INVALID_DEF": 7000, + "LOCERR_CALC_NOT_IN_LIB": 7001, + "LOCERR_CALC_HEAP_ERROR": 7002, + "LOCERR_CALC_TOO_LARGE": 7003, + "LOCERR_CALC_TIMEOUT": 7004, + "LOCERR_CALC_EVAL_CONDITION_FAILED": 7005, + "LOCERR_CALC_MIXED_LINKED_AGGREGATION": 7006, + "LOCERR_CALC_MISSING_LINKED": 7007, + "LOCERR_CALC_INVALID_COL_SORT": 7008, + "LOCERR_CALC_PAGES_TOO_LARGE": 7009, + "LOCERR_CALC_SEMANTIC_FIELD_NOT_ALLOWED": 7010, + "LOCERR_CALC_VALIDATION_STATE_INVALID": 7011, + "LOCERR_CALC_PIVOT_DIMENSIONS_ALREADY_EXISTS": 7012, + "LOCERR_CALC_MISSING_LINKED_FIELD": 7013, + "LOCERR_CALC_NOT_CALCULATED": 7014, + "LOCERR_LAYOUT_EXTENDS_INVALID_ID": 8000, + "LOCERR_LAYOUT_LINKED_OBJECT_NOT_FOUND": 8001, + "LOCERR_LAYOUT_LINKED_OBJECT_INVALID": 8002, + "LOCERR_PERSISTENCE_WRITE_FAILED": 9000, + "LOCERR_PERSISTENCE_READ_FAILED": 9001, + "LOCERR_PERSISTENCE_DELETE_FAILED": 9002, + "LOCERR_PERSISTENCE_NOT_FOUND": 9003, + "LOCERR_PERSISTENCE_UNSUPPORTED_VERSION": 9004, + "LOCERR_PERSISTENCE_MIGRATION_FAILED_READ_ONLY": 9005, + "LOCERR_PERSISTENCE_MIGRATION_CANCELLED": 9006, + "LOCERR_PERSISTENCE_MIGRATION_BACKUP_FAILED": 9007, + "LOCERR_PERSISTENCE_DISK_FULL": 9008, + "LOCERR_PERSISTENCE_NOT_SUPPORTED_FOR_SESSION_APP": 9009, + "LOCERR_PERSISTENCE_SYNC_SET_CHUNK_INVALID_PARAMETERS": 9510, + "LOCERR_PERSISTENCE_SYNC_GET_CHUNK_INVALID_PARAMETERS": 9511, + "LOCERR_SCRIPT_DATASOURCE_ACCESS_DENIED": 10000, + "LOCERR_RELOAD_IN_PROGRESS": 11000, + "LOCERR_RELOAD_TABLE_X_NOT_FOUND": 11001, + "LOCERR_RELOAD_UNKNOWN_STATEMENT": 11002, + "LOCERR_RELOAD_EXPECTED_SOMETHING_FOUND_UNKNOWN": 11003, + "LOCERR_RELOAD_EXPECTED_NOTHING_FOUND_UNKNOWN": 11004, + "LOCERR_RELOAD_EXPECTED_ONE_OF_1_TOKENS_FOUND_UNKNOWN": 11005, + "LOCERR_RELOAD_EXPECTED_ONE_OF_2_TOKENS_FOUND_UNKNOWN": 11006, + "LOCERR_RELOAD_EXPECTED_ONE_OF_3_TOKENS_FOUND_UNKNOWN": 11007, + "LOCERR_RELOAD_EXPECTED_ONE_OF_4_TOKENS_FOUND_UNKNOWN": 11008, + "LOCERR_RELOAD_EXPECTED_ONE_OF_5_TOKENS_FOUND_UNKNOWN": 11009, + "LOCERR_RELOAD_EXPECTED_ONE_OF_6_TOKENS_FOUND_UNKNOWN": 11010, + "LOCERR_RELOAD_EXPECTED_ONE_OF_7_TOKENS_FOUND_UNKNOWN": 11011, + "LOCERR_RELOAD_EXPECTED_ONE_OF_8_OR_MORE_TOKENS_FOUND_UNKNOWN": 11012, + "LOCERR_RELOAD_FIELD_X_NOT_FOUND": 11013, + "LOCERR_RELOAD_MAPPING_TABLE_X_NOT_FOUND": 11014, + "LOCERR_RELOAD_LIB_CONNECTION_X_NOT_FOUND": 11015, + "LOCERR_RELOAD_NAME_ALREADY_TAKEN": 11016, + "LOCERR_RELOAD_WRONG_FILE_FORMAT_DIF": 11017, + "LOCERR_RELOAD_WRONG_FILE_FORMAT_BIFF": 11018, + "LOCERR_RELOAD_WRONG_FILE_FORMAT_ENCRYPTED": 11019, + "LOCERR_RELOAD_OPEN_FILE_ERROR": 11020, + "LOCERR_RELOAD_AUTO_GENERATE_COUNT": 11021, + "LOCERR_RELOAD_PE_ILLEGAL_PREFIX_COMB": 11022, + "LOCERR_RELOAD_MATCHING_CONTROL_STATEMENT_ERROR": 11023, + "LOCERR_RELOAD_MATCHING_LIBPATH_X_NOT_FOUND": 11024, + "LOCERR_RELOAD_MATCHING_LIBPATH_X_INVALID": 11025, + "LOCERR_RELOAD_MATCHING_LIBPATH_X_OUTSIDE": 11026, + "LOCERR_RELOAD_NO_QUALIFIED_PATH_FOR_FILE": 11027, + "LOCERR_RELOAD_MODE_STATEMENT_ONLY_FOR_LIB_PATHS": 11028, + "LOCERR_RELOAD_INCONSISTENT_USE_OF_SEMANTIC_FIELDS": 11029, + "LOCERR_RELOAD_NO_OPEN_DATABASE": 11030, + "LOCERR_RELOAD_AGGREGATION_REQUIRED_BY_GROUP_BY": 11031, + "LOCERR_RELOAD_CONNECT_MUST_USE_LIB_PREFIX_IN_THIS_MODE": 11032, + "LOCERR_RELOAD_ODBC_CONNECT_FAILED": 11033, + "LOCERR_RELOAD_OLEDB_CONNECT_FAILED": 11034, + "LOCERR_RELOAD_CUSTOM_CONNECT_FAILED": 11035, + "LOCERR_RELOAD_ODBC_READ_FAILED": 11036, + "LOCERR_RELOAD_OLEDB_READ_FAILED": 11037, + "LOCERR_RELOAD_CUSTOM_READ_FAILED": 11038, + "LOCERR_RELOAD_BINARY_LOAD_PROHIBITED": 11039, + "LOCERR_RELOAD_CONNECTOR_START_FAILED": 11040, + "LOCERR_RELOAD_CONNECTOR_NOT_RESPONDING": 11041, + "LOCERR_RELOAD_CONNECTOR_REPLY_ERROR": 11042, + "LOCERR_RELOAD_CONNECTOR_CONNECT_ERROR": 11043, + "LOCERR_RELOAD_CONNECTOR_NOT_FOUND_ERROR": 11044, + "LOCERR_RELOAD_INPUT_FIELD_WITH_DUPLICATE_KEYS": 11045, + "LOCERR_RELOAD_CONCATENATE_LOAD_NO_PREVIOUS_TABLE": 11046, + "LOCERR_PERSONAL_NEW_VERSION_AVAILABLE": 12000, + "LOCERR_PERSONAL_VERSION_EXPIRED": 12001, + "LOCERR_PERSONAL_SECTION_ACCESS_DETECTED": 12002, + "LOCERR_PERSONAL_APP_DELETION_FAILED": 12003, + "LOCERR_USER_AUTHENTICATION_FAILURE": 12004, + "LOCERR_EXPORT_OUT_OF_MEMORY": 13000, + "LOCERR_EXPORT_NO_DATA": 13001, + "LOCERR_SYNC_INVALID_OFFSET": 14000, + "LOCERR_SEARCH_TIMEOUT": 15000, + "LOCERR_DIRECT_DISCOVERY_LINKED_EXPRESSION_FAIL": 16000, + "LOCERR_DIRECT_DISCOVERY_ROWCOUNT_OVERFLOW": 16001, + "LOCERR_DIRECT_DISCOVERY_EMPTY_RESULT": 16002, + "LOCERR_DIRECT_DISCOVERY_DB_CONNECTION_FAILED": 16003, + "LOCERR_DIRECT_DISCOVERY_MEASURE_NOT_ALLOWED": 16004, + "LOCERR_DIRECT_DISCOVERY_DETAIL_NOT_ALLOWED": 16005, + "LOCERR_DIRECT_DISCOVERY_NOT_SYNTH_CIRCULAR_ALLOWED": 16006, + "LOCERR_DIRECT_DISCOVERY_ONLY_ONE_DD_TABLE_ALLOWED": 16007, + "LOCERR_DIRECT_DISCOVERY_DB_AUTHORIZATION_FAILED": 16008, + "LOCERR_SMART_LOAD_TABLE_NOT_FOUND": 17000, + "LOCERR_SMART_LOAD_TABLE_DUPLICATED": 17001, + "LOCERR_VARIABLE_NO_NAME": 18000, + "LOCERR_VARIABLE_DUPLICATE_NAME": 18001, + "LOCERR_VARIABLE_INCONSISTENCY": 18002, + "LOCERR_MEDIA_LIBRARY_LIST_FAILED": 19000, + "LOCERR_MEDIA_LIBRARY_CONTENT_FAILED": 19001, + "LOCERR_MEDIA_BUNDLING_FAILED": 19002, + "LOCERR_MEDIA_UNBUNDLING_FAILED": 19003, + "LOCERR_MEDIA_LIBRARY_NOT_FOUND": 19004, + "LOCERR_FEATURE_DISABLED": 20000, + "LOCERR_JSON_RPC_INVALID_REQUEST": -32600, + "LOCERR_JSON_RPC_METHOD_NOT_FOUND": -32601, + "LOCERR_JSON_RPC_INVALID_PARAMETERS": -32602, + "LOCERR_JSON_RPC_INTERNAL_ERROR": -32603, + "LOCERR_JSON_RPC_PARSE_ERROR": -32700, + "LOCERR_MQ_SOCKET_CONNECT_FAILURE": 33000, + "LOCERR_MQ_SOCKET_OPEN_FAILURE": 33001, + "LOCERR_MQ_PROTOCOL_NO_RESPONE": 33002, + "LOCERR_MQ_PROTOCOL_LIBRARY_EXCEPTION": 33003, + "LOCERR_MQ_PROTOCOL_CONNECTION_CLOSED": 33004, + "LOCERR_MQ_PROTOCOL_CHANNEL_CLOSED": 33005, + "LOCERR_MQ_PROTOCOL_UNKNOWN_ERROR": 33006, + "LOCERR_MQ_PROTOCOL_INVALID_STATUS": 33007, + "LOCERR_EXTENGINE_GRPC_STATUS_OK": 22000, + "LOCERR_EXTENGINE_GRPC_STATUS_CANCELLED": 22001, + "LOCERR_EXTENGINE_GRPC_STATUS_UNKNOWN": 22002, + "LOCERR_EXTENGINE_GRPC_STATUS_INVALID_ARGUMENT": 22003, + "LOCERR_EXTENGINE_GRPC_STATUS_DEADLINE_EXCEEDED": 22004, + "LOCERR_EXTENGINE_GRPC_STATUS_NOT_FOUND": 22005, + "LOCERR_EXTENGINE_GRPC_STATUS_ALREADY_EXISTS": 22006, + "LOCERR_EXTENGINE_GRPC_STATUS_PERMISSION_DENIED": 22007, + "LOCERR_EXTENGINE_GRPC_STATUS_RESOURCE_EXHAUSTED": 22008, + "LOCERR_EXTENGINE_GRPC_STATUS_FAILED_PRECONDITION": 22009, + "LOCERR_EXTENGINE_GRPC_STATUS_ABORTED": 22010, + "LOCERR_EXTENGINE_GRPC_STATUS_OUT_OF_RANGE": 22011, + "LOCERR_EXTENGINE_GRPC_STATUS_UNIMPLEMENTED": 22012, + "LOCERR_EXTENGINE_GRPC_STATUS_INTERNAL": 22013, + "LOCERR_EXTENGINE_GRPC_STATUS_UNAVAILABLE": 22014, + "LOCERR_EXTENGINE_GRPC_STATUS_DATA_LOSS": 22015, + "LOCERR_EXTENGINE_GRPC_STATUS_UNAUTHENTICATED": 22016, + "LOCERR_LXW_INVALID_OBJ": 23001, + "LOCERR_LXW_INVALID_FILE": 23002, + "LOCERR_LXW_INVALID_SHEET": 23003, + "LOCERR_LXW_INVALID_EXPORT_RANGE": 23004, + "LOCERR_LXW_ERROR": 23005, + "LOCERR_LXW_ERROR_MEMORY_MALLOC_FAILED": 23006, + "LOCERR_LXW_ERROR_CREATING_XLSX_FILE": 23007, + "LOCERR_LXW_ERROR_CREATING_TMPFILE": 23008, + "LOCERR_LXW_ERROR_ZIP_FILE_OPERATION": 23009, + "LOCERR_LXW_ERROR_ZIP_FILE_ADD": 23010, + "LOCERR_LXW_ERROR_ZIP_CLOSE": 23011, + "LOCERR_LXW_ERROR_NULL_PARAMETER_IGNORED": 23012, + "LOCERR_LXW_ERROR_MAX_STRING_LENGTH_EXCEEDED": 23013, + "LOCERR_LXW_ERROR_255_STRING_LENGTH_EXCEEDED": 23014, + "LOCERR_LXW_ERROR_SHARED_STRING_INDEX_NOT_FOUND": 23015, + "LOCERR_LXW_ERROR_WORKSHEET_INDEX_OUT_OF_RANGE": 23016, + "LOCERR_LXW_ERROR_WORKSHEET_MAX_NUMBER_URLS_EXCEEDED": 23017, + "LOCERR_CURL_UNSUPPORTED_PROTOCOL": 30000, + "LOCERR_CURL_COULDNT_RESOLVE_PROXY": 30001, + "LOCERR_CURL_COULDNT_CONNECT": 30002, + "LOCERR_CURL_REMOTE_ACCESS_DENIED": 30003, + "LOCERR_CURL_FTP_ACCEPT_FAILED": 30004, + "LOCERR_CURL_FTP_ACCEPT_TIMEOUT": 30005, + "LOCERR_CURL_FTP_CANT_GET_HOST": 30006, + "LOCERR_CURL_PARTIAL_FILE": 30007, + "LOCERR_CURL_QUOTE_ERROR": 30008, + "LOCERR_CURL_WRITE_ERROR": 30009, + "LOCERR_CURL_UPLOAD_FAILED": 30010, + "LOCERR_CURL_OUT_OF_MEMORY": 30011, + "LOCERR_CURL_OPERATION_TIMEDOUT": 30012, + "LOCERR_CURL_FTP_COULDNT_USE_REST": 30013, + "LOCERR_CURL_HTTP_POST_ERROR": 30014, + "LOCERR_CURL_SSL_CONNECT_ERROR": 30015, + "LOCERR_CURL_FILE_COULDNT_READ_FILE": 30016, + "LOCERR_CURL_LDAP_CANNOT_BIND": 30017, + "LOCERR_CURL_LDAP_SEARCH_FAILED": 30018, + "LOCERR_CURL_TOO_MANY_REDIRECTS": 30019, + "LOCERR_CURL_PEER_FAILED_VERIFICATION": 30020, + "LOCERR_CURL_GOT_NOTHING": 30021, + "LOCERR_CURL_SSL_ENGINE_NOTFOUND": 30022, + "LOCERR_CURL_SSL_ENGINE_SETFAILED": 30023, + "LOCERR_CURL_SSL_CERTPROBLEM": 30024, + "LOCERR_CURL_SSL_CIPHER": 30025, + "LOCERR_CURL_SSL_CACERT": 30026, + "LOCERR_CURL_BAD_CONTENT_ENCODING": 30027, + "LOCERR_CURL_LDAP_INVALID_URL": 30028, + "LOCERR_CURL_USE_SSL_FAILED": 30029, + "LOCERR_CURL_SSL_ENGINE_INITFAILED": 30030, + "LOCERR_CURL_LOGIN_DENIED": 30031, + "LOCERR_CURL_TFTP_NOTFOUND": 30032, + "LOCERR_CURL_TFTP_ILLEGAL": 30033, + "LOCERR_CURL_SSH": 30034 + }, + "LocalizedWarningCode": { + "LOCWARN_PERSONAL_RELOAD_REQUIRED": 0, + "LOCWARN_PERSONAL_VERSION_EXPIRES_SOON": 1, + "LOCWARN_EXPORT_DATA_TRUNCATED": 1000, + "LOCWARN_COULD_NOT_OPEN_ALL_OBJECTS": 2000 + }, + "GrpType": { + "GRP_NX_NONE": 0, + "GRP_NX_HIEARCHY": 1, + "GRP_NX_COLLECTION": 2 + }, + "ExportFileType": { + "EXPORT_CSV_C": 0, + "EXPORT_CSV_T": 1, + "EXPORT_OOXML": 2 + }, + "ExportState": { + "EXPORT_POSSIBLE": 0, + "EXPORT_ALL": 1 + }, + "DimCellType": { + "NX_DIM_CELL_VALUE": 0, + "NX_DIM_CELL_EMPTY": 1, + "NX_DIM_CELL_NORMAL": 2, + "NX_DIM_CELL_TOTAL": 3, + "NX_DIM_CELL_OTHER": 4, + "NX_DIM_CELL_AGGR": 5, + "NX_DIM_CELL_PSEUDO": 6, + "NX_DIM_CELL_ROOT": 7, + "NX_DIM_CELL_NULL": 8, + "NX_DIM_CELL_GENERATED": 9 + }, + "StackElemType": { + "NX_STACK_CELL_NORMAL": 0, + "NX_STACK_CELL_TOTAL": 1, + "NX_STACK_CELL_OTHER": 2, + "NX_STACK_CELL_SUM": 3, + "NX_STACK_CELL_VALUE": 4, + "NX_STACK_CELL_PSEUDO": 5 + }, + "SortIndicatorType": { + "NX_SORT_INDICATE_NONE": 0, + "NX_SORT_INDICATE_ASC": 1, + "NX_SORT_INDICATE_DESC": 2 + }, + "DimensionType": { + "NX_DIMENSION_TYPE_DISCRETE": 0, + "NX_DIMENSION_TYPE_NUMERIC": 1, + "NX_DIMENSION_TYPE_TIME": 2 + }, + "FieldSelectionMode": { + "SELECTION_MODE_NORMAL": 0, + "SELECTION_MODE_AND": 1, + "SELECTION_MODE_NOT": 2 + }, + "FrequencyMode": { + "NX_FREQUENCY_NONE": 0, + "NX_FREQUENCY_VALUE": 1, + "NX_FREQUENCY_PERCENT": 2, + "NX_FREQUENCY_RELATIVE": 3 + }, + "DataReductionMode": { + "DATA_REDUCTION_NONE": 0, + "DATA_REDUCTION_ONEDIM": 1, + "DATA_REDUCTION_SCATTERED": 2, + "DATA_REDUCTION_CLUSTERED": 3, + "DATA_REDUCTION_STACKED": 4 + }, + "HypercubeMode": { + "DATA_MODE_STRAIGHT": 0, + "DATA_MODE_PIVOT": 1, + "DATA_MODE_PIVOT_STACK": 2, + "DATA_MODE_TREE": 3 + }, + "PatchOperationType": { + "Add": 0, + "Remove": 1, + "Replace": 2 + }, + "SelectionCellType": { + "NX_CELL_DATA": 0, + "NX_CELL_TOP": 1, + "NX_CELL_LEFT": 2 + }, + "MatchingFieldMode": { + "MATCHINGFIELDMODE_MATCH_ALL": 0, + "MATCHINGFIELDMODE_MATCH_ONE": 1 + }, + "SessionState": { + "SESSION_CREATED": 0, + "SESSION_ATTACHED": 1, + "SESSION_ERROR_NO_LICENSE": 2, + "SESSION_ERROR_LICENSE_RENEW": 3 + }, + "ReloadState": { + "RELOAD_PAUSED": 0, + "RELOAD_STARTED": 1, + "RELOAD_ABORTED": 2 + }, + "QrsChangeType": { + "QRS_CHANGE_UNDEFINED": 0, + "QRS_CHANGE_ADD": 1, + "QRS_CHANGE_UPDATE": 2, + "QRS_CHANGE_DELETE": 3 + }, + "ExtEngineDataType": { + "NX_EXT_DATATYPE_STRING": 0, + "NX_EXT_DATATYPE_DOUBLE": 1, + "NX_EXT_DATATYPE_BOTH": 2 + }, + "ExtEngineFunctionType": { + "NX_EXT_FUNCTIONTYPE_SCALAR": 0, + "NX_EXT_FUNCTIONTYPE_AGGR": 1, + "NX_EXT_FUNCTIONTYPE_TENSOR": 2 + }, + "ExtEngineMsgType": { + "NX_EXT_MSGTYPE_FUNCTION_CALL": 1, + "NX_EXT_MSGTYPE_SCRIPT_CALL": 2, + "NX_EXT_MSGTYPE_RETURN_VALUE": 3, + "NX_EXT_MSGTYPE_RETURN_MULTIPLE": 4, + "NX_EXT_MSGTYPE_RETURN_ERROR": 5 + } + }, + "version": "12.170.2" +} diff --git a/jwt-scratch/src/js/node_modules/enigma.js/schemas/12.20.0.json b/jwt-scratch/src/js/node_modules/enigma.js/schemas/12.20.0.json new file mode 100644 index 0000000..eb3e09d --- /dev/null +++ b/jwt-scratch/src/js/node_modules/enigma.js/schemas/12.20.0.json @@ -0,0 +1,1562 @@ +{ + "structs": { + "Field":{ + "GetCardinal": { + "In": [], + "Out": [] + }, + "GetAndMode": { + "In": [], + "Out": [] + }, + "SelectValues": { + "In": [{ "Name": "qFieldValues","DefaultValue": [{"qText": "", "qIsNumeric": false, "qNumber": 0}] }, { "Name": "qToggleMode","DefaultValue": false, "Optional": true }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Select": { + "In": [{ "Name": "qMatch","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qExcludedValuesMode","DefaultValue": 0, "Optional": true }], + "Out": [] + }, + "ToggleSelect": { + "In": [{ "Name": "qMatch","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qExcludedValuesMode","DefaultValue": 0, "Optional": true }], + "Out": [] + }, + "ClearAllButThis": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectPossible": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectExcluded": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectAll": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Lock": { + "In": [], + "Out": [] + }, + "Unlock": { + "In": [], + "Out": [] + }, + "GetNxProperties": { + "In": [], + "Out": [{ "Name": "qProperties" }] + }, + "SetNxProperties": { + "In": [{ "Name": "qProperties","DefaultValue": {"qOneAndOnlyOne": false} }], + "Out": [] + }, + "SetAndMode": { + "In": [{ "Name": "qAndMode","DefaultValue": false }], + "Out": [] + }, + "SelectAlternative": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "LowLevelSelect": { + "In": [{ "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Clear": { + "In": [], + "Out": [] + } + }, + "Variable":{ + "GetContent": { + "In": [], + "Out": [{ "Name": "qContent" }] + }, + "GetRawContent": { + "In": [], + "Out": [] + }, + "SetContent": { + "In": [{ "Name": "qContent","DefaultValue": "" }, { "Name": "qUpdateMRU","DefaultValue": false }], + "Out": [] + }, + "ForceContent": { + "In": [{ "Name": "qs","DefaultValue": "" }, { "Name": "qd","DefaultValue": 0 }], + "Out": [] + }, + "GetNxProperties": { + "In": [], + "Out": [{ "Name": "qProperties" }] + }, + "SetNxProperties": { + "In": [{ "Name": "qProperties","DefaultValue": {"qName": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qUsePredefListedValues": false, "qPreDefinedList": [""]} }], + "Out": [] + } + }, + "GenericObject":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "GetListObjectData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeReducedData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qZoomFactor","DefaultValue": 0 }, { "Name": "qReductionMode","DefaultValue": 0 }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubePivotData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeStackData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qMaxNbrCells","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeContinuousData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qOptions","DefaultValue": {"qStart": 0, "qEnd": 0, "qNbrPoints": 0, "qMaxNbrTicks": 0, "qMaxNumberLines": 0} }, { "Name": "qReverseSort","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qDataPages" }, { "Name": "qAxisData" }] + }, + "GetHyperCubeBinnedData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qViewport","DefaultValue": {"qWidth": 0, "qHeight": 0, "qZoomLevel": 0} }, { "Name": "qDataRanges","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qMaxNbrCells","DefaultValue": 0 }, { "Name": "qQueryLevel","DefaultValue": 0 }, { "Name": "qBinningMethod","DefaultValue": 0 }], + "Out": [{ "Name": "qDataPages" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }, { "Name": "qSoftPatch","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "ClearSoftPatches": { + "In": [], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetEffectiveProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "SetFullPropertyTree": { + "In": [{ "Name": "qPropEntry","DefaultValue": {"qProperty": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}}, "qChildren": [], "qEmbeddedSnapshotRef": null} }], + "Out": [] + }, + "GetFullPropertyTree": { + "In": [], + "Out": [{ "Name": "qPropEntry" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "ClearSelections": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "ExportData": { + "In": [{ "Name": "qFileType","DefaultValue": 0 }, { "Name": "qPath","DefaultValue": "", "Optional": true }, { "Name": "qFileName","DefaultValue": "", "Optional": true }, { "Name": "qExportState","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qUrl" }, { "Name": "qWarnings" }] + }, + "SelectListObjectValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectPossible": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectExcluded": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectAlternative": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectAll": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectContinuousRange": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SearchListObjectFor": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qMatch","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "AbortListObjectSearch": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [] + }, + "AcceptListObjectSearch": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "ExpandLeft": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "ExpandTop": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "CollapseLeft": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "CollapseTop": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "DrillUp": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qDimNo","DefaultValue": 0 }, { "Name": "qNbrSteps","DefaultValue": 0 }], + "Out": [] + }, + "Lock": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "Unlock": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "SelectHyperCubeValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qDimNo","DefaultValue": 0 }, { "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectHyperCubeCells": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRowIndices","DefaultValue": [0] }, { "Name": "qColIndices","DefaultValue": [0] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectPivotCells": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSelections","DefaultValue": [{"qType": 0, "qCol": 0, "qRow": 0}] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "RangeSelectHyperCubeValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qRange": {"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}, "qMeasureIx": 0}] }, { "Name": "qColumnsToSelect","DefaultValue": [0], "Optional": true }, { "Name": "qOrMode","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "MultiRangeSelectHyperCubeValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qRanges": [{"qRange": {"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}, "qMeasureIx": 0}], "qColumnsToSelect": [0]}] }, { "Name": "qOrMode","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectHyperCubeContinuousRange": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qRange": {"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}, "qDimIx": 0}] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetChild": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetChildInfos": { + "In": [], + "Out": [{ "Name": "qInfos" }] + }, + "CreateChild": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }, { "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyChild": { + "In": [{ "Name": "qId","DefaultValue": "" }, { "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "DestroyAllChildren": { + "In": [{ "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [] + }, + "SetChildArrayOrder": { + "In": [{ "Name": "qIds","DefaultValue": [""] }], + "Out": [] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "CopyFrom": { + "In": [{ "Name": "qFromId","DefaultValue": "" }], + "Out": [] + }, + "BeginSelections": { + "In": [{ "Name": "qPaths","DefaultValue": [""] }], + "Out": [] + }, + "EndSelections": { + "In": [{ "Name": "qAccept","DefaultValue": false }], + "Out": [] + }, + "ResetMadeSelections": { + "In": [], + "Out": [] + }, + "EmbedSnapshotObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetSnapshotObject": { + "In": [], + "Out": [] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericDimension":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDim": {"qGrouping": 0, "qFieldDefs": [""], "qFieldLabels": [""], "qLabelExpression": ""}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetDimension": { + "In": [], + "Out": [{ "Name": "qDim" }] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericBookmark":{ + "GetFieldValues": { + "In": [{ "Name": "qField","DefaultValue": "" }, { "Name": "qGetExcludedValues","DefaultValue": false }, { "Name": "qDataPage","DefaultValue": {"qStartIndex": 0, "qEndIndex": 0} }], + "Out": [{ "Name": "qFieldValues" }] + }, + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "Apply": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericVariable":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "SetStringValue": { + "In": [{ "Name": "qVal","DefaultValue": "" }], + "Out": [] + }, + "SetNumValue": { + "In": [{ "Name": "qVal","DefaultValue": 0 }], + "Out": [] + }, + "SetDualValue": { + "In": [{ "Name": "qText","DefaultValue": "" }, { "Name": "qNum","DefaultValue": 0 }], + "Out": [] + } + }, + "GenericMeasure":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMeasure": {"qLabel": "", "qDef": "", "qGrouping": 0, "qExpressions": [""], "qActiveExpression": 0, "qLabelExpression": ""}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetMeasure": { + "In": [], + "Out": [{ "Name": "qMeasure" }] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericDerivedFields":{ + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDerivedDefinitionId": "", "qFieldName": [""], "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetDerivedFieldData": { + "In": [], + "Out": [{ "Name": "qData" }] + }, + "GetDerivedField": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qFields" }] + }, + "GetListData": { + "In": [], + "Out": [{ "Name": "qListData" }] + }, + "GetDerivedFields": { + "In": [], + "Out": [{ "Name": "qFields" }] + }, + "GetDerivedGroups": { + "In": [], + "Out": [{ "Name": "qGroups" }] + } + }, + "Doc":{ + "GetField": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }, { "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "GetFieldDescription": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }], + "Out": [] + }, + "GetVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "GetLooselyCoupledVector": { + "In": [], + "Out": [{ "Name": "qv" }] + }, + "SetLooselyCoupledVector": { + "In": [{ "Name": "qv","DefaultValue": [0] }], + "Out": [] + }, + "Evaluate": { + "In": [{ "Name": "qExpression","DefaultValue": "" }], + "Out": [] + }, + "EvaluateEx": { + "In": [{ "Name": "qExpression","DefaultValue": "" }], + "Out": [{ "Name": "qValue" }] + }, + "ClearAll": { + "In": [{ "Name": "qLockedAlso","DefaultValue": false, "Optional": true }, { "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "LockAll": { + "In": [{ "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "UnlockAll": { + "In": [{ "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "Back": { + "In": [], + "Out": [] + }, + "Forward": { + "In": [], + "Out": [] + }, + "CreateVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "RemoveVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "GetLocaleInfo": { + "In": [], + "Out": [] + }, + "GetTablesAndKeys": { + "In": [{ "Name": "qWindowSize","DefaultValue": {"qcx": 0, "qcy": 0} }, { "Name": "qNullSize","DefaultValue": {"qcx": 0, "qcy": 0} }, { "Name": "qCellHeight","DefaultValue": 0 }, { "Name": "qSyntheticMode","DefaultValue": false }, { "Name": "qIncludeSysVars","DefaultValue": false }], + "Out": [{ "Name": "qtr" }, { "Name": "qk" }] + }, + "GetViewDlgSaveInfo": { + "In": [], + "Out": [] + }, + "SetViewDlgSaveInfo": { + "In": [{ "Name": "qInfo","DefaultValue": {"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCtlInfo": {"qInternalView": {"qTables": [{"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCaption": ""}], "qBroomPoints": [{"qPos": {"qx": 0, "qy": 0}, "qTable": "", "qFields": [""]}], "qConnectionPoints": [{"qPos": {"qx": 0, "qy": 0}, "qFields": [""]}], "qZoomFactor": 0}, "qSourceView": {"qTables": [{"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCaption": ""}], "qBroomPoints": [{"qPos": {"qx": 0, "qy": 0}, "qTable": "", "qFields": [""]}], "qConnectionPoints": [{"qPos": {"qx": 0, "qy": 0}, "qFields": [""]}], "qZoomFactor": 0}}, "qMode": 0} }], + "Out": [] + }, + "GetEmptyScript": { + "In": [{ "Name": "qLocalizedMainSection","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "DoReload": { + "In": [{ "Name": "qMode","DefaultValue": 0, "Optional": true }, { "Name": "qPartial","DefaultValue": false, "Optional": true }, { "Name": "qDebug","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "GetScriptBreakpoints": { + "In": [], + "Out": [{ "Name": "qBreakpoints" }] + }, + "SetScriptBreakpoints": { + "In": [{ "Name": "qBreakpoints","DefaultValue": [{"qbufferName": "", "qlineIx": 0, "qEnabled": false}] }], + "Out": [] + }, + "GetScript": { + "In": [], + "Out": [{ "Name": "qScript" }] + }, + "GetTextMacros": { + "In": [], + "Out": [{ "Name": "qMacros" }] + }, + "SetFetchLimit": { + "In": [{ "Name": "qLimit","DefaultValue": 0 }], + "Out": [] + }, + "DoSave": { + "In": [{ "Name": "qFileName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "GetTableData": { + "In": [{ "Name": "qOffset","DefaultValue": 0 }, { "Name": "qRows","DefaultValue": 0 }, { "Name": "qSyntheticMode","DefaultValue": false }, { "Name": "qTableName","DefaultValue": "" }], + "Out": [{ "Name": "qData" }] + }, + "GetAppLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "SetAppProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qTitle": "", "qLastReloadTime": "", "qMigrationHash": "", "qSavedInProductVersion": "", "qThumbnail": {"qUrl": ""}} }], + "Out": [] + }, + "GetAppProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetLineage": { + "In": [], + "Out": [{ "Name": "qLineage" }] + }, + "CreateSessionObject": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }], + "Out": [] + }, + "DestroySessionObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CreateObject": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetObjects": { + "In": [{ "Name": "qOptions","DefaultValue": {"qTypes": [""], "qIncludeSessionObjects": false, "qData": {}} }], + "Out": [{ "Name": "qList" }] + }, + "GetBookmarks": { + "In": [{ "Name": "qOptions","DefaultValue": {"qTypes": [""], "qData": {}} }], + "Out": [{ "Name": "qList" }] + }, + "CloneObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qDraftId" }] + }, + "CommitDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "DestroyDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }, { "Name": "qSourceId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "Undo": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "Redo": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "ClearUndoBuffer": { + "In": [], + "Out": [] + }, + "CreateDimension": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDim": {"qGrouping": 0, "qFieldDefs": [""], "qFieldLabels": [""], "qLabelExpression": ""}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "CloneDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateMeasure": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMeasure": {"qLabel": "", "qDef": "", "qGrouping": 0, "qExpressions": [""], "qActiveExpression": 0, "qLabelExpression": ""}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "CloneMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateSessionVariable": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [] + }, + "DestroySessionVariable": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CreateVariableEx": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyVariableById": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "DestroyVariableByName": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetVariableById": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetVariableByName": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "MigrateVariables": { + "In": [], + "Out": [] + }, + "MigrateDerivedFields": { + "In": [], + "Out": [] + }, + "CheckExpression": { + "In": [{ "Name": "qExpr","DefaultValue": "" }, { "Name": "qLabels","DefaultValue": [""], "Optional": true }], + "Out": [{ "Name": "qErrorMsg" }, { "Name": "qBadFieldNames" }, { "Name": "qDangerousFieldNames" }] + }, + "CheckNumberOrExpression": { + "In": [{ "Name": "qExpr","DefaultValue": "" }], + "Out": [{ "Name": "qErrorMsg" }, { "Name": "qBadFieldNames" }] + }, + "AddAlternateState": { + "In": [{ "Name": "qStateName","DefaultValue": "" }], + "Out": [] + }, + "RemoveAlternateState": { + "In": [{ "Name": "qStateName","DefaultValue": "" }], + "Out": [] + }, + "CreateBookmark": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "ApplyBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CloneBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "AddFieldFromExpression": { + "In": [{ "Name": "qName","DefaultValue": "" }, { "Name": "qExpr","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetAllInfos": { + "In": [], + "Out": [{ "Name": "qInfos" }] + }, + "Resume": { + "In": [], + "Out": [] + }, + "AbortModal": { + "In": [{ "Name": "qAccept","DefaultValue": false }], + "Out": [] + }, + "Publish": { + "In": [{ "Name": "qStreamId","DefaultValue": "" }, { "Name": "qName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + }, + "GetMatchingFields": { + "In": [{ "Name": "qTags","DefaultValue": [""] }, { "Name": "qMatchingFieldMode","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qFieldNames" }] + }, + "FindMatchingFields": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }, { "Name": "qTags","DefaultValue": [""] }], + "Out": [{ "Name": "qFieldNames" }] + }, + "Scramble": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }], + "Out": [] + }, + "SaveObjects": { + "In": [], + "Out": [] + }, + "GetAssociationScores": { + "In": [{ "Name": "qTable1","DefaultValue": "" }, { "Name": "qTable2","DefaultValue": "" }], + "Out": [{ "Name": "qScore" }] + }, + "GetMediaList": { + "In": [], + "Out": [{ "Name": "qList" }] + }, + "GetContentLibraries": { + "In": [], + "Out": [{ "Name": "qList" }] + }, + "GetLibraryContent": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [{ "Name": "qList" }] + }, + "DoReloadEx": { + "In": [{ "Name": "qParams","DefaultValue": {"qMode": 0, "qPartial": false, "qDebug": false}, "Optional": true }], + "Out": [{ "Name": "qResult" }] + }, + "BackCount": { + "In": [], + "Out": [] + }, + "ForwardCount": { + "In": [], + "Out": [] + }, + "ExportReducedData": { + "In": [{ "Name": "qOptions","DefaultValue": {"qBookmarkId": "", "qExpires": 0}, "Optional": true }], + "Out": [{ "Name": "qDownloadInfo" }] + }, + "SetScript": { + "In": [{ "Name": "qScript","DefaultValue": "" }], + "Out": [] + }, + "CheckScriptSyntax": { + "In": [], + "Out": [{ "Name": "qErrors" }] + }, + "GetFavoriteVariables": { + "In": [], + "Out": [{ "Name": "qNames" }] + }, + "SetFavoriteVariables": { + "In": [{ "Name": "qNames","DefaultValue": [""] }], + "Out": [] + }, + "GetIncludeFileContent": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [{ "Name": "qContent" }] + }, + "CreateConnection": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }], + "Out": [{ "Name": "qConnectionId" }] + }, + "ModifyConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }, { "Name": "qOverrideCredentials","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "DeleteConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [] + }, + "GetConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qConnection" }] + }, + "GetConnections": { + "In": [], + "Out": [{ "Name": "qConnections" }] + }, + "GetDatabaseInfo": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qInfo" }] + }, + "GetDatabases": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qDatabases" }] + }, + "GetDatabaseOwners": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qOwners" }] + }, + "GetDatabaseTables": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qTables" }] + }, + "GetDatabaseTableFields": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qFields" }] + }, + "GetDatabaseTablePreview": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }, { "Name": "qTable","DefaultValue": "" }, { "Name": "qConditions","DefaultValue": {"qType": 0, "qWherePredicate": ""}, "Optional": true }], + "Out": [{ "Name": "qPreview" }, { "Name": "qRowCount" }] + }, + "GetFolderItemsForConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qFolderItems" }] + }, + "GuessFileType": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qDataFormat" }] + }, + "GetFileTables": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }], + "Out": [{ "Name": "qTables" }] + }, + "GetFileTableFields": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qFields" }, { "Name": "qFormatSpec" }] + }, + "GetFileTablePreview": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qPreview" }, { "Name": "qFormatSpec" }] + }, + "GetFileTablesEx": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }], + "Out": [{ "Name": "qTables" }] + }, + "SendGenericCommandToCustomConnector": { + "In": [{ "Name": "qProvider","DefaultValue": "" }, { "Name": "qCommand","DefaultValue": "" }, { "Name": "qMethod","DefaultValue": "" }, { "Name": "qParameters","DefaultValue": [""] }, { "Name": "qAppendConnection","DefaultValue": "" }], + "Out": [{ "Name": "qResult" }] + }, + "SearchSuggest": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0, "qCharEncoding": 0, "qAttributes": [""]} }, { "Name": "qTerms","DefaultValue": [""] }], + "Out": [{ "Name": "qResult" }] + }, + "SearchAssociations": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0, "qCharEncoding": 0, "qAttributes": [""]} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qPage","DefaultValue": {"qOffset": 0, "qCount": 0, "qMaxNbrFieldMatches": 0, "qGroupOptions": [{"qGroupType": 0, "qOffset": 0, "qCount": 0}], "qGroupItemOptions": [{"qGroupItemType": 0, "qOffset": 0, "qCount": 0}]} }], + "Out": [{ "Name": "qResults" }] + }, + "SelectAssociations": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0, "qCharEncoding": 0, "qAttributes": [""]} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qMatchIx","DefaultValue": 0 }, { "Name": "qSoftLock","DefaultValue": null, "Optional": true }], + "Out": [] + }, + "SearchResults": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0, "qCharEncoding": 0, "qAttributes": [""]} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qPage","DefaultValue": {"qOffset": 0, "qCount": 0, "qMaxNbrFieldMatches": 0, "qGroupOptions": [{"qGroupType": 0, "qOffset": 0, "qCount": 0}], "qGroupItemOptions": [{"qGroupItemType": 0, "qOffset": 0, "qCount": 0}]} }], + "Out": [{ "Name": "qResult" }] + }, + "SearchObjects": { + "In": [{ "Name": "qOptions","DefaultValue": {"qAttributes": [""], "qCharEncoding": 0} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qPage","DefaultValue": {"qOffset": 0, "qCount": 0, "qMaxNbrFieldMatches": 0, "qGroupOptions": [{"qGroupType": 0, "qOffset": 0, "qCount": 0}], "qGroupItemOptions": [{"qGroupItemType": 0, "qOffset": 0, "qCount": 0}]} }], + "Out": [{ "Name": "qResult" }] + } + }, + "Global":{ + "AbortRequest": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [] + }, + "AbortAll": { + "In": [], + "Out": [] + }, + "GetProgress": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [{ "Name": "qProgressData" }] + }, + "QvVersion": { + "In": [], + "Out": [] + }, + "OSVersion": { + "In": [], + "Out": [] + }, + "OSName": { + "In": [], + "Out": [] + }, + "QTProduct": { + "In": [], + "Out": [] + }, + "GetDocList": { + "In": [], + "Out": [{ "Name": "qDocList" }] + }, + "GetInteract": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [{ "Name": "qDef" }] + }, + "InteractDone": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }, { "Name": "qDef","DefaultValue": {"qType": 0, "qTitle": "", "qMsg": "", "qButtons": 0, "qLine": "", "qOldLineNr": 0, "qNewLineNr": 0, "qPath": "", "qHidden": false, "qResult": 0, "qInput": ""} }], + "Out": [] + }, + "GetAuthenticatedUser": { + "In": [], + "Out": [] + }, + "CreateDocEx": { + "In": [{ "Name": "qDocName","DefaultValue": "" }, { "Name": "qUserName","DefaultValue": "", "Optional": true }, { "Name": "qPassword","DefaultValue": "", "Optional": true }, { "Name": "qSerial","DefaultValue": "", "Optional": true }, { "Name": "qLocalizedScriptMainSection","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qDocId" }] + }, + "GetActiveDoc": { + "In": [], + "Out": [] + }, + "AllowCreateApp": { + "In": [], + "Out": [] + }, + "CreateApp": { + "In": [{ "Name": "qAppName","DefaultValue": "" }, { "Name": "qLocalizedScriptMainSection","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qSuccess" }, { "Name": "qAppId" }] + }, + "DeleteApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "IsDesktopMode": { + "In": [], + "Out": [] + }, + "GetConfiguration": { + "In": [], + "Out": [{ "Name": "qConfig" }] + }, + "CancelRequest": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [] + }, + "ShutdownProcess": { + "In": [], + "Out": [] + }, + "ReloadExtensionList": { + "In": [], + "Out": [] + }, + "ReplaceAppFromID": { + "In": [{ "Name": "qTargetAppId","DefaultValue": "" }, { "Name": "qSrcAppID","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "CopyApp": { + "In": [{ "Name": "qTargetAppId","DefaultValue": "" }, { "Name": "qSrcAppId","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "ImportApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qSrcPath","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "ImportAppEx": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qSrcPath","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }, { "Name": "qExcludeConnections","DefaultValue": false }], + "Out": [] + }, + "ExportApp": { + "In": [{ "Name": "qTargetPath","DefaultValue": "" }, { "Name": "qSrcAppId","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "PublishApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qName","DefaultValue": "" }, { "Name": "qStreamId","DefaultValue": "" }], + "Out": [] + }, + "IsPersonalMode": { + "In": [], + "Out": [] + }, + "GetUniqueID": { + "In": [], + "Out": [{ "Name": "qUniqueID" }] + }, + "OpenDoc": { + "In": [{ "Name": "qDocName","DefaultValue": "" }, { "Name": "qUserName","DefaultValue": "", "Optional": true }, { "Name": "qPassword","DefaultValue": "", "Optional": true }, { "Name": "qSerial","DefaultValue": "", "Optional": true }, { "Name": "qNoData","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "CreateSessionApp": { + "In": [], + "Out": [{ "Name": "qSessionAppId" }] + }, + "CreateSessionAppFromApp": { + "In": [{ "Name": "qSrcAppId","DefaultValue": "" }], + "Out": [{ "Name": "qSessionAppId" }] + }, + "ProductVersion": { + "In": [], + "Out": [] + }, + "GetAppEntry": { + "In": [{ "Name": "qAppID","DefaultValue": "" }], + "Out": [{ "Name": "qEntry" }] + }, + "ConfigureReload": { + "In": [{ "Name": "qCancelOnScriptError","DefaultValue": false }, { "Name": "qUseErrorData","DefaultValue": false }, { "Name": "qInteractOnError","DefaultValue": false }], + "Out": [] + }, + "CancelReload": { + "In": [], + "Out": [] + }, + "GetBNF": { + "In": [{ "Name": "qBnfType","DefaultValue": 0 }], + "Out": [{ "Name": "qBnfDefs" }] + }, + "GetFunctions": { + "In": [{ "Name": "qGroup","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qFunctions" }] + }, + "GetOdbcDsns": { + "In": [], + "Out": [{ "Name": "qOdbcDsns" }] + }, + "GetOleDbProviders": { + "In": [], + "Out": [{ "Name": "qOleDbProviders" }] + }, + "GetDatabasesFromConnectionString": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }], + "Out": [{ "Name": "qDatabases" }] + }, + "IsValidConnectionString": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }], + "Out": [] + }, + "GetDefaultAppFolder": { + "In": [], + "Out": [{ "Name": "qPath" }] + }, + "GetMyDocumentsFolder": { + "In": [], + "Out": [{ "Name": "qFolder" }] + }, + "GetLogicalDriveStrings": { + "In": [], + "Out": [{ "Name": "qDrives" }] + }, + "GetFolderItemsForPath": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [{ "Name": "qFolderItems" }] + }, + "GetSupportedCodePages": { + "In": [], + "Out": [{ "Name": "qCodePages" }] + }, + "GetCustomConnectors": { + "In": [{ "Name": "qReloadList","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qConnectors" }] + }, + "GetStreamList": { + "In": [], + "Out": [{ "Name": "qStreamList" }] + }, + "UploadToContentService": { + "In": [{ "Name": "qDirectory","DefaultValue": "" }, { "Name": "qAppId","DefaultValue": "" }, { "Name": "qQrsObjects","DefaultValue": [{"qEngineObjectID": "", "qItemID": ""}] }], + "Out": [{ "Name": "qUploadedObjects" }] + }, + "EngineVersion": { + "In": [], + "Out": [{ "Name": "qVersion" }] + }, + "GetBaseBNF": { + "In": [{ "Name": "qBnfType","DefaultValue": 0 }], + "Out": [{ "Name": "qBnfDefs" }, { "Name": "qBnfHash" }] + }, + "GetBaseBNFHash": { + "In": [{ "Name": "qBnfType","DefaultValue": 0 }], + "Out": [{ "Name": "qBnfHash" }] + } + } + }, + "enums": { + "LocalizedMessageCode": { + "LOCMSG_SCRIPTEDITOR_EMPTY_MESSAGE": 0, + "LOCMSG_SCRIPTEDITOR_PROGRESS_SAVING_STARTED": 1, + "LOCMSG_SCRIPTEDITOR_PROGRESS_BYTES_LEFT": 2, + "LOCMSG_SCRIPTEDITOR_PROGRESS_STORING_TABLES": 3, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_ROWS_SO_FAR": 4, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECTED": 5, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECTING_TO": 6, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECT_FAILED": 7, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_ROWISH": 8, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_COLUMNAR": 9, + "LOCMSG_SCRIPTEDITOR_ERROR": 10, + "LOCMSG_SCRIPTEDITOR_DONE": 11, + "LOCMSG_SCRIPTEDITOR_LOAD_EXTERNAL_DATA": 12, + "LOCMSG_SCRIPTEDITOR_PROGRESS_OLD_QVD_ISLOADING": 13, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_LOADING": 14, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_BUFFERED": 15, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_PREPARING": 16, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_APPENDING": 17, + "LOCMSG_SCRIPTEDITOR_REMOVE_SYNTHETIC": 18, + "LOCMSG_SCRIPTEDITOR_PENDING_LINKEDTABLE_FETCHING": 19, + "LOCMSG_SCRIPTEDITOR_RELOAD": 20, + "LOCMSG_SCRIPTEDITOR_LINES_FETCHED": 21, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_START": 22, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_FIELD": 23, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_SUCCESS": 24, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_FAILURE": 25, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_STARTABORT": 26, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_ENDABORT": 27, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_TIMEOUT": 28, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_OUTOFMEMORY": 29 + }, + "LocalizedErrorCode": { + "LOCERR_INTERNAL_ERROR": -128, + "LOCERR_GENERIC_UNKNOWN": -1, + "LOCERR_GENERIC_OK": 0, + "LOCERR_GENERIC_NOT_SET": 1, + "LOCERR_GENERIC_NOT_FOUND": 2, + "LOCERR_GENERIC_ALREADY_EXISTS": 3, + "LOCERR_GENERIC_INVALID_PATH": 4, + "LOCERR_GENERIC_ACCESS_DENIED": 5, + "LOCERR_GENERIC_OUT_OF_MEMORY": 6, + "LOCERR_GENERIC_NOT_INITIALIZED": 7, + "LOCERR_GENERIC_INVALID_PARAMETERS": 8, + "LOCERR_GENERIC_EMPTY_PARAMETERS": 9, + "LOCERR_GENERIC_INTERNAL_ERROR": 10, + "LOCERR_GENERIC_CORRUPT_DATA": 11, + "LOCERR_GENERIC_MEMORY_INCONSISTENCY": 12, + "LOCERR_GENERIC_INVISIBLE_OWNER_ABORT": 13, + "LOCERR_GENERIC_PROHIBIT_VALIDATE": 14, + "LOCERR_GENERIC_ABORTED": 15, + "LOCERR_GENERIC_CONNECTION_LOST": 16, + "LOCERR_GENERIC_UNSUPPORTED_IN_PRODUCT_VERSION": 17, + "LOCERR_GENERIC_REST_CONNECTION_FAILURE": 18, + "LOCERR_HTTP_400": 400, + "LOCERR_HTTP_401": 401, + "LOCERR_HTTP_402": 402, + "LOCERR_HTTP_403": 403, + "LOCERR_HTTP_404": 404, + "LOCERR_HTTP_405": 405, + "LOCERR_HTTP_406": 406, + "LOCERR_HTTP_407": 407, + "LOCERR_HTTP_408": 408, + "LOCERR_HTTP_409": 409, + "LOCERR_HTTP_410": 410, + "LOCERR_HTTP_411": 411, + "LOCERR_HTTP_412": 412, + "LOCERR_HTTP_413": 413, + "LOCERR_HTTP_414": 414, + "LOCERR_HTTP_415": 415, + "LOCERR_HTTP_416": 416, + "LOCERR_HTTP_417": 417, + "LOCERR_HTTP_500": 500, + "LOCERR_HTTP_501": 501, + "LOCERR_HTTP_502": 502, + "LOCERR_HTTP_503": 503, + "LOCERR_HTTP_504": 504, + "LOCERR_HTTP_505": 505, + "LOCERR_HTTP_509": 509, + "LOCERR_HTTP_COULD_NOT_RESOLVE_HOST": 700, + "LOCERR_APP_ALREADY_EXISTS": 1000, + "LOCERR_APP_INVALID_NAME": 1001, + "LOCERR_APP_ALREADY_OPEN": 1002, + "LOCERR_APP_NOT_FOUND": 1003, + "LOCERR_APP_IMPORT_FAILED": 1004, + "LOCERR_APP_SAVE_FAILED": 1005, + "LOCERR_APP_CREATE_FAILED": 1006, + "LOCERR_APP_INVALID": 1007, + "LOCERR_APP_CONNECT_FAILED": 1008, + "LOCERR_APP_ALREADY_OPEN_IN_DIFFERENT_MODE": 1009, + "LOCERR_APP_MIGRATION_COULD_NOT_CONTACT_MIGRATION_SERVICE": 1010, + "LOCERR_APP_MIGRATION_COULD_NOT_START_MIGRATION": 1011, + "LOCERR_APP_MIGRATION_FAILURE": 1012, + "LOCERR_APP_SCRIPT_MISSING": 1013, + "LOCERR_CONNECTION_ALREADY_EXISTS": 2000, + "LOCERR_CONNECTION_NOT_FOUND": 2001, + "LOCERR_CONNECTION_FAILED_TO_LOAD": 2002, + "LOCERR_CONNECTION_FAILED_TO_IMPORT": 2003, + "LOCERR_CONNECTION_NAME_IS_INVALID": 2004, + "LOCERR_CONNECTOR_NO_FILE_STREAMING_SUPPORT": 2300, + "LOCERR_FILE_ACCESS_DENIED": 3000, + "LOCERR_FILE_NAME_INVALID": 3001, + "LOCERR_FILE_CORRUPT": 3002, + "LOCERR_FILE_NOT_FOUND": 3003, + "LOCERR_FILE_FORMAT_UNSUPPORTED": 3004, + "LOCERR_FILE_OPENED_IN_UNSUPPORTED_MODE": 3005, + "LOCERR_FILE_TABLE_NOT_FOUND": 3006, + "LOCERR_USER_ACCESS_DENIED": 4000, + "LOCERR_USER_IMPERSONATION_FAILED": 4001, + "LOCERR_SERVER_OUT_OF_SESSION_AND_USER_CALS": 5000, + "LOCERR_SERVER_OUT_OF_SESSION_CALS": 5001, + "LOCERR_SERVER_OUT_OF_USAGE_CALS": 5002, + "LOCERR_SERVER_OUT_OF_CALS": 5003, + "LOCERR_SERVER_OUT_OF_NAMED_CALS": 5004, + "LOCERR_SERVER_OFF_DUTY": 5005, + "LOCERR_SERVER_BUSY": 5006, + "LOCERR_SERVER_LICENSE_EXPIRED": 5007, + "LOCERR_SERVER_AJAX_DISABLED": 5008, + "LOCERR_HC_INVALID_OBJECT": 6000, + "LOCERR_HC_RESULT_TOO_LARGE": 6001, + "LOCERR_HC_INVALID_OBJECT_STATE": 6002, + "LOCERR_HC_MODAL_OBJECT_ERROR": 6003, + "LOCERR_CALC_INVALID_DEF": 7000, + "LOCERR_CALC_NOT_IN_LIB": 7001, + "LOCERR_CALC_HEAP_ERROR": 7002, + "LOCERR_CALC_TOO_LARGE": 7003, + "LOCERR_CALC_TIMEOUT": 7004, + "LOCERR_CALC_EVAL_CONDITION_FAILED": 7005, + "LOCERR_CALC_MIXED_LINKED_AGGREGATION": 7006, + "LOCERR_CALC_MISSING_LINKED": 7007, + "LOCERR_CALC_INVALID_COL_SORT": 7008, + "LOCERR_CALC_PAGES_TOO_LARGE": 7009, + "LOCERR_CALC_SEMANTIC_FIELD_NOT_ALLOWED": 7010, + "LOCERR_CALC_VALIDATION_STATE_INVALID": 7011, + "LOCERR_CALC_PIVOT_DIMENSIONS_ALREADY_EXISTS": 7012, + "LOCERR_CALC_MISSING_LINKED_FIELD": 7013, + "LOCERR_CALC_NOT_CALCULATED": 7014, + "LOCERR_LAYOUT_EXTENDS_INVALID_ID": 8000, + "LOCERR_LAYOUT_LINKED_OBJECT_NOT_FOUND": 8001, + "LOCERR_LAYOUT_LINKED_OBJECT_INVALID": 8002, + "LOCERR_PERSISTENCE_WRITE_FAILED": 9000, + "LOCERR_PERSISTENCE_READ_FAILED": 9001, + "LOCERR_PERSISTENCE_DELETE_FAILED": 9002, + "LOCERR_PERSISTENCE_NOT_FOUND": 9003, + "LOCERR_PERSISTENCE_UNSUPPORTED_VERSION": 9004, + "LOCERR_PERSISTENCE_MIGRATION_FAILED_READ_ONLY": 9005, + "LOCERR_PERSISTENCE_MIGRATION_CANCELLED": 9006, + "LOCERR_PERSISTENCE_MIGRATION_BACKUP_FAILED": 9007, + "LOCERR_PERSISTENCE_DISK_FULL": 9008, + "LOCERR_PERSISTENCE_NOT_SUPPORTED_FOR_SESSION_APP": 9009, + "LOCERR_PERSISTENCE_SYNC_SET_CHUNK_INVALID_PARAMETERS": 9510, + "LOCERR_PERSISTENCE_SYNC_GET_CHUNK_INVALID_PARAMETERS": 9511, + "LOCERR_SCRIPT_DATASOURCE_ACCESS_DENIED": 10000, + "LOCERR_RELOAD_IN_PROGRESS": 11000, + "LOCERR_RELOAD_TABLE_X_NOT_FOUND": 11001, + "LOCERR_RELOAD_UNKNOWN_STATEMENT": 11002, + "LOCERR_RELOAD_EXPECTED_SOMETHING_FOUND_UNKNOWN": 11003, + "LOCERR_RELOAD_EXPECTED_NOTHING_FOUND_UNKNOWN": 11004, + "LOCERR_RELOAD_EXPECTED_ONE_OF_1_TOKENS_FOUND_UNKNOWN": 11005, + "LOCERR_RELOAD_EXPECTED_ONE_OF_2_TOKENS_FOUND_UNKNOWN": 11006, + "LOCERR_RELOAD_EXPECTED_ONE_OF_3_TOKENS_FOUND_UNKNOWN": 11007, + "LOCERR_RELOAD_EXPECTED_ONE_OF_4_TOKENS_FOUND_UNKNOWN": 11008, + "LOCERR_RELOAD_EXPECTED_ONE_OF_5_TOKENS_FOUND_UNKNOWN": 11009, + "LOCERR_RELOAD_EXPECTED_ONE_OF_6_TOKENS_FOUND_UNKNOWN": 11010, + "LOCERR_RELOAD_EXPECTED_ONE_OF_7_TOKENS_FOUND_UNKNOWN": 11011, + "LOCERR_RELOAD_EXPECTED_ONE_OF_8_OR_MORE_TOKENS_FOUND_UNKNOWN": 11012, + "LOCERR_RELOAD_FIELD_X_NOT_FOUND": 11013, + "LOCERR_RELOAD_MAPPING_TABLE_X_NOT_FOUND": 11014, + "LOCERR_RELOAD_LIB_CONNECTION_X_NOT_FOUND": 11015, + "LOCERR_RELOAD_NAME_ALREADY_TAKEN": 11016, + "LOCERR_RELOAD_WRONG_FILE_FORMAT_DIF": 11017, + "LOCERR_RELOAD_WRONG_FILE_FORMAT_BIFF": 11018, + "LOCERR_RELOAD_WRONG_FILE_FORMAT_ENCRYPTED": 11019, + "LOCERR_RELOAD_OPEN_FILE_ERROR": 11020, + "LOCERR_RELOAD_AUTO_GENERATE_COUNT": 11021, + "LOCERR_RELOAD_PE_ILLEGAL_PREFIX_COMB": 11022, + "LOCERR_RELOAD_MATCHING_CONTROL_STATEMENT_ERROR": 11023, + "LOCERR_RELOAD_MATCHING_LIBPATH_X_NOT_FOUND": 11024, + "LOCERR_RELOAD_MATCHING_LIBPATH_X_INVALID": 11025, + "LOCERR_RELOAD_MATCHING_LIBPATH_X_OUTSIDE": 11026, + "LOCERR_RELOAD_NO_QUALIFIED_PATH_FOR_FILE": 11027, + "LOCERR_RELOAD_MODE_STATEMENT_ONLY_FOR_LIB_PATHS": 11028, + "LOCERR_RELOAD_INCONSISTENT_USE_OF_SEMANTIC_FIELDS": 11029, + "LOCERR_RELOAD_NO_OPEN_DATABASE": 11030, + "LOCERR_RELOAD_AGGREGATION_REQUIRED_BY_GROUP_BY": 11031, + "LOCERR_RELOAD_CONNECT_MUST_USE_LIB_PREFIX_IN_THIS_MODE": 11032, + "LOCERR_RELOAD_ODBC_CONNECT_FAILED": 11033, + "LOCERR_RELOAD_OLEDB_CONNECT_FAILED": 11034, + "LOCERR_RELOAD_CUSTOM_CONNECT_FAILED": 11035, + "LOCERR_RELOAD_ODBC_READ_FAILED": 11036, + "LOCERR_RELOAD_OLEDB_READ_FAILED": 11037, + "LOCERR_RELOAD_CUSTOM_READ_FAILED": 11038, + "LOCERR_RELOAD_BINARY_LOAD_PROHIBITED": 11039, + "LOCERR_RELOAD_CONNECTOR_START_FAILED": 11040, + "LOCERR_RELOAD_CONNECTOR_NOT_RESPONDING": 11041, + "LOCERR_RELOAD_CONNECTOR_REPLY_ERROR": 11042, + "LOCERR_RELOAD_CONNECTOR_CONNECT_ERROR": 11043, + "LOCERR_RELOAD_CONNECTOR_NOT_FOUND_ERROR": 11044, + "LOCERR_PERSONAL_NEW_VERSION_AVAILABLE": 12000, + "LOCERR_PERSONAL_VERSION_EXPIRED": 12001, + "LOCERR_PERSONAL_SECTION_ACCESS_DETECTED": 12002, + "LOCERR_PERSONAL_APP_DELETION_FAILED": 12003, + "LOCERR_USER_AUTHENTICATION_FAILURE": 12004, + "LOCERR_EXPORT_OUT_OF_MEMORY": 13000, + "LOCERR_EXPORT_NO_DATA": 13001, + "LOCERR_SYNC_INVALID_OFFSET": 14000, + "LOCERR_SEARCH_TIMEOUT": 15000, + "LOCERR_DIRECT_DISCOVERY_LINKED_EXPRESSION_FAIL": 16000, + "LOCERR_DIRECT_DISCOVERY_ROWCOUNT_OVERFLOW": 16001, + "LOCERR_DIRECT_DISCOVERY_EMPTY_RESULT": 16002, + "LOCERR_DIRECT_DISCOVERY_DB_CONNECTION_FAILED": 16003, + "LOCERR_DIRECT_DISCOVERY_MEASURE_NOT_ALLOWED": 16004, + "LOCERR_DIRECT_DISCOVERY_DETAIL_NOT_ALLOWED": 16005, + "LOCERR_DIRECT_DISCOVERY_NOT_SYNTH_CIRCULAR_ALLOWED": 16006, + "LOCERR_DIRECT_DISCOVERY_ONLY_ONE_DD_TABLE_ALLOWED": 16007, + "LOCERR_DIRECT_DISCOVERY_DB_AUTHORIZATION_FAILED": 16008, + "LOCERR_SMART_LOAD_TABLE_NOT_FOUND": 17000, + "LOCERR_SMART_LOAD_TABLE_DUPLICATED": 17001, + "LOCERR_VARIABLE_NO_NAME": 18000, + "LOCERR_VARIABLE_DUPLICATE_NAME": 18001, + "LOCERR_VARIABLE_INCONSISTENCY": 18002, + "LOCERR_MEDIA_LIBRARY_LIST_FAILED": 19000, + "LOCERR_MEDIA_LIBRARY_CONTENT_FAILED": 19001, + "LOCERR_MEDIA_BUNDLING_FAILED": 19002, + "LOCERR_MEDIA_UNBUNDLING_FAILED": 19003, + "LOCERR_MEDIA_LIBRARY_NOT_FOUND": 19004, + "LOCERR_FEATURE_DISABLED": 20000, + "LOCERR_JSON_RPC_INVALID_REQUEST": -32600, + "LOCERR_JSON_RPC_METHOD_NOT_FOUND": -32601, + "LOCERR_JSON_RPC_INVALID_PARAMETERS": -32602, + "LOCERR_JSON_RPC_INTERNAL_ERROR": -32603, + "LOCERR_JSON_RPC_PARSE_ERROR": -32700, + "LOCERR_MQ_SOCKET_CONNECT_FAILURE": 33000, + "LOCERR_MQ_SOCKET_OPEN_FAILURE": 33001, + "LOCERR_MQ_PROTOCOL_NO_RESPONE": 33002, + "LOCERR_MQ_PROTOCOL_LIBRARY_EXCEPTION": 33003, + "LOCERR_MQ_PROTOCOL_CONNECTION_CLOSED": 33004, + "LOCERR_MQ_PROTOCOL_CHANNEL_CLOSED": 33005, + "LOCERR_MQ_PROTOCOL_UNKNOWN_ERROR": 33006, + "LOCERR_MQ_PROTOCOL_INVALID_STATUS": 33007, + "LOCERR_EXTENGINE_GRPC_STATUS_OK": 22000, + "LOCERR_EXTENGINE_GRPC_STATUS_CANCELLED": 22001, + "LOCERR_EXTENGINE_GRPC_STATUS_UNKNOWN": 22002, + "LOCERR_EXTENGINE_GRPC_STATUS_INVALID_ARGUMENT": 22003, + "LOCERR_EXTENGINE_GRPC_STATUS_DEADLINE_EXCEEDED": 22004, + "LOCERR_EXTENGINE_GRPC_STATUS_NOT_FOUND": 22005, + "LOCERR_EXTENGINE_GRPC_STATUS_ALREADY_EXISTS": 22006, + "LOCERR_EXTENGINE_GRPC_STATUS_PERMISSION_DENIED": 22007, + "LOCERR_EXTENGINE_GRPC_STATUS_UNAUTHENTICATED": 220016, + "LOCERR_EXTENGINE_GRPC_STATUS_RESOURCE_EXHAUSTED": 22008, + "LOCERR_EXTENGINE_GRPC_STATUS_FAILED_PRECONDITION": 22009, + "LOCERR_EXTENGINE_GRPC_STATUS_ABORTED": 22010, + "LOCERR_EXTENGINE_GRPC_STATUS_OUT_OF_RANGE": 22011, + "LOCERR_EXTENGINE_GRPC_STATUS_UNIMPLEMENTED": 22012, + "LOCERR_EXTENGINE_GRPC_STATUS_INTERNAL": 22013, + "LOCERR_EXTENGINE_GRPC_STATUS_UNAVAILABLE": 22014, + "LOCERR_EXTENGINE_GRPC_STATUS_DATA_LOSS": 22015 + }, + "LocalizedWarningCode": { + "LOCWARN_PERSONAL_RELOAD_REQUIRED": 0, + "LOCWARN_PERSONAL_VERSION_EXPIRES_SOON": 1, + "LOCWARN_EXPORT_DATA_TRUNCATED": 1000, + "LOCWARN_COULD_NOT_OPEN_ALL_OBJECTS": 2000 + }, + "GrpType": { + "GRP_NX_NONE": 0, + "GRP_NX_HIEARCHY": 1, + "GRP_NX_COLLECTION": 2 + }, + "ExportFileType": { + "EXPORT_CSV_C": 0, + "EXPORT_CSV_T": 1, + "EXPORT_OOXML": 2 + }, + "ExportState": { + "EXPORT_POSSIBLE": 0, + "EXPORT_ALL": 1 + }, + "DimCellType": { + "NX_DIM_CELL_VALUE": 0, + "NX_DIM_CELL_EMPTY": 1, + "NX_DIM_CELL_NORMAL": 2, + "NX_DIM_CELL_TOTAL": 3, + "NX_DIM_CELL_OTHER": 4, + "NX_DIM_CELL_AGGR": 5, + "NX_DIM_CELL_PSEUDO": 6, + "NX_DIM_CELL_ROOT": 7, + "NX_DIM_CELL_NULL": 8 + }, + "StackElemType": { + "NX_STACK_CELL_NORMAL": 0, + "NX_STACK_CELL_TOTAL": 1, + "NX_STACK_CELL_OTHER": 2, + "NX_STACK_CELL_SUM": 3, + "NX_STACK_CELL_VALUE": 4, + "NX_STACK_CELL_PSEUDO": 5 + }, + "SortIndicatorType": { + "NX_SORT_INDICATE_NONE": 0, + "NX_SORT_INDICATE_ASC": 1, + "NX_SORT_INDICATE_DESC": 2 + }, + "DimensionType": { + "NX_DIMENSION_TYPE_DISCRETE": 0, + "NX_DIMENSION_TYPE_NUMERIC": 1, + "NX_DIMENSION_TYPE_TIME": 2 + }, + "FieldSelectionMode": { + "SELECTION_MODE_NORMAL": 0, + "SELECTION_MODE_AND": 1, + "SELECTION_MODE_NOT": 2 + }, + "FrequencyMode": { + "NX_FREQUENCY_NONE": 0, + "NX_FREQUENCY_VALUE": 1, + "NX_FREQUENCY_PERCENT": 2, + "NX_FREQUENCY_RELATIVE": 3 + }, + "DataReductionMode": { + "DATA_REDUCTION_NONE": 0, + "DATA_REDUCTION_ONEDIM": 1, + "DATA_REDUCTION_SCATTERED": 2, + "DATA_REDUCTION_CLUSTERED": 3, + "DATA_REDUCTION_STACKED": 4 + }, + "HypercubeMode": { + "DATA_MODE_STRAIGHT": 0, + "DATA_MODE_PIVOT": 1, + "DATA_MODE_PIVOT_STACK": 2 + }, + "PatchOperationType": { + "Add": 0, + "Remove": 1, + "Replace": 2 + }, + "SelectionCellType": { + "NX_CELL_DATA": 0, + "NX_CELL_TOP": 1, + "NX_CELL_LEFT": 2 + }, + "MatchingFieldMode": { + "MATCHINGFIELDMODE_MATCH_ALL": 0, + "MATCHINGFIELDMODE_MATCH_ONE": 1 + }, + "SessionState": { + "SESSION_CREATED": 0, + "SESSION_ATTACHED": 1 + }, + "QrsChangeType": { + "QRS_CHANGE_UNDEFINED": 0, + "QRS_CHANGE_ADD": 1, + "QRS_CHANGE_UPDATE": 2, + "QRS_CHANGE_DELETE": 3 + }, + "ExtEngineDataType": { + "NX_EXT_DATATYPE_STRING": 0, + "NX_EXT_DATATYPE_DOUBLE": 1, + "NX_EXT_DATATYPE_BOTH": 2 + }, + "ExtEngineFunctionType": { + "NX_EXT_FUNCTIONTYPE_SCALAR": 0, + "NX_EXT_FUNCTIONTYPE_AGGR": 1, + "NX_EXT_FUNCTIONTYPE_TENSOR": 2 + }, + "ExtEngineMsgType": { + "NX_EXT_MSGTYPE_FUNCTION_CALL": 1, + "NX_EXT_MSGTYPE_SCRIPT_CALL": 2, + "NX_EXT_MSGTYPE_RETURN_VALUE": 3, + "NX_EXT_MSGTYPE_RETURN_MULTIPLE": 4, + "NX_EXT_MSGTYPE_RETURN_ERROR": 5 + } + }, + "version": "12.20.0" +} diff --git a/jwt-scratch/src/js/node_modules/enigma.js/schemas/12.34.11.json b/jwt-scratch/src/js/node_modules/enigma.js/schemas/12.34.11.json new file mode 100644 index 0000000..30096d0 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/enigma.js/schemas/12.34.11.json @@ -0,0 +1,1583 @@ +{ + "structs": { + "Field":{ + "GetCardinal": { + "In": [], + "Out": [] + }, + "GetAndMode": { + "In": [], + "Out": [] + }, + "SelectValues": { + "In": [{ "Name": "qFieldValues","DefaultValue": [{"qText": "", "qIsNumeric": false, "qNumber": 0}] }, { "Name": "qToggleMode","DefaultValue": false, "Optional": true }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Select": { + "In": [{ "Name": "qMatch","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qExcludedValuesMode","DefaultValue": 0, "Optional": true }], + "Out": [] + }, + "ToggleSelect": { + "In": [{ "Name": "qMatch","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qExcludedValuesMode","DefaultValue": 0, "Optional": true }], + "Out": [] + }, + "ClearAllButThis": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectPossible": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectExcluded": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectAll": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Lock": { + "In": [], + "Out": [] + }, + "Unlock": { + "In": [], + "Out": [] + }, + "GetNxProperties": { + "In": [], + "Out": [{ "Name": "qProperties" }] + }, + "SetNxProperties": { + "In": [{ "Name": "qProperties","DefaultValue": {"qOneAndOnlyOne": false} }], + "Out": [] + }, + "SetAndMode": { + "In": [{ "Name": "qAndMode","DefaultValue": false }], + "Out": [] + }, + "SelectAlternative": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "LowLevelSelect": { + "In": [{ "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Clear": { + "In": [], + "Out": [] + } + }, + "Variable":{ + "GetContent": { + "In": [], + "Out": [{ "Name": "qContent" }] + }, + "GetRawContent": { + "In": [], + "Out": [] + }, + "SetContent": { + "In": [{ "Name": "qContent","DefaultValue": "" }, { "Name": "qUpdateMRU","DefaultValue": false }], + "Out": [] + }, + "ForceContent": { + "In": [{ "Name": "qs","DefaultValue": "" }, { "Name": "qd","DefaultValue": 0 }], + "Out": [] + }, + "GetNxProperties": { + "In": [], + "Out": [{ "Name": "qProperties" }] + }, + "SetNxProperties": { + "In": [{ "Name": "qProperties","DefaultValue": {"qName": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qUsePredefListedValues": false, "qPreDefinedList": [""]} }], + "Out": [] + } + }, + "GenericObject":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "GetListObjectData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeReducedData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qZoomFactor","DefaultValue": 0 }, { "Name": "qReductionMode","DefaultValue": 0 }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubePivotData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeStackData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qMaxNbrCells","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeContinuousData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qOptions","DefaultValue": {"qStart": 0, "qEnd": 0, "qNbrPoints": 0, "qMaxNbrTicks": 0, "qMaxNumberLines": 0} }, { "Name": "qReverseSort","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qDataPages" }, { "Name": "qAxisData" }] + }, + "GetHyperCubeTreeData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qNodeOptions","DefaultValue": {"qMaxNbrOfNodes": 0, "qTreeNodes": [{"qArea": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qAllValues": false}], "qTreeLevels": {"qLeft": 0, "qDepth": 0}} }], + "Out": [{ "Name": "qNodes" }] + }, + "GetHyperCubeBinnedData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qViewport","DefaultValue": {"qWidth": 0, "qHeight": 0, "qZoomLevel": 0} }, { "Name": "qDataRanges","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qMaxNbrCells","DefaultValue": 0 }, { "Name": "qQueryLevel","DefaultValue": 0 }, { "Name": "qBinningMethod","DefaultValue": 0 }], + "Out": [{ "Name": "qDataPages" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }, { "Name": "qSoftPatch","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "ClearSoftPatches": { + "In": [], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetEffectiveProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "SetFullPropertyTree": { + "In": [{ "Name": "qPropEntry","DefaultValue": {"qProperty": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}}, "qChildren": [], "qEmbeddedSnapshotRef": null} }], + "Out": [] + }, + "GetFullPropertyTree": { + "In": [], + "Out": [{ "Name": "qPropEntry" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "ClearSelections": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "ExportData": { + "In": [{ "Name": "qFileType","DefaultValue": 0 }, { "Name": "qPath","DefaultValue": "", "Optional": true }, { "Name": "qFileName","DefaultValue": "", "Optional": true }, { "Name": "qExportState","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qUrl" }, { "Name": "qWarnings" }] + }, + "SelectListObjectValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectPossible": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectExcluded": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectAlternative": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectAll": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectContinuousRange": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SearchListObjectFor": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qMatch","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "AbortListObjectSearch": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [] + }, + "AcceptListObjectSearch": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "ExpandLeft": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "ExpandTop": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "CollapseLeft": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "CollapseTop": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "DrillUp": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qDimNo","DefaultValue": 0 }, { "Name": "qNbrSteps","DefaultValue": 0 }], + "Out": [] + }, + "Lock": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "Unlock": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "SelectHyperCubeValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qDimNo","DefaultValue": 0 }, { "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectHyperCubeCells": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRowIndices","DefaultValue": [0] }, { "Name": "qColIndices","DefaultValue": [0] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectPivotCells": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSelections","DefaultValue": [{"qType": 0, "qCol": 0, "qRow": 0}] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "RangeSelectHyperCubeValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qRange": {"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}, "qMeasureIx": 0}] }, { "Name": "qColumnsToSelect","DefaultValue": [0], "Optional": true }, { "Name": "qOrMode","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "MultiRangeSelectHyperCubeValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qRanges": [{"qRange": {"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}, "qMeasureIx": 0}], "qColumnsToSelect": [0]}] }, { "Name": "qOrMode","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectHyperCubeContinuousRange": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qRange": {"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}, "qDimIx": 0}] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetChild": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetChildInfos": { + "In": [], + "Out": [{ "Name": "qInfos" }] + }, + "CreateChild": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }, { "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyChild": { + "In": [{ "Name": "qId","DefaultValue": "" }, { "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "DestroyAllChildren": { + "In": [{ "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [] + }, + "SetChildArrayOrder": { + "In": [{ "Name": "qIds","DefaultValue": [""] }], + "Out": [] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "CopyFrom": { + "In": [{ "Name": "qFromId","DefaultValue": "" }], + "Out": [] + }, + "BeginSelections": { + "In": [{ "Name": "qPaths","DefaultValue": [""] }], + "Out": [] + }, + "EndSelections": { + "In": [{ "Name": "qAccept","DefaultValue": false }], + "Out": [] + }, + "ResetMadeSelections": { + "In": [], + "Out": [] + }, + "EmbedSnapshotObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetSnapshotObject": { + "In": [], + "Out": [] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericDimension":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDim": {"qGrouping": 0, "qFieldDefs": [""], "qFieldLabels": [""], "qLabelExpression": ""}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetDimension": { + "In": [], + "Out": [{ "Name": "qDim" }] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericBookmark":{ + "GetFieldValues": { + "In": [{ "Name": "qField","DefaultValue": "" }, { "Name": "qGetExcludedValues","DefaultValue": false }, { "Name": "qDataPage","DefaultValue": {"qStartIndex": 0, "qEndIndex": 0} }], + "Out": [{ "Name": "qFieldValues" }] + }, + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "Apply": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericVariable":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "SetStringValue": { + "In": [{ "Name": "qVal","DefaultValue": "" }], + "Out": [] + }, + "SetNumValue": { + "In": [{ "Name": "qVal","DefaultValue": 0 }], + "Out": [] + }, + "SetDualValue": { + "In": [{ "Name": "qText","DefaultValue": "" }, { "Name": "qNum","DefaultValue": 0 }], + "Out": [] + } + }, + "GenericMeasure":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMeasure": {"qLabel": "", "qDef": "", "qGrouping": 0, "qExpressions": [""], "qActiveExpression": 0, "qLabelExpression": ""}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetMeasure": { + "In": [], + "Out": [{ "Name": "qMeasure" }] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericDerivedFields":{ + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDerivedDefinitionId": "", "qFieldName": [""], "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetDerivedFieldData": { + "In": [], + "Out": [{ "Name": "qData" }] + }, + "GetDerivedField": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qFields" }] + }, + "GetListData": { + "In": [], + "Out": [{ "Name": "qListData" }] + }, + "GetDerivedFields": { + "In": [], + "Out": [{ "Name": "qFields" }] + }, + "GetDerivedGroups": { + "In": [], + "Out": [{ "Name": "qGroups" }] + } + }, + "Doc":{ + "GetField": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }, { "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "GetFieldDescription": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }], + "Out": [] + }, + "GetVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "GetLooselyCoupledVector": { + "In": [], + "Out": [{ "Name": "qv" }] + }, + "SetLooselyCoupledVector": { + "In": [{ "Name": "qv","DefaultValue": [0] }], + "Out": [] + }, + "Evaluate": { + "In": [{ "Name": "qExpression","DefaultValue": "" }], + "Out": [] + }, + "EvaluateEx": { + "In": [{ "Name": "qExpression","DefaultValue": "" }], + "Out": [{ "Name": "qValue" }] + }, + "ClearAll": { + "In": [{ "Name": "qLockedAlso","DefaultValue": false, "Optional": true }, { "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "LockAll": { + "In": [{ "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "UnlockAll": { + "In": [{ "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "Back": { + "In": [], + "Out": [] + }, + "Forward": { + "In": [], + "Out": [] + }, + "CreateVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "RemoveVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "GetLocaleInfo": { + "In": [], + "Out": [] + }, + "GetTablesAndKeys": { + "In": [{ "Name": "qWindowSize","DefaultValue": {"qcx": 0, "qcy": 0} }, { "Name": "qNullSize","DefaultValue": {"qcx": 0, "qcy": 0} }, { "Name": "qCellHeight","DefaultValue": 0 }, { "Name": "qSyntheticMode","DefaultValue": false }, { "Name": "qIncludeSysVars","DefaultValue": false }], + "Out": [{ "Name": "qtr" }, { "Name": "qk" }] + }, + "GetViewDlgSaveInfo": { + "In": [], + "Out": [] + }, + "SetViewDlgSaveInfo": { + "In": [{ "Name": "qInfo","DefaultValue": {"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCtlInfo": {"qInternalView": {"qTables": [{"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCaption": ""}], "qBroomPoints": [{"qPos": {"qx": 0, "qy": 0}, "qTable": "", "qFields": [""]}], "qConnectionPoints": [{"qPos": {"qx": 0, "qy": 0}, "qFields": [""]}], "qZoomFactor": 0}, "qSourceView": {"qTables": [{"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCaption": ""}], "qBroomPoints": [{"qPos": {"qx": 0, "qy": 0}, "qTable": "", "qFields": [""]}], "qConnectionPoints": [{"qPos": {"qx": 0, "qy": 0}, "qFields": [""]}], "qZoomFactor": 0}}, "qMode": 0} }], + "Out": [] + }, + "GetEmptyScript": { + "In": [{ "Name": "qLocalizedMainSection","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "DoReload": { + "In": [{ "Name": "qMode","DefaultValue": 0, "Optional": true }, { "Name": "qPartial","DefaultValue": false, "Optional": true }, { "Name": "qDebug","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "GetScriptBreakpoints": { + "In": [], + "Out": [{ "Name": "qBreakpoints" }] + }, + "SetScriptBreakpoints": { + "In": [{ "Name": "qBreakpoints","DefaultValue": [{"qbufferName": "", "qlineIx": 0, "qEnabled": false}] }], + "Out": [] + }, + "GetScript": { + "In": [], + "Out": [{ "Name": "qScript" }] + }, + "GetTextMacros": { + "In": [], + "Out": [{ "Name": "qMacros" }] + }, + "SetFetchLimit": { + "In": [{ "Name": "qLimit","DefaultValue": 0 }], + "Out": [] + }, + "DoSave": { + "In": [{ "Name": "qFileName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "GetTableData": { + "In": [{ "Name": "qOffset","DefaultValue": 0 }, { "Name": "qRows","DefaultValue": 0 }, { "Name": "qSyntheticMode","DefaultValue": false }, { "Name": "qTableName","DefaultValue": "" }], + "Out": [{ "Name": "qData" }] + }, + "GetAppLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "SetAppProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qTitle": "", "qLastReloadTime": "", "qMigrationHash": "", "qSavedInProductVersion": "", "qThumbnail": {"qUrl": ""}} }], + "Out": [] + }, + "GetAppProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetLineage": { + "In": [], + "Out": [{ "Name": "qLineage" }] + }, + "CreateSessionObject": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }], + "Out": [] + }, + "DestroySessionObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CreateObject": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetObjects": { + "In": [{ "Name": "qOptions","DefaultValue": {"qTypes": [""], "qIncludeSessionObjects": false, "qData": {}} }], + "Out": [{ "Name": "qList" }] + }, + "GetBookmarks": { + "In": [{ "Name": "qOptions","DefaultValue": {"qTypes": [""], "qData": {}} }], + "Out": [{ "Name": "qList" }] + }, + "CloneObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qDraftId" }] + }, + "CommitDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "DestroyDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }, { "Name": "qSourceId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "Undo": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "Redo": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "ClearUndoBuffer": { + "In": [], + "Out": [] + }, + "CreateDimension": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDim": {"qGrouping": 0, "qFieldDefs": [""], "qFieldLabels": [""], "qLabelExpression": ""}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "CloneDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateMeasure": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMeasure": {"qLabel": "", "qDef": "", "qGrouping": 0, "qExpressions": [""], "qActiveExpression": 0, "qLabelExpression": ""}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "CloneMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateSessionVariable": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [] + }, + "DestroySessionVariable": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CreateVariableEx": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyVariableById": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "DestroyVariableByName": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetVariableById": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetVariableByName": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "MigrateVariables": { + "In": [], + "Out": [] + }, + "MigrateDerivedFields": { + "In": [], + "Out": [] + }, + "CheckExpression": { + "In": [{ "Name": "qExpr","DefaultValue": "" }, { "Name": "qLabels","DefaultValue": [""], "Optional": true }], + "Out": [{ "Name": "qErrorMsg" }, { "Name": "qBadFieldNames" }, { "Name": "qDangerousFieldNames" }] + }, + "CheckNumberOrExpression": { + "In": [{ "Name": "qExpr","DefaultValue": "" }], + "Out": [{ "Name": "qErrorMsg" }, { "Name": "qBadFieldNames" }] + }, + "AddAlternateState": { + "In": [{ "Name": "qStateName","DefaultValue": "" }], + "Out": [] + }, + "RemoveAlternateState": { + "In": [{ "Name": "qStateName","DefaultValue": "" }], + "Out": [] + }, + "CreateBookmark": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "ApplyBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CloneBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "AddFieldFromExpression": { + "In": [{ "Name": "qName","DefaultValue": "" }, { "Name": "qExpr","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetAllInfos": { + "In": [], + "Out": [{ "Name": "qInfos" }] + }, + "Resume": { + "In": [], + "Out": [] + }, + "AbortModal": { + "In": [{ "Name": "qAccept","DefaultValue": false }], + "Out": [] + }, + "Publish": { + "In": [{ "Name": "qStreamId","DefaultValue": "" }, { "Name": "qName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + }, + "GetMatchingFields": { + "In": [{ "Name": "qTags","DefaultValue": [""] }, { "Name": "qMatchingFieldMode","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qFieldNames" }] + }, + "FindMatchingFields": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }, { "Name": "qTags","DefaultValue": [""] }], + "Out": [{ "Name": "qFieldNames" }] + }, + "Scramble": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }], + "Out": [] + }, + "SaveObjects": { + "In": [], + "Out": [] + }, + "GetAssociationScores": { + "In": [{ "Name": "qTable1","DefaultValue": "" }, { "Name": "qTable2","DefaultValue": "" }], + "Out": [{ "Name": "qScore" }] + }, + "GetMediaList": { + "In": [], + "Out": [{ "Name": "qList" }] + }, + "GetContentLibraries": { + "In": [], + "Out": [{ "Name": "qList" }] + }, + "GetLibraryContent": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [{ "Name": "qList" }] + }, + "DoReloadEx": { + "In": [{ "Name": "qParams","DefaultValue": {"qMode": 0, "qPartial": false, "qDebug": false}, "Optional": true }], + "Out": [{ "Name": "qResult" }] + }, + "BackCount": { + "In": [], + "Out": [] + }, + "ForwardCount": { + "In": [], + "Out": [] + }, + "ExportReducedData": { + "In": [{ "Name": "qOptions","DefaultValue": {"qBookmarkId": "", "qExpires": 0}, "Optional": true }], + "Out": [{ "Name": "qDownloadInfo" }] + }, + "SetScript": { + "In": [{ "Name": "qScript","DefaultValue": "" }], + "Out": [] + }, + "CheckScriptSyntax": { + "In": [], + "Out": [{ "Name": "qErrors" }] + }, + "GetFavoriteVariables": { + "In": [], + "Out": [{ "Name": "qNames" }] + }, + "SetFavoriteVariables": { + "In": [{ "Name": "qNames","DefaultValue": [""] }], + "Out": [] + }, + "GetIncludeFileContent": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [{ "Name": "qContent" }] + }, + "CreateConnection": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }], + "Out": [{ "Name": "qConnectionId" }] + }, + "ModifyConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }, { "Name": "qOverrideCredentials","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "DeleteConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [] + }, + "GetConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qConnection" }] + }, + "GetConnections": { + "In": [], + "Out": [{ "Name": "qConnections" }] + }, + "GetDatabaseInfo": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qInfo" }] + }, + "GetDatabases": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qDatabases" }] + }, + "GetDatabaseOwners": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qOwners" }] + }, + "GetDatabaseTables": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qTables" }] + }, + "GetDatabaseTableFields": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qFields" }] + }, + "GetDatabaseTablePreview": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }, { "Name": "qTable","DefaultValue": "" }, { "Name": "qConditions","DefaultValue": {"qType": 0, "qWherePredicate": ""}, "Optional": true }], + "Out": [{ "Name": "qPreview" }, { "Name": "qRowCount" }] + }, + "GetFolderItemsForConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qFolderItems" }] + }, + "GuessFileType": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qDataFormat" }] + }, + "GetFileTables": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }], + "Out": [{ "Name": "qTables" }] + }, + "GetFileTableFields": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qFields" }, { "Name": "qFormatSpec" }] + }, + "GetFileTablePreview": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qPreview" }, { "Name": "qFormatSpec" }] + }, + "GetFileTablesEx": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }], + "Out": [{ "Name": "qTables" }] + }, + "SendGenericCommandToCustomConnector": { + "In": [{ "Name": "qProvider","DefaultValue": "" }, { "Name": "qCommand","DefaultValue": "" }, { "Name": "qMethod","DefaultValue": "" }, { "Name": "qParameters","DefaultValue": [""] }, { "Name": "qAppendConnection","DefaultValue": "" }], + "Out": [{ "Name": "qResult" }] + }, + "SearchSuggest": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0, "qCharEncoding": 0, "qAttributes": [""]} }, { "Name": "qTerms","DefaultValue": [""] }], + "Out": [{ "Name": "qResult" }] + }, + "SearchAssociations": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0, "qCharEncoding": 0, "qAttributes": [""]} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qPage","DefaultValue": {"qOffset": 0, "qCount": 0, "qMaxNbrFieldMatches": 0, "qGroupOptions": [{"qGroupType": 0, "qOffset": 0, "qCount": 0}], "qGroupItemOptions": [{"qGroupItemType": 0, "qOffset": 0, "qCount": 0}]} }], + "Out": [{ "Name": "qResults" }] + }, + "SelectAssociations": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0, "qCharEncoding": 0, "qAttributes": [""]} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qMatchIx","DefaultValue": 0 }, { "Name": "qSoftLock","DefaultValue": null, "Optional": true }], + "Out": [] + }, + "SearchResults": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0, "qCharEncoding": 0, "qAttributes": [""]} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qPage","DefaultValue": {"qOffset": 0, "qCount": 0, "qMaxNbrFieldMatches": 0, "qGroupOptions": [{"qGroupType": 0, "qOffset": 0, "qCount": 0}], "qGroupItemOptions": [{"qGroupItemType": 0, "qOffset": 0, "qCount": 0}]} }], + "Out": [{ "Name": "qResult" }] + }, + "SearchObjects": { + "In": [{ "Name": "qOptions","DefaultValue": {"qAttributes": [""], "qCharEncoding": 0} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qPage","DefaultValue": {"qOffset": 0, "qCount": 0, "qMaxNbrFieldMatches": 0, "qGroupOptions": [{"qGroupType": 0, "qOffset": 0, "qCount": 0}], "qGroupItemOptions": [{"qGroupItemType": 0, "qOffset": 0, "qCount": 0}]} }], + "Out": [{ "Name": "qResult" }] + } + }, + "Global":{ + "AbortRequest": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [] + }, + "AbortAll": { + "In": [], + "Out": [] + }, + "GetProgress": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [{ "Name": "qProgressData" }] + }, + "QvVersion": { + "In": [], + "Out": [] + }, + "OSVersion": { + "In": [], + "Out": [] + }, + "OSName": { + "In": [], + "Out": [] + }, + "QTProduct": { + "In": [], + "Out": [] + }, + "GetDocList": { + "In": [], + "Out": [{ "Name": "qDocList" }] + }, + "GetInteract": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [{ "Name": "qDef" }] + }, + "InteractDone": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }, { "Name": "qDef","DefaultValue": {"qType": 0, "qTitle": "", "qMsg": "", "qButtons": 0, "qLine": "", "qOldLineNr": 0, "qNewLineNr": 0, "qPath": "", "qHidden": false, "qResult": 0, "qInput": ""} }], + "Out": [] + }, + "GetAuthenticatedUser": { + "In": [], + "Out": [] + }, + "CreateDocEx": { + "In": [{ "Name": "qDocName","DefaultValue": "" }, { "Name": "qUserName","DefaultValue": "", "Optional": true }, { "Name": "qPassword","DefaultValue": "", "Optional": true }, { "Name": "qSerial","DefaultValue": "", "Optional": true }, { "Name": "qLocalizedScriptMainSection","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qDocId" }] + }, + "GetActiveDoc": { + "In": [], + "Out": [] + }, + "AllowCreateApp": { + "In": [], + "Out": [] + }, + "CreateApp": { + "In": [{ "Name": "qAppName","DefaultValue": "" }, { "Name": "qLocalizedScriptMainSection","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qSuccess" }, { "Name": "qAppId" }] + }, + "DeleteApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "IsDesktopMode": { + "In": [], + "Out": [] + }, + "GetConfiguration": { + "In": [], + "Out": [{ "Name": "qConfig" }] + }, + "CancelRequest": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [] + }, + "ShutdownProcess": { + "In": [], + "Out": [] + }, + "ReloadExtensionList": { + "In": [], + "Out": [] + }, + "ReplaceAppFromID": { + "In": [{ "Name": "qTargetAppId","DefaultValue": "" }, { "Name": "qSrcAppID","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "CopyApp": { + "In": [{ "Name": "qTargetAppId","DefaultValue": "" }, { "Name": "qSrcAppId","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "ImportApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qSrcPath","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "ImportAppEx": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qSrcPath","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }, { "Name": "qExcludeConnections","DefaultValue": false }], + "Out": [] + }, + "ExportApp": { + "In": [{ "Name": "qTargetPath","DefaultValue": "" }, { "Name": "qSrcAppId","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "PublishApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qName","DefaultValue": "" }, { "Name": "qStreamId","DefaultValue": "" }], + "Out": [] + }, + "IsPersonalMode": { + "In": [], + "Out": [] + }, + "GetUniqueID": { + "In": [], + "Out": [{ "Name": "qUniqueID" }] + }, + "OpenDoc": { + "In": [{ "Name": "qDocName","DefaultValue": "" }, { "Name": "qUserName","DefaultValue": "", "Optional": true }, { "Name": "qPassword","DefaultValue": "", "Optional": true }, { "Name": "qSerial","DefaultValue": "", "Optional": true }, { "Name": "qNoData","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "CreateSessionApp": { + "In": [], + "Out": [{ "Name": "qSessionAppId" }] + }, + "CreateSessionAppFromApp": { + "In": [{ "Name": "qSrcAppId","DefaultValue": "" }], + "Out": [{ "Name": "qSessionAppId" }] + }, + "ProductVersion": { + "In": [], + "Out": [] + }, + "GetAppEntry": { + "In": [{ "Name": "qAppID","DefaultValue": "" }], + "Out": [{ "Name": "qEntry" }] + }, + "ConfigureReload": { + "In": [{ "Name": "qCancelOnScriptError","DefaultValue": false }, { "Name": "qUseErrorData","DefaultValue": false }, { "Name": "qInteractOnError","DefaultValue": false }], + "Out": [] + }, + "CancelReload": { + "In": [], + "Out": [] + }, + "GetBNF": { + "In": [{ "Name": "qBnfType","DefaultValue": 0 }], + "Out": [{ "Name": "qBnfDefs" }] + }, + "GetFunctions": { + "In": [{ "Name": "qGroup","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qFunctions" }] + }, + "GetOdbcDsns": { + "In": [], + "Out": [{ "Name": "qOdbcDsns" }] + }, + "GetOleDbProviders": { + "In": [], + "Out": [{ "Name": "qOleDbProviders" }] + }, + "GetDatabasesFromConnectionString": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }], + "Out": [{ "Name": "qDatabases" }] + }, + "IsValidConnectionString": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }], + "Out": [] + }, + "GetDefaultAppFolder": { + "In": [], + "Out": [{ "Name": "qPath" }] + }, + "GetMyDocumentsFolder": { + "In": [], + "Out": [{ "Name": "qFolder" }] + }, + "GetLogicalDriveStrings": { + "In": [], + "Out": [{ "Name": "qDrives" }] + }, + "GetFolderItemsForPath": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [{ "Name": "qFolderItems" }] + }, + "GetSupportedCodePages": { + "In": [], + "Out": [{ "Name": "qCodePages" }] + }, + "GetCustomConnectors": { + "In": [{ "Name": "qReloadList","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qConnectors" }] + }, + "GetStreamList": { + "In": [], + "Out": [{ "Name": "qStreamList" }] + }, + "EngineVersion": { + "In": [], + "Out": [{ "Name": "qVersion" }] + }, + "GetBaseBNF": { + "In": [{ "Name": "qBnfType","DefaultValue": 0 }], + "Out": [{ "Name": "qBnfDefs" }, { "Name": "qBnfHash" }] + }, + "GetBaseBNFHash": { + "In": [{ "Name": "qBnfType","DefaultValue": 0 }], + "Out": [{ "Name": "qBnfHash" }] + } + } + }, + "enums": { + "LocalizedMessageCode": { + "LOCMSG_SCRIPTEDITOR_EMPTY_MESSAGE": 0, + "LOCMSG_SCRIPTEDITOR_PROGRESS_SAVING_STARTED": 1, + "LOCMSG_SCRIPTEDITOR_PROGRESS_BYTES_LEFT": 2, + "LOCMSG_SCRIPTEDITOR_PROGRESS_STORING_TABLES": 3, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_ROWS_SO_FAR": 4, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECTED": 5, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECTING_TO": 6, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECT_FAILED": 7, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_ROWISH": 8, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_COLUMNAR": 9, + "LOCMSG_SCRIPTEDITOR_ERROR": 10, + "LOCMSG_SCRIPTEDITOR_DONE": 11, + "LOCMSG_SCRIPTEDITOR_LOAD_EXTERNAL_DATA": 12, + "LOCMSG_SCRIPTEDITOR_PROGRESS_OLD_QVD_ISLOADING": 13, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_LOADING": 14, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_BUFFERED": 15, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_PREPARING": 16, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_APPENDING": 17, + "LOCMSG_SCRIPTEDITOR_REMOVE_SYNTHETIC": 18, + "LOCMSG_SCRIPTEDITOR_PENDING_LINKEDTABLE_FETCHING": 19, + "LOCMSG_SCRIPTEDITOR_RELOAD": 20, + "LOCMSG_SCRIPTEDITOR_LINES_FETCHED": 21, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_START": 22, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_FIELD": 23, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_SUCCESS": 24, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_FAILURE": 25, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_STARTABORT": 26, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_ENDABORT": 27, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_TIMEOUT": 28, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_OUTOFMEMORY": 29 + }, + "LocalizedErrorCode": { + "LOCERR_INTERNAL_ERROR": -128, + "LOCERR_GENERIC_UNKNOWN": -1, + "LOCERR_GENERIC_OK": 0, + "LOCERR_GENERIC_NOT_SET": 1, + "LOCERR_GENERIC_NOT_FOUND": 2, + "LOCERR_GENERIC_ALREADY_EXISTS": 3, + "LOCERR_GENERIC_INVALID_PATH": 4, + "LOCERR_GENERIC_ACCESS_DENIED": 5, + "LOCERR_GENERIC_OUT_OF_MEMORY": 6, + "LOCERR_GENERIC_NOT_INITIALIZED": 7, + "LOCERR_GENERIC_INVALID_PARAMETERS": 8, + "LOCERR_GENERIC_EMPTY_PARAMETERS": 9, + "LOCERR_GENERIC_INTERNAL_ERROR": 10, + "LOCERR_GENERIC_CORRUPT_DATA": 11, + "LOCERR_GENERIC_MEMORY_INCONSISTENCY": 12, + "LOCERR_GENERIC_INVISIBLE_OWNER_ABORT": 13, + "LOCERR_GENERIC_PROHIBIT_VALIDATE": 14, + "LOCERR_GENERIC_ABORTED": 15, + "LOCERR_GENERIC_CONNECTION_LOST": 16, + "LOCERR_GENERIC_UNSUPPORTED_IN_PRODUCT_VERSION": 17, + "LOCERR_GENERIC_REST_CONNECTION_FAILURE": 18, + "LOCERR_HTTP_400": 400, + "LOCERR_HTTP_401": 401, + "LOCERR_HTTP_402": 402, + "LOCERR_HTTP_403": 403, + "LOCERR_HTTP_404": 404, + "LOCERR_HTTP_405": 405, + "LOCERR_HTTP_406": 406, + "LOCERR_HTTP_407": 407, + "LOCERR_HTTP_408": 408, + "LOCERR_HTTP_409": 409, + "LOCERR_HTTP_410": 410, + "LOCERR_HTTP_411": 411, + "LOCERR_HTTP_412": 412, + "LOCERR_HTTP_413": 413, + "LOCERR_HTTP_414": 414, + "LOCERR_HTTP_415": 415, + "LOCERR_HTTP_416": 416, + "LOCERR_HTTP_417": 417, + "LOCERR_HTTP_429": 429, + "LOCERR_HTTP_500": 500, + "LOCERR_HTTP_501": 501, + "LOCERR_HTTP_502": 502, + "LOCERR_HTTP_503": 503, + "LOCERR_HTTP_504": 504, + "LOCERR_HTTP_505": 505, + "LOCERR_HTTP_509": 509, + "LOCERR_HTTP_COULD_NOT_RESOLVE_HOST": 700, + "LOCERR_APP_ALREADY_EXISTS": 1000, + "LOCERR_APP_INVALID_NAME": 1001, + "LOCERR_APP_ALREADY_OPEN": 1002, + "LOCERR_APP_NOT_FOUND": 1003, + "LOCERR_APP_IMPORT_FAILED": 1004, + "LOCERR_APP_SAVE_FAILED": 1005, + "LOCERR_APP_CREATE_FAILED": 1006, + "LOCERR_APP_INVALID": 1007, + "LOCERR_APP_CONNECT_FAILED": 1008, + "LOCERR_APP_ALREADY_OPEN_IN_DIFFERENT_MODE": 1009, + "LOCERR_APP_MIGRATION_COULD_NOT_CONTACT_MIGRATION_SERVICE": 1010, + "LOCERR_APP_MIGRATION_COULD_NOT_START_MIGRATION": 1011, + "LOCERR_APP_MIGRATION_FAILURE": 1012, + "LOCERR_APP_SCRIPT_MISSING": 1013, + "LOCERR_APP_EXPORT_FAILED": 1014, + "LOCERR_CONNECTION_ALREADY_EXISTS": 2000, + "LOCERR_CONNECTION_NOT_FOUND": 2001, + "LOCERR_CONNECTION_FAILED_TO_LOAD": 2002, + "LOCERR_CONNECTION_FAILED_TO_IMPORT": 2003, + "LOCERR_CONNECTION_NAME_IS_INVALID": 2004, + "LOCERR_CONNECTOR_NO_FILE_STREAMING_SUPPORT": 2300, + "LOCERR_FILE_ACCESS_DENIED": 3000, + "LOCERR_FILE_NAME_INVALID": 3001, + "LOCERR_FILE_CORRUPT": 3002, + "LOCERR_FILE_NOT_FOUND": 3003, + "LOCERR_FILE_FORMAT_UNSUPPORTED": 3004, + "LOCERR_FILE_OPENED_IN_UNSUPPORTED_MODE": 3005, + "LOCERR_FILE_TABLE_NOT_FOUND": 3006, + "LOCERR_USER_ACCESS_DENIED": 4000, + "LOCERR_USER_IMPERSONATION_FAILED": 4001, + "LOCERR_SERVER_OUT_OF_SESSION_AND_USER_CALS": 5000, + "LOCERR_SERVER_OUT_OF_SESSION_CALS": 5001, + "LOCERR_SERVER_OUT_OF_USAGE_CALS": 5002, + "LOCERR_SERVER_OUT_OF_CALS": 5003, + "LOCERR_SERVER_OUT_OF_NAMED_CALS": 5004, + "LOCERR_SERVER_OFF_DUTY": 5005, + "LOCERR_SERVER_BUSY": 5006, + "LOCERR_SERVER_LICENSE_EXPIRED": 5007, + "LOCERR_SERVER_AJAX_DISABLED": 5008, + "LOCERR_HC_INVALID_OBJECT": 6000, + "LOCERR_HC_RESULT_TOO_LARGE": 6001, + "LOCERR_HC_INVALID_OBJECT_STATE": 6002, + "LOCERR_HC_MODAL_OBJECT_ERROR": 6003, + "LOCERR_CALC_INVALID_DEF": 7000, + "LOCERR_CALC_NOT_IN_LIB": 7001, + "LOCERR_CALC_HEAP_ERROR": 7002, + "LOCERR_CALC_TOO_LARGE": 7003, + "LOCERR_CALC_TIMEOUT": 7004, + "LOCERR_CALC_EVAL_CONDITION_FAILED": 7005, + "LOCERR_CALC_MIXED_LINKED_AGGREGATION": 7006, + "LOCERR_CALC_MISSING_LINKED": 7007, + "LOCERR_CALC_INVALID_COL_SORT": 7008, + "LOCERR_CALC_PAGES_TOO_LARGE": 7009, + "LOCERR_CALC_SEMANTIC_FIELD_NOT_ALLOWED": 7010, + "LOCERR_CALC_VALIDATION_STATE_INVALID": 7011, + "LOCERR_CALC_PIVOT_DIMENSIONS_ALREADY_EXISTS": 7012, + "LOCERR_CALC_MISSING_LINKED_FIELD": 7013, + "LOCERR_CALC_NOT_CALCULATED": 7014, + "LOCERR_LAYOUT_EXTENDS_INVALID_ID": 8000, + "LOCERR_LAYOUT_LINKED_OBJECT_NOT_FOUND": 8001, + "LOCERR_LAYOUT_LINKED_OBJECT_INVALID": 8002, + "LOCERR_PERSISTENCE_WRITE_FAILED": 9000, + "LOCERR_PERSISTENCE_READ_FAILED": 9001, + "LOCERR_PERSISTENCE_DELETE_FAILED": 9002, + "LOCERR_PERSISTENCE_NOT_FOUND": 9003, + "LOCERR_PERSISTENCE_UNSUPPORTED_VERSION": 9004, + "LOCERR_PERSISTENCE_MIGRATION_FAILED_READ_ONLY": 9005, + "LOCERR_PERSISTENCE_MIGRATION_CANCELLED": 9006, + "LOCERR_PERSISTENCE_MIGRATION_BACKUP_FAILED": 9007, + "LOCERR_PERSISTENCE_DISK_FULL": 9008, + "LOCERR_PERSISTENCE_NOT_SUPPORTED_FOR_SESSION_APP": 9009, + "LOCERR_PERSISTENCE_SYNC_SET_CHUNK_INVALID_PARAMETERS": 9510, + "LOCERR_PERSISTENCE_SYNC_GET_CHUNK_INVALID_PARAMETERS": 9511, + "LOCERR_SCRIPT_DATASOURCE_ACCESS_DENIED": 10000, + "LOCERR_RELOAD_IN_PROGRESS": 11000, + "LOCERR_RELOAD_TABLE_X_NOT_FOUND": 11001, + "LOCERR_RELOAD_UNKNOWN_STATEMENT": 11002, + "LOCERR_RELOAD_EXPECTED_SOMETHING_FOUND_UNKNOWN": 11003, + "LOCERR_RELOAD_EXPECTED_NOTHING_FOUND_UNKNOWN": 11004, + "LOCERR_RELOAD_EXPECTED_ONE_OF_1_TOKENS_FOUND_UNKNOWN": 11005, + "LOCERR_RELOAD_EXPECTED_ONE_OF_2_TOKENS_FOUND_UNKNOWN": 11006, + "LOCERR_RELOAD_EXPECTED_ONE_OF_3_TOKENS_FOUND_UNKNOWN": 11007, + "LOCERR_RELOAD_EXPECTED_ONE_OF_4_TOKENS_FOUND_UNKNOWN": 11008, + "LOCERR_RELOAD_EXPECTED_ONE_OF_5_TOKENS_FOUND_UNKNOWN": 11009, + "LOCERR_RELOAD_EXPECTED_ONE_OF_6_TOKENS_FOUND_UNKNOWN": 11010, + "LOCERR_RELOAD_EXPECTED_ONE_OF_7_TOKENS_FOUND_UNKNOWN": 11011, + "LOCERR_RELOAD_EXPECTED_ONE_OF_8_OR_MORE_TOKENS_FOUND_UNKNOWN": 11012, + "LOCERR_RELOAD_FIELD_X_NOT_FOUND": 11013, + "LOCERR_RELOAD_MAPPING_TABLE_X_NOT_FOUND": 11014, + "LOCERR_RELOAD_LIB_CONNECTION_X_NOT_FOUND": 11015, + "LOCERR_RELOAD_NAME_ALREADY_TAKEN": 11016, + "LOCERR_RELOAD_WRONG_FILE_FORMAT_DIF": 11017, + "LOCERR_RELOAD_WRONG_FILE_FORMAT_BIFF": 11018, + "LOCERR_RELOAD_WRONG_FILE_FORMAT_ENCRYPTED": 11019, + "LOCERR_RELOAD_OPEN_FILE_ERROR": 11020, + "LOCERR_RELOAD_AUTO_GENERATE_COUNT": 11021, + "LOCERR_RELOAD_PE_ILLEGAL_PREFIX_COMB": 11022, + "LOCERR_RELOAD_MATCHING_CONTROL_STATEMENT_ERROR": 11023, + "LOCERR_RELOAD_MATCHING_LIBPATH_X_NOT_FOUND": 11024, + "LOCERR_RELOAD_MATCHING_LIBPATH_X_INVALID": 11025, + "LOCERR_RELOAD_MATCHING_LIBPATH_X_OUTSIDE": 11026, + "LOCERR_RELOAD_NO_QUALIFIED_PATH_FOR_FILE": 11027, + "LOCERR_RELOAD_MODE_STATEMENT_ONLY_FOR_LIB_PATHS": 11028, + "LOCERR_RELOAD_INCONSISTENT_USE_OF_SEMANTIC_FIELDS": 11029, + "LOCERR_RELOAD_NO_OPEN_DATABASE": 11030, + "LOCERR_RELOAD_AGGREGATION_REQUIRED_BY_GROUP_BY": 11031, + "LOCERR_RELOAD_CONNECT_MUST_USE_LIB_PREFIX_IN_THIS_MODE": 11032, + "LOCERR_RELOAD_ODBC_CONNECT_FAILED": 11033, + "LOCERR_RELOAD_OLEDB_CONNECT_FAILED": 11034, + "LOCERR_RELOAD_CUSTOM_CONNECT_FAILED": 11035, + "LOCERR_RELOAD_ODBC_READ_FAILED": 11036, + "LOCERR_RELOAD_OLEDB_READ_FAILED": 11037, + "LOCERR_RELOAD_CUSTOM_READ_FAILED": 11038, + "LOCERR_RELOAD_BINARY_LOAD_PROHIBITED": 11039, + "LOCERR_RELOAD_CONNECTOR_START_FAILED": 11040, + "LOCERR_RELOAD_CONNECTOR_NOT_RESPONDING": 11041, + "LOCERR_RELOAD_CONNECTOR_REPLY_ERROR": 11042, + "LOCERR_RELOAD_CONNECTOR_CONNECT_ERROR": 11043, + "LOCERR_RELOAD_CONNECTOR_NOT_FOUND_ERROR": 11044, + "LOCERR_PERSONAL_NEW_VERSION_AVAILABLE": 12000, + "LOCERR_PERSONAL_VERSION_EXPIRED": 12001, + "LOCERR_PERSONAL_SECTION_ACCESS_DETECTED": 12002, + "LOCERR_PERSONAL_APP_DELETION_FAILED": 12003, + "LOCERR_USER_AUTHENTICATION_FAILURE": 12004, + "LOCERR_EXPORT_OUT_OF_MEMORY": 13000, + "LOCERR_EXPORT_NO_DATA": 13001, + "LOCERR_SYNC_INVALID_OFFSET": 14000, + "LOCERR_SEARCH_TIMEOUT": 15000, + "LOCERR_DIRECT_DISCOVERY_LINKED_EXPRESSION_FAIL": 16000, + "LOCERR_DIRECT_DISCOVERY_ROWCOUNT_OVERFLOW": 16001, + "LOCERR_DIRECT_DISCOVERY_EMPTY_RESULT": 16002, + "LOCERR_DIRECT_DISCOVERY_DB_CONNECTION_FAILED": 16003, + "LOCERR_DIRECT_DISCOVERY_MEASURE_NOT_ALLOWED": 16004, + "LOCERR_DIRECT_DISCOVERY_DETAIL_NOT_ALLOWED": 16005, + "LOCERR_DIRECT_DISCOVERY_NOT_SYNTH_CIRCULAR_ALLOWED": 16006, + "LOCERR_DIRECT_DISCOVERY_ONLY_ONE_DD_TABLE_ALLOWED": 16007, + "LOCERR_DIRECT_DISCOVERY_DB_AUTHORIZATION_FAILED": 16008, + "LOCERR_SMART_LOAD_TABLE_NOT_FOUND": 17000, + "LOCERR_SMART_LOAD_TABLE_DUPLICATED": 17001, + "LOCERR_VARIABLE_NO_NAME": 18000, + "LOCERR_VARIABLE_DUPLICATE_NAME": 18001, + "LOCERR_VARIABLE_INCONSISTENCY": 18002, + "LOCERR_MEDIA_LIBRARY_LIST_FAILED": 19000, + "LOCERR_MEDIA_LIBRARY_CONTENT_FAILED": 19001, + "LOCERR_MEDIA_BUNDLING_FAILED": 19002, + "LOCERR_MEDIA_UNBUNDLING_FAILED": 19003, + "LOCERR_MEDIA_LIBRARY_NOT_FOUND": 19004, + "LOCERR_FEATURE_DISABLED": 20000, + "LOCERR_JSON_RPC_INVALID_REQUEST": -32600, + "LOCERR_JSON_RPC_METHOD_NOT_FOUND": -32601, + "LOCERR_JSON_RPC_INVALID_PARAMETERS": -32602, + "LOCERR_JSON_RPC_INTERNAL_ERROR": -32603, + "LOCERR_JSON_RPC_PARSE_ERROR": -32700, + "LOCERR_MQ_SOCKET_CONNECT_FAILURE": 33000, + "LOCERR_MQ_SOCKET_OPEN_FAILURE": 33001, + "LOCERR_MQ_PROTOCOL_NO_RESPONE": 33002, + "LOCERR_MQ_PROTOCOL_LIBRARY_EXCEPTION": 33003, + "LOCERR_MQ_PROTOCOL_CONNECTION_CLOSED": 33004, + "LOCERR_MQ_PROTOCOL_CHANNEL_CLOSED": 33005, + "LOCERR_MQ_PROTOCOL_UNKNOWN_ERROR": 33006, + "LOCERR_MQ_PROTOCOL_INVALID_STATUS": 33007, + "LOCERR_EXTENGINE_GRPC_STATUS_OK": 22000, + "LOCERR_EXTENGINE_GRPC_STATUS_CANCELLED": 22001, + "LOCERR_EXTENGINE_GRPC_STATUS_UNKNOWN": 22002, + "LOCERR_EXTENGINE_GRPC_STATUS_INVALID_ARGUMENT": 22003, + "LOCERR_EXTENGINE_GRPC_STATUS_DEADLINE_EXCEEDED": 22004, + "LOCERR_EXTENGINE_GRPC_STATUS_NOT_FOUND": 22005, + "LOCERR_EXTENGINE_GRPC_STATUS_ALREADY_EXISTS": 22006, + "LOCERR_EXTENGINE_GRPC_STATUS_PERMISSION_DENIED": 22007, + "LOCERR_EXTENGINE_GRPC_STATUS_RESOURCE_EXHAUSTED": 22008, + "LOCERR_EXTENGINE_GRPC_STATUS_FAILED_PRECONDITION": 22009, + "LOCERR_EXTENGINE_GRPC_STATUS_ABORTED": 22010, + "LOCERR_EXTENGINE_GRPC_STATUS_OUT_OF_RANGE": 22011, + "LOCERR_EXTENGINE_GRPC_STATUS_UNIMPLEMENTED": 22012, + "LOCERR_EXTENGINE_GRPC_STATUS_INTERNAL": 22013, + "LOCERR_EXTENGINE_GRPC_STATUS_UNAVAILABLE": 22014, + "LOCERR_EXTENGINE_GRPC_STATUS_DATA_LOSS": 22015, + "LOCERR_EXTENGINE_GRPC_STATUS_UNAUTHENTICATED": 22016, + "LOCERR_LXW_INVALID_OBJ": 23001, + "LOCERR_LXW_INVALID_FILE": 23002, + "LOCERR_LXW_INVALID_SHEET": 23003, + "LOCERR_LXW_INVALID_EXPORT_RANGE": 23004, + "LOCERR_LXW_ERROR": 23005, + "LOCERR_LXW_ERROR_MEMORY_MALLOC_FAILED": 23006, + "LOCERR_LXW_ERROR_CREATING_XLSX_FILE": 23007, + "LOCERR_LXW_ERROR_CREATING_TMPFILE": 23008, + "LOCERR_LXW_ERROR_ZIP_FILE_OPERATION": 23009, + "LOCERR_LXW_ERROR_ZIP_FILE_ADD": 23010, + "LOCERR_LXW_ERROR_ZIP_CLOSE": 23011, + "LOCERR_LXW_ERROR_NULL_PARAMETER_IGNORED": 23012, + "LOCERR_LXW_ERROR_MAX_STRING_LENGTH_EXCEEDED": 23013, + "LOCERR_LXW_ERROR_255_STRING_LENGTH_EXCEEDED": 23014, + "LOCERR_LXW_ERROR_SHARED_STRING_INDEX_NOT_FOUND": 23015, + "LOCERR_LXW_ERROR_WORKSHEET_INDEX_OUT_OF_RANGE": 23016, + "LOCERR_LXW_ERROR_WORKSHEET_MAX_NUMBER_URLS_EXCEEDED": 23017 + }, + "LocalizedWarningCode": { + "LOCWARN_PERSONAL_RELOAD_REQUIRED": 0, + "LOCWARN_PERSONAL_VERSION_EXPIRES_SOON": 1, + "LOCWARN_EXPORT_DATA_TRUNCATED": 1000, + "LOCWARN_COULD_NOT_OPEN_ALL_OBJECTS": 2000 + }, + "GrpType": { + "GRP_NX_NONE": 0, + "GRP_NX_HIEARCHY": 1, + "GRP_NX_COLLECTION": 2 + }, + "ExportFileType": { + "EXPORT_CSV_C": 0, + "EXPORT_CSV_T": 1, + "EXPORT_OOXML": 2 + }, + "ExportState": { + "EXPORT_POSSIBLE": 0, + "EXPORT_ALL": 1 + }, + "DimCellType": { + "NX_DIM_CELL_VALUE": 0, + "NX_DIM_CELL_EMPTY": 1, + "NX_DIM_CELL_NORMAL": 2, + "NX_DIM_CELL_TOTAL": 3, + "NX_DIM_CELL_OTHER": 4, + "NX_DIM_CELL_AGGR": 5, + "NX_DIM_CELL_PSEUDO": 6, + "NX_DIM_CELL_ROOT": 7, + "NX_DIM_CELL_NULL": 8, + "NX_DIM_CELL_GENERATED": 9 + }, + "StackElemType": { + "NX_STACK_CELL_NORMAL": 0, + "NX_STACK_CELL_TOTAL": 1, + "NX_STACK_CELL_OTHER": 2, + "NX_STACK_CELL_SUM": 3, + "NX_STACK_CELL_VALUE": 4, + "NX_STACK_CELL_PSEUDO": 5 + }, + "SortIndicatorType": { + "NX_SORT_INDICATE_NONE": 0, + "NX_SORT_INDICATE_ASC": 1, + "NX_SORT_INDICATE_DESC": 2 + }, + "DimensionType": { + "NX_DIMENSION_TYPE_DISCRETE": 0, + "NX_DIMENSION_TYPE_NUMERIC": 1, + "NX_DIMENSION_TYPE_TIME": 2 + }, + "FieldSelectionMode": { + "SELECTION_MODE_NORMAL": 0, + "SELECTION_MODE_AND": 1, + "SELECTION_MODE_NOT": 2 + }, + "FrequencyMode": { + "NX_FREQUENCY_NONE": 0, + "NX_FREQUENCY_VALUE": 1, + "NX_FREQUENCY_PERCENT": 2, + "NX_FREQUENCY_RELATIVE": 3 + }, + "DataReductionMode": { + "DATA_REDUCTION_NONE": 0, + "DATA_REDUCTION_ONEDIM": 1, + "DATA_REDUCTION_SCATTERED": 2, + "DATA_REDUCTION_CLUSTERED": 3, + "DATA_REDUCTION_STACKED": 4 + }, + "HypercubeMode": { + "DATA_MODE_STRAIGHT": 0, + "DATA_MODE_PIVOT": 1, + "DATA_MODE_PIVOT_STACK": 2, + "DATA_MODE_TREE": 3 + }, + "PatchOperationType": { + "Add": 0, + "Remove": 1, + "Replace": 2 + }, + "SelectionCellType": { + "NX_CELL_DATA": 0, + "NX_CELL_TOP": 1, + "NX_CELL_LEFT": 2 + }, + "MatchingFieldMode": { + "MATCHINGFIELDMODE_MATCH_ALL": 0, + "MATCHINGFIELDMODE_MATCH_ONE": 1 + }, + "SessionState": { + "SESSION_CREATED": 0, + "SESSION_ATTACHED": 1 + }, + "QrsChangeType": { + "QRS_CHANGE_UNDEFINED": 0, + "QRS_CHANGE_ADD": 1, + "QRS_CHANGE_UPDATE": 2, + "QRS_CHANGE_DELETE": 3 + }, + "ExtEngineDataType": { + "NX_EXT_DATATYPE_STRING": 0, + "NX_EXT_DATATYPE_DOUBLE": 1, + "NX_EXT_DATATYPE_BOTH": 2 + }, + "ExtEngineFunctionType": { + "NX_EXT_FUNCTIONTYPE_SCALAR": 0, + "NX_EXT_FUNCTIONTYPE_AGGR": 1, + "NX_EXT_FUNCTIONTYPE_TENSOR": 2 + }, + "ExtEngineMsgType": { + "NX_EXT_MSGTYPE_FUNCTION_CALL": 1, + "NX_EXT_MSGTYPE_SCRIPT_CALL": 2, + "NX_EXT_MSGTYPE_RETURN_VALUE": 3, + "NX_EXT_MSGTYPE_RETURN_MULTIPLE": 4, + "NX_EXT_MSGTYPE_RETURN_ERROR": 5 + } + }, + "version": "12.34.11" +} diff --git a/jwt-scratch/src/js/node_modules/enigma.js/schemas/12.612.0.json b/jwt-scratch/src/js/node_modules/enigma.js/schemas/12.612.0.json new file mode 100644 index 0000000..23cb5d3 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/enigma.js/schemas/12.612.0.json @@ -0,0 +1,1743 @@ +{ + "structs": { + "Field":{ + "GetCardinal": { + "In": [], + "Out": [] + }, + "GetAndMode": { + "In": [], + "Out": [] + }, + "SelectValues": { + "In": [{ "Name": "qFieldValues","DefaultValue": [{"qText": "", "qIsNumeric": false, "qNumber": 0}] }, { "Name": "qToggleMode","DefaultValue": false, "Optional": true }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Select": { + "In": [{ "Name": "qMatch","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qExcludedValuesMode","DefaultValue": 0, "Optional": true }], + "Out": [] + }, + "ToggleSelect": { + "In": [{ "Name": "qMatch","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qExcludedValuesMode","DefaultValue": 0, "Optional": true }], + "Out": [] + }, + "ClearAllButThis": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectPossible": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectExcluded": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectAll": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Lock": { + "In": [], + "Out": [] + }, + "Unlock": { + "In": [], + "Out": [] + }, + "GetNxProperties": { + "In": [], + "Out": [{ "Name": "qProperties" }] + }, + "SetNxProperties": { + "In": [{ "Name": "qProperties","DefaultValue": {"qOneAndOnlyOne": false} }], + "Out": [] + }, + "SetAndMode": { + "In": [{ "Name": "qAndMode","DefaultValue": false }], + "Out": [] + }, + "SelectAlternative": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "LowLevelSelect": { + "In": [{ "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Clear": { + "In": [], + "Out": [] + } + }, + "Variable":{ + "GetContent": { + "In": [], + "Out": [{ "Name": "qContent" }] + }, + "GetRawContent": { + "In": [], + "Out": [] + }, + "SetContent": { + "In": [{ "Name": "qContent","DefaultValue": "" }, { "Name": "qUpdateMRU","DefaultValue": false }], + "Out": [] + }, + "ForceContent": { + "In": [{ "Name": "qs","DefaultValue": "" }, { "Name": "qd","DefaultValue": 0 }], + "Out": [] + }, + "GetNxProperties": { + "In": [], + "Out": [{ "Name": "qProperties" }] + }, + "SetNxProperties": { + "In": [{ "Name": "qProperties","DefaultValue": {"qName": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qUsePredefListedValues": false, "qPreDefinedList": [""]} }], + "Out": [] + } + }, + "GenericObject":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "GetListObjectData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeReducedData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qZoomFactor","DefaultValue": 0 }, { "Name": "qReductionMode","DefaultValue": 0 }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubePivotData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeStackData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qMaxNbrCells","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeContinuousData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qOptions","DefaultValue": {"qStart": 0, "qEnd": 0, "qNbrPoints": 0, "qMaxNbrTicks": 0, "qMaxNumberLines": 0} }, { "Name": "qReverseSort","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qDataPages" }, { "Name": "qAxisData" }] + }, + "GetHyperCubeTreeData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qNodeOptions","DefaultValue": {"qMaxNbrOfNodes": 0, "qTreeNodes": [{"qArea": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qAllValues": false}], "qTreeLevels": {"qLeft": 0, "qDepth": 0}}, "Optional": true }], + "Out": [{ "Name": "qNodes" }] + }, + "GetHyperCubeBinnedData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qViewport","DefaultValue": {"qWidth": 0, "qHeight": 0, "qZoomLevel": 0} }, { "Name": "qDataRanges","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qMaxNbrCells","DefaultValue": 0 }, { "Name": "qQueryLevel","DefaultValue": 0 }, { "Name": "qBinningMethod","DefaultValue": 0 }], + "Out": [{ "Name": "qDataPages" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }, { "Name": "qSoftPatch","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "ClearSoftPatches": { + "In": [], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}, "qStateName": ""} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetEffectiveProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "SetFullPropertyTree": { + "In": [{ "Name": "qPropEntry","DefaultValue": {"qProperty": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}, "qStateName": ""}, "qChildren": [], "qEmbeddedSnapshotRef": null} }], + "Out": [] + }, + "GetFullPropertyTree": { + "In": [], + "Out": [{ "Name": "qPropEntry" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "ClearSelections": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "ExportData": { + "In": [{ "Name": "qFileType","DefaultValue": 0 }, { "Name": "qPath","DefaultValue": "", "Optional": true }, { "Name": "qFileName","DefaultValue": "", "Optional": true }, { "Name": "qExportState","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qUrl" }, { "Name": "qWarnings" }] + }, + "SelectListObjectValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectPossible": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectExcluded": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectAlternative": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectAll": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectContinuousRange": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SearchListObjectFor": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qMatch","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "AbortListObjectSearch": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [] + }, + "AcceptListObjectSearch": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "ExpandLeft": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "ExpandTop": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "CollapseLeft": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "CollapseTop": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "DrillUp": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qDimNo","DefaultValue": 0 }, { "Name": "qNbrSteps","DefaultValue": 0 }], + "Out": [] + }, + "Lock": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "Unlock": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "SelectHyperCubeValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qDimNo","DefaultValue": 0 }, { "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectHyperCubeCells": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRowIndices","DefaultValue": [0] }, { "Name": "qColIndices","DefaultValue": [0] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectPivotCells": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSelections","DefaultValue": [{"qType": 0, "qCol": 0, "qRow": 0}] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "RangeSelectHyperCubeValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qRange": {"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}, "qMeasureIx": 0}] }, { "Name": "qColumnsToSelect","DefaultValue": [0], "Optional": true }, { "Name": "qOrMode","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "MultiRangeSelectHyperCubeValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qRanges": [{"qRange": {"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}, "qMeasureIx": 0}], "qColumnsToSelect": [0]}] }, { "Name": "qOrMode","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "MultiRangeSelectTreeDataValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qRanges": [{"qRange": {"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}, "qMeasureIx": 0, "qDimensionIx": 0}]}] }, { "Name": "qOrMode","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectHyperCubeContinuousRange": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qRange": {"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}, "qDimIx": 0}] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetChild": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetParent": { + "In": [], + "Out": [] + }, + "GetChildInfos": { + "In": [], + "Out": [{ "Name": "qInfos" }] + }, + "CreateChild": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}, "qStateName": ""} }, { "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyChild": { + "In": [{ "Name": "qId","DefaultValue": "" }, { "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "DestroyAllChildren": { + "In": [{ "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [] + }, + "SetChildArrayOrder": { + "In": [{ "Name": "qIds","DefaultValue": [""] }], + "Out": [] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "CopyFrom": { + "In": [{ "Name": "qFromId","DefaultValue": "" }], + "Out": [] + }, + "BeginSelections": { + "In": [{ "Name": "qPaths","DefaultValue": [""] }], + "Out": [] + }, + "EndSelections": { + "In": [{ "Name": "qAccept","DefaultValue": false }], + "Out": [] + }, + "ResetMadeSelections": { + "In": [], + "Out": [] + }, + "EmbedSnapshotObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetSnapshotObject": { + "In": [], + "Out": [] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + }, + "Approve": { + "In": [], + "Out": [] + }, + "UnApprove": { + "In": [], + "Out": [] + } + }, + "GenericDimension":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDim": {"qGrouping": 0, "qFieldDefs": [""], "qFieldLabels": [""], "qLabelExpression": ""}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetDimension": { + "In": [], + "Out": [{ "Name": "qDim" }] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + }, + "Approve": { + "In": [], + "Out": [] + }, + "UnApprove": { + "In": [], + "Out": [] + } + }, + "GenericBookmark":{ + "GetFieldValues": { + "In": [{ "Name": "qField","DefaultValue": "" }, { "Name": "qGetExcludedValues","DefaultValue": false }, { "Name": "qDataPage","DefaultValue": {"qStartIndex": 0, "qEndIndex": 0} }], + "Out": [{ "Name": "qFieldValues" }] + }, + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "Apply": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + }, + "Approve": { + "In": [], + "Out": [] + }, + "UnApprove": { + "In": [], + "Out": [] + } + }, + "GenericVariable":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "SetStringValue": { + "In": [{ "Name": "qVal","DefaultValue": "" }], + "Out": [] + }, + "SetNumValue": { + "In": [{ "Name": "qVal","DefaultValue": 0 }], + "Out": [] + }, + "SetDualValue": { + "In": [{ "Name": "qText","DefaultValue": "" }, { "Name": "qNum","DefaultValue": 0 }], + "Out": [] + }, + "GetRawContent": { + "In": [], + "Out": [] + } + }, + "GenericMeasure":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMeasure": {"qLabel": "", "qDef": "", "qGrouping": 0, "qExpressions": [""], "qActiveExpression": 0, "qLabelExpression": ""}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetMeasure": { + "In": [], + "Out": [{ "Name": "qMeasure" }] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + }, + "Approve": { + "In": [], + "Out": [] + }, + "UnApprove": { + "In": [], + "Out": [] + } + }, + "Doc":{ + "GetField": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }, { "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "GetFieldDescription": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }], + "Out": [] + }, + "GetVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "GetLooselyCoupledVector": { + "In": [], + "Out": [{ "Name": "qv" }] + }, + "SetLooselyCoupledVector": { + "In": [{ "Name": "qv","DefaultValue": [0] }], + "Out": [] + }, + "Evaluate": { + "In": [{ "Name": "qExpression","DefaultValue": "" }], + "Out": [] + }, + "EvaluateEx": { + "In": [{ "Name": "qExpression","DefaultValue": "" }], + "Out": [{ "Name": "qValue" }] + }, + "ClearAll": { + "In": [{ "Name": "qLockedAlso","DefaultValue": false, "Optional": true }, { "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "LockAll": { + "In": [{ "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "UnlockAll": { + "In": [{ "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "Back": { + "In": [], + "Out": [] + }, + "Forward": { + "In": [], + "Out": [] + }, + "CreateVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "RemoveVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "GetLocaleInfo": { + "In": [], + "Out": [] + }, + "GetTablesAndKeys": { + "In": [{ "Name": "qWindowSize","DefaultValue": {"qcx": 0, "qcy": 0} }, { "Name": "qNullSize","DefaultValue": {"qcx": 0, "qcy": 0} }, { "Name": "qCellHeight","DefaultValue": 0 }, { "Name": "qSyntheticMode","DefaultValue": false }, { "Name": "qIncludeSysVars","DefaultValue": false }], + "Out": [{ "Name": "qtr" }, { "Name": "qk" }] + }, + "GetViewDlgSaveInfo": { + "In": [], + "Out": [] + }, + "SetViewDlgSaveInfo": { + "In": [{ "Name": "qInfo","DefaultValue": {"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCtlInfo": {"qInternalView": {"qTables": [{"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCaption": ""}], "qBroomPoints": [{"qPos": {"qx": 0, "qy": 0}, "qTable": "", "qFields": [""]}], "qConnectionPoints": [{"qPos": {"qx": 0, "qy": 0}, "qFields": [""]}], "qZoomFactor": 0}, "qSourceView": {"qTables": [{"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCaption": ""}], "qBroomPoints": [{"qPos": {"qx": 0, "qy": 0}, "qTable": "", "qFields": [""]}], "qConnectionPoints": [{"qPos": {"qx": 0, "qy": 0}, "qFields": [""]}], "qZoomFactor": 0}}, "qMode": 0} }], + "Out": [] + }, + "GetEmptyScript": { + "In": [{ "Name": "qLocalizedMainSection","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "DoReload": { + "In": [{ "Name": "qMode","DefaultValue": 0, "Optional": true }, { "Name": "qPartial","DefaultValue": false, "Optional": true }, { "Name": "qDebug","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "GetScriptBreakpoints": { + "In": [], + "Out": [{ "Name": "qBreakpoints" }] + }, + "SetScriptBreakpoints": { + "In": [{ "Name": "qBreakpoints","DefaultValue": [{"qbufferName": "", "qlineIx": 0, "qEnabled": false}] }], + "Out": [] + }, + "GetScript": { + "In": [], + "Out": [{ "Name": "qScript" }] + }, + "GetTextMacros": { + "In": [], + "Out": [{ "Name": "qMacros" }] + }, + "SetFetchLimit": { + "In": [{ "Name": "qLimit","DefaultValue": 0 }], + "Out": [] + }, + "DoSave": { + "In": [{ "Name": "qFileName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "GetTableData": { + "In": [{ "Name": "qOffset","DefaultValue": 0 }, { "Name": "qRows","DefaultValue": 0 }, { "Name": "qSyntheticMode","DefaultValue": false }, { "Name": "qTableName","DefaultValue": "" }], + "Out": [{ "Name": "qData" }] + }, + "GetAppLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "SetAppProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qTitle": "", "qLastReloadTime": "", "qMigrationHash": "", "qSavedInProductVersion": "", "qThumbnail": {"qUrl": ""}, "qHasSectionAccess": false} }], + "Out": [] + }, + "GetAppProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetLineage": { + "In": [], + "Out": [{ "Name": "qLineage" }] + }, + "CreateSessionObject": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}, "qStateName": ""} }], + "Out": [] + }, + "DestroySessionObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CreateObject": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}, "qStateName": ""} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetObjects": { + "In": [{ "Name": "qOptions","DefaultValue": {"qTypes": [""], "qIncludeSessionObjects": false, "qData": {}} }], + "Out": [{ "Name": "qList" }] + }, + "GetBookmarks": { + "In": [{ "Name": "qOptions","DefaultValue": {"qTypes": [""], "qData": {}} }], + "Out": [{ "Name": "qList" }] + }, + "CloneObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qDraftId" }] + }, + "CommitDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "DestroyDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }, { "Name": "qSourceId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "Undo": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "Redo": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "ClearUndoBuffer": { + "In": [], + "Out": [] + }, + "CreateDimension": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDim": {"qGrouping": 0, "qFieldDefs": [""], "qFieldLabels": [""], "qLabelExpression": ""}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "CloneDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateMeasure": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMeasure": {"qLabel": "", "qDef": "", "qGrouping": 0, "qExpressions": [""], "qActiveExpression": 0, "qLabelExpression": ""}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "CloneMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateSessionVariable": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [] + }, + "DestroySessionVariable": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CreateVariableEx": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyVariableById": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "DestroyVariableByName": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetVariableById": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetVariableByName": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "MigrateVariables": { + "In": [], + "Out": [] + }, + "MigrateDerivedFields": { + "In": [], + "Out": [] + }, + "CheckExpression": { + "In": [{ "Name": "qExpr","DefaultValue": "" }, { "Name": "qLabels","DefaultValue": [""], "Optional": true }], + "Out": [{ "Name": "qErrorMsg" }, { "Name": "qBadFieldNames" }, { "Name": "qDangerousFieldNames" }] + }, + "CheckNumberOrExpression": { + "In": [{ "Name": "qExpr","DefaultValue": "" }], + "Out": [{ "Name": "qErrorMsg" }, { "Name": "qBadFieldNames" }] + }, + "AddAlternateState": { + "In": [{ "Name": "qStateName","DefaultValue": "" }], + "Out": [] + }, + "RemoveAlternateState": { + "In": [{ "Name": "qStateName","DefaultValue": "" }], + "Out": [] + }, + "CreateBookmark": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "ApplyBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CloneBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "AddFieldFromExpression": { + "In": [{ "Name": "qName","DefaultValue": "" }, { "Name": "qExpr","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetFieldOnTheFlyByName": { + "In": [{ "Name": "qReadableName","DefaultValue": "" }], + "Out": [{ "Name": "qName" }] + }, + "GetAllInfos": { + "In": [], + "Out": [{ "Name": "qInfos" }] + }, + "Resume": { + "In": [], + "Out": [] + }, + "AbortModal": { + "In": [{ "Name": "qAccept","DefaultValue": false }], + "Out": [] + }, + "Publish": { + "In": [{ "Name": "qStreamId","DefaultValue": "" }, { "Name": "qName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + }, + "GetMatchingFields": { + "In": [{ "Name": "qTags","DefaultValue": [""] }, { "Name": "qMatchingFieldMode","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qFieldNames" }] + }, + "FindMatchingFields": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }, { "Name": "qTags","DefaultValue": [""] }], + "Out": [{ "Name": "qFieldNames" }] + }, + "Scramble": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }], + "Out": [] + }, + "SaveObjects": { + "In": [], + "Out": [] + }, + "GetAssociationScores": { + "In": [{ "Name": "qTable1","DefaultValue": "" }, { "Name": "qTable2","DefaultValue": "" }], + "Out": [{ "Name": "qScore" }] + }, + "GetMediaList": { + "In": [], + "Out": [{ "Name": "qList" }] + }, + "GetContentLibraries": { + "In": [], + "Out": [{ "Name": "qList" }] + }, + "GetLibraryContent": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [{ "Name": "qList" }] + }, + "DoReloadEx": { + "In": [{ "Name": "qParams","DefaultValue": {"qMode": 0, "qPartial": false, "qDebug": false, "qReloadId": ""}, "Optional": true }], + "Out": [{ "Name": "qResult" }] + }, + "BackCount": { + "In": [], + "Out": [] + }, + "ForwardCount": { + "In": [], + "Out": [] + }, + "ExportReducedData": { + "In": [{ "Name": "qOptions","DefaultValue": {"qBookmarkId": "", "qExpires": 0}, "Optional": true }], + "Out": [{ "Name": "qDownloadInfo" }] + }, + "GetSetAnalysis": { + "In": [{ "Name": "qStateName","DefaultValue": "", "Optional": true }, { "Name": "qBookmarkId","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qSetExpression" }] + }, + "SetScript": { + "In": [{ "Name": "qScript","DefaultValue": "" }], + "Out": [] + }, + "CheckScriptSyntax": { + "In": [], + "Out": [{ "Name": "qErrors" }] + }, + "GetFavoriteVariables": { + "In": [], + "Out": [{ "Name": "qNames" }] + }, + "SetFavoriteVariables": { + "In": [{ "Name": "qNames","DefaultValue": [""] }], + "Out": [] + }, + "GetIncludeFileContent": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [{ "Name": "qContent" }] + }, + "CreateConnection": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }], + "Out": [{ "Name": "qConnectionId" }] + }, + "ModifyConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }, { "Name": "qOverrideCredentials","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "DeleteConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [] + }, + "GetConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qConnection" }] + }, + "GetConnections": { + "In": [], + "Out": [{ "Name": "qConnections" }] + }, + "GetDatabaseInfo": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qInfo" }] + }, + "GetDatabases": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qDatabases" }] + }, + "GetDatabaseOwners": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qOwners" }] + }, + "GetDatabaseTables": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qTables" }] + }, + "GetDatabaseTableFields": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qFields" }] + }, + "GetDatabaseTablePreview": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }, { "Name": "qTable","DefaultValue": "" }, { "Name": "qConditions","DefaultValue": {"qType": 0, "qWherePredicate": ""}, "Optional": true }], + "Out": [{ "Name": "qPreview" }, { "Name": "qRowCount" }] + }, + "GetFolderItemsForConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qFolderItems" }] + }, + "GuessFileType": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qDataFormat" }] + }, + "GetFileTables": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }], + "Out": [{ "Name": "qTables" }] + }, + "GetFileTableFields": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qFields" }, { "Name": "qFormatSpec" }] + }, + "GetFileTablePreview": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qPreview" }, { "Name": "qFormatSpec" }] + }, + "GetFileTablesEx": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }], + "Out": [{ "Name": "qTables" }] + }, + "SendGenericCommandToCustomConnector": { + "In": [{ "Name": "qProvider","DefaultValue": "" }, { "Name": "qCommand","DefaultValue": "" }, { "Name": "qMethod","DefaultValue": "" }, { "Name": "qParameters","DefaultValue": [""] }, { "Name": "qAppendConnection","DefaultValue": "" }], + "Out": [{ "Name": "qResult" }] + }, + "SearchSuggest": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0, "qCharEncoding": 0, "qAttributes": [""]} }, { "Name": "qTerms","DefaultValue": [""] }], + "Out": [{ "Name": "qResult" }] + }, + "SearchAssociations": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0, "qCharEncoding": 0, "qAttributes": [""]} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qPage","DefaultValue": {"qOffset": 0, "qCount": 0, "qMaxNbrFieldMatches": 0, "qGroupOptions": [{"qGroupType": 0, "qOffset": 0, "qCount": 0}], "qGroupItemOptions": [{"qGroupItemType": 0, "qOffset": 0, "qCount": 0}]} }], + "Out": [{ "Name": "qResults" }] + }, + "SelectAssociations": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0, "qCharEncoding": 0, "qAttributes": [""]} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qMatchIx","DefaultValue": 0 }, { "Name": "qSoftLock","DefaultValue": null, "Optional": true }], + "Out": [] + }, + "SearchResults": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0, "qCharEncoding": 0, "qAttributes": [""]} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qPage","DefaultValue": {"qOffset": 0, "qCount": 0, "qMaxNbrFieldMatches": 0, "qGroupOptions": [{"qGroupType": 0, "qOffset": 0, "qCount": 0}], "qGroupItemOptions": [{"qGroupItemType": 0, "qOffset": 0, "qCount": 0}]} }], + "Out": [{ "Name": "qResult" }] + }, + "SearchObjects": { + "In": [{ "Name": "qOptions","DefaultValue": {"qAttributes": [""], "qCharEncoding": 0} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qPage","DefaultValue": {"qOffset": 0, "qCount": 0, "qMaxNbrFieldMatches": 0, "qGroupOptions": [{"qGroupType": 0, "qOffset": 0, "qCount": 0}], "qGroupItemOptions": [{"qGroupItemType": 0, "qOffset": 0, "qCount": 0}]} }], + "Out": [{ "Name": "qResult" }] + }, + "GetFieldAndColumnSamples": { + "In": [{ "Name": "qFieldsOrColumnsWithWildcards","DefaultValue": [{"qFieldName": "", "qTableName": ""}] }, { "Name": "qMaxNumberOfValues","DefaultValue": 0 }, { "Name": "qRandSeed","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qResult" }] + }, + "GetScriptEx": { + "In": [], + "Out": [{ "Name": "qScript" }] + }, + "GetVariables": { + "In": [{ "Name": "qListDef","DefaultValue": {"qType": "", "qShowReserved": false, "qShowConfig": false, "qData": {}, "qShowSession": false} }], + "Out": [{ "Name": "qList" }] + }, + "ExpandExpression": { + "In": [{ "Name": "qExpression","DefaultValue": "" }], + "Out": [{ "Name": "qExpandedExpression" }] + }, + "DestroySessionVariableById": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "DestroySessionVariableByName": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "SetAppObjectSortingRank": { + "In": [{ "Name": "qId","DefaultValue": "" }, { "Name": "qRank","DefaultValue": 0 }], + "Out": [] + }, + "GetActiveSheetId": { + "In": [], + "Out": [{ "Name": "qId" }] + }, + "GetLayoutProperties": { + "In": [], + "Out": [{ "Name": "qLayoutProp" }] + }, + "CreateBookmarkEx": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}} }, { "Name": "qObjectIdsToPatch","DefaultValue": [""], "Optional": true }], + "Out": [{ "Name": "qInfo" }] + }, + "SaveAs": { + "In": [{ "Name": "qNewAppName","DefaultValue": "" }], + "Out": [{ "Name": "qNewAppId" }] + } + }, + "Global":{ + "AbortRequest": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [] + }, + "AbortAll": { + "In": [], + "Out": [] + }, + "GetProgress": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [{ "Name": "qProgressData" }] + }, + "QvVersion": { + "In": [], + "Out": [] + }, + "OSVersion": { + "In": [], + "Out": [] + }, + "OSName": { + "In": [], + "Out": [] + }, + "QTProduct": { + "In": [], + "Out": [] + }, + "GetDocList": { + "In": [], + "Out": [{ "Name": "qDocList" }] + }, + "GetInteract": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [{ "Name": "qDef" }] + }, + "InteractDone": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }, { "Name": "qDef","DefaultValue": {"qType": 0, "qTitle": "", "qMsg": "", "qButtons": 0, "qLine": "", "qOldLineNr": 0, "qNewLineNr": 0, "qPath": "", "qHidden": false, "qResult": 0, "qInput": ""} }], + "Out": [] + }, + "GetAuthenticatedUser": { + "In": [], + "Out": [] + }, + "CreateDocEx": { + "In": [{ "Name": "qDocName","DefaultValue": "" }, { "Name": "qUserName","DefaultValue": "", "Optional": true }, { "Name": "qPassword","DefaultValue": "", "Optional": true }, { "Name": "qSerial","DefaultValue": "", "Optional": true }, { "Name": "qLocalizedScriptMainSection","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qDocId" }] + }, + "GetActiveDoc": { + "In": [], + "Out": [] + }, + "AllowCreateApp": { + "In": [], + "Out": [] + }, + "CreateApp": { + "In": [{ "Name": "qAppName","DefaultValue": "" }, { "Name": "qLocalizedScriptMainSection","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qSuccess" }, { "Name": "qAppId" }] + }, + "DeleteApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "IsDesktopMode": { + "In": [], + "Out": [] + }, + "GetConfiguration": { + "In": [], + "Out": [{ "Name": "qConfig" }] + }, + "CancelRequest": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [] + }, + "ShutdownProcess": { + "In": [], + "Out": [] + }, + "ReloadExtensionList": { + "In": [], + "Out": [] + }, + "ReplaceAppFromID": { + "In": [{ "Name": "qTargetAppId","DefaultValue": "" }, { "Name": "qSrcAppID","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "ReplaceAppFromPath": { + "In": [{ "Name": "qTargetAppId","DefaultValue": "" }, { "Name": "qSrcPath","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }, { "Name": "qNoData","DefaultValue": false }], + "Out": [] + }, + "CopyApp": { + "In": [{ "Name": "qTargetAppId","DefaultValue": "" }, { "Name": "qSrcAppId","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "ImportApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qSrcPath","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "ImportAppEx": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qSrcPath","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }, { "Name": "qExcludeConnections","DefaultValue": false }], + "Out": [] + }, + "ExportApp": { + "In": [{ "Name": "qTargetPath","DefaultValue": "" }, { "Name": "qSrcAppId","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }, { "Name": "qNoData","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "PublishApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qName","DefaultValue": "" }, { "Name": "qStreamId","DefaultValue": "" }], + "Out": [] + }, + "IsPersonalMode": { + "In": [], + "Out": [] + }, + "GetUniqueID": { + "In": [], + "Out": [{ "Name": "qUniqueID" }] + }, + "OpenDoc": { + "In": [{ "Name": "qDocName","DefaultValue": "" }, { "Name": "qUserName","DefaultValue": "", "Optional": true }, { "Name": "qPassword","DefaultValue": "", "Optional": true }, { "Name": "qSerial","DefaultValue": "", "Optional": true }, { "Name": "qNoData","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "CreateSessionApp": { + "In": [], + "Out": [{ "Name": "qSessionAppId" }] + }, + "CreateSessionAppFromApp": { + "In": [{ "Name": "qSrcAppId","DefaultValue": "" }], + "Out": [{ "Name": "qSessionAppId" }] + }, + "ProductVersion": { + "In": [], + "Out": [] + }, + "GetAppEntry": { + "In": [{ "Name": "qAppID","DefaultValue": "" }], + "Out": [{ "Name": "qEntry" }] + }, + "ConfigureReload": { + "In": [{ "Name": "qCancelOnScriptError","DefaultValue": false }, { "Name": "qUseErrorData","DefaultValue": false }, { "Name": "qInteractOnError","DefaultValue": false }], + "Out": [] + }, + "CancelReload": { + "In": [], + "Out": [] + }, + "GetBNF": { + "In": [{ "Name": "qBnfType","DefaultValue": 0 }], + "Out": [{ "Name": "qBnfDefs" }] + }, + "GetFunctions": { + "In": [{ "Name": "qGroup","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qFunctions" }] + }, + "GetOdbcDsns": { + "In": [], + "Out": [{ "Name": "qOdbcDsns" }] + }, + "GetOleDbProviders": { + "In": [], + "Out": [{ "Name": "qOleDbProviders" }] + }, + "GetDatabasesFromConnectionString": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }], + "Out": [{ "Name": "qDatabases" }] + }, + "IsValidConnectionString": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }], + "Out": [] + }, + "GetDefaultAppFolder": { + "In": [], + "Out": [{ "Name": "qPath" }] + }, + "GetMyDocumentsFolder": { + "In": [], + "Out": [{ "Name": "qFolder" }] + }, + "GetLogicalDriveStrings": { + "In": [], + "Out": [{ "Name": "qDrives" }] + }, + "GetFolderItemsForPath": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [{ "Name": "qFolderItems" }] + }, + "GetSupportedCodePages": { + "In": [], + "Out": [{ "Name": "qCodePages" }] + }, + "GetCustomConnectors": { + "In": [{ "Name": "qReloadList","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qConnectors" }] + }, + "GetStreamList": { + "In": [], + "Out": [{ "Name": "qStreamList" }] + }, + "EngineVersion": { + "In": [], + "Out": [{ "Name": "qVersion" }] + }, + "GetBaseBNF": { + "In": [{ "Name": "qBnfType","DefaultValue": 0 }], + "Out": [{ "Name": "qBnfDefs" }, { "Name": "qBnfHash" }] + }, + "GetBaseBNFHash": { + "In": [{ "Name": "qBnfType","DefaultValue": 0 }], + "Out": [{ "Name": "qBnfHash" }] + }, + "GetBaseBNFString": { + "In": [{ "Name": "qBnfType","DefaultValue": 0 }], + "Out": [{ "Name": "qBnfStr" }, { "Name": "qBnfHash" }] + }, + "SaveAs": { + "In": [{ "Name": "qNewAppName","DefaultValue": "" }], + "Out": [{ "Name": "qNewAppId" }] + } + } + }, + "enums": { + "LocalizedMessageCode": { + "LOCMSG_SCRIPTEDITOR_EMPTY_MESSAGE": 0, + "LOCMSG_SCRIPTEDITOR_PROGRESS_SAVING_STARTED": 1, + "LOCMSG_SCRIPTEDITOR_PROGRESS_BYTES_LEFT": 2, + "LOCMSG_SCRIPTEDITOR_PROGRESS_STORING_TABLES": 3, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_ROWS_SO_FAR": 4, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECTED": 5, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECTING_TO": 6, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECT_FAILED": 7, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_ROWISH": 8, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_COLUMNAR": 9, + "LOCMSG_SCRIPTEDITOR_ERROR": 10, + "LOCMSG_SCRIPTEDITOR_DONE": 11, + "LOCMSG_SCRIPTEDITOR_LOAD_EXTERNAL_DATA": 12, + "LOCMSG_SCRIPTEDITOR_PROGRESS_OLD_QVD_ISLOADING": 13, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_LOADING": 14, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_BUFFERED": 15, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_PREPARING": 16, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_APPENDING": 17, + "LOCMSG_SCRIPTEDITOR_REMOVE_SYNTHETIC": 18, + "LOCMSG_SCRIPTEDITOR_PENDING_LINKEDTABLE_FETCHING": 19, + "LOCMSG_SCRIPTEDITOR_RELOAD": 20, + "LOCMSG_SCRIPTEDITOR_LINES_FETCHED": 21, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_START": 22, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_FIELD": 23, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_SUCCESS": 24, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_FAILURE": 25, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_STARTABORT": 26, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_ENDABORT": 27, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_TIMEOUT": 28, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_OUTOFMEMORY": 29, + "LOCMSG_SCRIPTEDITOR_ACCESS_DENIED_AFTER_RELOAD": 30 + }, + "LocalizedErrorCode": { + "LOCERR_INTERNAL_ERROR": -128, + "LOCERR_GENERIC_UNKNOWN": -1, + "LOCERR_GENERIC_OK": 0, + "LOCERR_GENERIC_NOT_SET": 1, + "LOCERR_GENERIC_NOT_FOUND": 2, + "LOCERR_GENERIC_ALREADY_EXISTS": 3, + "LOCERR_GENERIC_INVALID_PATH": 4, + "LOCERR_GENERIC_ACCESS_DENIED": 5, + "LOCERR_GENERIC_OUT_OF_MEMORY": 6, + "LOCERR_GENERIC_NOT_INITIALIZED": 7, + "LOCERR_GENERIC_INVALID_PARAMETERS": 8, + "LOCERR_GENERIC_EMPTY_PARAMETERS": 9, + "LOCERR_GENERIC_INTERNAL_ERROR": 10, + "LOCERR_GENERIC_CORRUPT_DATA": 11, + "LOCERR_GENERIC_MEMORY_INCONSISTENCY": 12, + "LOCERR_GENERIC_INVISIBLE_OWNER_ABORT": 13, + "LOCERR_GENERIC_PROHIBIT_VALIDATE": 14, + "LOCERR_GENERIC_ABORTED": 15, + "LOCERR_GENERIC_CONNECTION_LOST": 16, + "LOCERR_GENERIC_UNSUPPORTED_IN_PRODUCT_VERSION": 17, + "LOCERR_GENERIC_REST_CONNECTION_FAILURE": 18, + "LOCERR_GENERIC_MEMORY_LIMIT_REACHED": 19, + "LOCERR_GENERIC_NOT_IMPLEMENTED": 20, + "LOCERR_HTTP_400": 400, + "LOCERR_HTTP_401": 401, + "LOCERR_HTTP_402": 402, + "LOCERR_HTTP_403": 403, + "LOCERR_HTTP_404": 404, + "LOCERR_HTTP_405": 405, + "LOCERR_HTTP_406": 406, + "LOCERR_HTTP_407": 407, + "LOCERR_HTTP_408": 408, + "LOCERR_HTTP_409": 409, + "LOCERR_HTTP_410": 410, + "LOCERR_HTTP_411": 411, + "LOCERR_HTTP_412": 412, + "LOCERR_HTTP_413": 413, + "LOCERR_HTTP_414": 414, + "LOCERR_HTTP_415": 415, + "LOCERR_HTTP_416": 416, + "LOCERR_HTTP_417": 417, + "LOCERR_HTTP_422": 422, + "LOCERR_HTTP_429": 429, + "LOCERR_HTTP_500": 500, + "LOCERR_HTTP_501": 501, + "LOCERR_HTTP_502": 502, + "LOCERR_HTTP_503": 503, + "LOCERR_HTTP_504": 504, + "LOCERR_HTTP_505": 505, + "LOCERR_HTTP_509": 509, + "LOCERR_HTTP_COULD_NOT_RESOLVE_HOST": 700, + "LOCERR_APP_ALREADY_EXISTS": 1000, + "LOCERR_APP_INVALID_NAME": 1001, + "LOCERR_APP_ALREADY_OPEN": 1002, + "LOCERR_APP_NOT_FOUND": 1003, + "LOCERR_APP_IMPORT_FAILED": 1004, + "LOCERR_APP_SAVE_FAILED": 1005, + "LOCERR_APP_CREATE_FAILED": 1006, + "LOCERR_APP_INVALID": 1007, + "LOCERR_APP_CONNECT_FAILED": 1008, + "LOCERR_APP_ALREADY_OPEN_IN_DIFFERENT_MODE": 1009, + "LOCERR_APP_MIGRATION_COULD_NOT_CONTACT_MIGRATION_SERVICE": 1010, + "LOCERR_APP_MIGRATION_COULD_NOT_START_MIGRATION": 1011, + "LOCERR_APP_MIGRATION_FAILURE": 1012, + "LOCERR_APP_SCRIPT_MISSING": 1013, + "LOCERR_APP_EXPORT_FAILED": 1014, + "LOCERR_CONNECTION_ALREADY_EXISTS": 2000, + "LOCERR_CONNECTION_NOT_FOUND": 2001, + "LOCERR_CONNECTION_FAILED_TO_LOAD": 2002, + "LOCERR_CONNECTION_FAILED_TO_IMPORT": 2003, + "LOCERR_CONNECTION_NAME_IS_INVALID": 2004, + "LOCERR_CONNECTOR_NO_FILE_STREAMING_SUPPORT": 2300, + "LOCERR_CONNECTOR_FILESIZE_EXCEEDED_BUFFER_SIZE": 2301, + "LOCERR_FILE_ACCESS_DENIED": 3000, + "LOCERR_FILE_NAME_INVALID": 3001, + "LOCERR_FILE_CORRUPT": 3002, + "LOCERR_FILE_NOT_FOUND": 3003, + "LOCERR_FILE_FORMAT_UNSUPPORTED": 3004, + "LOCERR_FILE_OPENED_IN_UNSUPPORTED_MODE": 3005, + "LOCERR_FILE_TABLE_NOT_FOUND": 3006, + "LOCERR_USER_ACCESS_DENIED": 4000, + "LOCERR_USER_IMPERSONATION_FAILED": 4001, + "LOCERR_SERVER_OUT_OF_SESSION_AND_USER_CALS": 5000, + "LOCERR_SERVER_OUT_OF_SESSION_CALS": 5001, + "LOCERR_SERVER_OUT_OF_USAGE_CALS": 5002, + "LOCERR_SERVER_OUT_OF_CALS": 5003, + "LOCERR_SERVER_OUT_OF_NAMED_CALS": 5004, + "LOCERR_SERVER_OFF_DUTY": 5005, + "LOCERR_SERVER_BUSY": 5006, + "LOCERR_SERVER_LICENSE_EXPIRED": 5007, + "LOCERR_SERVER_AJAX_DISABLED": 5008, + "LOCERR_SERVER_NO_TOKEN": 5009, + "LOCERR_HC_INVALID_OBJECT": 6000, + "LOCERR_HC_RESULT_TOO_LARGE": 6001, + "LOCERR_HC_INVALID_OBJECT_STATE": 6002, + "LOCERR_HC_MODAL_OBJECT_ERROR": 6003, + "LOCERR_CALC_INVALID_DEF": 7000, + "LOCERR_CALC_NOT_IN_LIB": 7001, + "LOCERR_CALC_HEAP_ERROR": 7002, + "LOCERR_CALC_TOO_LARGE": 7003, + "LOCERR_CALC_TIMEOUT": 7004, + "LOCERR_CALC_EVAL_CONDITION_FAILED": 7005, + "LOCERR_CALC_MIXED_LINKED_AGGREGATION": 7006, + "LOCERR_CALC_MISSING_LINKED": 7007, + "LOCERR_CALC_INVALID_COL_SORT": 7008, + "LOCERR_CALC_PAGES_TOO_LARGE": 7009, + "LOCERR_CALC_SEMANTIC_FIELD_NOT_ALLOWED": 7010, + "LOCERR_CALC_VALIDATION_STATE_INVALID": 7011, + "LOCERR_CALC_PIVOT_DIMENSIONS_ALREADY_EXISTS": 7012, + "LOCERR_CALC_MISSING_LINKED_FIELD": 7013, + "LOCERR_CALC_NOT_CALCULATED": 7014, + "LOCERR_LAYOUT_EXTENDS_INVALID_ID": 8000, + "LOCERR_LAYOUT_LINKED_OBJECT_NOT_FOUND": 8001, + "LOCERR_LAYOUT_LINKED_OBJECT_INVALID": 8002, + "LOCERR_PERSISTENCE_WRITE_FAILED": 9000, + "LOCERR_PERSISTENCE_READ_FAILED": 9001, + "LOCERR_PERSISTENCE_DELETE_FAILED": 9002, + "LOCERR_PERSISTENCE_NOT_FOUND": 9003, + "LOCERR_PERSISTENCE_UNSUPPORTED_VERSION": 9004, + "LOCERR_PERSISTENCE_MIGRATION_FAILED_READ_ONLY": 9005, + "LOCERR_PERSISTENCE_MIGRATION_CANCELLED": 9006, + "LOCERR_PERSISTENCE_MIGRATION_BACKUP_FAILED": 9007, + "LOCERR_PERSISTENCE_DISK_FULL": 9008, + "LOCERR_PERSISTENCE_NOT_SUPPORTED_FOR_SESSION_APP": 9009, + "LOCERR_PERSISTENCE_MOVE_FAILED": 9010, + "LOCERR_PERSISTENCE_SYNC_SET_CHUNK_INVALID_PARAMETERS": 9510, + "LOCERR_PERSISTENCE_SYNC_GET_CHUNK_INVALID_PARAMETERS": 9511, + "LOCERR_SCRIPT_DATASOURCE_ACCESS_DENIED": 10000, + "LOCERR_RELOAD_IN_PROGRESS": 11000, + "LOCERR_RELOAD_TABLE_X_NOT_FOUND": 11001, + "LOCERR_RELOAD_UNKNOWN_STATEMENT": 11002, + "LOCERR_RELOAD_EXPECTED_SOMETHING_FOUND_UNKNOWN": 11003, + "LOCERR_RELOAD_EXPECTED_NOTHING_FOUND_UNKNOWN": 11004, + "LOCERR_RELOAD_EXPECTED_ONE_OF_1_TOKENS_FOUND_UNKNOWN": 11005, + "LOCERR_RELOAD_EXPECTED_ONE_OF_2_TOKENS_FOUND_UNKNOWN": 11006, + "LOCERR_RELOAD_EXPECTED_ONE_OF_3_TOKENS_FOUND_UNKNOWN": 11007, + "LOCERR_RELOAD_EXPECTED_ONE_OF_4_TOKENS_FOUND_UNKNOWN": 11008, + "LOCERR_RELOAD_EXPECTED_ONE_OF_5_TOKENS_FOUND_UNKNOWN": 11009, + "LOCERR_RELOAD_EXPECTED_ONE_OF_6_TOKENS_FOUND_UNKNOWN": 11010, + "LOCERR_RELOAD_EXPECTED_ONE_OF_7_TOKENS_FOUND_UNKNOWN": 11011, + "LOCERR_RELOAD_EXPECTED_ONE_OF_8_OR_MORE_TOKENS_FOUND_UNKNOWN": 11012, + "LOCERR_RELOAD_FIELD_X_NOT_FOUND": 11013, + "LOCERR_RELOAD_MAPPING_TABLE_X_NOT_FOUND": 11014, + "LOCERR_RELOAD_LIB_CONNECTION_X_NOT_FOUND": 11015, + "LOCERR_RELOAD_NAME_ALREADY_TAKEN": 11016, + "LOCERR_RELOAD_WRONG_FILE_FORMAT_DIF": 11017, + "LOCERR_RELOAD_WRONG_FILE_FORMAT_BIFF": 11018, + "LOCERR_RELOAD_WRONG_FILE_FORMAT_ENCRYPTED": 11019, + "LOCERR_RELOAD_OPEN_FILE_ERROR": 11020, + "LOCERR_RELOAD_AUTO_GENERATE_COUNT": 11021, + "LOCERR_RELOAD_PE_ILLEGAL_PREFIX_COMB": 11022, + "LOCERR_RELOAD_MATCHING_CONTROL_STATEMENT_ERROR": 11023, + "LOCERR_RELOAD_MATCHING_LIBPATH_X_NOT_FOUND": 11024, + "LOCERR_RELOAD_MATCHING_LIBPATH_X_INVALID": 11025, + "LOCERR_RELOAD_MATCHING_LIBPATH_X_OUTSIDE": 11026, + "LOCERR_RELOAD_NO_QUALIFIED_PATH_FOR_FILE": 11027, + "LOCERR_RELOAD_MODE_STATEMENT_ONLY_FOR_LIB_PATHS": 11028, + "LOCERR_RELOAD_INCONSISTENT_USE_OF_SEMANTIC_FIELDS": 11029, + "LOCERR_RELOAD_NO_OPEN_DATABASE": 11030, + "LOCERR_RELOAD_AGGREGATION_REQUIRED_BY_GROUP_BY": 11031, + "LOCERR_RELOAD_CONNECT_MUST_USE_LIB_PREFIX_IN_THIS_MODE": 11032, + "LOCERR_RELOAD_ODBC_CONNECT_FAILED": 11033, + "LOCERR_RELOAD_OLEDB_CONNECT_FAILED": 11034, + "LOCERR_RELOAD_CUSTOM_CONNECT_FAILED": 11035, + "LOCERR_RELOAD_ODBC_READ_FAILED": 11036, + "LOCERR_RELOAD_OLEDB_READ_FAILED": 11037, + "LOCERR_RELOAD_CUSTOM_READ_FAILED": 11038, + "LOCERR_RELOAD_BINARY_LOAD_PROHIBITED": 11039, + "LOCERR_RELOAD_CONNECTOR_START_FAILED": 11040, + "LOCERR_RELOAD_CONNECTOR_NOT_RESPONDING": 11041, + "LOCERR_RELOAD_CONNECTOR_REPLY_ERROR": 11042, + "LOCERR_RELOAD_CONNECTOR_CONNECT_ERROR": 11043, + "LOCERR_RELOAD_CONNECTOR_NOT_FOUND_ERROR": 11044, + "LOCERR_RELOAD_INPUT_FIELD_WITH_DUPLICATE_KEYS": 11045, + "LOCERR_RELOAD_CONCATENATE_LOAD_NO_PREVIOUS_TABLE": 11046, + "LOCERR_RELOAD_WRONG_FILE_FORMAT_QVD": 11047, + "LOCERR_PERSONAL_NEW_VERSION_AVAILABLE": 12000, + "LOCERR_PERSONAL_VERSION_EXPIRED": 12001, + "LOCERR_PERSONAL_SECTION_ACCESS_DETECTED": 12002, + "LOCERR_PERSONAL_APP_DELETION_FAILED": 12003, + "LOCERR_USER_AUTHENTICATION_FAILURE": 12004, + "LOCERR_EXPORT_OUT_OF_MEMORY": 13000, + "LOCERR_EXPORT_NO_DATA": 13001, + "LOCERR_SYNC_INVALID_OFFSET": 14000, + "LOCERR_SEARCH_TIMEOUT": 15000, + "LOCERR_DIRECT_DISCOVERY_LINKED_EXPRESSION_FAIL": 16000, + "LOCERR_DIRECT_DISCOVERY_ROWCOUNT_OVERFLOW": 16001, + "LOCERR_DIRECT_DISCOVERY_EMPTY_RESULT": 16002, + "LOCERR_DIRECT_DISCOVERY_DB_CONNECTION_FAILED": 16003, + "LOCERR_DIRECT_DISCOVERY_MEASURE_NOT_ALLOWED": 16004, + "LOCERR_DIRECT_DISCOVERY_DETAIL_NOT_ALLOWED": 16005, + "LOCERR_DIRECT_DISCOVERY_NOT_SYNTH_CIRCULAR_ALLOWED": 16006, + "LOCERR_DIRECT_DISCOVERY_ONLY_ONE_DD_TABLE_ALLOWED": 16007, + "LOCERR_DIRECT_DISCOVERY_DB_AUTHORIZATION_FAILED": 16008, + "LOCERR_SMART_LOAD_TABLE_NOT_FOUND": 17000, + "LOCERR_SMART_LOAD_TABLE_DUPLICATED": 17001, + "LOCERR_VARIABLE_NO_NAME": 18000, + "LOCERR_VARIABLE_DUPLICATE_NAME": 18001, + "LOCERR_VARIABLE_INCONSISTENCY": 18002, + "LOCERR_MEDIA_LIBRARY_LIST_FAILED": 19000, + "LOCERR_MEDIA_LIBRARY_CONTENT_FAILED": 19001, + "LOCERR_MEDIA_BUNDLING_FAILED": 19002, + "LOCERR_MEDIA_UNBUNDLING_FAILED": 19003, + "LOCERR_MEDIA_LIBRARY_NOT_FOUND": 19004, + "LOCERR_FEATURE_DISABLED": 20000, + "LOCERR_JSON_RPC_INVALID_REQUEST": -32600, + "LOCERR_JSON_RPC_METHOD_NOT_FOUND": -32601, + "LOCERR_JSON_RPC_INVALID_PARAMETERS": -32602, + "LOCERR_JSON_RPC_INTERNAL_ERROR": -32603, + "LOCERR_JSON_RPC_PARSE_ERROR": -32700, + "LOCERR_MQ_SOCKET_CONNECT_FAILURE": 33000, + "LOCERR_MQ_SOCKET_OPEN_FAILURE": 33001, + "LOCERR_MQ_PROTOCOL_NO_RESPONE": 33002, + "LOCERR_MQ_PROTOCOL_LIBRARY_EXCEPTION": 33003, + "LOCERR_MQ_PROTOCOL_CONNECTION_CLOSED": 33004, + "LOCERR_MQ_PROTOCOL_CHANNEL_CLOSED": 33005, + "LOCERR_MQ_PROTOCOL_UNKNOWN_ERROR": 33006, + "LOCERR_MQ_PROTOCOL_INVALID_STATUS": 33007, + "LOCERR_EXTENGINE_GRPC_STATUS_OK": 22000, + "LOCERR_EXTENGINE_GRPC_STATUS_CANCELLED": 22001, + "LOCERR_EXTENGINE_GRPC_STATUS_UNKNOWN": 22002, + "LOCERR_EXTENGINE_GRPC_STATUS_INVALID_ARGUMENT": 22003, + "LOCERR_EXTENGINE_GRPC_STATUS_DEADLINE_EXCEEDED": 22004, + "LOCERR_EXTENGINE_GRPC_STATUS_NOT_FOUND": 22005, + "LOCERR_EXTENGINE_GRPC_STATUS_ALREADY_EXISTS": 22006, + "LOCERR_EXTENGINE_GRPC_STATUS_PERMISSION_DENIED": 22007, + "LOCERR_EXTENGINE_GRPC_STATUS_RESOURCE_EXHAUSTED": 22008, + "LOCERR_EXTENGINE_GRPC_STATUS_FAILED_PRECONDITION": 22009, + "LOCERR_EXTENGINE_GRPC_STATUS_ABORTED": 22010, + "LOCERR_EXTENGINE_GRPC_STATUS_OUT_OF_RANGE": 22011, + "LOCERR_EXTENGINE_GRPC_STATUS_UNIMPLEMENTED": 22012, + "LOCERR_EXTENGINE_GRPC_STATUS_INTERNAL": 22013, + "LOCERR_EXTENGINE_GRPC_STATUS_UNAVAILABLE": 22014, + "LOCERR_EXTENGINE_GRPC_STATUS_DATA_LOSS": 22015, + "LOCERR_EXTENGINE_GRPC_STATUS_UNAUTHENTICATED": 22016, + "LOCERR_LXW_INVALID_OBJ": 23001, + "LOCERR_LXW_INVALID_FILE": 23002, + "LOCERR_LXW_INVALID_SHEET": 23003, + "LOCERR_LXW_INVALID_EXPORT_RANGE": 23004, + "LOCERR_LXW_ERROR": 23005, + "LOCERR_LXW_ERROR_MEMORY_MALLOC_FAILED": 23006, + "LOCERR_LXW_ERROR_CREATING_XLSX_FILE": 23007, + "LOCERR_LXW_ERROR_CREATING_TMPFILE": 23008, + "LOCERR_LXW_ERROR_ZIP_FILE_OPERATION": 23009, + "LOCERR_LXW_ERROR_ZIP_FILE_ADD": 23010, + "LOCERR_LXW_ERROR_ZIP_CLOSE": 23011, + "LOCERR_LXW_ERROR_NULL_PARAMETER_IGNORED": 23012, + "LOCERR_LXW_ERROR_MAX_STRING_LENGTH_EXCEEDED": 23013, + "LOCERR_LXW_ERROR_255_STRING_LENGTH_EXCEEDED": 23014, + "LOCERR_LXW_ERROR_SHARED_STRING_INDEX_NOT_FOUND": 23015, + "LOCERR_LXW_ERROR_WORKSHEET_INDEX_OUT_OF_RANGE": 23016, + "LOCERR_LXW_ERROR_WORKSHEET_MAX_NUMBER_URLS_EXCEEDED": 23017, + "LOCERR_BDI_STATUS_OK": 24000, + "LOCERR_BDI_GENERIC_ERROR_NOT_TRANSLATED": 24001, + "LOCERR_TRENDLINE_INVALID_DEF": 25000, + "LOCERR_TRENDLINE_INVALID_MATH_ERROR": 25001, + "LOCERR_CURL_UNSUPPORTED_PROTOCOL": 30000, + "LOCERR_CURL_COULDNT_RESOLVE_PROXY": 30001, + "LOCERR_CURL_COULDNT_CONNECT": 30002, + "LOCERR_CURL_REMOTE_ACCESS_DENIED": 30003, + "LOCERR_CURL_FTP_ACCEPT_FAILED": 30004, + "LOCERR_CURL_FTP_ACCEPT_TIMEOUT": 30005, + "LOCERR_CURL_FTP_CANT_GET_HOST": 30006, + "LOCERR_CURL_PARTIAL_FILE": 30007, + "LOCERR_CURL_QUOTE_ERROR": 30008, + "LOCERR_CURL_WRITE_ERROR": 30009, + "LOCERR_CURL_UPLOAD_FAILED": 30010, + "LOCERR_CURL_OUT_OF_MEMORY": 30011, + "LOCERR_CURL_OPERATION_TIMEDOUT": 30012, + "LOCERR_CURL_FTP_COULDNT_USE_REST": 30013, + "LOCERR_CURL_HTTP_POST_ERROR": 30014, + "LOCERR_CURL_SSL_CONNECT_ERROR": 30015, + "LOCERR_CURL_FILE_COULDNT_READ_FILE": 30016, + "LOCERR_CURL_LDAP_CANNOT_BIND": 30017, + "LOCERR_CURL_LDAP_SEARCH_FAILED": 30018, + "LOCERR_CURL_TOO_MANY_REDIRECTS": 30019, + "LOCERR_CURL_PEER_FAILED_VERIFICATION": 30020, + "LOCERR_CURL_GOT_NOTHING": 30021, + "LOCERR_CURL_SSL_ENGINE_NOTFOUND": 30022, + "LOCERR_CURL_SSL_ENGINE_SETFAILED": 30023, + "LOCERR_CURL_SSL_CERTPROBLEM": 30024, + "LOCERR_CURL_SSL_CIPHER": 30025, + "LOCERR_CURL_SSL_CACERT": 30026, + "LOCERR_CURL_BAD_CONTENT_ENCODING": 30027, + "LOCERR_CURL_LDAP_INVALID_URL": 30028, + "LOCERR_CURL_USE_SSL_FAILED": 30029, + "LOCERR_CURL_SSL_ENGINE_INITFAILED": 30030, + "LOCERR_CURL_LOGIN_DENIED": 30031, + "LOCERR_CURL_TFTP_NOTFOUND": 30032, + "LOCERR_CURL_TFTP_ILLEGAL": 30033, + "LOCERR_CURL_SSH": 30034, + "LOCERR_SETEXPRESSION_TOO_LARGE": 30100 + }, + "LocalizedWarningCode": { + "LOCWARN_PERSONAL_RELOAD_REQUIRED": 0, + "LOCWARN_PERSONAL_VERSION_EXPIRES_SOON": 1, + "LOCWARN_EXPORT_DATA_TRUNCATED": 1000, + "LOCWARN_COULD_NOT_OPEN_ALL_OBJECTS": 2000, + "LOCWARN_SEARCH_INVALID_SEARCHFIELD_DETECTED": 3000 + }, + "GrpType": { + "GRP_NX_NONE": 0, + "GRP_NX_HIEARCHY": 1, + "GRP_NX_COLLECTION": 2 + }, + "ExportFileType": { + "EXPORT_CSV_C": 0, + "EXPORT_CSV_T": 1, + "EXPORT_OOXML": 2 + }, + "ExportState": { + "EXPORT_POSSIBLE": 0, + "EXPORT_ALL": 1 + }, + "LTrendlineType": { + "Average": 0, + "Linear": 1, + "Polynomial2": 2, + "Polynomial3": 3, + "Polynomial4": 4, + "Exponential": 5, + "Power": 6, + "Logarithmic": 7 + }, + "ContinuousMode": { + "CONTINUOUS_NEVER": 0, + "CONTINUOUS_IF_POSSIBLE": 1, + "CONTINUOUS_IF_TIME": 2 + }, + "TrendlineMode": { + "TRENDLINE_MULTILINE": 0, + "TRENDLINE_SUM": 1 + }, + "DimCellType": { + "NX_DIM_CELL_VALUE": 0, + "NX_DIM_CELL_EMPTY": 1, + "NX_DIM_CELL_NORMAL": 2, + "NX_DIM_CELL_TOTAL": 3, + "NX_DIM_CELL_OTHER": 4, + "NX_DIM_CELL_AGGR": 5, + "NX_DIM_CELL_PSEUDO": 6, + "NX_DIM_CELL_ROOT": 7, + "NX_DIM_CELL_NULL": 8, + "NX_DIM_CELL_GENERATED": 9 + }, + "StackElemType": { + "NX_STACK_CELL_NORMAL": 0, + "NX_STACK_CELL_TOTAL": 1, + "NX_STACK_CELL_OTHER": 2, + "NX_STACK_CELL_SUM": 3, + "NX_STACK_CELL_VALUE": 4, + "NX_STACK_CELL_PSEUDO": 5 + }, + "SortIndicatorType": { + "NX_SORT_INDICATE_NONE": 0, + "NX_SORT_INDICATE_ASC": 1, + "NX_SORT_INDICATE_DESC": 2 + }, + "DimensionType": { + "NX_DIMENSION_TYPE_DISCRETE": 0, + "NX_DIMENSION_TYPE_NUMERIC": 1, + "NX_DIMENSION_TYPE_TIME": 2 + }, + "FieldSelectionMode": { + "SELECTION_MODE_NORMAL": 0, + "SELECTION_MODE_AND": 1, + "SELECTION_MODE_NOT": 2 + }, + "FrequencyMode": { + "NX_FREQUENCY_NONE": 0, + "NX_FREQUENCY_VALUE": 1, + "NX_FREQUENCY_PERCENT": 2, + "NX_FREQUENCY_RELATIVE": 3 + }, + "DataReductionMode": { + "DATA_REDUCTION_NONE": 0, + "DATA_REDUCTION_ONEDIM": 1, + "DATA_REDUCTION_SCATTERED": 2, + "DATA_REDUCTION_CLUSTERED": 3, + "DATA_REDUCTION_STACKED": 4 + }, + "HypercubeMode": { + "DATA_MODE_STRAIGHT": 0, + "DATA_MODE_PIVOT": 1, + "DATA_MODE_PIVOT_STACK": 2, + "DATA_MODE_TREE": 3 + }, + "PatchOperationType": { + "Add": 0, + "Remove": 1, + "Replace": 2 + }, + "SelectionCellType": { + "NX_CELL_DATA": 0, + "NX_CELL_TOP": 1, + "NX_CELL_LEFT": 2 + }, + "MatchingFieldMode": { + "MATCHINGFIELDMODE_MATCH_ALL": 0, + "MATCHINGFIELDMODE_MATCH_ONE": 1 + }, + "SessionState": { + "SESSION_CREATED": 0, + "SESSION_ATTACHED": 1, + "SESSION_ERROR_NO_LICENSE": 2, + "SESSION_ERROR_LICENSE_RENEW": 3, + "SESSION_ERROR_LIMIT_EXCEEDED": 4, + "SESSION_ERROR_SECURITY_HEADER_CHANGED": 5, + "SESSION_ACCESS_CONTROL_SETUP_FAILURE": 6, + "SESSION_ERROR_APP_ACCESS_DENIED": 7, + "SESSION_ERROR_APP_FAILURE": 8 + }, + "ReloadState": { + "RELOAD_PAUSED": 0, + "RELOAD_STARTED": 1, + "RELOAD_ABORTED": 2 + }, + "OpenApiVersion": { + "V2": 0, + "V3": 1 + }, + "QrsChangeType": { + "QRS_CHANGE_UNDEFINED": 0, + "QRS_CHANGE_ADD": 1, + "QRS_CHANGE_UPDATE": 2, + "QRS_CHANGE_DELETE": 3 + }, + "ExtEngineDataType": { + "NX_EXT_DATATYPE_STRING": 0, + "NX_EXT_DATATYPE_DOUBLE": 1, + "NX_EXT_DATATYPE_BOTH": 2 + }, + "ExtEngineFunctionType": { + "NX_EXT_FUNCTIONTYPE_SCALAR": 0, + "NX_EXT_FUNCTIONTYPE_AGGR": 1, + "NX_EXT_FUNCTIONTYPE_TENSOR": 2 + }, + "ExtEngineMsgType": { + "NX_EXT_MSGTYPE_FUNCTION_CALL": 1, + "NX_EXT_MSGTYPE_SCRIPT_CALL": 2, + "NX_EXT_MSGTYPE_RETURN_VALUE": 3, + "NX_EXT_MSGTYPE_RETURN_MULTIPLE": 4, + "NX_EXT_MSGTYPE_RETURN_ERROR": 5 + } + }, + "version": "12.612.0" +} diff --git a/jwt-scratch/src/js/node_modules/enigma.js/schemas/12.67.2.json b/jwt-scratch/src/js/node_modules/enigma.js/schemas/12.67.2.json new file mode 100644 index 0000000..4e3ba2d --- /dev/null +++ b/jwt-scratch/src/js/node_modules/enigma.js/schemas/12.67.2.json @@ -0,0 +1,1597 @@ +{ + "structs": { + "Field":{ + "GetCardinal": { + "In": [], + "Out": [] + }, + "GetAndMode": { + "In": [], + "Out": [] + }, + "SelectValues": { + "In": [{ "Name": "qFieldValues","DefaultValue": [{"qText": "", "qIsNumeric": false, "qNumber": 0}] }, { "Name": "qToggleMode","DefaultValue": false, "Optional": true }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Select": { + "In": [{ "Name": "qMatch","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qExcludedValuesMode","DefaultValue": 0, "Optional": true }], + "Out": [] + }, + "ToggleSelect": { + "In": [{ "Name": "qMatch","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qExcludedValuesMode","DefaultValue": 0, "Optional": true }], + "Out": [] + }, + "ClearAllButThis": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectPossible": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectExcluded": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectAll": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Lock": { + "In": [], + "Out": [] + }, + "Unlock": { + "In": [], + "Out": [] + }, + "GetNxProperties": { + "In": [], + "Out": [{ "Name": "qProperties" }] + }, + "SetNxProperties": { + "In": [{ "Name": "qProperties","DefaultValue": {"qOneAndOnlyOne": false} }], + "Out": [] + }, + "SetAndMode": { + "In": [{ "Name": "qAndMode","DefaultValue": false }], + "Out": [] + }, + "SelectAlternative": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "LowLevelSelect": { + "In": [{ "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Clear": { + "In": [], + "Out": [] + } + }, + "Variable":{ + "GetContent": { + "In": [], + "Out": [{ "Name": "qContent" }] + }, + "GetRawContent": { + "In": [], + "Out": [] + }, + "SetContent": { + "In": [{ "Name": "qContent","DefaultValue": "" }, { "Name": "qUpdateMRU","DefaultValue": false }], + "Out": [] + }, + "ForceContent": { + "In": [{ "Name": "qs","DefaultValue": "" }, { "Name": "qd","DefaultValue": 0 }], + "Out": [] + }, + "GetNxProperties": { + "In": [], + "Out": [{ "Name": "qProperties" }] + }, + "SetNxProperties": { + "In": [{ "Name": "qProperties","DefaultValue": {"qName": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qUsePredefListedValues": false, "qPreDefinedList": [""]} }], + "Out": [] + } + }, + "GenericObject":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "GetListObjectData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeReducedData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qZoomFactor","DefaultValue": 0 }, { "Name": "qReductionMode","DefaultValue": 0 }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubePivotData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeStackData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qMaxNbrCells","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeContinuousData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qOptions","DefaultValue": {"qStart": 0, "qEnd": 0, "qNbrPoints": 0, "qMaxNbrTicks": 0, "qMaxNumberLines": 0} }, { "Name": "qReverseSort","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qDataPages" }, { "Name": "qAxisData" }] + }, + "GetHyperCubeTreeData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qNodeOptions","DefaultValue": {"qMaxNbrOfNodes": 0, "qTreeNodes": [{"qArea": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qAllValues": false}], "qTreeLevels": {"qLeft": 0, "qDepth": 0}} }], + "Out": [{ "Name": "qNodes" }] + }, + "GetHyperCubeBinnedData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qViewport","DefaultValue": {"qWidth": 0, "qHeight": 0, "qZoomLevel": 0} }, { "Name": "qDataRanges","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qMaxNbrCells","DefaultValue": 0 }, { "Name": "qQueryLevel","DefaultValue": 0 }, { "Name": "qBinningMethod","DefaultValue": 0 }], + "Out": [{ "Name": "qDataPages" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }, { "Name": "qSoftPatch","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "ClearSoftPatches": { + "In": [], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetEffectiveProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "SetFullPropertyTree": { + "In": [{ "Name": "qPropEntry","DefaultValue": {"qProperty": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}}, "qChildren": [], "qEmbeddedSnapshotRef": null} }], + "Out": [] + }, + "GetFullPropertyTree": { + "In": [], + "Out": [{ "Name": "qPropEntry" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "ClearSelections": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "ExportData": { + "In": [{ "Name": "qFileType","DefaultValue": 0 }, { "Name": "qPath","DefaultValue": "", "Optional": true }, { "Name": "qFileName","DefaultValue": "", "Optional": true }, { "Name": "qExportState","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qUrl" }, { "Name": "qWarnings" }] + }, + "SelectListObjectValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectPossible": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectExcluded": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectAlternative": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectAll": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectContinuousRange": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SearchListObjectFor": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qMatch","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "AbortListObjectSearch": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [] + }, + "AcceptListObjectSearch": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "ExpandLeft": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "ExpandTop": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "CollapseLeft": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "CollapseTop": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "DrillUp": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qDimNo","DefaultValue": 0 }, { "Name": "qNbrSteps","DefaultValue": 0 }], + "Out": [] + }, + "Lock": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "Unlock": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "SelectHyperCubeValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qDimNo","DefaultValue": 0 }, { "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectHyperCubeCells": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRowIndices","DefaultValue": [0] }, { "Name": "qColIndices","DefaultValue": [0] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectPivotCells": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSelections","DefaultValue": [{"qType": 0, "qCol": 0, "qRow": 0}] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "RangeSelectHyperCubeValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qRange": {"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}, "qMeasureIx": 0}] }, { "Name": "qColumnsToSelect","DefaultValue": [0], "Optional": true }, { "Name": "qOrMode","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "MultiRangeSelectHyperCubeValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qRanges": [{"qRange": {"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}, "qMeasureIx": 0}], "qColumnsToSelect": [0]}] }, { "Name": "qOrMode","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectHyperCubeContinuousRange": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qRange": {"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}, "qDimIx": 0}] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetChild": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetChildInfos": { + "In": [], + "Out": [{ "Name": "qInfos" }] + }, + "CreateChild": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }, { "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyChild": { + "In": [{ "Name": "qId","DefaultValue": "" }, { "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "DestroyAllChildren": { + "In": [{ "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [] + }, + "SetChildArrayOrder": { + "In": [{ "Name": "qIds","DefaultValue": [""] }], + "Out": [] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "CopyFrom": { + "In": [{ "Name": "qFromId","DefaultValue": "" }], + "Out": [] + }, + "BeginSelections": { + "In": [{ "Name": "qPaths","DefaultValue": [""] }], + "Out": [] + }, + "EndSelections": { + "In": [{ "Name": "qAccept","DefaultValue": false }], + "Out": [] + }, + "ResetMadeSelections": { + "In": [], + "Out": [] + }, + "EmbedSnapshotObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetSnapshotObject": { + "In": [], + "Out": [] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericDimension":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDim": {"qGrouping": 0, "qFieldDefs": [""], "qFieldLabels": [""], "qLabelExpression": ""}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetDimension": { + "In": [], + "Out": [{ "Name": "qDim" }] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericBookmark":{ + "GetFieldValues": { + "In": [{ "Name": "qField","DefaultValue": "" }, { "Name": "qGetExcludedValues","DefaultValue": false }, { "Name": "qDataPage","DefaultValue": {"qStartIndex": 0, "qEndIndex": 0} }], + "Out": [{ "Name": "qFieldValues" }] + }, + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "Apply": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericVariable":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "SetStringValue": { + "In": [{ "Name": "qVal","DefaultValue": "" }], + "Out": [] + }, + "SetNumValue": { + "In": [{ "Name": "qVal","DefaultValue": 0 }], + "Out": [] + }, + "SetDualValue": { + "In": [{ "Name": "qText","DefaultValue": "" }, { "Name": "qNum","DefaultValue": 0 }], + "Out": [] + } + }, + "GenericMeasure":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMeasure": {"qLabel": "", "qDef": "", "qGrouping": 0, "qExpressions": [""], "qActiveExpression": 0, "qLabelExpression": ""}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetMeasure": { + "In": [], + "Out": [{ "Name": "qMeasure" }] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericDerivedFields":{ + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDerivedDefinitionId": "", "qFieldName": [""], "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetDerivedFieldData": { + "In": [], + "Out": [{ "Name": "qData" }] + }, + "GetDerivedField": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qFields" }] + }, + "GetListData": { + "In": [], + "Out": [{ "Name": "qListData" }] + }, + "GetDerivedFields": { + "In": [], + "Out": [{ "Name": "qFields" }] + }, + "GetDerivedGroups": { + "In": [], + "Out": [{ "Name": "qGroups" }] + } + }, + "Doc":{ + "GetField": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }, { "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "GetFieldDescription": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }], + "Out": [] + }, + "GetVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "GetLooselyCoupledVector": { + "In": [], + "Out": [{ "Name": "qv" }] + }, + "SetLooselyCoupledVector": { + "In": [{ "Name": "qv","DefaultValue": [0] }], + "Out": [] + }, + "Evaluate": { + "In": [{ "Name": "qExpression","DefaultValue": "" }], + "Out": [] + }, + "EvaluateEx": { + "In": [{ "Name": "qExpression","DefaultValue": "" }], + "Out": [{ "Name": "qValue" }] + }, + "ClearAll": { + "In": [{ "Name": "qLockedAlso","DefaultValue": false, "Optional": true }, { "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "LockAll": { + "In": [{ "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "UnlockAll": { + "In": [{ "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "Back": { + "In": [], + "Out": [] + }, + "Forward": { + "In": [], + "Out": [] + }, + "CreateVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "RemoveVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "GetLocaleInfo": { + "In": [], + "Out": [] + }, + "GetTablesAndKeys": { + "In": [{ "Name": "qWindowSize","DefaultValue": {"qcx": 0, "qcy": 0} }, { "Name": "qNullSize","DefaultValue": {"qcx": 0, "qcy": 0} }, { "Name": "qCellHeight","DefaultValue": 0 }, { "Name": "qSyntheticMode","DefaultValue": false }, { "Name": "qIncludeSysVars","DefaultValue": false }], + "Out": [{ "Name": "qtr" }, { "Name": "qk" }] + }, + "GetViewDlgSaveInfo": { + "In": [], + "Out": [] + }, + "SetViewDlgSaveInfo": { + "In": [{ "Name": "qInfo","DefaultValue": {"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCtlInfo": {"qInternalView": {"qTables": [{"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCaption": ""}], "qBroomPoints": [{"qPos": {"qx": 0, "qy": 0}, "qTable": "", "qFields": [""]}], "qConnectionPoints": [{"qPos": {"qx": 0, "qy": 0}, "qFields": [""]}], "qZoomFactor": 0}, "qSourceView": {"qTables": [{"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCaption": ""}], "qBroomPoints": [{"qPos": {"qx": 0, "qy": 0}, "qTable": "", "qFields": [""]}], "qConnectionPoints": [{"qPos": {"qx": 0, "qy": 0}, "qFields": [""]}], "qZoomFactor": 0}}, "qMode": 0} }], + "Out": [] + }, + "GetEmptyScript": { + "In": [{ "Name": "qLocalizedMainSection","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "DoReload": { + "In": [{ "Name": "qMode","DefaultValue": 0, "Optional": true }, { "Name": "qPartial","DefaultValue": false, "Optional": true }, { "Name": "qDebug","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "GetScriptBreakpoints": { + "In": [], + "Out": [{ "Name": "qBreakpoints" }] + }, + "SetScriptBreakpoints": { + "In": [{ "Name": "qBreakpoints","DefaultValue": [{"qbufferName": "", "qlineIx": 0, "qEnabled": false}] }], + "Out": [] + }, + "GetScript": { + "In": [], + "Out": [{ "Name": "qScript" }] + }, + "GetTextMacros": { + "In": [], + "Out": [{ "Name": "qMacros" }] + }, + "SetFetchLimit": { + "In": [{ "Name": "qLimit","DefaultValue": 0 }], + "Out": [] + }, + "DoSave": { + "In": [{ "Name": "qFileName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "GetTableData": { + "In": [{ "Name": "qOffset","DefaultValue": 0 }, { "Name": "qRows","DefaultValue": 0 }, { "Name": "qSyntheticMode","DefaultValue": false }, { "Name": "qTableName","DefaultValue": "" }], + "Out": [{ "Name": "qData" }] + }, + "GetAppLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "SetAppProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qTitle": "", "qLastReloadTime": "", "qMigrationHash": "", "qSavedInProductVersion": "", "qThumbnail": {"qUrl": ""}} }], + "Out": [] + }, + "GetAppProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetLineage": { + "In": [], + "Out": [{ "Name": "qLineage" }] + }, + "CreateSessionObject": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }], + "Out": [] + }, + "DestroySessionObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CreateObject": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetObjects": { + "In": [{ "Name": "qOptions","DefaultValue": {"qTypes": [""], "qIncludeSessionObjects": false, "qData": {}} }], + "Out": [{ "Name": "qList" }] + }, + "GetBookmarks": { + "In": [{ "Name": "qOptions","DefaultValue": {"qTypes": [""], "qData": {}} }], + "Out": [{ "Name": "qList" }] + }, + "CloneObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qDraftId" }] + }, + "CommitDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "DestroyDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }, { "Name": "qSourceId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "Undo": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "Redo": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "ClearUndoBuffer": { + "In": [], + "Out": [] + }, + "CreateDimension": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDim": {"qGrouping": 0, "qFieldDefs": [""], "qFieldLabels": [""], "qLabelExpression": ""}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "CloneDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateMeasure": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMeasure": {"qLabel": "", "qDef": "", "qGrouping": 0, "qExpressions": [""], "qActiveExpression": 0, "qLabelExpression": ""}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "CloneMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateSessionVariable": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [] + }, + "DestroySessionVariable": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CreateVariableEx": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyVariableById": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "DestroyVariableByName": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetVariableById": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetVariableByName": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "MigrateVariables": { + "In": [], + "Out": [] + }, + "MigrateDerivedFields": { + "In": [], + "Out": [] + }, + "CheckExpression": { + "In": [{ "Name": "qExpr","DefaultValue": "" }, { "Name": "qLabels","DefaultValue": [""], "Optional": true }], + "Out": [{ "Name": "qErrorMsg" }, { "Name": "qBadFieldNames" }, { "Name": "qDangerousFieldNames" }] + }, + "CheckNumberOrExpression": { + "In": [{ "Name": "qExpr","DefaultValue": "" }], + "Out": [{ "Name": "qErrorMsg" }, { "Name": "qBadFieldNames" }] + }, + "AddAlternateState": { + "In": [{ "Name": "qStateName","DefaultValue": "" }], + "Out": [] + }, + "RemoveAlternateState": { + "In": [{ "Name": "qStateName","DefaultValue": "" }], + "Out": [] + }, + "CreateBookmark": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "ApplyBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CloneBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "AddFieldFromExpression": { + "In": [{ "Name": "qName","DefaultValue": "" }, { "Name": "qExpr","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetFieldOnTheFlyByName": { + "In": [{ "Name": "qReadableName","DefaultValue": "" }], + "Out": [{ "Name": "qName" }] + }, + "GetAllInfos": { + "In": [], + "Out": [{ "Name": "qInfos" }] + }, + "Resume": { + "In": [], + "Out": [] + }, + "AbortModal": { + "In": [{ "Name": "qAccept","DefaultValue": false }], + "Out": [] + }, + "Publish": { + "In": [{ "Name": "qStreamId","DefaultValue": "" }, { "Name": "qName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + }, + "GetMatchingFields": { + "In": [{ "Name": "qTags","DefaultValue": [""] }, { "Name": "qMatchingFieldMode","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qFieldNames" }] + }, + "FindMatchingFields": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }, { "Name": "qTags","DefaultValue": [""] }], + "Out": [{ "Name": "qFieldNames" }] + }, + "Scramble": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }], + "Out": [] + }, + "SaveObjects": { + "In": [], + "Out": [] + }, + "GetAssociationScores": { + "In": [{ "Name": "qTable1","DefaultValue": "" }, { "Name": "qTable2","DefaultValue": "" }], + "Out": [{ "Name": "qScore" }] + }, + "GetMediaList": { + "In": [], + "Out": [{ "Name": "qList" }] + }, + "GetContentLibraries": { + "In": [], + "Out": [{ "Name": "qList" }] + }, + "GetLibraryContent": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [{ "Name": "qList" }] + }, + "DoReloadEx": { + "In": [{ "Name": "qParams","DefaultValue": {"qMode": 0, "qPartial": false, "qDebug": false}, "Optional": true }], + "Out": [{ "Name": "qResult" }] + }, + "BackCount": { + "In": [], + "Out": [] + }, + "ForwardCount": { + "In": [], + "Out": [] + }, + "ExportReducedData": { + "In": [{ "Name": "qOptions","DefaultValue": {"qBookmarkId": "", "qExpires": 0}, "Optional": true }], + "Out": [{ "Name": "qDownloadInfo" }] + }, + "SetScript": { + "In": [{ "Name": "qScript","DefaultValue": "" }], + "Out": [] + }, + "CheckScriptSyntax": { + "In": [], + "Out": [{ "Name": "qErrors" }] + }, + "GetFavoriteVariables": { + "In": [], + "Out": [{ "Name": "qNames" }] + }, + "SetFavoriteVariables": { + "In": [{ "Name": "qNames","DefaultValue": [""] }], + "Out": [] + }, + "GetIncludeFileContent": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [{ "Name": "qContent" }] + }, + "CreateConnection": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }], + "Out": [{ "Name": "qConnectionId" }] + }, + "ModifyConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }, { "Name": "qOverrideCredentials","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "DeleteConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [] + }, + "GetConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qConnection" }] + }, + "GetConnections": { + "In": [], + "Out": [{ "Name": "qConnections" }] + }, + "GetDatabaseInfo": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qInfo" }] + }, + "GetDatabases": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qDatabases" }] + }, + "GetDatabaseOwners": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qOwners" }] + }, + "GetDatabaseTables": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qTables" }] + }, + "GetDatabaseTableFields": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qFields" }] + }, + "GetDatabaseTablePreview": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }, { "Name": "qTable","DefaultValue": "" }, { "Name": "qConditions","DefaultValue": {"qType": 0, "qWherePredicate": ""}, "Optional": true }], + "Out": [{ "Name": "qPreview" }, { "Name": "qRowCount" }] + }, + "GetFolderItemsForConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qFolderItems" }] + }, + "GuessFileType": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qDataFormat" }] + }, + "GetFileTables": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }], + "Out": [{ "Name": "qTables" }] + }, + "GetFileTableFields": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qFields" }, { "Name": "qFormatSpec" }] + }, + "GetFileTablePreview": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qPreview" }, { "Name": "qFormatSpec" }] + }, + "GetFileTablesEx": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }], + "Out": [{ "Name": "qTables" }] + }, + "SendGenericCommandToCustomConnector": { + "In": [{ "Name": "qProvider","DefaultValue": "" }, { "Name": "qCommand","DefaultValue": "" }, { "Name": "qMethod","DefaultValue": "" }, { "Name": "qParameters","DefaultValue": [""] }, { "Name": "qAppendConnection","DefaultValue": "" }], + "Out": [{ "Name": "qResult" }] + }, + "SearchSuggest": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0, "qCharEncoding": 0, "qAttributes": [""]} }, { "Name": "qTerms","DefaultValue": [""] }], + "Out": [{ "Name": "qResult" }] + }, + "SearchAssociations": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0, "qCharEncoding": 0, "qAttributes": [""]} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qPage","DefaultValue": {"qOffset": 0, "qCount": 0, "qMaxNbrFieldMatches": 0, "qGroupOptions": [{"qGroupType": 0, "qOffset": 0, "qCount": 0}], "qGroupItemOptions": [{"qGroupItemType": 0, "qOffset": 0, "qCount": 0}]} }], + "Out": [{ "Name": "qResults" }] + }, + "SelectAssociations": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0, "qCharEncoding": 0, "qAttributes": [""]} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qMatchIx","DefaultValue": 0 }, { "Name": "qSoftLock","DefaultValue": null, "Optional": true }], + "Out": [] + }, + "SearchResults": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0, "qCharEncoding": 0, "qAttributes": [""]} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qPage","DefaultValue": {"qOffset": 0, "qCount": 0, "qMaxNbrFieldMatches": 0, "qGroupOptions": [{"qGroupType": 0, "qOffset": 0, "qCount": 0}], "qGroupItemOptions": [{"qGroupItemType": 0, "qOffset": 0, "qCount": 0}]} }], + "Out": [{ "Name": "qResult" }] + }, + "SearchObjects": { + "In": [{ "Name": "qOptions","DefaultValue": {"qAttributes": [""], "qCharEncoding": 0} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qPage","DefaultValue": {"qOffset": 0, "qCount": 0, "qMaxNbrFieldMatches": 0, "qGroupOptions": [{"qGroupType": 0, "qOffset": 0, "qCount": 0}], "qGroupItemOptions": [{"qGroupItemType": 0, "qOffset": 0, "qCount": 0}]} }], + "Out": [{ "Name": "qResult" }] + } + }, + "Global":{ + "AbortRequest": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [] + }, + "AbortAll": { + "In": [], + "Out": [] + }, + "GetProgress": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [{ "Name": "qProgressData" }] + }, + "QvVersion": { + "In": [], + "Out": [] + }, + "OSVersion": { + "In": [], + "Out": [] + }, + "OSName": { + "In": [], + "Out": [] + }, + "QTProduct": { + "In": [], + "Out": [] + }, + "GetDocList": { + "In": [], + "Out": [{ "Name": "qDocList" }] + }, + "GetInteract": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [{ "Name": "qDef" }] + }, + "InteractDone": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }, { "Name": "qDef","DefaultValue": {"qType": 0, "qTitle": "", "qMsg": "", "qButtons": 0, "qLine": "", "qOldLineNr": 0, "qNewLineNr": 0, "qPath": "", "qHidden": false, "qResult": 0, "qInput": ""} }], + "Out": [] + }, + "GetAuthenticatedUser": { + "In": [], + "Out": [] + }, + "CreateDocEx": { + "In": [{ "Name": "qDocName","DefaultValue": "" }, { "Name": "qUserName","DefaultValue": "", "Optional": true }, { "Name": "qPassword","DefaultValue": "", "Optional": true }, { "Name": "qSerial","DefaultValue": "", "Optional": true }, { "Name": "qLocalizedScriptMainSection","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qDocId" }] + }, + "GetActiveDoc": { + "In": [], + "Out": [] + }, + "AllowCreateApp": { + "In": [], + "Out": [] + }, + "CreateApp": { + "In": [{ "Name": "qAppName","DefaultValue": "" }, { "Name": "qLocalizedScriptMainSection","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qSuccess" }, { "Name": "qAppId" }] + }, + "DeleteApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "IsDesktopMode": { + "In": [], + "Out": [] + }, + "GetConfiguration": { + "In": [], + "Out": [{ "Name": "qConfig" }] + }, + "CancelRequest": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [] + }, + "ShutdownProcess": { + "In": [], + "Out": [] + }, + "ReloadExtensionList": { + "In": [], + "Out": [] + }, + "ReplaceAppFromID": { + "In": [{ "Name": "qTargetAppId","DefaultValue": "" }, { "Name": "qSrcAppID","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "CopyApp": { + "In": [{ "Name": "qTargetAppId","DefaultValue": "" }, { "Name": "qSrcAppId","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "ImportApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qSrcPath","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "ImportAppEx": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qSrcPath","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }, { "Name": "qExcludeConnections","DefaultValue": false }], + "Out": [] + }, + "ExportApp": { + "In": [{ "Name": "qTargetPath","DefaultValue": "" }, { "Name": "qSrcAppId","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "PublishApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qName","DefaultValue": "" }, { "Name": "qStreamId","DefaultValue": "" }], + "Out": [] + }, + "IsPersonalMode": { + "In": [], + "Out": [] + }, + "GetUniqueID": { + "In": [], + "Out": [{ "Name": "qUniqueID" }] + }, + "OpenDoc": { + "In": [{ "Name": "qDocName","DefaultValue": "" }, { "Name": "qUserName","DefaultValue": "", "Optional": true }, { "Name": "qPassword","DefaultValue": "", "Optional": true }, { "Name": "qSerial","DefaultValue": "", "Optional": true }, { "Name": "qNoData","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "CreateSessionApp": { + "In": [], + "Out": [{ "Name": "qSessionAppId" }] + }, + "CreateSessionAppFromApp": { + "In": [{ "Name": "qSrcAppId","DefaultValue": "" }], + "Out": [{ "Name": "qSessionAppId" }] + }, + "ProductVersion": { + "In": [], + "Out": [] + }, + "GetAppEntry": { + "In": [{ "Name": "qAppID","DefaultValue": "" }], + "Out": [{ "Name": "qEntry" }] + }, + "ConfigureReload": { + "In": [{ "Name": "qCancelOnScriptError","DefaultValue": false }, { "Name": "qUseErrorData","DefaultValue": false }, { "Name": "qInteractOnError","DefaultValue": false }], + "Out": [] + }, + "CancelReload": { + "In": [], + "Out": [] + }, + "GetBNF": { + "In": [{ "Name": "qBnfType","DefaultValue": 0 }], + "Out": [{ "Name": "qBnfDefs" }] + }, + "GetFunctions": { + "In": [{ "Name": "qGroup","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qFunctions" }] + }, + "GetOdbcDsns": { + "In": [], + "Out": [{ "Name": "qOdbcDsns" }] + }, + "GetOleDbProviders": { + "In": [], + "Out": [{ "Name": "qOleDbProviders" }] + }, + "GetDatabasesFromConnectionString": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }], + "Out": [{ "Name": "qDatabases" }] + }, + "IsValidConnectionString": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }], + "Out": [] + }, + "GetDefaultAppFolder": { + "In": [], + "Out": [{ "Name": "qPath" }] + }, + "GetMyDocumentsFolder": { + "In": [], + "Out": [{ "Name": "qFolder" }] + }, + "GetLogicalDriveStrings": { + "In": [], + "Out": [{ "Name": "qDrives" }] + }, + "GetFolderItemsForPath": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [{ "Name": "qFolderItems" }] + }, + "GetSupportedCodePages": { + "In": [], + "Out": [{ "Name": "qCodePages" }] + }, + "GetCustomConnectors": { + "In": [{ "Name": "qReloadList","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qConnectors" }] + }, + "GetStreamList": { + "In": [], + "Out": [{ "Name": "qStreamList" }] + }, + "EngineVersion": { + "In": [], + "Out": [{ "Name": "qVersion" }] + }, + "GetBaseBNF": { + "In": [{ "Name": "qBnfType","DefaultValue": 0 }], + "Out": [{ "Name": "qBnfDefs" }, { "Name": "qBnfHash" }] + }, + "GetBaseBNFHash": { + "In": [{ "Name": "qBnfType","DefaultValue": 0 }], + "Out": [{ "Name": "qBnfHash" }] + }, + "GetBaseBNFString": { + "In": [{ "Name": "qBnfType","DefaultValue": 0 }], + "Out": [{ "Name": "qBnfStr" }, { "Name": "qBnfHash" }] + } + } + }, + "enums": { + "LocalizedMessageCode": { + "LOCMSG_SCRIPTEDITOR_EMPTY_MESSAGE": 0, + "LOCMSG_SCRIPTEDITOR_PROGRESS_SAVING_STARTED": 1, + "LOCMSG_SCRIPTEDITOR_PROGRESS_BYTES_LEFT": 2, + "LOCMSG_SCRIPTEDITOR_PROGRESS_STORING_TABLES": 3, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_ROWS_SO_FAR": 4, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECTED": 5, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECTING_TO": 6, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECT_FAILED": 7, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_ROWISH": 8, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_COLUMNAR": 9, + "LOCMSG_SCRIPTEDITOR_ERROR": 10, + "LOCMSG_SCRIPTEDITOR_DONE": 11, + "LOCMSG_SCRIPTEDITOR_LOAD_EXTERNAL_DATA": 12, + "LOCMSG_SCRIPTEDITOR_PROGRESS_OLD_QVD_ISLOADING": 13, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_LOADING": 14, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_BUFFERED": 15, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_PREPARING": 16, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_APPENDING": 17, + "LOCMSG_SCRIPTEDITOR_REMOVE_SYNTHETIC": 18, + "LOCMSG_SCRIPTEDITOR_PENDING_LINKEDTABLE_FETCHING": 19, + "LOCMSG_SCRIPTEDITOR_RELOAD": 20, + "LOCMSG_SCRIPTEDITOR_LINES_FETCHED": 21, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_START": 22, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_FIELD": 23, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_SUCCESS": 24, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_FAILURE": 25, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_STARTABORT": 26, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_ENDABORT": 27, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_TIMEOUT": 28, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_OUTOFMEMORY": 29 + }, + "LocalizedErrorCode": { + "LOCERR_INTERNAL_ERROR": -128, + "LOCERR_GENERIC_UNKNOWN": -1, + "LOCERR_GENERIC_OK": 0, + "LOCERR_GENERIC_NOT_SET": 1, + "LOCERR_GENERIC_NOT_FOUND": 2, + "LOCERR_GENERIC_ALREADY_EXISTS": 3, + "LOCERR_GENERIC_INVALID_PATH": 4, + "LOCERR_GENERIC_ACCESS_DENIED": 5, + "LOCERR_GENERIC_OUT_OF_MEMORY": 6, + "LOCERR_GENERIC_NOT_INITIALIZED": 7, + "LOCERR_GENERIC_INVALID_PARAMETERS": 8, + "LOCERR_GENERIC_EMPTY_PARAMETERS": 9, + "LOCERR_GENERIC_INTERNAL_ERROR": 10, + "LOCERR_GENERIC_CORRUPT_DATA": 11, + "LOCERR_GENERIC_MEMORY_INCONSISTENCY": 12, + "LOCERR_GENERIC_INVISIBLE_OWNER_ABORT": 13, + "LOCERR_GENERIC_PROHIBIT_VALIDATE": 14, + "LOCERR_GENERIC_ABORTED": 15, + "LOCERR_GENERIC_CONNECTION_LOST": 16, + "LOCERR_GENERIC_UNSUPPORTED_IN_PRODUCT_VERSION": 17, + "LOCERR_GENERIC_REST_CONNECTION_FAILURE": 18, + "LOCERR_HTTP_400": 400, + "LOCERR_HTTP_401": 401, + "LOCERR_HTTP_402": 402, + "LOCERR_HTTP_403": 403, + "LOCERR_HTTP_404": 404, + "LOCERR_HTTP_405": 405, + "LOCERR_HTTP_406": 406, + "LOCERR_HTTP_407": 407, + "LOCERR_HTTP_408": 408, + "LOCERR_HTTP_409": 409, + "LOCERR_HTTP_410": 410, + "LOCERR_HTTP_411": 411, + "LOCERR_HTTP_412": 412, + "LOCERR_HTTP_413": 413, + "LOCERR_HTTP_414": 414, + "LOCERR_HTTP_415": 415, + "LOCERR_HTTP_416": 416, + "LOCERR_HTTP_417": 417, + "LOCERR_HTTP_429": 429, + "LOCERR_HTTP_500": 500, + "LOCERR_HTTP_501": 501, + "LOCERR_HTTP_502": 502, + "LOCERR_HTTP_503": 503, + "LOCERR_HTTP_504": 504, + "LOCERR_HTTP_505": 505, + "LOCERR_HTTP_509": 509, + "LOCERR_HTTP_COULD_NOT_RESOLVE_HOST": 700, + "LOCERR_APP_ALREADY_EXISTS": 1000, + "LOCERR_APP_INVALID_NAME": 1001, + "LOCERR_APP_ALREADY_OPEN": 1002, + "LOCERR_APP_NOT_FOUND": 1003, + "LOCERR_APP_IMPORT_FAILED": 1004, + "LOCERR_APP_SAVE_FAILED": 1005, + "LOCERR_APP_CREATE_FAILED": 1006, + "LOCERR_APP_INVALID": 1007, + "LOCERR_APP_CONNECT_FAILED": 1008, + "LOCERR_APP_ALREADY_OPEN_IN_DIFFERENT_MODE": 1009, + "LOCERR_APP_MIGRATION_COULD_NOT_CONTACT_MIGRATION_SERVICE": 1010, + "LOCERR_APP_MIGRATION_COULD_NOT_START_MIGRATION": 1011, + "LOCERR_APP_MIGRATION_FAILURE": 1012, + "LOCERR_APP_SCRIPT_MISSING": 1013, + "LOCERR_APP_EXPORT_FAILED": 1014, + "LOCERR_CONNECTION_ALREADY_EXISTS": 2000, + "LOCERR_CONNECTION_NOT_FOUND": 2001, + "LOCERR_CONNECTION_FAILED_TO_LOAD": 2002, + "LOCERR_CONNECTION_FAILED_TO_IMPORT": 2003, + "LOCERR_CONNECTION_NAME_IS_INVALID": 2004, + "LOCERR_CONNECTOR_NO_FILE_STREAMING_SUPPORT": 2300, + "LOCERR_CONNECTOR_FILESIZE_EXCEEDED_BUFFER_SIZE": 2301, + "LOCERR_FILE_ACCESS_DENIED": 3000, + "LOCERR_FILE_NAME_INVALID": 3001, + "LOCERR_FILE_CORRUPT": 3002, + "LOCERR_FILE_NOT_FOUND": 3003, + "LOCERR_FILE_FORMAT_UNSUPPORTED": 3004, + "LOCERR_FILE_OPENED_IN_UNSUPPORTED_MODE": 3005, + "LOCERR_FILE_TABLE_NOT_FOUND": 3006, + "LOCERR_USER_ACCESS_DENIED": 4000, + "LOCERR_USER_IMPERSONATION_FAILED": 4001, + "LOCERR_SERVER_OUT_OF_SESSION_AND_USER_CALS": 5000, + "LOCERR_SERVER_OUT_OF_SESSION_CALS": 5001, + "LOCERR_SERVER_OUT_OF_USAGE_CALS": 5002, + "LOCERR_SERVER_OUT_OF_CALS": 5003, + "LOCERR_SERVER_OUT_OF_NAMED_CALS": 5004, + "LOCERR_SERVER_OFF_DUTY": 5005, + "LOCERR_SERVER_BUSY": 5006, + "LOCERR_SERVER_LICENSE_EXPIRED": 5007, + "LOCERR_SERVER_AJAX_DISABLED": 5008, + "LOCERR_HC_INVALID_OBJECT": 6000, + "LOCERR_HC_RESULT_TOO_LARGE": 6001, + "LOCERR_HC_INVALID_OBJECT_STATE": 6002, + "LOCERR_HC_MODAL_OBJECT_ERROR": 6003, + "LOCERR_CALC_INVALID_DEF": 7000, + "LOCERR_CALC_NOT_IN_LIB": 7001, + "LOCERR_CALC_HEAP_ERROR": 7002, + "LOCERR_CALC_TOO_LARGE": 7003, + "LOCERR_CALC_TIMEOUT": 7004, + "LOCERR_CALC_EVAL_CONDITION_FAILED": 7005, + "LOCERR_CALC_MIXED_LINKED_AGGREGATION": 7006, + "LOCERR_CALC_MISSING_LINKED": 7007, + "LOCERR_CALC_INVALID_COL_SORT": 7008, + "LOCERR_CALC_PAGES_TOO_LARGE": 7009, + "LOCERR_CALC_SEMANTIC_FIELD_NOT_ALLOWED": 7010, + "LOCERR_CALC_VALIDATION_STATE_INVALID": 7011, + "LOCERR_CALC_PIVOT_DIMENSIONS_ALREADY_EXISTS": 7012, + "LOCERR_CALC_MISSING_LINKED_FIELD": 7013, + "LOCERR_CALC_NOT_CALCULATED": 7014, + "LOCERR_LAYOUT_EXTENDS_INVALID_ID": 8000, + "LOCERR_LAYOUT_LINKED_OBJECT_NOT_FOUND": 8001, + "LOCERR_LAYOUT_LINKED_OBJECT_INVALID": 8002, + "LOCERR_PERSISTENCE_WRITE_FAILED": 9000, + "LOCERR_PERSISTENCE_READ_FAILED": 9001, + "LOCERR_PERSISTENCE_DELETE_FAILED": 9002, + "LOCERR_PERSISTENCE_NOT_FOUND": 9003, + "LOCERR_PERSISTENCE_UNSUPPORTED_VERSION": 9004, + "LOCERR_PERSISTENCE_MIGRATION_FAILED_READ_ONLY": 9005, + "LOCERR_PERSISTENCE_MIGRATION_CANCELLED": 9006, + "LOCERR_PERSISTENCE_MIGRATION_BACKUP_FAILED": 9007, + "LOCERR_PERSISTENCE_DISK_FULL": 9008, + "LOCERR_PERSISTENCE_NOT_SUPPORTED_FOR_SESSION_APP": 9009, + "LOCERR_PERSISTENCE_SYNC_SET_CHUNK_INVALID_PARAMETERS": 9510, + "LOCERR_PERSISTENCE_SYNC_GET_CHUNK_INVALID_PARAMETERS": 9511, + "LOCERR_SCRIPT_DATASOURCE_ACCESS_DENIED": 10000, + "LOCERR_RELOAD_IN_PROGRESS": 11000, + "LOCERR_RELOAD_TABLE_X_NOT_FOUND": 11001, + "LOCERR_RELOAD_UNKNOWN_STATEMENT": 11002, + "LOCERR_RELOAD_EXPECTED_SOMETHING_FOUND_UNKNOWN": 11003, + "LOCERR_RELOAD_EXPECTED_NOTHING_FOUND_UNKNOWN": 11004, + "LOCERR_RELOAD_EXPECTED_ONE_OF_1_TOKENS_FOUND_UNKNOWN": 11005, + "LOCERR_RELOAD_EXPECTED_ONE_OF_2_TOKENS_FOUND_UNKNOWN": 11006, + "LOCERR_RELOAD_EXPECTED_ONE_OF_3_TOKENS_FOUND_UNKNOWN": 11007, + "LOCERR_RELOAD_EXPECTED_ONE_OF_4_TOKENS_FOUND_UNKNOWN": 11008, + "LOCERR_RELOAD_EXPECTED_ONE_OF_5_TOKENS_FOUND_UNKNOWN": 11009, + "LOCERR_RELOAD_EXPECTED_ONE_OF_6_TOKENS_FOUND_UNKNOWN": 11010, + "LOCERR_RELOAD_EXPECTED_ONE_OF_7_TOKENS_FOUND_UNKNOWN": 11011, + "LOCERR_RELOAD_EXPECTED_ONE_OF_8_OR_MORE_TOKENS_FOUND_UNKNOWN": 11012, + "LOCERR_RELOAD_FIELD_X_NOT_FOUND": 11013, + "LOCERR_RELOAD_MAPPING_TABLE_X_NOT_FOUND": 11014, + "LOCERR_RELOAD_LIB_CONNECTION_X_NOT_FOUND": 11015, + "LOCERR_RELOAD_NAME_ALREADY_TAKEN": 11016, + "LOCERR_RELOAD_WRONG_FILE_FORMAT_DIF": 11017, + "LOCERR_RELOAD_WRONG_FILE_FORMAT_BIFF": 11018, + "LOCERR_RELOAD_WRONG_FILE_FORMAT_ENCRYPTED": 11019, + "LOCERR_RELOAD_OPEN_FILE_ERROR": 11020, + "LOCERR_RELOAD_AUTO_GENERATE_COUNT": 11021, + "LOCERR_RELOAD_PE_ILLEGAL_PREFIX_COMB": 11022, + "LOCERR_RELOAD_MATCHING_CONTROL_STATEMENT_ERROR": 11023, + "LOCERR_RELOAD_MATCHING_LIBPATH_X_NOT_FOUND": 11024, + "LOCERR_RELOAD_MATCHING_LIBPATH_X_INVALID": 11025, + "LOCERR_RELOAD_MATCHING_LIBPATH_X_OUTSIDE": 11026, + "LOCERR_RELOAD_NO_QUALIFIED_PATH_FOR_FILE": 11027, + "LOCERR_RELOAD_MODE_STATEMENT_ONLY_FOR_LIB_PATHS": 11028, + "LOCERR_RELOAD_INCONSISTENT_USE_OF_SEMANTIC_FIELDS": 11029, + "LOCERR_RELOAD_NO_OPEN_DATABASE": 11030, + "LOCERR_RELOAD_AGGREGATION_REQUIRED_BY_GROUP_BY": 11031, + "LOCERR_RELOAD_CONNECT_MUST_USE_LIB_PREFIX_IN_THIS_MODE": 11032, + "LOCERR_RELOAD_ODBC_CONNECT_FAILED": 11033, + "LOCERR_RELOAD_OLEDB_CONNECT_FAILED": 11034, + "LOCERR_RELOAD_CUSTOM_CONNECT_FAILED": 11035, + "LOCERR_RELOAD_ODBC_READ_FAILED": 11036, + "LOCERR_RELOAD_OLEDB_READ_FAILED": 11037, + "LOCERR_RELOAD_CUSTOM_READ_FAILED": 11038, + "LOCERR_RELOAD_BINARY_LOAD_PROHIBITED": 11039, + "LOCERR_RELOAD_CONNECTOR_START_FAILED": 11040, + "LOCERR_RELOAD_CONNECTOR_NOT_RESPONDING": 11041, + "LOCERR_RELOAD_CONNECTOR_REPLY_ERROR": 11042, + "LOCERR_RELOAD_CONNECTOR_CONNECT_ERROR": 11043, + "LOCERR_RELOAD_CONNECTOR_NOT_FOUND_ERROR": 11044, + "LOCERR_PERSONAL_NEW_VERSION_AVAILABLE": 12000, + "LOCERR_PERSONAL_VERSION_EXPIRED": 12001, + "LOCERR_PERSONAL_SECTION_ACCESS_DETECTED": 12002, + "LOCERR_PERSONAL_APP_DELETION_FAILED": 12003, + "LOCERR_USER_AUTHENTICATION_FAILURE": 12004, + "LOCERR_EXPORT_OUT_OF_MEMORY": 13000, + "LOCERR_EXPORT_NO_DATA": 13001, + "LOCERR_SYNC_INVALID_OFFSET": 14000, + "LOCERR_SEARCH_TIMEOUT": 15000, + "LOCERR_DIRECT_DISCOVERY_LINKED_EXPRESSION_FAIL": 16000, + "LOCERR_DIRECT_DISCOVERY_ROWCOUNT_OVERFLOW": 16001, + "LOCERR_DIRECT_DISCOVERY_EMPTY_RESULT": 16002, + "LOCERR_DIRECT_DISCOVERY_DB_CONNECTION_FAILED": 16003, + "LOCERR_DIRECT_DISCOVERY_MEASURE_NOT_ALLOWED": 16004, + "LOCERR_DIRECT_DISCOVERY_DETAIL_NOT_ALLOWED": 16005, + "LOCERR_DIRECT_DISCOVERY_NOT_SYNTH_CIRCULAR_ALLOWED": 16006, + "LOCERR_DIRECT_DISCOVERY_ONLY_ONE_DD_TABLE_ALLOWED": 16007, + "LOCERR_DIRECT_DISCOVERY_DB_AUTHORIZATION_FAILED": 16008, + "LOCERR_SMART_LOAD_TABLE_NOT_FOUND": 17000, + "LOCERR_SMART_LOAD_TABLE_DUPLICATED": 17001, + "LOCERR_VARIABLE_NO_NAME": 18000, + "LOCERR_VARIABLE_DUPLICATE_NAME": 18001, + "LOCERR_VARIABLE_INCONSISTENCY": 18002, + "LOCERR_MEDIA_LIBRARY_LIST_FAILED": 19000, + "LOCERR_MEDIA_LIBRARY_CONTENT_FAILED": 19001, + "LOCERR_MEDIA_BUNDLING_FAILED": 19002, + "LOCERR_MEDIA_UNBUNDLING_FAILED": 19003, + "LOCERR_MEDIA_LIBRARY_NOT_FOUND": 19004, + "LOCERR_FEATURE_DISABLED": 20000, + "LOCERR_JSON_RPC_INVALID_REQUEST": -32600, + "LOCERR_JSON_RPC_METHOD_NOT_FOUND": -32601, + "LOCERR_JSON_RPC_INVALID_PARAMETERS": -32602, + "LOCERR_JSON_RPC_INTERNAL_ERROR": -32603, + "LOCERR_JSON_RPC_PARSE_ERROR": -32700, + "LOCERR_MQ_SOCKET_CONNECT_FAILURE": 33000, + "LOCERR_MQ_SOCKET_OPEN_FAILURE": 33001, + "LOCERR_MQ_PROTOCOL_NO_RESPONE": 33002, + "LOCERR_MQ_PROTOCOL_LIBRARY_EXCEPTION": 33003, + "LOCERR_MQ_PROTOCOL_CONNECTION_CLOSED": 33004, + "LOCERR_MQ_PROTOCOL_CHANNEL_CLOSED": 33005, + "LOCERR_MQ_PROTOCOL_UNKNOWN_ERROR": 33006, + "LOCERR_MQ_PROTOCOL_INVALID_STATUS": 33007, + "LOCERR_EXTENGINE_GRPC_STATUS_OK": 22000, + "LOCERR_EXTENGINE_GRPC_STATUS_CANCELLED": 22001, + "LOCERR_EXTENGINE_GRPC_STATUS_UNKNOWN": 22002, + "LOCERR_EXTENGINE_GRPC_STATUS_INVALID_ARGUMENT": 22003, + "LOCERR_EXTENGINE_GRPC_STATUS_DEADLINE_EXCEEDED": 22004, + "LOCERR_EXTENGINE_GRPC_STATUS_NOT_FOUND": 22005, + "LOCERR_EXTENGINE_GRPC_STATUS_ALREADY_EXISTS": 22006, + "LOCERR_EXTENGINE_GRPC_STATUS_PERMISSION_DENIED": 22007, + "LOCERR_EXTENGINE_GRPC_STATUS_RESOURCE_EXHAUSTED": 22008, + "LOCERR_EXTENGINE_GRPC_STATUS_FAILED_PRECONDITION": 22009, + "LOCERR_EXTENGINE_GRPC_STATUS_ABORTED": 22010, + "LOCERR_EXTENGINE_GRPC_STATUS_OUT_OF_RANGE": 22011, + "LOCERR_EXTENGINE_GRPC_STATUS_UNIMPLEMENTED": 22012, + "LOCERR_EXTENGINE_GRPC_STATUS_INTERNAL": 22013, + "LOCERR_EXTENGINE_GRPC_STATUS_UNAVAILABLE": 22014, + "LOCERR_EXTENGINE_GRPC_STATUS_DATA_LOSS": 22015, + "LOCERR_EXTENGINE_GRPC_STATUS_UNAUTHENTICATED": 22016, + "LOCERR_LXW_INVALID_OBJ": 23001, + "LOCERR_LXW_INVALID_FILE": 23002, + "LOCERR_LXW_INVALID_SHEET": 23003, + "LOCERR_LXW_INVALID_EXPORT_RANGE": 23004, + "LOCERR_LXW_ERROR": 23005, + "LOCERR_LXW_ERROR_MEMORY_MALLOC_FAILED": 23006, + "LOCERR_LXW_ERROR_CREATING_XLSX_FILE": 23007, + "LOCERR_LXW_ERROR_CREATING_TMPFILE": 23008, + "LOCERR_LXW_ERROR_ZIP_FILE_OPERATION": 23009, + "LOCERR_LXW_ERROR_ZIP_FILE_ADD": 23010, + "LOCERR_LXW_ERROR_ZIP_CLOSE": 23011, + "LOCERR_LXW_ERROR_NULL_PARAMETER_IGNORED": 23012, + "LOCERR_LXW_ERROR_MAX_STRING_LENGTH_EXCEEDED": 23013, + "LOCERR_LXW_ERROR_255_STRING_LENGTH_EXCEEDED": 23014, + "LOCERR_LXW_ERROR_SHARED_STRING_INDEX_NOT_FOUND": 23015, + "LOCERR_LXW_ERROR_WORKSHEET_INDEX_OUT_OF_RANGE": 23016, + "LOCERR_LXW_ERROR_WORKSHEET_MAX_NUMBER_URLS_EXCEEDED": 23017 + }, + "LocalizedWarningCode": { + "LOCWARN_PERSONAL_RELOAD_REQUIRED": 0, + "LOCWARN_PERSONAL_VERSION_EXPIRES_SOON": 1, + "LOCWARN_EXPORT_DATA_TRUNCATED": 1000, + "LOCWARN_COULD_NOT_OPEN_ALL_OBJECTS": 2000 + }, + "GrpType": { + "GRP_NX_NONE": 0, + "GRP_NX_HIEARCHY": 1, + "GRP_NX_COLLECTION": 2 + }, + "ExportFileType": { + "EXPORT_CSV_C": 0, + "EXPORT_CSV_T": 1, + "EXPORT_OOXML": 2 + }, + "ExportState": { + "EXPORT_POSSIBLE": 0, + "EXPORT_ALL": 1 + }, + "DimCellType": { + "NX_DIM_CELL_VALUE": 0, + "NX_DIM_CELL_EMPTY": 1, + "NX_DIM_CELL_NORMAL": 2, + "NX_DIM_CELL_TOTAL": 3, + "NX_DIM_CELL_OTHER": 4, + "NX_DIM_CELL_AGGR": 5, + "NX_DIM_CELL_PSEUDO": 6, + "NX_DIM_CELL_ROOT": 7, + "NX_DIM_CELL_NULL": 8, + "NX_DIM_CELL_GENERATED": 9 + }, + "StackElemType": { + "NX_STACK_CELL_NORMAL": 0, + "NX_STACK_CELL_TOTAL": 1, + "NX_STACK_CELL_OTHER": 2, + "NX_STACK_CELL_SUM": 3, + "NX_STACK_CELL_VALUE": 4, + "NX_STACK_CELL_PSEUDO": 5 + }, + "SortIndicatorType": { + "NX_SORT_INDICATE_NONE": 0, + "NX_SORT_INDICATE_ASC": 1, + "NX_SORT_INDICATE_DESC": 2 + }, + "DimensionType": { + "NX_DIMENSION_TYPE_DISCRETE": 0, + "NX_DIMENSION_TYPE_NUMERIC": 1, + "NX_DIMENSION_TYPE_TIME": 2 + }, + "FieldSelectionMode": { + "SELECTION_MODE_NORMAL": 0, + "SELECTION_MODE_AND": 1, + "SELECTION_MODE_NOT": 2 + }, + "FrequencyMode": { + "NX_FREQUENCY_NONE": 0, + "NX_FREQUENCY_VALUE": 1, + "NX_FREQUENCY_PERCENT": 2, + "NX_FREQUENCY_RELATIVE": 3 + }, + "DataReductionMode": { + "DATA_REDUCTION_NONE": 0, + "DATA_REDUCTION_ONEDIM": 1, + "DATA_REDUCTION_SCATTERED": 2, + "DATA_REDUCTION_CLUSTERED": 3, + "DATA_REDUCTION_STACKED": 4 + }, + "HypercubeMode": { + "DATA_MODE_STRAIGHT": 0, + "DATA_MODE_PIVOT": 1, + "DATA_MODE_PIVOT_STACK": 2, + "DATA_MODE_TREE": 3 + }, + "PatchOperationType": { + "Add": 0, + "Remove": 1, + "Replace": 2 + }, + "SelectionCellType": { + "NX_CELL_DATA": 0, + "NX_CELL_TOP": 1, + "NX_CELL_LEFT": 2 + }, + "MatchingFieldMode": { + "MATCHINGFIELDMODE_MATCH_ALL": 0, + "MATCHINGFIELDMODE_MATCH_ONE": 1 + }, + "SessionState": { + "SESSION_CREATED": 0, + "SESSION_ATTACHED": 1 + }, + "ReloadState": { + "RELOAD_PAUSED": 0, + "RELOAD_STARTED": 1, + "RELOAD_ABORTED": 2 + }, + "QrsChangeType": { + "QRS_CHANGE_UNDEFINED": 0, + "QRS_CHANGE_ADD": 1, + "QRS_CHANGE_UPDATE": 2, + "QRS_CHANGE_DELETE": 3 + }, + "ExtEngineDataType": { + "NX_EXT_DATATYPE_STRING": 0, + "NX_EXT_DATATYPE_DOUBLE": 1, + "NX_EXT_DATATYPE_BOTH": 2 + }, + "ExtEngineFunctionType": { + "NX_EXT_FUNCTIONTYPE_SCALAR": 0, + "NX_EXT_FUNCTIONTYPE_AGGR": 1, + "NX_EXT_FUNCTIONTYPE_TENSOR": 2 + }, + "ExtEngineMsgType": { + "NX_EXT_MSGTYPE_FUNCTION_CALL": 1, + "NX_EXT_MSGTYPE_SCRIPT_CALL": 2, + "NX_EXT_MSGTYPE_RETURN_VALUE": 3, + "NX_EXT_MSGTYPE_RETURN_MULTIPLE": 4, + "NX_EXT_MSGTYPE_RETURN_ERROR": 5 + } + }, + "version": "12.67.2" +} diff --git a/jwt-scratch/src/js/node_modules/enigma.js/schemas/2.1.json b/jwt-scratch/src/js/node_modules/enigma.js/schemas/2.1.json new file mode 100644 index 0000000..388c773 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/enigma.js/schemas/2.1.json @@ -0,0 +1,1528 @@ +{ + "structs": { + "Field":{ + "GetCardinal": { + "In": [], + "Out": [] + }, + "GetAndMode": { + "In": [], + "Out": [] + }, + "SelectValues": { + "In": [{ "Name": "qFieldValues","DefaultValue": [{"qText": "", "qIsNumeric": false, "qNumber": 0}] }, { "Name": "qToggleMode","DefaultValue": false, "Optional": true }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Select": { + "In": [{ "Name": "qMatch","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qExcludedValuesMode","DefaultValue": 0, "Optional": true }], + "Out": [] + }, + "ToggleSelect": { + "In": [{ "Name": "qMatch","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qExcludedValuesMode","DefaultValue": 0, "Optional": true }], + "Out": [] + }, + "ClearAllButThis": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectPossible": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectExcluded": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectAll": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Lock": { + "In": [], + "Out": [] + }, + "Unlock": { + "In": [], + "Out": [] + }, + "GetNxProperties": { + "In": [], + "Out": [{ "Name": "qProperties" }] + }, + "SetNxProperties": { + "In": [{ "Name": "qProperties","DefaultValue": {"qOneAndOnlyOne": false} }], + "Out": [] + }, + "SetAndMode": { + "In": [{ "Name": "qAndMode","DefaultValue": false }], + "Out": [] + }, + "SelectAlternative": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "LowLevelSelect": { + "In": [{ "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Clear": { + "In": [], + "Out": [] + } + }, + "Variable":{ + "GetContent": { + "In": [], + "Out": [{ "Name": "qContent" }] + }, + "GetRawContent": { + "In": [], + "Out": [] + }, + "SetContent": { + "In": [{ "Name": "qContent","DefaultValue": "" }, { "Name": "qUpdateMRU","DefaultValue": false }], + "Out": [] + }, + "ForceContent": { + "In": [{ "Name": "qs","DefaultValue": "" }, { "Name": "qd","DefaultValue": 0 }], + "Out": [] + }, + "GetNxProperties": { + "In": [], + "Out": [{ "Name": "qProperties" }] + }, + "SetNxProperties": { + "In": [{ "Name": "qProperties","DefaultValue": {"qName": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qUsePredefListedValues": false, "qPreDefinedList": [""]} }], + "Out": [] + } + }, + "GenericObject":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "GetListObjectData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeReducedData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qZoomFactor","DefaultValue": 0 }, { "Name": "qReductionMode","DefaultValue": 0 }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubePivotData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeStackData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qMaxNbrCells","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeBinnedData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qViewport","DefaultValue": {"qWidth": 0, "qHeight": 0, "qZoomLevel": 0} }, { "Name": "qDataRanges","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qMaxNbrCells","DefaultValue": 0 }, { "Name": "qQueryLevel","DefaultValue": 0 }, { "Name": "qBinningMethod","DefaultValue": 0 }], + "Out": [{ "Name": "qDataPages" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }, { "Name": "qSoftPatch","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "ClearSoftPatches": { + "In": [], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetEffectiveProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "SetFullPropertyTree": { + "In": [{ "Name": "qPropEntry","DefaultValue": {"qProperty": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}}, "qChildren": [], "qEmbeddedSnapshotRef": null} }], + "Out": [] + }, + "GetFullPropertyTree": { + "In": [], + "Out": [{ "Name": "qPropEntry" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "ClearSelections": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "ExportData": { + "In": [{ "Name": "qFileType","DefaultValue": 0 }, { "Name": "qPath","DefaultValue": "", "Optional": true }, { "Name": "qFileName","DefaultValue": "", "Optional": true }, { "Name": "qExportState","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qUrl" }] + }, + "SelectListObjectValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectPossible": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectExcluded": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectAlternative": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectAll": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SearchListObjectFor": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qMatch","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "AbortListObjectSearch": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [] + }, + "AcceptListObjectSearch": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "ExpandLeft": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "ExpandTop": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "CollapseLeft": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "CollapseTop": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "DrillUp": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qDimNo","DefaultValue": 0 }, { "Name": "qNbrSteps","DefaultValue": 0 }], + "Out": [] + }, + "Lock": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "Unlock": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "SelectHyperCubeValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qDimNo","DefaultValue": 0 }, { "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectHyperCubeCells": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRowIndices","DefaultValue": [0] }, { "Name": "qColIndices","DefaultValue": [0] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectPivotCells": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSelections","DefaultValue": [{"qType": 0, "qCol": 0, "qRow": 0}] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "RangeSelectHyperCubeValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qRange": {"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}, "qMeasureIx": 0}] }, { "Name": "qColumnsToSelect","DefaultValue": [0], "Optional": true }, { "Name": "qOrMode","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetChild": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetChildInfos": { + "In": [], + "Out": [{ "Name": "qInfos" }] + }, + "CreateChild": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }, { "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyChild": { + "In": [{ "Name": "qId","DefaultValue": "" }, { "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "DestroyAllChildren": { + "In": [{ "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [] + }, + "SetChildArrayOrder": { + "In": [{ "Name": "qIds","DefaultValue": [""] }], + "Out": [] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "CopyFrom": { + "In": [{ "Name": "qFromId","DefaultValue": "" }], + "Out": [] + }, + "BeginSelections": { + "In": [{ "Name": "qPaths","DefaultValue": [""] }], + "Out": [] + }, + "EndSelections": { + "In": [{ "Name": "qAccept","DefaultValue": false }], + "Out": [] + }, + "ResetMadeSelections": { + "In": [], + "Out": [] + }, + "EmbedSnapshotObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetSnapshotObject": { + "In": [], + "Out": [] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericDimension":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDim": {"qGrouping": 0, "qFieldDefs": [""], "qFieldLabels": [""]}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetDimension": { + "In": [], + "Out": [{ "Name": "qDim" }] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericBookmark":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "Apply": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericVariable":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "SetStringValue": { + "In": [{ "Name": "qVal","DefaultValue": "" }], + "Out": [] + }, + "SetNumValue": { + "In": [{ "Name": "qVal","DefaultValue": 0 }], + "Out": [] + }, + "SetDualValue": { + "In": [{ "Name": "qText","DefaultValue": "" }, { "Name": "qNum","DefaultValue": 0 }], + "Out": [] + } + }, + "GenericMeasure":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMeasure": {"qLabel": "", "qDef": "", "qGrouping": 0, "qExpressions": [""], "qActiveExpression": 0}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetMeasure": { + "In": [], + "Out": [{ "Name": "qMeasure" }] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericDerivedDefinition":{ + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDerivedDefinition": {"qName": "", "qTags": [""], "qParameters": [{"qName": "", "qValue": ""}], "qFieldDefs": [{"qName": "", "qExpression": "", "qTags": [""]}], "qGroupDefs": [{"qName": "", "qGrouping": 0, "qFieldDerivedDefinitionNames": [""]}]}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "MatchTags": { + "In": [{ "Name": "qTags","DefaultValue": [""] }], + "Out": [] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetDerivedDefinitionData": { + "In": [], + "Out": [{ "Name": "qData" }] + }, + "GetExpression": { + "In": [{ "Name": "qExpressionName","DefaultValue": "" }, { "Name": "qParameters","DefaultValue": [""] }], + "Out": [] + } + }, + "GenericDerivedFields":{ + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDerivedDefinitionId": "", "qFieldName": [""], "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetDerivedFieldData": { + "In": [], + "Out": [{ "Name": "qData" }] + }, + "GetDerivedField": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qFields" }] + }, + "GetListData": { + "In": [], + "Out": [{ "Name": "qListData" }] + }, + "GetDerivedFields": { + "In": [], + "Out": [{ "Name": "qFields" }] + }, + "GetDerivedGroups": { + "In": [], + "Out": [{ "Name": "qGroups" }] + } + }, + "InternalTest":{ + "Initialised": { + "In": [], + "Out": [] + }, + "TestMemoryManagement": { + "In": [], + "Out": [] + }, + "TestNextFileFormat": { + "In": [], + "Out": [] + }, + "BombQRS": { + "In": [], + "Out": [] + }, + "BombQRSParallel": { + "In": [{ "Name": "qNThreads","DefaultValue": 0 }], + "Out": [] + }, + "TestLogging": { + "In": [{ "Name": "qLogger","DefaultValue": "" }, { "Name": "qVerbosity","DefaultValue": 0 }, { "Name": "qSteps","DefaultValue": 0, "Optional": true }], + "Out": [] + }, + "TestRepositoryLogging": { + "In": [{ "Name": "qLogger","DefaultValue": "" }, { "Name": "qVerbosity","DefaultValue": 0 }, { "Name": "qMessage","DefaultValue": "" }], + "Out": [] + }, + "GetQixCounters": { + "In": [], + "Out": [{ "Name": "qCounters" }] + }, + "ResetQixCounters": { + "In": [], + "Out": [] + } + }, + "Doc":{ + "GetProperties": { + "In": [], + "Out": [] + }, + "GetField": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }, { "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "GetFieldDescription": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }], + "Out": [] + }, + "GetVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "GetLooselyCoupledVector": { + "In": [], + "Out": [{ "Name": "qv" }] + }, + "SetLooselyCoupledVector": { + "In": [{ "Name": "qv","DefaultValue": [0] }], + "Out": [] + }, + "Evaluate": { + "In": [{ "Name": "qExpression","DefaultValue": "" }], + "Out": [] + }, + "EvaluateEx": { + "In": [{ "Name": "qExpression","DefaultValue": "" }], + "Out": [{ "Name": "qValue" }] + }, + "ClearAll": { + "In": [{ "Name": "qLockedAlso","DefaultValue": false, "Optional": true }, { "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "LockAll": { + "In": [{ "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "UnlockAll": { + "In": [{ "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "Back": { + "In": [], + "Out": [] + }, + "Forward": { + "In": [], + "Out": [] + }, + "ReduceData": { + "In": [{ "Name": "qConfirm","DefaultValue": false, "Optional": true }, { "Name": "qDropFieldNames","DefaultValue": [""], "Optional": true }], + "Out": [] + }, + "RemoveAllData": { + "In": [{ "Name": "qConfirm","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "CreateVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "RemoveVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "GetLocaleInfo": { + "In": [], + "Out": [] + }, + "GetTablesAndKeys": { + "In": [{ "Name": "qWindowSize","DefaultValue": {"qcx": 0, "qcy": 0} }, { "Name": "qNullSize","DefaultValue": {"qcx": 0, "qcy": 0} }, { "Name": "qCellHeight","DefaultValue": 0 }, { "Name": "qSyntheticMode","DefaultValue": false }, { "Name": "qIncludeSysVars","DefaultValue": false }], + "Out": [{ "Name": "qtr" }, { "Name": "qk" }] + }, + "GetViewDlgSaveInfo": { + "In": [], + "Out": [] + }, + "SetViewDlgSaveInfo": { + "In": [{ "Name": "qInfo","DefaultValue": {"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCtlInfo": {"qInternalView": {"qTables": [{"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCaption": ""}], "qBroomPoints": [{"qPos": {"qx": 0, "qy": 0}, "qTable": "", "qFields": [""]}], "qConnectionPoints": [{"qPos": {"qx": 0, "qy": 0}, "qFields": [""]}], "qZoomFactor": 0}, "qSourceView": {"qTables": [{"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCaption": ""}], "qBroomPoints": [{"qPos": {"qx": 0, "qy": 0}, "qTable": "", "qFields": [""]}], "qConnectionPoints": [{"qPos": {"qx": 0, "qy": 0}, "qFields": [""]}], "qZoomFactor": 0}}, "qMode": 0} }], + "Out": [] + }, + "GetEmptyScript": { + "In": [{ "Name": "qLocalizedMainSection","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "DoReload": { + "In": [{ "Name": "qMode","DefaultValue": 0, "Optional": true }, { "Name": "qPartial","DefaultValue": false, "Optional": true }, { "Name": "qDebug","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "GetScriptBreakpoints": { + "In": [], + "Out": [{ "Name": "qBreakpoints" }] + }, + "SetScriptBreakpoints": { + "In": [{ "Name": "qBreakpoints","DefaultValue": [{"qbufferName": "", "qlineIx": 0, "qEnabled": false}] }], + "Out": [] + }, + "GetScript": { + "In": [], + "Out": [{ "Name": "qScript" }] + }, + "GetTextMacros": { + "In": [], + "Out": [{ "Name": "qMacros" }] + }, + "SetFetchLimit": { + "In": [{ "Name": "qLimit","DefaultValue": 0 }], + "Out": [] + }, + "DoSave": { + "In": [{ "Name": "qFileName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "GetTableData": { + "In": [{ "Name": "qOffset","DefaultValue": 0 }, { "Name": "qRows","DefaultValue": 0 }, { "Name": "qSyntheticMode","DefaultValue": false }, { "Name": "qTableName","DefaultValue": "" }], + "Out": [{ "Name": "qData" }] + }, + "GetAppLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "SetAppProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qTitle": "", "qLastReloadTime": "", "qMigrationHash": "", "qSavedInProductVersion": "", "qThumbnail": {"qUrl": ""}} }], + "Out": [] + }, + "GetAppProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "CreateSessionObject": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }], + "Out": [] + }, + "DestroySessionObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CreateObject": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "CloneObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qDraftId" }] + }, + "CommitDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "DestroyDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }, { "Name": "qSourceId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "Undo": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "Redo": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "ClearUndoBuffer": { + "In": [], + "Out": [] + }, + "CreateDimension": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDim": {"qGrouping": 0, "qFieldDefs": [""], "qFieldLabels": [""]}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "CloneDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateMeasure": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMeasure": {"qLabel": "", "qDef": "", "qGrouping": 0, "qExpressions": [""], "qActiveExpression": 0}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "CloneMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateSessionVariable": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [] + }, + "DestroySessionVariable": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CreateVariableEx": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyVariableById": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "DestroyVariableByName": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetVariableById": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetVariableByName": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "MigrateVariables": { + "In": [], + "Out": [] + }, + "CreateDerivedDefinition": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDerivedDefinition": {"qName": "", "qTags": [""], "qParameters": [{"qName": "", "qValue": ""}], "qFieldDefs": [{"qName": "", "qExpression": "", "qTags": [""]}], "qGroupDefs": [{"qName": "", "qGrouping": 0, "qFieldDerivedDefinitionNames": [""]}]}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyDerivedDefinition": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetDerivedDefinition": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetDerivedDefinitionByName": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "CloneDerivedDefinition": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "GetDerivedDefinitionsForTags": { + "In": [{ "Name": "qTags","DefaultValue": [""] }], + "Out": [{ "Name": "qInstanceName" }] + }, + "AssignDerivedFieldFor": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }, { "Name": "qDerivedDefinitionNames","DefaultValue": [""] }], + "Out": [] + }, + "CreateDerivedFields": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDerivedDefinitionId": "", "qFieldName": [""], "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyDerivedFields": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetDerivedFields": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetAllDerivedFields_INTERNAL": { + "In": [], + "Out": [{ "Name": "qDerivedFields" }] + }, + "GetDerivedFieldDimensionDef": { + "In": [{ "Name": "qLibraryId","DefaultValue": "" }], + "Out": [{ "Name": "qDimensionDef" }] + }, + "GetDerivedFieldFor": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }, { "Name": "qGetDerivedDefinitionsForTags","DefaultValue": "" }], + "Out": [] + }, + "GetAllDerivedFieldsFor": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }], + "Out": [{ "Name": "qDerivedFields" }] + }, + "MigrateDerivedFields": { + "In": [], + "Out": [] + }, + "CheckExpression": { + "In": [{ "Name": "qExpr","DefaultValue": "" }, { "Name": "qLabels","DefaultValue": [""], "Optional": true }], + "Out": [{ "Name": "qErrorMsg" }, { "Name": "qBadFieldNames" }, { "Name": "qDangerousFieldNames" }] + }, + "CheckNumberOrExpression": { + "In": [{ "Name": "qExpr","DefaultValue": "" }], + "Out": [{ "Name": "qErrorMsg" }, { "Name": "qBadFieldNames" }] + }, + "AddAlternateState": { + "In": [{ "Name": "qStateName","DefaultValue": "" }], + "Out": [] + }, + "RemoveAlternateState": { + "In": [{ "Name": "qStateName","DefaultValue": "" }], + "Out": [] + }, + "CreateBookmark": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "ApplyBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CloneBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "AddFieldFromExpression": { + "In": [{ "Name": "qName","DefaultValue": "" }, { "Name": "qExpr","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetAllInfos": { + "In": [], + "Out": [{ "Name": "qInfos" }] + }, + "Resume": { + "In": [], + "Out": [] + }, + "AbortModal": { + "In": [{ "Name": "qAccept","DefaultValue": false }], + "Out": [] + }, + "Publish": { + "In": [{ "Name": "qStreamId","DefaultValue": "" }, { "Name": "qName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + }, + "GetMatchingFields": { + "In": [{ "Name": "qTags","DefaultValue": [""] }, { "Name": "qMatchingFieldMode","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qFieldNames" }] + }, + "FindMatchingFields": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }, { "Name": "qTags","DefaultValue": [""] }], + "Out": [{ "Name": "qFieldNames" }] + }, + "SearchSuggest": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0} }, { "Name": "qTerms","DefaultValue": [""] }], + "Out": [{ "Name": "qResult" }] + }, + "SearchAssociations": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qPage","DefaultValue": {"qOffset": 0, "qCount": 0, "qMaxNbrFieldMatches": 0} }], + "Out": [{ "Name": "qResults" }] + }, + "SelectAssociations": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qMatchIx","DefaultValue": 0 }, { "Name": "qSoftLock","DefaultValue": null, "Optional": true }], + "Out": [] + }, + "SaveObjects": { + "In": [], + "Out": [] + }, + "GetAssociationScores": { + "In": [{ "Name": "qTable1","DefaultValue": "" }, { "Name": "qTable2","DefaultValue": "" }], + "Out": [{ "Name": "qScore" }] + }, + "GetMediaList": { + "In": [], + "Out": [{ "Name": "qList" }] + }, + "GetContentLibraries": { + "In": [], + "Out": [{ "Name": "qList" }] + }, + "GetLibraryContent": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [{ "Name": "qList" }] + }, + "DoReloadEx": { + "In": [{ "Name": "qParams","DefaultValue": {"qMode": 0, "qPartial": false, "qDebug": false}, "Optional": true }], + "Out": [{ "Name": "qResult" }] + }, + "BackCount": { + "In": [], + "Out": [] + }, + "ForwardCount": { + "In": [], + "Out": [] + }, + "SetScript": { + "In": [{ "Name": "qScript","DefaultValue": "" }], + "Out": [] + }, + "CheckScriptSyntax": { + "In": [], + "Out": [{ "Name": "qErrors" }] + }, + "GetFavoriteVariables": { + "In": [], + "Out": [{ "Name": "qNames" }] + }, + "SetFavoriteVariables": { + "In": [{ "Name": "qNames","DefaultValue": [""] }], + "Out": [] + }, + "GetIncludeFileContent": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [{ "Name": "qContent" }] + }, + "CreateConnection": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}} }], + "Out": [{ "Name": "qConnectionId" }] + }, + "ModifyConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}} }, { "Name": "qOverrideCredentials","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "DeleteConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [] + }, + "GetConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qConnection" }] + }, + "GetConnections": { + "In": [], + "Out": [{ "Name": "qConnections" }] + }, + "GetDatabaseInfo": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qInfo" }] + }, + "GetDatabases": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qDatabases" }] + }, + "GetDatabaseOwners": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qOwners" }] + }, + "GetDatabaseTables": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qTables" }] + }, + "GetDatabaseTableFields": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qFields" }] + }, + "GetDatabaseTablePreview": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qPreview" }] + }, + "GetFolderItemsForConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qFolderItems" }] + }, + "GuessFileType": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qDataFormat" }] + }, + "GetFileTables": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }], + "Out": [{ "Name": "qTables" }] + }, + "GetFileTableFields": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qFields" }, { "Name": "qFormatSpec" }] + }, + "GetFileTablePreview": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qPreview" }, { "Name": "qFormatSpec" }] + }, + "GetFileTablesEx": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }], + "Out": [{ "Name": "qTables" }] + }, + "SendGenericCommandToCustomConnector": { + "In": [{ "Name": "qProvider","DefaultValue": "" }, { "Name": "qCommand","DefaultValue": "" }, { "Name": "qMethod","DefaultValue": "" }, { "Name": "qParameters","DefaultValue": [""] }, { "Name": "qAppendConnection","DefaultValue": "" }], + "Out": [{ "Name": "qResult" }] + } + }, + "Global":{ + "AbortRequest": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [] + }, + "AbortAll": { + "In": [], + "Out": [] + }, + "GetProgress": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [{ "Name": "qProgressData" }] + }, + "QvVersion": { + "In": [], + "Out": [] + }, + "OSVersion": { + "In": [], + "Out": [] + }, + "OSName": { + "In": [], + "Out": [] + }, + "QTProduct": { + "In": [], + "Out": [] + }, + "GetDocList": { + "In": [], + "Out": [{ "Name": "qDocList" }] + }, + "GetInteract": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [{ "Name": "qDef" }] + }, + "InteractDone": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }, { "Name": "qDef","DefaultValue": {"qType": 0, "qTitle": "", "qMsg": "", "qButtons": 0, "qLine": "", "qOldLineNr": 0, "qNewLineNr": 0, "qPath": "", "qHidden": false, "qResult": 0, "qInput": ""} }], + "Out": [] + }, + "GetAuthenticatedUser": { + "In": [], + "Out": [] + }, + "GetStreamList": { + "In": [], + "Out": [{ "Name": "qStreamList" }] + }, + "CreateDocEx": { + "In": [{ "Name": "qDocName","DefaultValue": "" }, { "Name": "qUserName","DefaultValue": "", "Optional": true }, { "Name": "qPassword","DefaultValue": "", "Optional": true }, { "Name": "qSerial","DefaultValue": "", "Optional": true }, { "Name": "qLocalizedScriptMainSection","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qDocId" }] + }, + "GetActiveDoc": { + "In": [], + "Out": [] + }, + "AllowCreateApp": { + "In": [], + "Out": [] + }, + "CreateApp": { + "In": [{ "Name": "qAppName","DefaultValue": "" }, { "Name": "qLocalizedScriptMainSection","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qSuccess" }, { "Name": "qAppId" }] + }, + "DeleteApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "IsDesktopMode": { + "In": [], + "Out": [] + }, + "GetConfiguration": { + "In": [], + "Out": [{ "Name": "qConfig" }] + }, + "CancelRequest": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [] + }, + "GetInternalTest": { + "In": [{ "Name": "qKey","DefaultValue": "" }], + "Out": [] + }, + "ShutdownProcess": { + "In": [], + "Out": [] + }, + "ReloadExtensionList": { + "In": [], + "Out": [] + }, + "ReplaceAppFromID": { + "In": [{ "Name": "qTargetAppId","DefaultValue": "" }, { "Name": "qSrcAppID","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "CopyApp": { + "In": [{ "Name": "qTargetAppId","DefaultValue": "" }, { "Name": "qSrcAppId","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "ImportApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qSrcPath","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "ImportAppEx": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qSrcPath","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }, { "Name": "qExcludeConnections","DefaultValue": false }], + "Out": [] + }, + "ExportApp": { + "In": [{ "Name": "qTargetPath","DefaultValue": "" }, { "Name": "qSrcAppId","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "PublishApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qStreamId","DefaultValue": "" }, { "Name": "qCopy","DefaultValue": false }, { "Name": "qReplaceId","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "IsPersonalMode": { + "In": [], + "Out": [] + }, + "GetUniqueID": { + "In": [], + "Out": [{ "Name": "qUniqueID" }] + }, + "OpenDoc": { + "In": [{ "Name": "qDocName","DefaultValue": "" }, { "Name": "qUserName","DefaultValue": "", "Optional": true }, { "Name": "qPassword","DefaultValue": "", "Optional": true }, { "Name": "qSerial","DefaultValue": "", "Optional": true }, { "Name": "qNoData","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "CreateSessionApp": { + "In": [], + "Out": [{ "Name": "qSessionAppId" }] + }, + "CreateSessionAppFromApp": { + "In": [{ "Name": "qSrcAppId","DefaultValue": "" }], + "Out": [{ "Name": "qSessionAppId" }] + }, + "ProductVersion": { + "In": [], + "Out": [] + }, + "GetAppEntry": { + "In": [{ "Name": "qAppID","DefaultValue": "" }], + "Out": [{ "Name": "qEntry" }] + }, + "ConfigureReload": { + "In": [{ "Name": "qCancelOnScriptError","DefaultValue": false }, { "Name": "qUseErrorData","DefaultValue": false }, { "Name": "qInteractOnError","DefaultValue": false }], + "Out": [] + }, + "CancelReload": { + "In": [], + "Out": [] + }, + "GetBNF": { + "In": [{ "Name": "qBnfType","DefaultValue": 0 }], + "Out": [{ "Name": "qBnfDefs" }] + }, + "GetFunctions": { + "In": [{ "Name": "qGroup","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qFunctions" }] + }, + "GetOdbcDsns": { + "In": [], + "Out": [{ "Name": "qOdbcDsns" }] + }, + "GetOleDbProviders": { + "In": [], + "Out": [{ "Name": "qOleDbProviders" }] + }, + "GetDatabasesFromConnectionString": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}} }], + "Out": [{ "Name": "qDatabases" }] + }, + "IsValidConnectionString": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}} }], + "Out": [] + }, + "GetDefaultAppFolder": { + "In": [], + "Out": [{ "Name": "qPath" }] + }, + "GetMyDocumentsFolder": { + "In": [], + "Out": [{ "Name": "qFolder" }] + }, + "GetLogicalDriveStrings": { + "In": [], + "Out": [{ "Name": "qDrives" }] + }, + "GetFolderItemsForPath": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [{ "Name": "qFolderItems" }] + }, + "GetSupportedCodePages": { + "In": [], + "Out": [{ "Name": "qCodePages" }] + }, + "GetCustomConnectors": { + "In": [{ "Name": "qReloadList","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qConnectors" }] + } + } + }, + "enums": { + "LocalizedMessageCode": { + "LOCMSG_SCRIPTEDITOR_EMPTY_MESSAGE": 0, + "LOCMSG_SCRIPTEDITOR_PROGRESS_SAVING_STARTED": 1, + "LOCMSG_SCRIPTEDITOR_PROGRESS_BYTES_LEFT": 2, + "LOCMSG_SCRIPTEDITOR_PROGRESS_STORING_TABLES": 3, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_ROWS_SO_FAR": 4, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECTED": 5, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECTING_TO": 6, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECT_FAILED": 7, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_ROWISH": 8, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_COLUMNAR": 9, + "LOCMSG_SCRIPTEDITOR_ERROR": 10, + "LOCMSG_SCRIPTEDITOR_DONE": 11, + "LOCMSG_SCRIPTEDITOR_LOAD_EXTERNAL_DATA": 12, + "LOCMSG_SCRIPTEDITOR_PROGRESS_OLD_QVD_ISLOADING": 13, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_LOADING": 14, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_BUFFERED": 15, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_PREPARING": 16, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_APPENDING": 17, + "LOCMSG_SCRIPTEDITOR_REMOVE_SYNTHETIC": 18, + "LOCMSG_SCRIPTEDITOR_PENDING_LINKEDTABLE_FETCHING": 19, + "LOCMSG_SCRIPTEDITOR_RELOAD": 20, + "LOCMSG_SCRIPTEDITOR_LINES_FETCHED": 21 + }, + "QrsChangeType": { + "QRS_CHANGE_UNDEFINED": 0, + "QRS_CHANGE_ADD": 1, + "QRS_CHANGE_UPDATE": 2, + "QRS_CHANGE_DELETE": 3 + }, + "LocalizedErrorCode": { + "LOCERR_INTERNAL_ERROR": -128, + "LOCERR_GENERIC_UNKNOWN": -1, + "LOCERR_GENERIC_OK": 0, + "LOCERR_GENERIC_NOT_SET": 1, + "LOCERR_GENERIC_NOT_FOUND": 2, + "LOCERR_GENERIC_ALREADY_EXISTS": 3, + "LOCERR_GENERIC_INVALID_PATH": 4, + "LOCERR_GENERIC_ACCESS_DENIED": 5, + "LOCERR_GENERIC_OUT_OF_MEMORY": 6, + "LOCERR_GENERIC_NOT_INITIALIZED": 7, + "LOCERR_GENERIC_INVALID_PARAMETERS": 8, + "LOCERR_GENERIC_EMPTY_PARAMETERS": 9, + "LOCERR_GENERIC_INTERNAL_ERROR": 10, + "LOCERR_GENERIC_CORRUPT_DATA": 11, + "LOCERR_GENERIC_MEMORY_INCONSISTENCY": 12, + "LOCERR_GENERIC_INVISIBLE_OWNER_ABORT": 13, + "LOCERR_GENERIC_PROHIBIT_VALIDATE": 14, + "LOCERR_GENERIC_ABORTED": 15, + "LOCERR_GENERIC_CONNECTION_LOST": 16, + "LOCERR_GENERIC_UNSUPPORTED_IN_PRODUCT_VERSION": 17, + "LOCERR_GENERIC_REST_CONNECTION_FAILURE": 18, + "LOCERR_HTTP_400": 400, + "LOCERR_HTTP_401": 401, + "LOCERR_HTTP_402": 402, + "LOCERR_HTTP_403": 403, + "LOCERR_HTTP_404": 404, + "LOCERR_HTTP_405": 405, + "LOCERR_HTTP_406": 406, + "LOCERR_HTTP_407": 407, + "LOCERR_HTTP_408": 408, + "LOCERR_HTTP_409": 409, + "LOCERR_HTTP_410": 410, + "LOCERR_HTTP_411": 411, + "LOCERR_HTTP_412": 412, + "LOCERR_HTTP_413": 413, + "LOCERR_HTTP_414": 414, + "LOCERR_HTTP_415": 415, + "LOCERR_HTTP_416": 416, + "LOCERR_HTTP_417": 417, + "LOCERR_HTTP_500": 500, + "LOCERR_HTTP_501": 501, + "LOCERR_HTTP_502": 502, + "LOCERR_HTTP_503": 503, + "LOCERR_HTTP_504": 504, + "LOCERR_HTTP_505": 505, + "LOCERR_HTTP_509": 509, + "LOCERR_APP_ALREADY_EXISTS": 1000, + "LOCERR_APP_INVALID_NAME": 1001, + "LOCERR_APP_ALREADY_OPEN": 1002, + "LOCERR_APP_NOT_FOUND": 1003, + "LOCERR_APP_IMPORT_FAILED": 1004, + "LOCERR_APP_SAVE_FAILED": 1005, + "LOCERR_APP_CREATE_FAILED": 1006, + "LOCERR_APP_INVALID": 1007, + "LOCERR_APP_CONNECT_FAILED": 1008, + "LOCERR_APP_ALREADY_OPEN_IN_DIFFERENT_MODE": 1009, + "LOCERR_APP_MIGRATION_COULD_NOT_CONTACT_MIGRATION_SERVICE": 1010, + "LOCERR_APP_MIGRATION_COULD_NOT_START_MIGRATION": 1011, + "LOCERR_APP_MIGRATION_FAILURE": 1012, + "LOCERR_CONNECTION_ALREADY_EXISTS": 2000, + "LOCERR_CONNECTION_NOT_FOUND": 2001, + "LOCERR_CONNECTION_FAILED_TO_LOAD": 2002, + "LOCERR_CONNECTION_FAILED_TO_IMPORT": 2003, + "LOCERR_CONNECTION_NAME_IS_INVALID": 2004, + "LOCERR_FILE_ACCESS_DENIED": 3000, + "LOCERR_FILE_NAME_INVALID": 3001, + "LOCERR_FILE_CORRUPT": 3002, + "LOCERR_FILE_NOT_FOUND": 3003, + "LOCERR_FILE_FORMAT_UNSUPPORTED": 3004, + "LOCERR_FILE_OPENED_IN_UNSUPPORTED_MODE": 3005, + "LOCERR_USER_ACCESS_DENIED": 4000, + "LOCERR_USER_IMPERSONATION_FAILED": 4001, + "LOCERR_SERVER_OUT_OF_SESSION_AND_USER_CALS": 5000, + "LOCERR_SERVER_OUT_OF_SESSION_CALS": 5001, + "LOCERR_SERVER_OUT_OF_USAGE_CALS": 5002, + "LOCERR_SERVER_OUT_OF_CALS": 5003, + "LOCERR_SERVER_OUT_OF_NAMED_CALS": 5004, + "LOCERR_SERVER_OFF_DUTY": 5005, + "LOCERR_SERVER_BUSY": 5006, + "LOCERR_SERVER_LICENSE_EXPIRED": 5007, + "LOCERR_SERVER_AJAX_DISABLED": 5008, + "LOCERR_HC_INVALID_OBJECT": 6000, + "LOCERR_HC_RESULT_TOO_LARGE": 6001, + "LOCERR_HC_INVALID_OBJECT_STATE": 6002, + "LOCERR_HC_MODAL_OBJECT_ERROR": 6003, + "LOCERR_CALC_INVALID_DEF": 7000, + "LOCERR_CALC_NOT_IN_LIB": 7001, + "LOCERR_CALC_HEAP_ERROR": 7002, + "LOCERR_CALC_TOO_LARGE": 7003, + "LOCERR_CALC_TIMEOUT": 7004, + "LOCERR_CALC_EVAL_CONDITION_FAILED": 7005, + "LOCERR_CALC_MIXED_LINKED_AGGREGATION": 7006, + "LOCERR_CALC_MISSING_LINKED": 7007, + "LOCERR_CALC_INVALID_COL_SORT": 7008, + "LOCERR_CALC_PAGES_TOO_LARGE": 7009, + "LOCERR_CALC_SEMANTIC_FIELD_NOT_ALLOWED": 7010, + "LOCERR_CALC_VALIDATION_STATE_INVALID": 7011, + "LOCERR_CALC_PIVOT_DIMENSIONS_ALREADY_EXISTS": 7012, + "LOCERR_CALC_MISSING_LINKED_FIELD": 7013, + "LOCERR_LAYOUT_EXTENDS_INVALID_ID": 8000, + "LOCERR_LAYOUT_LINKED_OBJECT_NOT_FOUND": 8001, + "LOCERR_LAYOUT_LINKED_OBJECT_INVALID": 8002, + "LOCERR_PERSISTENCE_WRITE_FAILED": 9000, + "LOCERR_PERSISTENCE_READ_FAILED": 9001, + "LOCERR_PERSISTENCE_DELETE_FAILED": 9002, + "LOCERR_PERSISTENCE_NOT_FOUND": 9003, + "LOCERR_PERSISTENCE_UNSUPPORTED_VERSION": 9004, + "LOCERR_PERSISTENCE_MIGRATION_FAILED_READ_ONLY": 9005, + "LOCERR_PERSISTENCE_MIGRATION_CANCELLED": 9006, + "LOCERR_PERSISTENCE_MIGRATION_BACKUP_FAILED": 9007, + "LOCERR_PERSISTENCE_DISK_FULL": 9008, + "LOCERR_PERSISTENCE_NOT_SUPPORTED_FOR_SESSION_APP": 9009, + "LOCERR_PERSISTENCE_SYNC_SET_CHUNK_INVALID_PARAMETERS": 9510, + "LOCERR_PERSISTENCE_SYNC_GET_CHUNK_INVALID_PARAMETERS": 9511, + "LOCERR_SCRIPT_DATASOURCE_ACCESS_DENIED": 10000, + "LOCERR_RELOAD_IN_PROGRESS": 11000, + "LOCERR_PERSONAL_NEW_VERSION_AVAILABLE": 12000, + "LOCERR_PERSONAL_VERSION_EXPIRED": 12001, + "LOCERR_PERSONAL_SECTION_ACCESS_DETECTED": 12002, + "LOCERR_PERSONAL_APP_DELETION_FAILED": 12003, + "LOCERR_EXPORT_OUT_OF_MEMORY": 13000, + "LOCERR_EXPORT_NO_DATA": 13001, + "LOCERR_SYNC_INVALID_OFFSET": 14000, + "LOCERR_SEARCH_TIMEOUT": 15000, + "LOCERR_DIRECT_DISCOVERY_LINKED_EXPRESSION_FAIL": 16000, + "LOCERR_DIRECT_DISCOVERY_ROWCOUNT_OVERFLOW": 16001, + "LOCERR_DIRECT_DISCOVERY_EMPTY_RESULT": 16002, + "LOCERR_DIRECT_DISCOVERY_DB_CONNECTION_FAILED": 16003, + "LOCERR_DIRECT_DISCOVERY_MEASURE_NOT_ALLOWED": 16004, + "LOCERR_DIRECT_DISCOVERY_DETAIL_NOT_ALLOWED": 16005, + "LOCERR_DIRECT_DISCOVERY_NOT_SYNTH_CIRCULAR_ALLOWED": 16006, + "LOCERR_DIRECT_DISCOVERY_ONLY_ONE_DD_TABLE_ALLOWED": 16007, + "LOCERR_SMART_LOAD_TABLE_NOT_FOUND": 17000, + "LOCERR_SMART_LOAD_TABLE_DUPLICATED": 17001, + "LOCERR_VARIABLE_NO_NAME": 18000, + "LOCERR_VARIABLE_DUPLICATE_NAME": 18001, + "LOCERR_VARIABLE_INCONSISTENCY": 18002, + "LOCERR_MEDIA_LIBRARY_CONTENT_FAILED": 19000, + "LOCERR_MEDIA_LIBRARY_LIST_FAILED": 19001, + "LOCERR_MEDIA_BUNDLING_FAILED": 19002, + "LOCERR_MEDIA_UNBUNDLING_FAILED": 19003, + "LOCERR_MEDIA_LIBRARY_NOT_FOUND": 19004, + "LOCERR_JSON_RPC_INVALID_REQUEST": -32600, + "LOCERR_JSON_RPC_METHOD_NOT_FOUND": -32601, + "LOCERR_JSON_RPC_INVALID_PARAMETERS": -32602, + "LOCERR_JSON_RPC_INTERNAL_ERROR": -32603, + "LOCERR_JSON_RPC_PARSE_ERROR": -32700 + }, + "LocalizedWarningCode": { + "LOCWARN_PERSONAL_RELOAD_REQUIRED": 0, + "LOCWARN_PERSONAL_VERSION_EXPIRES_SOON": 1, + "LOCWARN_EXPORT_DATA_TRUNCATED": 1000, + "LOCWARN_COULD_NOT_OPEN_ALL_OBJECTS": 2000 + }, + "GrpType": { + "GRP_NX_NONE": 0, + "GRP_NX_HIEARCHY": 1, + "GRP_NX_COLLECTION": 2 + }, + "ExportFileType": { + "EXPORT_CSV_C": 0, + "EXPORT_CSV_T": 1, + "EXPORT_OOXML": 2 + }, + "ExportState": { + "EXPORT_POSSIBLE": 0, + "EXPORT_ALL": 1 + }, + "DimCellType": { + "NX_DIM_CELL_VALUE": 0, + "NX_DIM_CELL_EMPTY": 1, + "NX_DIM_CELL_NORMAL": 2, + "NX_DIM_CELL_TOTAL": 3, + "NX_DIM_CELL_OTHER": 4, + "NX_DIM_CELL_AGGR": 5, + "NX_DIM_CELL_PSEUDO": 6, + "NX_DIM_CELL_ROOT": 7, + "NX_DIM_CELL_NULL": 8 + }, + "StackElemType": { + "NX_STACK_CELL_NORMAL": 0, + "NX_STACK_CELL_TOTAL": 1, + "NX_STACK_CELL_OTHER": 2, + "NX_STACK_CELL_SUM": 3, + "NX_STACK_CELL_VALUE": 4, + "NX_STACK_CELL_PSEUDO": 5 + }, + "SortIndicatorType": { + "NX_SORT_INDICATE_NONE": 0, + "NX_SORT_INDICATE_ASC": 1, + "NX_SORT_INDICATE_DESC": 2 + }, + "DimensionType": { + "NX_DIMENSION_TYPE_DISCRETE": 0, + "NX_DIMENSION_TYPE_NUMERIC": 1, + "NX_DIMENSION_TYPE_TIME": 2 + }, + "FieldSelectionMode": { + "SELECTION_MODE_NORMAL": 0, + "SELECTION_MODE_AND": 1, + "SELECTION_MODE_NOT": 2 + }, + "FrequencyMode": { + "NX_FREQUENCY_NONE": 0, + "NX_FREQUENCY_VALUE": 1, + "NX_FREQUENCY_PERCENT": 2, + "NX_FREQUENCY_RELATIVE": 3 + }, + "DataReductionMode": { + "DATA_REDUCTION_NONE": 0, + "DATA_REDUCTION_ONEDIM": 1, + "DATA_REDUCTION_SCATTERED": 2, + "DATA_REDUCTION_CLUSTERED": 3, + "DATA_REDUCTION_STACKED": 4 + }, + "HypercubeMode": { + "DATA_MODE_STRAIGHT": 0, + "DATA_MODE_PIVOT": 1, + "DATA_MODE_PIVOT_STACK": 2 + }, + "PatchOperationType": { + "Add": 0, + "Remove": 1, + "Replace": 2 + }, + "SelectionCellType": { + "NX_CELL_DATA": 0, + "NX_CELL_TOP": 1, + "NX_CELL_LEFT": 2 + }, + "MatchingFieldMode": { + "MATCHINGFIELDMODE_MATCH_ALL": 0, + "MATCHINGFIELDMODE_MATCH_ONE": 1 + } + }, + "version": "2.1" +} diff --git a/jwt-scratch/src/js/node_modules/enigma.js/schemas/2.2.json b/jwt-scratch/src/js/node_modules/enigma.js/schemas/2.2.json new file mode 100644 index 0000000..af131c7 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/enigma.js/schemas/2.2.json @@ -0,0 +1,1533 @@ +{ + "structs": { + "Field":{ + "GetCardinal": { + "In": [], + "Out": [] + }, + "GetAndMode": { + "In": [], + "Out": [] + }, + "SelectValues": { + "In": [{ "Name": "qFieldValues","DefaultValue": [{"qText": "", "qIsNumeric": false, "qNumber": 0}] }, { "Name": "qToggleMode","DefaultValue": false, "Optional": true }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Select": { + "In": [{ "Name": "qMatch","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qExcludedValuesMode","DefaultValue": 0, "Optional": true }], + "Out": [] + }, + "ToggleSelect": { + "In": [{ "Name": "qMatch","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qExcludedValuesMode","DefaultValue": 0, "Optional": true }], + "Out": [] + }, + "ClearAllButThis": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectPossible": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectExcluded": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectAll": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Lock": { + "In": [], + "Out": [] + }, + "Unlock": { + "In": [], + "Out": [] + }, + "GetNxProperties": { + "In": [], + "Out": [{ "Name": "qProperties" }] + }, + "SetNxProperties": { + "In": [{ "Name": "qProperties","DefaultValue": {"qOneAndOnlyOne": false} }], + "Out": [] + }, + "SetAndMode": { + "In": [{ "Name": "qAndMode","DefaultValue": false }], + "Out": [] + }, + "SelectAlternative": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "LowLevelSelect": { + "In": [{ "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Clear": { + "In": [], + "Out": [] + } + }, + "Variable":{ + "GetContent": { + "In": [], + "Out": [{ "Name": "qContent" }] + }, + "GetRawContent": { + "In": [], + "Out": [] + }, + "SetContent": { + "In": [{ "Name": "qContent","DefaultValue": "" }, { "Name": "qUpdateMRU","DefaultValue": false }], + "Out": [] + }, + "ForceContent": { + "In": [{ "Name": "qs","DefaultValue": "" }, { "Name": "qd","DefaultValue": 0 }], + "Out": [] + }, + "GetNxProperties": { + "In": [], + "Out": [{ "Name": "qProperties" }] + }, + "SetNxProperties": { + "In": [{ "Name": "qProperties","DefaultValue": {"qName": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qUsePredefListedValues": false, "qPreDefinedList": [""]} }], + "Out": [] + } + }, + "GenericObject":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "GetListObjectData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeReducedData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qZoomFactor","DefaultValue": 0 }, { "Name": "qReductionMode","DefaultValue": 0 }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubePivotData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeStackData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qMaxNbrCells","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeBinnedData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qViewport","DefaultValue": {"qWidth": 0, "qHeight": 0, "qZoomLevel": 0} }, { "Name": "qDataRanges","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qMaxNbrCells","DefaultValue": 0 }, { "Name": "qQueryLevel","DefaultValue": 0 }, { "Name": "qBinningMethod","DefaultValue": 0 }], + "Out": [{ "Name": "qDataPages" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }, { "Name": "qSoftPatch","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "ClearSoftPatches": { + "In": [], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetEffectiveProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "SetFullPropertyTree": { + "In": [{ "Name": "qPropEntry","DefaultValue": {"qProperty": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}}, "qChildren": [], "qEmbeddedSnapshotRef": null} }], + "Out": [] + }, + "GetFullPropertyTree": { + "In": [], + "Out": [{ "Name": "qPropEntry" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "ClearSelections": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "ExportData": { + "In": [{ "Name": "qFileType","DefaultValue": 0 }, { "Name": "qPath","DefaultValue": "", "Optional": true }, { "Name": "qFileName","DefaultValue": "", "Optional": true }, { "Name": "qExportState","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qUrl" }] + }, + "SelectListObjectValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectPossible": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectExcluded": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectAlternative": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectAll": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SearchListObjectFor": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qMatch","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "AbortListObjectSearch": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [] + }, + "AcceptListObjectSearch": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "ExpandLeft": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "ExpandTop": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "CollapseLeft": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "CollapseTop": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "DrillUp": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qDimNo","DefaultValue": 0 }, { "Name": "qNbrSteps","DefaultValue": 0 }], + "Out": [] + }, + "Lock": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "Unlock": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "SelectHyperCubeValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qDimNo","DefaultValue": 0 }, { "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectHyperCubeCells": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRowIndices","DefaultValue": [0] }, { "Name": "qColIndices","DefaultValue": [0] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectPivotCells": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSelections","DefaultValue": [{"qType": 0, "qCol": 0, "qRow": 0}] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "RangeSelectHyperCubeValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qRange": {"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}, "qMeasureIx": 0}] }, { "Name": "qColumnsToSelect","DefaultValue": [0], "Optional": true }, { "Name": "qOrMode","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetChild": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetChildInfos": { + "In": [], + "Out": [{ "Name": "qInfos" }] + }, + "CreateChild": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }, { "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyChild": { + "In": [{ "Name": "qId","DefaultValue": "" }, { "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "DestroyAllChildren": { + "In": [{ "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [] + }, + "SetChildArrayOrder": { + "In": [{ "Name": "qIds","DefaultValue": [""] }], + "Out": [] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "CopyFrom": { + "In": [{ "Name": "qFromId","DefaultValue": "" }], + "Out": [] + }, + "BeginSelections": { + "In": [{ "Name": "qPaths","DefaultValue": [""] }], + "Out": [] + }, + "EndSelections": { + "In": [{ "Name": "qAccept","DefaultValue": false }], + "Out": [] + }, + "ResetMadeSelections": { + "In": [], + "Out": [] + }, + "EmbedSnapshotObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetSnapshotObject": { + "In": [], + "Out": [] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericDimension":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDim": {"qGrouping": 0, "qFieldDefs": [""], "qFieldLabels": [""]}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetDimension": { + "In": [], + "Out": [{ "Name": "qDim" }] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericBookmark":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "Apply": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericVariable":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "SetStringValue": { + "In": [{ "Name": "qVal","DefaultValue": "" }], + "Out": [] + }, + "SetNumValue": { + "In": [{ "Name": "qVal","DefaultValue": 0 }], + "Out": [] + }, + "SetDualValue": { + "In": [{ "Name": "qText","DefaultValue": "" }, { "Name": "qNum","DefaultValue": 0 }], + "Out": [] + } + }, + "GenericMeasure":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMeasure": {"qLabel": "", "qDef": "", "qGrouping": 0, "qExpressions": [""], "qActiveExpression": 0}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetMeasure": { + "In": [], + "Out": [{ "Name": "qMeasure" }] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericDerivedDefinition":{ + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDerivedDefinition": {"qName": "", "qTags": [""], "qParameters": [{"qName": "", "qValue": ""}], "qFieldDefs": [{"qName": "", "qExpression": "", "qTags": [""]}], "qGroupDefs": [{"qName": "", "qGrouping": 0, "qFieldDerivedDefinitionNames": [""]}]}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "MatchTags": { + "In": [{ "Name": "qTags","DefaultValue": [""] }], + "Out": [] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetDerivedDefinitionData": { + "In": [], + "Out": [{ "Name": "qData" }] + }, + "GetExpression": { + "In": [{ "Name": "qExpressionName","DefaultValue": "" }, { "Name": "qParameters","DefaultValue": [""] }], + "Out": [] + } + }, + "GenericDerivedFields":{ + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDerivedDefinitionId": "", "qFieldName": [""], "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetDerivedFieldData": { + "In": [], + "Out": [{ "Name": "qData" }] + }, + "GetDerivedField": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qFields" }] + }, + "GetListData": { + "In": [], + "Out": [{ "Name": "qListData" }] + }, + "GetDerivedFields": { + "In": [], + "Out": [{ "Name": "qFields" }] + }, + "GetDerivedGroups": { + "In": [], + "Out": [{ "Name": "qGroups" }] + } + }, + "InternalTest":{ + "Initialised": { + "In": [], + "Out": [] + }, + "TestMemoryManagement": { + "In": [], + "Out": [] + }, + "TestNextFileFormat": { + "In": [], + "Out": [] + }, + "BombQRS": { + "In": [], + "Out": [] + }, + "BombQRSParallel": { + "In": [{ "Name": "qNThreads","DefaultValue": 0 }], + "Out": [] + }, + "TestLogging": { + "In": [{ "Name": "qLogger","DefaultValue": "" }, { "Name": "qVerbosity","DefaultValue": 0 }, { "Name": "qSteps","DefaultValue": 0, "Optional": true }], + "Out": [] + }, + "TestRepositoryLogging": { + "In": [{ "Name": "qLogger","DefaultValue": "" }, { "Name": "qVerbosity","DefaultValue": 0 }, { "Name": "qMessage","DefaultValue": "" }], + "Out": [] + }, + "GetQixCounters": { + "In": [], + "Out": [{ "Name": "qCounters" }] + }, + "ResetQixCounters": { + "In": [], + "Out": [] + } + }, + "Doc":{ + "GetProperties": { + "In": [], + "Out": [] + }, + "GetField": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }, { "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "GetFieldDescription": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }], + "Out": [] + }, + "GetVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "GetLooselyCoupledVector": { + "In": [], + "Out": [{ "Name": "qv" }] + }, + "SetLooselyCoupledVector": { + "In": [{ "Name": "qv","DefaultValue": [0] }], + "Out": [] + }, + "Evaluate": { + "In": [{ "Name": "qExpression","DefaultValue": "" }], + "Out": [] + }, + "EvaluateEx": { + "In": [{ "Name": "qExpression","DefaultValue": "" }], + "Out": [{ "Name": "qValue" }] + }, + "ClearAll": { + "In": [{ "Name": "qLockedAlso","DefaultValue": false, "Optional": true }, { "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "LockAll": { + "In": [{ "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "UnlockAll": { + "In": [{ "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "Back": { + "In": [], + "Out": [] + }, + "Forward": { + "In": [], + "Out": [] + }, + "ReduceData": { + "In": [{ "Name": "qConfirm","DefaultValue": false, "Optional": true }, { "Name": "qDropFieldNames","DefaultValue": [""], "Optional": true }], + "Out": [] + }, + "RemoveAllData": { + "In": [{ "Name": "qConfirm","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "CreateVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "RemoveVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "GetLocaleInfo": { + "In": [], + "Out": [] + }, + "GetTablesAndKeys": { + "In": [{ "Name": "qWindowSize","DefaultValue": {"qcx": 0, "qcy": 0} }, { "Name": "qNullSize","DefaultValue": {"qcx": 0, "qcy": 0} }, { "Name": "qCellHeight","DefaultValue": 0 }, { "Name": "qSyntheticMode","DefaultValue": false }, { "Name": "qIncludeSysVars","DefaultValue": false }], + "Out": [{ "Name": "qtr" }, { "Name": "qk" }] + }, + "GetViewDlgSaveInfo": { + "In": [], + "Out": [] + }, + "SetViewDlgSaveInfo": { + "In": [{ "Name": "qInfo","DefaultValue": {"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCtlInfo": {"qInternalView": {"qTables": [{"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCaption": ""}], "qBroomPoints": [{"qPos": {"qx": 0, "qy": 0}, "qTable": "", "qFields": [""]}], "qConnectionPoints": [{"qPos": {"qx": 0, "qy": 0}, "qFields": [""]}], "qZoomFactor": 0}, "qSourceView": {"qTables": [{"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCaption": ""}], "qBroomPoints": [{"qPos": {"qx": 0, "qy": 0}, "qTable": "", "qFields": [""]}], "qConnectionPoints": [{"qPos": {"qx": 0, "qy": 0}, "qFields": [""]}], "qZoomFactor": 0}}, "qMode": 0} }], + "Out": [] + }, + "GetEmptyScript": { + "In": [{ "Name": "qLocalizedMainSection","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "DoReload": { + "In": [{ "Name": "qMode","DefaultValue": 0, "Optional": true }, { "Name": "qPartial","DefaultValue": false, "Optional": true }, { "Name": "qDebug","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "GetScriptBreakpoints": { + "In": [], + "Out": [{ "Name": "qBreakpoints" }] + }, + "SetScriptBreakpoints": { + "In": [{ "Name": "qBreakpoints","DefaultValue": [{"qbufferName": "", "qlineIx": 0, "qEnabled": false}] }], + "Out": [] + }, + "GetScript": { + "In": [], + "Out": [{ "Name": "qScript" }] + }, + "GetTextMacros": { + "In": [], + "Out": [{ "Name": "qMacros" }] + }, + "SetFetchLimit": { + "In": [{ "Name": "qLimit","DefaultValue": 0 }], + "Out": [] + }, + "DoSave": { + "In": [{ "Name": "qFileName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "GetTableData": { + "In": [{ "Name": "qOffset","DefaultValue": 0 }, { "Name": "qRows","DefaultValue": 0 }, { "Name": "qSyntheticMode","DefaultValue": false }, { "Name": "qTableName","DefaultValue": "" }], + "Out": [{ "Name": "qData" }] + }, + "GetAppLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "SetAppProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qTitle": "", "qLastReloadTime": "", "qMigrationHash": "", "qSavedInProductVersion": "", "qThumbnail": {"qUrl": ""}} }], + "Out": [] + }, + "GetAppProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "CreateSessionObject": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }], + "Out": [] + }, + "DestroySessionObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CreateObject": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "CloneObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qDraftId" }] + }, + "CommitDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "DestroyDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }, { "Name": "qSourceId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "Undo": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "Redo": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "ClearUndoBuffer": { + "In": [], + "Out": [] + }, + "CreateDimension": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDim": {"qGrouping": 0, "qFieldDefs": [""], "qFieldLabels": [""]}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "CloneDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateMeasure": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMeasure": {"qLabel": "", "qDef": "", "qGrouping": 0, "qExpressions": [""], "qActiveExpression": 0}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "CloneMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateSessionVariable": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [] + }, + "DestroySessionVariable": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CreateVariableEx": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyVariableById": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "DestroyVariableByName": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetVariableById": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetVariableByName": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "MigrateVariables": { + "In": [], + "Out": [] + }, + "CreateDerivedDefinition": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDerivedDefinition": {"qName": "", "qTags": [""], "qParameters": [{"qName": "", "qValue": ""}], "qFieldDefs": [{"qName": "", "qExpression": "", "qTags": [""]}], "qGroupDefs": [{"qName": "", "qGrouping": 0, "qFieldDerivedDefinitionNames": [""]}]}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyDerivedDefinition": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetDerivedDefinition": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetDerivedDefinitionByName": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "CloneDerivedDefinition": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "GetDerivedDefinitionsForTags": { + "In": [{ "Name": "qTags","DefaultValue": [""] }], + "Out": [{ "Name": "qInstanceName" }] + }, + "AssignDerivedFieldFor": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }, { "Name": "qDerivedDefinitionNames","DefaultValue": [""] }], + "Out": [] + }, + "CreateDerivedFields": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDerivedDefinitionId": "", "qFieldName": [""], "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyDerivedFields": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetDerivedFields": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetAllDerivedFields_INTERNAL": { + "In": [], + "Out": [{ "Name": "qDerivedFields" }] + }, + "GetDerivedFieldDimensionDef": { + "In": [{ "Name": "qLibraryId","DefaultValue": "" }], + "Out": [{ "Name": "qDimensionDef" }] + }, + "GetDerivedFieldFor": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }, { "Name": "qGetDerivedDefinitionsForTags","DefaultValue": "" }], + "Out": [] + }, + "GetAllDerivedFieldsFor": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }], + "Out": [{ "Name": "qDerivedFields" }] + }, + "MigrateDerivedFields": { + "In": [], + "Out": [] + }, + "CheckExpression": { + "In": [{ "Name": "qExpr","DefaultValue": "" }, { "Name": "qLabels","DefaultValue": [""], "Optional": true }], + "Out": [{ "Name": "qErrorMsg" }, { "Name": "qBadFieldNames" }, { "Name": "qDangerousFieldNames" }] + }, + "CheckNumberOrExpression": { + "In": [{ "Name": "qExpr","DefaultValue": "" }], + "Out": [{ "Name": "qErrorMsg" }, { "Name": "qBadFieldNames" }] + }, + "AddAlternateState": { + "In": [{ "Name": "qStateName","DefaultValue": "" }], + "Out": [] + }, + "RemoveAlternateState": { + "In": [{ "Name": "qStateName","DefaultValue": "" }], + "Out": [] + }, + "CreateBookmark": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "ApplyBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CloneBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "AddFieldFromExpression": { + "In": [{ "Name": "qName","DefaultValue": "" }, { "Name": "qExpr","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetAllInfos": { + "In": [], + "Out": [{ "Name": "qInfos" }] + }, + "Resume": { + "In": [], + "Out": [] + }, + "AbortModal": { + "In": [{ "Name": "qAccept","DefaultValue": false }], + "Out": [] + }, + "Publish": { + "In": [{ "Name": "qStreamId","DefaultValue": "" }, { "Name": "qName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + }, + "GetMatchingFields": { + "In": [{ "Name": "qTags","DefaultValue": [""] }, { "Name": "qMatchingFieldMode","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qFieldNames" }] + }, + "FindMatchingFields": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }, { "Name": "qTags","DefaultValue": [""] }], + "Out": [{ "Name": "qFieldNames" }] + }, + "SaveObjects": { + "In": [], + "Out": [] + }, + "GetAssociationScores": { + "In": [{ "Name": "qTable1","DefaultValue": "" }, { "Name": "qTable2","DefaultValue": "" }], + "Out": [{ "Name": "qScore" }] + }, + "GetMediaList": { + "In": [], + "Out": [{ "Name": "qList" }] + }, + "GetContentLibraries": { + "In": [], + "Out": [{ "Name": "qList" }] + }, + "GetLibraryContent": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [{ "Name": "qList" }] + }, + "DoReloadEx": { + "In": [{ "Name": "qParams","DefaultValue": {"qMode": 0, "qPartial": false, "qDebug": false}, "Optional": true }], + "Out": [{ "Name": "qResult" }] + }, + "BackCount": { + "In": [], + "Out": [] + }, + "ForwardCount": { + "In": [], + "Out": [] + }, + "SetScript": { + "In": [{ "Name": "qScript","DefaultValue": "" }], + "Out": [] + }, + "CheckScriptSyntax": { + "In": [], + "Out": [{ "Name": "qErrors" }] + }, + "GetFavoriteVariables": { + "In": [], + "Out": [{ "Name": "qNames" }] + }, + "SetFavoriteVariables": { + "In": [{ "Name": "qNames","DefaultValue": [""] }], + "Out": [] + }, + "GetIncludeFileContent": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [{ "Name": "qContent" }] + }, + "CreateConnection": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}} }], + "Out": [{ "Name": "qConnectionId" }] + }, + "ModifyConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}} }, { "Name": "qOverrideCredentials","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "DeleteConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [] + }, + "GetConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qConnection" }] + }, + "GetConnections": { + "In": [], + "Out": [{ "Name": "qConnections" }] + }, + "GetDatabaseInfo": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qInfo" }] + }, + "GetDatabases": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qDatabases" }] + }, + "GetDatabaseOwners": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qOwners" }] + }, + "GetDatabaseTables": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qTables" }] + }, + "GetDatabaseTableFields": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qFields" }] + }, + "GetDatabaseTablePreview": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qPreview" }] + }, + "GetFolderItemsForConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qFolderItems" }] + }, + "GuessFileType": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qDataFormat" }] + }, + "GetFileTables": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }], + "Out": [{ "Name": "qTables" }] + }, + "GetFileTableFields": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qFields" }, { "Name": "qFormatSpec" }] + }, + "GetFileTablePreview": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qPreview" }, { "Name": "qFormatSpec" }] + }, + "GetFileTablesEx": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }], + "Out": [{ "Name": "qTables" }] + }, + "SendGenericCommandToCustomConnector": { + "In": [{ "Name": "qProvider","DefaultValue": "" }, { "Name": "qCommand","DefaultValue": "" }, { "Name": "qMethod","DefaultValue": "" }, { "Name": "qParameters","DefaultValue": [""] }, { "Name": "qAppendConnection","DefaultValue": "" }], + "Out": [{ "Name": "qResult" }] + }, + "SearchSuggest": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0} }, { "Name": "qTerms","DefaultValue": [""] }], + "Out": [{ "Name": "qResult" }] + }, + "SearchAssociations": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qPage","DefaultValue": {"qOffset": 0, "qCount": 0, "qMaxNbrFieldMatches": 0, "qGroupOptions": [{"qGroupType": 0, "qOffset": 0, "qCount": 0}], "qGroupItemOptions": [{"qGroupItemType": 0, "qOffset": 0, "qCount": 0}]} }], + "Out": [{ "Name": "qResults" }] + }, + "SelectAssociations": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qMatchIx","DefaultValue": 0 }, { "Name": "qSoftLock","DefaultValue": null, "Optional": true }], + "Out": [] + }, + "SearchResults": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qPage","DefaultValue": {"qOffset": 0, "qCount": 0, "qMaxNbrFieldMatches": 0, "qGroupOptions": [{"qGroupType": 0, "qOffset": 0, "qCount": 0}], "qGroupItemOptions": [{"qGroupItemType": 0, "qOffset": 0, "qCount": 0}]} }], + "Out": [{ "Name": "qResult" }] + } + }, + "Global":{ + "AbortRequest": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [] + }, + "AbortAll": { + "In": [], + "Out": [] + }, + "GetProgress": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [{ "Name": "qProgressData" }] + }, + "QvVersion": { + "In": [], + "Out": [] + }, + "OSVersion": { + "In": [], + "Out": [] + }, + "OSName": { + "In": [], + "Out": [] + }, + "QTProduct": { + "In": [], + "Out": [] + }, + "GetDocList": { + "In": [], + "Out": [{ "Name": "qDocList" }] + }, + "GetInteract": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [{ "Name": "qDef" }] + }, + "InteractDone": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }, { "Name": "qDef","DefaultValue": {"qType": 0, "qTitle": "", "qMsg": "", "qButtons": 0, "qLine": "", "qOldLineNr": 0, "qNewLineNr": 0, "qPath": "", "qHidden": false, "qResult": 0, "qInput": ""} }], + "Out": [] + }, + "GetAuthenticatedUser": { + "In": [], + "Out": [] + }, + "GetStreamList": { + "In": [], + "Out": [{ "Name": "qStreamList" }] + }, + "CreateDocEx": { + "In": [{ "Name": "qDocName","DefaultValue": "" }, { "Name": "qUserName","DefaultValue": "", "Optional": true }, { "Name": "qPassword","DefaultValue": "", "Optional": true }, { "Name": "qSerial","DefaultValue": "", "Optional": true }, { "Name": "qLocalizedScriptMainSection","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qDocId" }] + }, + "GetActiveDoc": { + "In": [], + "Out": [] + }, + "AllowCreateApp": { + "In": [], + "Out": [] + }, + "CreateApp": { + "In": [{ "Name": "qAppName","DefaultValue": "" }, { "Name": "qLocalizedScriptMainSection","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qSuccess" }, { "Name": "qAppId" }] + }, + "DeleteApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "IsDesktopMode": { + "In": [], + "Out": [] + }, + "GetConfiguration": { + "In": [], + "Out": [{ "Name": "qConfig" }] + }, + "CancelRequest": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [] + }, + "GetInternalTest": { + "In": [{ "Name": "qKey","DefaultValue": "" }], + "Out": [] + }, + "ShutdownProcess": { + "In": [], + "Out": [] + }, + "ReloadExtensionList": { + "In": [], + "Out": [] + }, + "ReplaceAppFromID": { + "In": [{ "Name": "qTargetAppId","DefaultValue": "" }, { "Name": "qSrcAppID","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "CopyApp": { + "In": [{ "Name": "qTargetAppId","DefaultValue": "" }, { "Name": "qSrcAppId","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "ImportApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qSrcPath","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "ImportAppEx": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qSrcPath","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }, { "Name": "qExcludeConnections","DefaultValue": false }], + "Out": [] + }, + "ExportApp": { + "In": [{ "Name": "qTargetPath","DefaultValue": "" }, { "Name": "qSrcAppId","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "PublishApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qStreamId","DefaultValue": "" }, { "Name": "qCopy","DefaultValue": false }, { "Name": "qReplaceId","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "IsPersonalMode": { + "In": [], + "Out": [] + }, + "GetUniqueID": { + "In": [], + "Out": [{ "Name": "qUniqueID" }] + }, + "OpenDoc": { + "In": [{ "Name": "qDocName","DefaultValue": "" }, { "Name": "qUserName","DefaultValue": "", "Optional": true }, { "Name": "qPassword","DefaultValue": "", "Optional": true }, { "Name": "qSerial","DefaultValue": "", "Optional": true }, { "Name": "qNoData","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "CreateSessionApp": { + "In": [], + "Out": [{ "Name": "qSessionAppId" }] + }, + "CreateSessionAppFromApp": { + "In": [{ "Name": "qSrcAppId","DefaultValue": "" }], + "Out": [{ "Name": "qSessionAppId" }] + }, + "ProductVersion": { + "In": [], + "Out": [] + }, + "GetAppEntry": { + "In": [{ "Name": "qAppID","DefaultValue": "" }], + "Out": [{ "Name": "qEntry" }] + }, + "ConfigureReload": { + "In": [{ "Name": "qCancelOnScriptError","DefaultValue": false }, { "Name": "qUseErrorData","DefaultValue": false }, { "Name": "qInteractOnError","DefaultValue": false }], + "Out": [] + }, + "CancelReload": { + "In": [], + "Out": [] + }, + "GetBNF": { + "In": [{ "Name": "qBnfType","DefaultValue": 0 }], + "Out": [{ "Name": "qBnfDefs" }] + }, + "GetFunctions": { + "In": [{ "Name": "qGroup","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qFunctions" }] + }, + "GetOdbcDsns": { + "In": [], + "Out": [{ "Name": "qOdbcDsns" }] + }, + "GetOleDbProviders": { + "In": [], + "Out": [{ "Name": "qOleDbProviders" }] + }, + "GetDatabasesFromConnectionString": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}} }], + "Out": [{ "Name": "qDatabases" }] + }, + "IsValidConnectionString": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}} }], + "Out": [] + }, + "GetDefaultAppFolder": { + "In": [], + "Out": [{ "Name": "qPath" }] + }, + "GetMyDocumentsFolder": { + "In": [], + "Out": [{ "Name": "qFolder" }] + }, + "GetLogicalDriveStrings": { + "In": [], + "Out": [{ "Name": "qDrives" }] + }, + "GetFolderItemsForPath": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [{ "Name": "qFolderItems" }] + }, + "GetSupportedCodePages": { + "In": [], + "Out": [{ "Name": "qCodePages" }] + }, + "GetCustomConnectors": { + "In": [{ "Name": "qReloadList","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qConnectors" }] + } + } + }, + "enums": { + "LocalizedMessageCode": { + "LOCMSG_SCRIPTEDITOR_EMPTY_MESSAGE": 0, + "LOCMSG_SCRIPTEDITOR_PROGRESS_SAVING_STARTED": 1, + "LOCMSG_SCRIPTEDITOR_PROGRESS_BYTES_LEFT": 2, + "LOCMSG_SCRIPTEDITOR_PROGRESS_STORING_TABLES": 3, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_ROWS_SO_FAR": 4, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECTED": 5, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECTING_TO": 6, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECT_FAILED": 7, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_ROWISH": 8, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_COLUMNAR": 9, + "LOCMSG_SCRIPTEDITOR_ERROR": 10, + "LOCMSG_SCRIPTEDITOR_DONE": 11, + "LOCMSG_SCRIPTEDITOR_LOAD_EXTERNAL_DATA": 12, + "LOCMSG_SCRIPTEDITOR_PROGRESS_OLD_QVD_ISLOADING": 13, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_LOADING": 14, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_BUFFERED": 15, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_PREPARING": 16, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_APPENDING": 17, + "LOCMSG_SCRIPTEDITOR_REMOVE_SYNTHETIC": 18, + "LOCMSG_SCRIPTEDITOR_PENDING_LINKEDTABLE_FETCHING": 19, + "LOCMSG_SCRIPTEDITOR_RELOAD": 20, + "LOCMSG_SCRIPTEDITOR_LINES_FETCHED": 21 + }, + "QrsChangeType": { + "QRS_CHANGE_UNDEFINED": 0, + "QRS_CHANGE_ADD": 1, + "QRS_CHANGE_UPDATE": 2, + "QRS_CHANGE_DELETE": 3 + }, + "LocalizedErrorCode": { + "LOCERR_INTERNAL_ERROR": -128, + "LOCERR_GENERIC_UNKNOWN": -1, + "LOCERR_GENERIC_OK": 0, + "LOCERR_GENERIC_NOT_SET": 1, + "LOCERR_GENERIC_NOT_FOUND": 2, + "LOCERR_GENERIC_ALREADY_EXISTS": 3, + "LOCERR_GENERIC_INVALID_PATH": 4, + "LOCERR_GENERIC_ACCESS_DENIED": 5, + "LOCERR_GENERIC_OUT_OF_MEMORY": 6, + "LOCERR_GENERIC_NOT_INITIALIZED": 7, + "LOCERR_GENERIC_INVALID_PARAMETERS": 8, + "LOCERR_GENERIC_EMPTY_PARAMETERS": 9, + "LOCERR_GENERIC_INTERNAL_ERROR": 10, + "LOCERR_GENERIC_CORRUPT_DATA": 11, + "LOCERR_GENERIC_MEMORY_INCONSISTENCY": 12, + "LOCERR_GENERIC_INVISIBLE_OWNER_ABORT": 13, + "LOCERR_GENERIC_PROHIBIT_VALIDATE": 14, + "LOCERR_GENERIC_ABORTED": 15, + "LOCERR_GENERIC_CONNECTION_LOST": 16, + "LOCERR_GENERIC_UNSUPPORTED_IN_PRODUCT_VERSION": 17, + "LOCERR_GENERIC_REST_CONNECTION_FAILURE": 18, + "LOCERR_HTTP_400": 400, + "LOCERR_HTTP_401": 401, + "LOCERR_HTTP_402": 402, + "LOCERR_HTTP_403": 403, + "LOCERR_HTTP_404": 404, + "LOCERR_HTTP_405": 405, + "LOCERR_HTTP_406": 406, + "LOCERR_HTTP_407": 407, + "LOCERR_HTTP_408": 408, + "LOCERR_HTTP_409": 409, + "LOCERR_HTTP_410": 410, + "LOCERR_HTTP_411": 411, + "LOCERR_HTTP_412": 412, + "LOCERR_HTTP_413": 413, + "LOCERR_HTTP_414": 414, + "LOCERR_HTTP_415": 415, + "LOCERR_HTTP_416": 416, + "LOCERR_HTTP_417": 417, + "LOCERR_HTTP_500": 500, + "LOCERR_HTTP_501": 501, + "LOCERR_HTTP_502": 502, + "LOCERR_HTTP_503": 503, + "LOCERR_HTTP_504": 504, + "LOCERR_HTTP_505": 505, + "LOCERR_HTTP_509": 509, + "LOCERR_APP_ALREADY_EXISTS": 1000, + "LOCERR_APP_INVALID_NAME": 1001, + "LOCERR_APP_ALREADY_OPEN": 1002, + "LOCERR_APP_NOT_FOUND": 1003, + "LOCERR_APP_IMPORT_FAILED": 1004, + "LOCERR_APP_SAVE_FAILED": 1005, + "LOCERR_APP_CREATE_FAILED": 1006, + "LOCERR_APP_INVALID": 1007, + "LOCERR_APP_CONNECT_FAILED": 1008, + "LOCERR_APP_ALREADY_OPEN_IN_DIFFERENT_MODE": 1009, + "LOCERR_APP_MIGRATION_COULD_NOT_CONTACT_MIGRATION_SERVICE": 1010, + "LOCERR_APP_MIGRATION_COULD_NOT_START_MIGRATION": 1011, + "LOCERR_APP_MIGRATION_FAILURE": 1012, + "LOCERR_APP_SCRIPT_MISSING": 1013, + "LOCERR_CONNECTION_ALREADY_EXISTS": 2000, + "LOCERR_CONNECTION_NOT_FOUND": 2001, + "LOCERR_CONNECTION_FAILED_TO_LOAD": 2002, + "LOCERR_CONNECTION_FAILED_TO_IMPORT": 2003, + "LOCERR_CONNECTION_NAME_IS_INVALID": 2004, + "LOCERR_FILE_ACCESS_DENIED": 3000, + "LOCERR_FILE_NAME_INVALID": 3001, + "LOCERR_FILE_CORRUPT": 3002, + "LOCERR_FILE_NOT_FOUND": 3003, + "LOCERR_FILE_FORMAT_UNSUPPORTED": 3004, + "LOCERR_FILE_OPENED_IN_UNSUPPORTED_MODE": 3005, + "LOCERR_USER_ACCESS_DENIED": 4000, + "LOCERR_USER_IMPERSONATION_FAILED": 4001, + "LOCERR_SERVER_OUT_OF_SESSION_AND_USER_CALS": 5000, + "LOCERR_SERVER_OUT_OF_SESSION_CALS": 5001, + "LOCERR_SERVER_OUT_OF_USAGE_CALS": 5002, + "LOCERR_SERVER_OUT_OF_CALS": 5003, + "LOCERR_SERVER_OUT_OF_NAMED_CALS": 5004, + "LOCERR_SERVER_OFF_DUTY": 5005, + "LOCERR_SERVER_BUSY": 5006, + "LOCERR_SERVER_LICENSE_EXPIRED": 5007, + "LOCERR_SERVER_AJAX_DISABLED": 5008, + "LOCERR_HC_INVALID_OBJECT": 6000, + "LOCERR_HC_RESULT_TOO_LARGE": 6001, + "LOCERR_HC_INVALID_OBJECT_STATE": 6002, + "LOCERR_HC_MODAL_OBJECT_ERROR": 6003, + "LOCERR_CALC_INVALID_DEF": 7000, + "LOCERR_CALC_NOT_IN_LIB": 7001, + "LOCERR_CALC_HEAP_ERROR": 7002, + "LOCERR_CALC_TOO_LARGE": 7003, + "LOCERR_CALC_TIMEOUT": 7004, + "LOCERR_CALC_EVAL_CONDITION_FAILED": 7005, + "LOCERR_CALC_MIXED_LINKED_AGGREGATION": 7006, + "LOCERR_CALC_MISSING_LINKED": 7007, + "LOCERR_CALC_INVALID_COL_SORT": 7008, + "LOCERR_CALC_PAGES_TOO_LARGE": 7009, + "LOCERR_CALC_SEMANTIC_FIELD_NOT_ALLOWED": 7010, + "LOCERR_CALC_VALIDATION_STATE_INVALID": 7011, + "LOCERR_CALC_PIVOT_DIMENSIONS_ALREADY_EXISTS": 7012, + "LOCERR_CALC_MISSING_LINKED_FIELD": 7013, + "LOCERR_LAYOUT_EXTENDS_INVALID_ID": 8000, + "LOCERR_LAYOUT_LINKED_OBJECT_NOT_FOUND": 8001, + "LOCERR_LAYOUT_LINKED_OBJECT_INVALID": 8002, + "LOCERR_PERSISTENCE_WRITE_FAILED": 9000, + "LOCERR_PERSISTENCE_READ_FAILED": 9001, + "LOCERR_PERSISTENCE_DELETE_FAILED": 9002, + "LOCERR_PERSISTENCE_NOT_FOUND": 9003, + "LOCERR_PERSISTENCE_UNSUPPORTED_VERSION": 9004, + "LOCERR_PERSISTENCE_MIGRATION_FAILED_READ_ONLY": 9005, + "LOCERR_PERSISTENCE_MIGRATION_CANCELLED": 9006, + "LOCERR_PERSISTENCE_MIGRATION_BACKUP_FAILED": 9007, + "LOCERR_PERSISTENCE_DISK_FULL": 9008, + "LOCERR_PERSISTENCE_NOT_SUPPORTED_FOR_SESSION_APP": 9009, + "LOCERR_PERSISTENCE_SYNC_SET_CHUNK_INVALID_PARAMETERS": 9510, + "LOCERR_PERSISTENCE_SYNC_GET_CHUNK_INVALID_PARAMETERS": 9511, + "LOCERR_SCRIPT_DATASOURCE_ACCESS_DENIED": 10000, + "LOCERR_RELOAD_IN_PROGRESS": 11000, + "LOCERR_PERSONAL_NEW_VERSION_AVAILABLE": 12000, + "LOCERR_PERSONAL_VERSION_EXPIRED": 12001, + "LOCERR_PERSONAL_SECTION_ACCESS_DETECTED": 12002, + "LOCERR_PERSONAL_APP_DELETION_FAILED": 12003, + "LOCERR_EXPORT_OUT_OF_MEMORY": 13000, + "LOCERR_EXPORT_NO_DATA": 13001, + "LOCERR_SYNC_INVALID_OFFSET": 14000, + "LOCERR_SEARCH_TIMEOUT": 15000, + "LOCERR_DIRECT_DISCOVERY_LINKED_EXPRESSION_FAIL": 16000, + "LOCERR_DIRECT_DISCOVERY_ROWCOUNT_OVERFLOW": 16001, + "LOCERR_DIRECT_DISCOVERY_EMPTY_RESULT": 16002, + "LOCERR_DIRECT_DISCOVERY_DB_CONNECTION_FAILED": 16003, + "LOCERR_DIRECT_DISCOVERY_MEASURE_NOT_ALLOWED": 16004, + "LOCERR_DIRECT_DISCOVERY_DETAIL_NOT_ALLOWED": 16005, + "LOCERR_DIRECT_DISCOVERY_NOT_SYNTH_CIRCULAR_ALLOWED": 16006, + "LOCERR_DIRECT_DISCOVERY_ONLY_ONE_DD_TABLE_ALLOWED": 16007, + "LOCERR_SMART_LOAD_TABLE_NOT_FOUND": 17000, + "LOCERR_SMART_LOAD_TABLE_DUPLICATED": 17001, + "LOCERR_VARIABLE_NO_NAME": 18000, + "LOCERR_VARIABLE_DUPLICATE_NAME": 18001, + "LOCERR_VARIABLE_INCONSISTENCY": 18002, + "LOCERR_MEDIA_LIBRARY_LIST_FAILED": 19000, + "LOCERR_MEDIA_LIBRARY_CONTENT_FAILED": 19001, + "LOCERR_MEDIA_BUNDLING_FAILED": 19002, + "LOCERR_MEDIA_UNBUNDLING_FAILED": 19003, + "LOCERR_MEDIA_LIBRARY_NOT_FOUND": 19004, + "LOCERR_JSON_RPC_INVALID_REQUEST": -32600, + "LOCERR_JSON_RPC_METHOD_NOT_FOUND": -32601, + "LOCERR_JSON_RPC_INVALID_PARAMETERS": -32602, + "LOCERR_JSON_RPC_INTERNAL_ERROR": -32603, + "LOCERR_JSON_RPC_PARSE_ERROR": -32700 + }, + "LocalizedWarningCode": { + "LOCWARN_PERSONAL_RELOAD_REQUIRED": 0, + "LOCWARN_PERSONAL_VERSION_EXPIRES_SOON": 1, + "LOCWARN_EXPORT_DATA_TRUNCATED": 1000, + "LOCWARN_COULD_NOT_OPEN_ALL_OBJECTS": 2000 + }, + "GrpType": { + "GRP_NX_NONE": 0, + "GRP_NX_HIEARCHY": 1, + "GRP_NX_COLLECTION": 2 + }, + "ExportFileType": { + "EXPORT_CSV_C": 0, + "EXPORT_CSV_T": 1, + "EXPORT_OOXML": 2 + }, + "ExportState": { + "EXPORT_POSSIBLE": 0, + "EXPORT_ALL": 1 + }, + "DimCellType": { + "NX_DIM_CELL_VALUE": 0, + "NX_DIM_CELL_EMPTY": 1, + "NX_DIM_CELL_NORMAL": 2, + "NX_DIM_CELL_TOTAL": 3, + "NX_DIM_CELL_OTHER": 4, + "NX_DIM_CELL_AGGR": 5, + "NX_DIM_CELL_PSEUDO": 6, + "NX_DIM_CELL_ROOT": 7, + "NX_DIM_CELL_NULL": 8 + }, + "StackElemType": { + "NX_STACK_CELL_NORMAL": 0, + "NX_STACK_CELL_TOTAL": 1, + "NX_STACK_CELL_OTHER": 2, + "NX_STACK_CELL_SUM": 3, + "NX_STACK_CELL_VALUE": 4, + "NX_STACK_CELL_PSEUDO": 5 + }, + "SortIndicatorType": { + "NX_SORT_INDICATE_NONE": 0, + "NX_SORT_INDICATE_ASC": 1, + "NX_SORT_INDICATE_DESC": 2 + }, + "DimensionType": { + "NX_DIMENSION_TYPE_DISCRETE": 0, + "NX_DIMENSION_TYPE_NUMERIC": 1, + "NX_DIMENSION_TYPE_TIME": 2 + }, + "FieldSelectionMode": { + "SELECTION_MODE_NORMAL": 0, + "SELECTION_MODE_AND": 1, + "SELECTION_MODE_NOT": 2 + }, + "FrequencyMode": { + "NX_FREQUENCY_NONE": 0, + "NX_FREQUENCY_VALUE": 1, + "NX_FREQUENCY_PERCENT": 2, + "NX_FREQUENCY_RELATIVE": 3 + }, + "DataReductionMode": { + "DATA_REDUCTION_NONE": 0, + "DATA_REDUCTION_ONEDIM": 1, + "DATA_REDUCTION_SCATTERED": 2, + "DATA_REDUCTION_CLUSTERED": 3, + "DATA_REDUCTION_STACKED": 4 + }, + "HypercubeMode": { + "DATA_MODE_STRAIGHT": 0, + "DATA_MODE_PIVOT": 1, + "DATA_MODE_PIVOT_STACK": 2 + }, + "PatchOperationType": { + "Add": 0, + "Remove": 1, + "Replace": 2 + }, + "SelectionCellType": { + "NX_CELL_DATA": 0, + "NX_CELL_TOP": 1, + "NX_CELL_LEFT": 2 + }, + "MatchingFieldMode": { + "MATCHINGFIELDMODE_MATCH_ALL": 0, + "MATCHINGFIELDMODE_MATCH_ONE": 1 + } + }, + "version": "2.2" +} diff --git a/jwt-scratch/src/js/node_modules/enigma.js/schemas/3.0.json b/jwt-scratch/src/js/node_modules/enigma.js/schemas/3.0.json new file mode 100644 index 0000000..33499c1 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/enigma.js/schemas/3.0.json @@ -0,0 +1,1452 @@ +{ + "structs": { + "Field":{ + "GetCardinal": { + "In": [], + "Out": [] + }, + "GetAndMode": { + "In": [], + "Out": [] + }, + "SelectValues": { + "In": [{ "Name": "qFieldValues","DefaultValue": [{"qText": "", "qIsNumeric": false, "qNumber": 0}] }, { "Name": "qToggleMode","DefaultValue": false, "Optional": true }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Select": { + "In": [{ "Name": "qMatch","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qExcludedValuesMode","DefaultValue": 0, "Optional": true }], + "Out": [] + }, + "ToggleSelect": { + "In": [{ "Name": "qMatch","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qExcludedValuesMode","DefaultValue": 0, "Optional": true }], + "Out": [] + }, + "ClearAllButThis": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectPossible": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectExcluded": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectAll": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Lock": { + "In": [], + "Out": [] + }, + "Unlock": { + "In": [], + "Out": [] + }, + "GetNxProperties": { + "In": [], + "Out": [{ "Name": "qProperties" }] + }, + "SetNxProperties": { + "In": [{ "Name": "qProperties","DefaultValue": {"qOneAndOnlyOne": false} }], + "Out": [] + }, + "SetAndMode": { + "In": [{ "Name": "qAndMode","DefaultValue": false }], + "Out": [] + }, + "SelectAlternative": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "LowLevelSelect": { + "In": [{ "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Clear": { + "In": [], + "Out": [] + } + }, + "Variable":{ + "GetContent": { + "In": [], + "Out": [{ "Name": "qContent" }] + }, + "GetRawContent": { + "In": [], + "Out": [] + }, + "SetContent": { + "In": [{ "Name": "qContent","DefaultValue": "" }, { "Name": "qUpdateMRU","DefaultValue": false }], + "Out": [] + }, + "ForceContent": { + "In": [{ "Name": "qs","DefaultValue": "" }, { "Name": "qd","DefaultValue": 0 }], + "Out": [] + }, + "GetNxProperties": { + "In": [], + "Out": [{ "Name": "qProperties" }] + }, + "SetNxProperties": { + "In": [{ "Name": "qProperties","DefaultValue": {"qName": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qUsePredefListedValues": false, "qPreDefinedList": [""]} }], + "Out": [] + } + }, + "GenericObject":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "GetListObjectData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeReducedData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qZoomFactor","DefaultValue": 0 }, { "Name": "qReductionMode","DefaultValue": 0 }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubePivotData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeStackData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qMaxNbrCells","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeContinuousData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qOptions","DefaultValue": {"qStart": 0, "qEnd": 0, "qNbrPoints": 0, "qMaxNbrTicks": 0, "qMaxNumberLines": 0} }, { "Name": "qReverseSort","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qDataPages" }, { "Name": "qAxisData" }] + }, + "GetHyperCubeBinnedData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qViewport","DefaultValue": {"qWidth": 0, "qHeight": 0, "qZoomLevel": 0} }, { "Name": "qDataRanges","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qMaxNbrCells","DefaultValue": 0 }, { "Name": "qQueryLevel","DefaultValue": 0 }, { "Name": "qBinningMethod","DefaultValue": 0 }], + "Out": [{ "Name": "qDataPages" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }, { "Name": "qSoftPatch","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "ClearSoftPatches": { + "In": [], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetEffectiveProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "SetFullPropertyTree": { + "In": [{ "Name": "qPropEntry","DefaultValue": {"qProperty": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}}, "qChildren": [], "qEmbeddedSnapshotRef": null} }], + "Out": [] + }, + "GetFullPropertyTree": { + "In": [], + "Out": [{ "Name": "qPropEntry" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "ClearSelections": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "ExportData": { + "In": [{ "Name": "qFileType","DefaultValue": 0 }, { "Name": "qPath","DefaultValue": "", "Optional": true }, { "Name": "qFileName","DefaultValue": "", "Optional": true }, { "Name": "qExportState","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qUrl" }] + }, + "SelectListObjectValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectPossible": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectExcluded": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectAlternative": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectAll": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectContinuousRange": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SearchListObjectFor": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qMatch","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "AbortListObjectSearch": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [] + }, + "AcceptListObjectSearch": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "ExpandLeft": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "ExpandTop": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "CollapseLeft": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "CollapseTop": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "DrillUp": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qDimNo","DefaultValue": 0 }, { "Name": "qNbrSteps","DefaultValue": 0 }], + "Out": [] + }, + "Lock": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "Unlock": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "SelectHyperCubeValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qDimNo","DefaultValue": 0 }, { "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectHyperCubeCells": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRowIndices","DefaultValue": [0] }, { "Name": "qColIndices","DefaultValue": [0] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectPivotCells": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSelections","DefaultValue": [{"qType": 0, "qCol": 0, "qRow": 0}] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "RangeSelectHyperCubeValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qRange": {"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}, "qMeasureIx": 0}] }, { "Name": "qColumnsToSelect","DefaultValue": [0], "Optional": true }, { "Name": "qOrMode","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectHyperCubeContinuousRange": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qRange": {"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}, "qDimIx": 0}] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetChild": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetChildInfos": { + "In": [], + "Out": [{ "Name": "qInfos" }] + }, + "CreateChild": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }, { "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyChild": { + "In": [{ "Name": "qId","DefaultValue": "" }, { "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "DestroyAllChildren": { + "In": [{ "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [] + }, + "SetChildArrayOrder": { + "In": [{ "Name": "qIds","DefaultValue": [""] }], + "Out": [] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "CopyFrom": { + "In": [{ "Name": "qFromId","DefaultValue": "" }], + "Out": [] + }, + "BeginSelections": { + "In": [{ "Name": "qPaths","DefaultValue": [""] }], + "Out": [] + }, + "EndSelections": { + "In": [{ "Name": "qAccept","DefaultValue": false }], + "Out": [] + }, + "ResetMadeSelections": { + "In": [], + "Out": [] + }, + "EmbedSnapshotObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetSnapshotObject": { + "In": [], + "Out": [] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericDimension":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDim": {"qGrouping": 0, "qFieldDefs": [""], "qFieldLabels": [""]}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetDimension": { + "In": [], + "Out": [{ "Name": "qDim" }] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericBookmark":{ + "GetFieldValues": { + "In": [{ "Name": "qField","DefaultValue": "" }, { "Name": "qGetExcludedValues","DefaultValue": false }, { "Name": "qDataPage","DefaultValue": {"qStartIndex": 0, "qEndIndex": 0} }], + "Out": [{ "Name": "qFieldValues" }] + }, + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "Apply": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericVariable":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "SetStringValue": { + "In": [{ "Name": "qVal","DefaultValue": "" }], + "Out": [] + }, + "SetNumValue": { + "In": [{ "Name": "qVal","DefaultValue": 0 }], + "Out": [] + }, + "SetDualValue": { + "In": [{ "Name": "qText","DefaultValue": "" }, { "Name": "qNum","DefaultValue": 0 }], + "Out": [] + } + }, + "GenericMeasure":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMeasure": {"qLabel": "", "qDef": "", "qGrouping": 0, "qExpressions": [""], "qActiveExpression": 0}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetMeasure": { + "In": [], + "Out": [{ "Name": "qMeasure" }] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericDerivedFields":{ + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDerivedDefinitionId": "", "qFieldName": [""], "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetDerivedFieldData": { + "In": [], + "Out": [{ "Name": "qData" }] + }, + "GetDerivedField": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qFields" }] + }, + "GetListData": { + "In": [], + "Out": [{ "Name": "qListData" }] + }, + "GetDerivedFields": { + "In": [], + "Out": [{ "Name": "qFields" }] + }, + "GetDerivedGroups": { + "In": [], + "Out": [{ "Name": "qGroups" }] + } + }, + "Doc":{ + "GetProperties": { + "In": [], + "Out": [] + }, + "GetField": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }, { "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "GetFieldDescription": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }], + "Out": [] + }, + "GetVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "GetLooselyCoupledVector": { + "In": [], + "Out": [{ "Name": "qv" }] + }, + "SetLooselyCoupledVector": { + "In": [{ "Name": "qv","DefaultValue": [0] }], + "Out": [] + }, + "Evaluate": { + "In": [{ "Name": "qExpression","DefaultValue": "" }], + "Out": [] + }, + "EvaluateEx": { + "In": [{ "Name": "qExpression","DefaultValue": "" }], + "Out": [{ "Name": "qValue" }] + }, + "ClearAll": { + "In": [{ "Name": "qLockedAlso","DefaultValue": false, "Optional": true }, { "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "LockAll": { + "In": [{ "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "UnlockAll": { + "In": [{ "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "Back": { + "In": [], + "Out": [] + }, + "Forward": { + "In": [], + "Out": [] + }, + "ReduceData": { + "In": [{ "Name": "qConfirm","DefaultValue": false, "Optional": true }, { "Name": "qDropFieldNames","DefaultValue": [""], "Optional": true }], + "Out": [] + }, + "RemoveAllData": { + "In": [{ "Name": "qConfirm","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "CreateVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "RemoveVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "GetLocaleInfo": { + "In": [], + "Out": [] + }, + "GetTablesAndKeys": { + "In": [{ "Name": "qWindowSize","DefaultValue": {"qcx": 0, "qcy": 0} }, { "Name": "qNullSize","DefaultValue": {"qcx": 0, "qcy": 0} }, { "Name": "qCellHeight","DefaultValue": 0 }, { "Name": "qSyntheticMode","DefaultValue": false }, { "Name": "qIncludeSysVars","DefaultValue": false }], + "Out": [{ "Name": "qtr" }, { "Name": "qk" }] + }, + "GetViewDlgSaveInfo": { + "In": [], + "Out": [] + }, + "SetViewDlgSaveInfo": { + "In": [{ "Name": "qInfo","DefaultValue": {"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCtlInfo": {"qInternalView": {"qTables": [{"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCaption": ""}], "qBroomPoints": [{"qPos": {"qx": 0, "qy": 0}, "qTable": "", "qFields": [""]}], "qConnectionPoints": [{"qPos": {"qx": 0, "qy": 0}, "qFields": [""]}], "qZoomFactor": 0}, "qSourceView": {"qTables": [{"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCaption": ""}], "qBroomPoints": [{"qPos": {"qx": 0, "qy": 0}, "qTable": "", "qFields": [""]}], "qConnectionPoints": [{"qPos": {"qx": 0, "qy": 0}, "qFields": [""]}], "qZoomFactor": 0}}, "qMode": 0} }], + "Out": [] + }, + "GetEmptyScript": { + "In": [{ "Name": "qLocalizedMainSection","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "DoReload": { + "In": [{ "Name": "qMode","DefaultValue": 0, "Optional": true }, { "Name": "qPartial","DefaultValue": false, "Optional": true }, { "Name": "qDebug","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "GetScriptBreakpoints": { + "In": [], + "Out": [{ "Name": "qBreakpoints" }] + }, + "SetScriptBreakpoints": { + "In": [{ "Name": "qBreakpoints","DefaultValue": [{"qbufferName": "", "qlineIx": 0, "qEnabled": false}] }], + "Out": [] + }, + "GetScript": { + "In": [], + "Out": [{ "Name": "qScript" }] + }, + "GetTextMacros": { + "In": [], + "Out": [{ "Name": "qMacros" }] + }, + "SetFetchLimit": { + "In": [{ "Name": "qLimit","DefaultValue": 0 }], + "Out": [] + }, + "DoSave": { + "In": [{ "Name": "qFileName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "GetTableData": { + "In": [{ "Name": "qOffset","DefaultValue": 0 }, { "Name": "qRows","DefaultValue": 0 }, { "Name": "qSyntheticMode","DefaultValue": false }, { "Name": "qTableName","DefaultValue": "" }], + "Out": [{ "Name": "qData" }] + }, + "GetAppLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "SetAppProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qTitle": "", "qLastReloadTime": "", "qMigrationHash": "", "qSavedInProductVersion": "", "qThumbnail": {"qUrl": ""}} }], + "Out": [] + }, + "GetAppProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "CreateSessionObject": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }], + "Out": [] + }, + "DestroySessionObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CreateObject": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "CloneObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qDraftId" }] + }, + "CommitDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "DestroyDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }, { "Name": "qSourceId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "Undo": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "Redo": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "ClearUndoBuffer": { + "In": [], + "Out": [] + }, + "CreateDimension": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDim": {"qGrouping": 0, "qFieldDefs": [""], "qFieldLabels": [""]}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "CloneDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateMeasure": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMeasure": {"qLabel": "", "qDef": "", "qGrouping": 0, "qExpressions": [""], "qActiveExpression": 0}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "CloneMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateSessionVariable": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [] + }, + "DestroySessionVariable": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CreateVariableEx": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyVariableById": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "DestroyVariableByName": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetVariableById": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetVariableByName": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "MigrateVariables": { + "In": [], + "Out": [] + }, + "MigrateDerivedFields": { + "In": [], + "Out": [] + }, + "CheckExpression": { + "In": [{ "Name": "qExpr","DefaultValue": "" }, { "Name": "qLabels","DefaultValue": [""], "Optional": true }], + "Out": [{ "Name": "qErrorMsg" }, { "Name": "qBadFieldNames" }, { "Name": "qDangerousFieldNames" }] + }, + "CheckNumberOrExpression": { + "In": [{ "Name": "qExpr","DefaultValue": "" }], + "Out": [{ "Name": "qErrorMsg" }, { "Name": "qBadFieldNames" }] + }, + "AddAlternateState": { + "In": [{ "Name": "qStateName","DefaultValue": "" }], + "Out": [] + }, + "RemoveAlternateState": { + "In": [{ "Name": "qStateName","DefaultValue": "" }], + "Out": [] + }, + "CreateBookmark": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "ApplyBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CloneBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "AddFieldFromExpression": { + "In": [{ "Name": "qName","DefaultValue": "" }, { "Name": "qExpr","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetAllInfos": { + "In": [], + "Out": [{ "Name": "qInfos" }] + }, + "Resume": { + "In": [], + "Out": [] + }, + "AbortModal": { + "In": [{ "Name": "qAccept","DefaultValue": false }], + "Out": [] + }, + "Publish": { + "In": [{ "Name": "qStreamId","DefaultValue": "" }, { "Name": "qName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + }, + "GetMatchingFields": { + "In": [{ "Name": "qTags","DefaultValue": [""] }, { "Name": "qMatchingFieldMode","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qFieldNames" }] + }, + "FindMatchingFields": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }, { "Name": "qTags","DefaultValue": [""] }], + "Out": [{ "Name": "qFieldNames" }] + }, + "SaveObjects": { + "In": [], + "Out": [] + }, + "GetAssociationScores": { + "In": [{ "Name": "qTable1","DefaultValue": "" }, { "Name": "qTable2","DefaultValue": "" }], + "Out": [{ "Name": "qScore" }] + }, + "GetMediaList": { + "In": [], + "Out": [{ "Name": "qList" }] + }, + "GetContentLibraries": { + "In": [], + "Out": [{ "Name": "qList" }] + }, + "GetLibraryContent": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [{ "Name": "qList" }] + }, + "DoReloadEx": { + "In": [{ "Name": "qParams","DefaultValue": {"qMode": 0, "qPartial": false, "qDebug": false}, "Optional": true }], + "Out": [{ "Name": "qResult" }] + }, + "BackCount": { + "In": [], + "Out": [] + }, + "ForwardCount": { + "In": [], + "Out": [] + }, + "SetScript": { + "In": [{ "Name": "qScript","DefaultValue": "" }], + "Out": [] + }, + "CheckScriptSyntax": { + "In": [], + "Out": [{ "Name": "qErrors" }] + }, + "GetFavoriteVariables": { + "In": [], + "Out": [{ "Name": "qNames" }] + }, + "SetFavoriteVariables": { + "In": [{ "Name": "qNames","DefaultValue": [""] }], + "Out": [] + }, + "GetIncludeFileContent": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [{ "Name": "qContent" }] + }, + "CreateConnection": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }], + "Out": [{ "Name": "qConnectionId" }] + }, + "ModifyConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }, { "Name": "qOverrideCredentials","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "DeleteConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [] + }, + "GetConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qConnection" }] + }, + "GetConnections": { + "In": [], + "Out": [{ "Name": "qConnections" }] + }, + "GetDatabaseInfo": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qInfo" }] + }, + "GetDatabases": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qDatabases" }] + }, + "GetDatabaseOwners": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qOwners" }] + }, + "GetDatabaseTables": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qTables" }] + }, + "GetDatabaseTableFields": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qFields" }] + }, + "GetDatabaseTablePreview": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qPreview" }] + }, + "GetFolderItemsForConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qFolderItems" }] + }, + "GuessFileType": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qDataFormat" }] + }, + "GetFileTables": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }], + "Out": [{ "Name": "qTables" }] + }, + "GetFileTableFields": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qFields" }, { "Name": "qFormatSpec" }] + }, + "GetFileTablePreview": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qPreview" }, { "Name": "qFormatSpec" }] + }, + "GetFileTablesEx": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }], + "Out": [{ "Name": "qTables" }] + }, + "SendGenericCommandToCustomConnector": { + "In": [{ "Name": "qProvider","DefaultValue": "" }, { "Name": "qCommand","DefaultValue": "" }, { "Name": "qMethod","DefaultValue": "" }, { "Name": "qParameters","DefaultValue": [""] }, { "Name": "qAppendConnection","DefaultValue": "" }], + "Out": [{ "Name": "qResult" }] + }, + "SearchSuggest": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0} }, { "Name": "qTerms","DefaultValue": [""] }], + "Out": [{ "Name": "qResult" }] + }, + "SearchAssociations": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qPage","DefaultValue": {"qOffset": 0, "qCount": 0, "qMaxNbrFieldMatches": 0, "qGroupOptions": [{"qGroupType": 0, "qOffset": 0, "qCount": 0}], "qGroupItemOptions": [{"qGroupItemType": 0, "qOffset": 0, "qCount": 0}]} }], + "Out": [{ "Name": "qResults" }] + }, + "SelectAssociations": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qMatchIx","DefaultValue": 0 }, { "Name": "qSoftLock","DefaultValue": null, "Optional": true }], + "Out": [] + }, + "SearchResults": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qPage","DefaultValue": {"qOffset": 0, "qCount": 0, "qMaxNbrFieldMatches": 0, "qGroupOptions": [{"qGroupType": 0, "qOffset": 0, "qCount": 0}], "qGroupItemOptions": [{"qGroupItemType": 0, "qOffset": 0, "qCount": 0}]} }], + "Out": [{ "Name": "qResult" }] + }, + "SearchObjects": { + "In": [{ "Name": "qOptions","DefaultValue": {"qAttributes": [""]} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qPage","DefaultValue": {"qOffset": 0, "qCount": 0, "qMaxNbrFieldMatches": 0, "qGroupOptions": [{"qGroupType": 0, "qOffset": 0, "qCount": 0}], "qGroupItemOptions": [{"qGroupItemType": 0, "qOffset": 0, "qCount": 0}]} }], + "Out": [{ "Name": "qResult" }] + } + }, + "Global":{ + "AbortRequest": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [] + }, + "AbortAll": { + "In": [], + "Out": [] + }, + "GetProgress": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [{ "Name": "qProgressData" }] + }, + "QvVersion": { + "In": [], + "Out": [] + }, + "OSVersion": { + "In": [], + "Out": [] + }, + "OSName": { + "In": [], + "Out": [] + }, + "QTProduct": { + "In": [], + "Out": [] + }, + "GetDocList": { + "In": [], + "Out": [{ "Name": "qDocList" }] + }, + "GetInteract": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [{ "Name": "qDef" }] + }, + "InteractDone": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }, { "Name": "qDef","DefaultValue": {"qType": 0, "qTitle": "", "qMsg": "", "qButtons": 0, "qLine": "", "qOldLineNr": 0, "qNewLineNr": 0, "qPath": "", "qHidden": false, "qResult": 0, "qInput": ""} }], + "Out": [] + }, + "GetAuthenticatedUser": { + "In": [], + "Out": [] + }, + "GetStreamList": { + "In": [], + "Out": [{ "Name": "qStreamList" }] + }, + "UploadToContentService": { + "In": [{ "Name": "qDirectory","DefaultValue": "" }, { "Name": "qAppId","DefaultValue": "" }, { "Name": "qQrsObjects","DefaultValue": [{"qEngineObjectID": "", "qItemID": ""}] }], + "Out": [{ "Name": "qUploadedObjects" }] + }, + "CreateDocEx": { + "In": [{ "Name": "qDocName","DefaultValue": "" }, { "Name": "qUserName","DefaultValue": "", "Optional": true }, { "Name": "qPassword","DefaultValue": "", "Optional": true }, { "Name": "qSerial","DefaultValue": "", "Optional": true }, { "Name": "qLocalizedScriptMainSection","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qDocId" }] + }, + "GetActiveDoc": { + "In": [], + "Out": [] + }, + "AllowCreateApp": { + "In": [], + "Out": [] + }, + "CreateApp": { + "In": [{ "Name": "qAppName","DefaultValue": "" }, { "Name": "qLocalizedScriptMainSection","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qSuccess" }, { "Name": "qAppId" }] + }, + "DeleteApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "IsDesktopMode": { + "In": [], + "Out": [] + }, + "GetConfiguration": { + "In": [], + "Out": [{ "Name": "qConfig" }] + }, + "CancelRequest": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [] + }, + "ShutdownProcess": { + "In": [], + "Out": [] + }, + "ReloadExtensionList": { + "In": [], + "Out": [] + }, + "ReplaceAppFromID": { + "In": [{ "Name": "qTargetAppId","DefaultValue": "" }, { "Name": "qSrcAppID","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "CopyApp": { + "In": [{ "Name": "qTargetAppId","DefaultValue": "" }, { "Name": "qSrcAppId","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "ImportApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qSrcPath","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "ImportAppEx": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qSrcPath","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }, { "Name": "qExcludeConnections","DefaultValue": false }], + "Out": [] + }, + "ExportApp": { + "In": [{ "Name": "qTargetPath","DefaultValue": "" }, { "Name": "qSrcAppId","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "PublishApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qName","DefaultValue": "" }, { "Name": "qStreamId","DefaultValue": "" }], + "Out": [] + }, + "IsPersonalMode": { + "In": [], + "Out": [] + }, + "GetUniqueID": { + "In": [], + "Out": [{ "Name": "qUniqueID" }] + }, + "OpenDoc": { + "In": [{ "Name": "qDocName","DefaultValue": "" }, { "Name": "qUserName","DefaultValue": "", "Optional": true }, { "Name": "qPassword","DefaultValue": "", "Optional": true }, { "Name": "qSerial","DefaultValue": "", "Optional": true }, { "Name": "qNoData","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "CreateSessionApp": { + "In": [], + "Out": [{ "Name": "qSessionAppId" }] + }, + "CreateSessionAppFromApp": { + "In": [{ "Name": "qSrcAppId","DefaultValue": "" }], + "Out": [{ "Name": "qSessionAppId" }] + }, + "ProductVersion": { + "In": [], + "Out": [] + }, + "GetAppEntry": { + "In": [{ "Name": "qAppID","DefaultValue": "" }], + "Out": [{ "Name": "qEntry" }] + }, + "ConfigureReload": { + "In": [{ "Name": "qCancelOnScriptError","DefaultValue": false }, { "Name": "qUseErrorData","DefaultValue": false }, { "Name": "qInteractOnError","DefaultValue": false }], + "Out": [] + }, + "CancelReload": { + "In": [], + "Out": [] + }, + "GetBNF": { + "In": [{ "Name": "qBnfType","DefaultValue": 0 }], + "Out": [{ "Name": "qBnfDefs" }] + }, + "GetFunctions": { + "In": [{ "Name": "qGroup","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qFunctions" }] + }, + "GetOdbcDsns": { + "In": [], + "Out": [{ "Name": "qOdbcDsns" }] + }, + "GetOleDbProviders": { + "In": [], + "Out": [{ "Name": "qOleDbProviders" }] + }, + "GetDatabasesFromConnectionString": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }], + "Out": [{ "Name": "qDatabases" }] + }, + "IsValidConnectionString": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }], + "Out": [] + }, + "GetDefaultAppFolder": { + "In": [], + "Out": [{ "Name": "qPath" }] + }, + "GetMyDocumentsFolder": { + "In": [], + "Out": [{ "Name": "qFolder" }] + }, + "GetLogicalDriveStrings": { + "In": [], + "Out": [{ "Name": "qDrives" }] + }, + "GetFolderItemsForPath": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [{ "Name": "qFolderItems" }] + }, + "GetSupportedCodePages": { + "In": [], + "Out": [{ "Name": "qCodePages" }] + }, + "GetCustomConnectors": { + "In": [{ "Name": "qReloadList","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qConnectors" }] + } + } + }, + "enums": { + "LocalizedMessageCode": { + "LOCMSG_SCRIPTEDITOR_EMPTY_MESSAGE": 0, + "LOCMSG_SCRIPTEDITOR_PROGRESS_SAVING_STARTED": 1, + "LOCMSG_SCRIPTEDITOR_PROGRESS_BYTES_LEFT": 2, + "LOCMSG_SCRIPTEDITOR_PROGRESS_STORING_TABLES": 3, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_ROWS_SO_FAR": 4, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECTED": 5, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECTING_TO": 6, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECT_FAILED": 7, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_ROWISH": 8, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_COLUMNAR": 9, + "LOCMSG_SCRIPTEDITOR_ERROR": 10, + "LOCMSG_SCRIPTEDITOR_DONE": 11, + "LOCMSG_SCRIPTEDITOR_LOAD_EXTERNAL_DATA": 12, + "LOCMSG_SCRIPTEDITOR_PROGRESS_OLD_QVD_ISLOADING": 13, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_LOADING": 14, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_BUFFERED": 15, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_PREPARING": 16, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_APPENDING": 17, + "LOCMSG_SCRIPTEDITOR_REMOVE_SYNTHETIC": 18, + "LOCMSG_SCRIPTEDITOR_PENDING_LINKEDTABLE_FETCHING": 19, + "LOCMSG_SCRIPTEDITOR_RELOAD": 20, + "LOCMSG_SCRIPTEDITOR_LINES_FETCHED": 21 + }, + "QrsChangeType": { + "QRS_CHANGE_UNDEFINED": 0, + "QRS_CHANGE_ADD": 1, + "QRS_CHANGE_UPDATE": 2, + "QRS_CHANGE_DELETE": 3 + }, + "LocalizedErrorCode": { + "LOCERR_INTERNAL_ERROR": -128, + "LOCERR_GENERIC_UNKNOWN": -1, + "LOCERR_GENERIC_OK": 0, + "LOCERR_GENERIC_NOT_SET": 1, + "LOCERR_GENERIC_NOT_FOUND": 2, + "LOCERR_GENERIC_ALREADY_EXISTS": 3, + "LOCERR_GENERIC_INVALID_PATH": 4, + "LOCERR_GENERIC_ACCESS_DENIED": 5, + "LOCERR_GENERIC_OUT_OF_MEMORY": 6, + "LOCERR_GENERIC_NOT_INITIALIZED": 7, + "LOCERR_GENERIC_INVALID_PARAMETERS": 8, + "LOCERR_GENERIC_EMPTY_PARAMETERS": 9, + "LOCERR_GENERIC_INTERNAL_ERROR": 10, + "LOCERR_GENERIC_CORRUPT_DATA": 11, + "LOCERR_GENERIC_MEMORY_INCONSISTENCY": 12, + "LOCERR_GENERIC_INVISIBLE_OWNER_ABORT": 13, + "LOCERR_GENERIC_PROHIBIT_VALIDATE": 14, + "LOCERR_GENERIC_ABORTED": 15, + "LOCERR_GENERIC_CONNECTION_LOST": 16, + "LOCERR_GENERIC_UNSUPPORTED_IN_PRODUCT_VERSION": 17, + "LOCERR_GENERIC_REST_CONNECTION_FAILURE": 18, + "LOCERR_HTTP_400": 400, + "LOCERR_HTTP_401": 401, + "LOCERR_HTTP_402": 402, + "LOCERR_HTTP_403": 403, + "LOCERR_HTTP_404": 404, + "LOCERR_HTTP_405": 405, + "LOCERR_HTTP_406": 406, + "LOCERR_HTTP_407": 407, + "LOCERR_HTTP_408": 408, + "LOCERR_HTTP_409": 409, + "LOCERR_HTTP_410": 410, + "LOCERR_HTTP_411": 411, + "LOCERR_HTTP_412": 412, + "LOCERR_HTTP_413": 413, + "LOCERR_HTTP_414": 414, + "LOCERR_HTTP_415": 415, + "LOCERR_HTTP_416": 416, + "LOCERR_HTTP_417": 417, + "LOCERR_HTTP_500": 500, + "LOCERR_HTTP_501": 501, + "LOCERR_HTTP_502": 502, + "LOCERR_HTTP_503": 503, + "LOCERR_HTTP_504": 504, + "LOCERR_HTTP_505": 505, + "LOCERR_HTTP_509": 509, + "LOCERR_APP_ALREADY_EXISTS": 1000, + "LOCERR_APP_INVALID_NAME": 1001, + "LOCERR_APP_ALREADY_OPEN": 1002, + "LOCERR_APP_NOT_FOUND": 1003, + "LOCERR_APP_IMPORT_FAILED": 1004, + "LOCERR_APP_SAVE_FAILED": 1005, + "LOCERR_APP_CREATE_FAILED": 1006, + "LOCERR_APP_INVALID": 1007, + "LOCERR_APP_CONNECT_FAILED": 1008, + "LOCERR_APP_ALREADY_OPEN_IN_DIFFERENT_MODE": 1009, + "LOCERR_APP_MIGRATION_COULD_NOT_CONTACT_MIGRATION_SERVICE": 1010, + "LOCERR_APP_MIGRATION_COULD_NOT_START_MIGRATION": 1011, + "LOCERR_APP_MIGRATION_FAILURE": 1012, + "LOCERR_APP_SCRIPT_MISSING": 1013, + "LOCERR_CONNECTION_ALREADY_EXISTS": 2000, + "LOCERR_CONNECTION_NOT_FOUND": 2001, + "LOCERR_CONNECTION_FAILED_TO_LOAD": 2002, + "LOCERR_CONNECTION_FAILED_TO_IMPORT": 2003, + "LOCERR_CONNECTION_NAME_IS_INVALID": 2004, + "LOCERR_FILE_ACCESS_DENIED": 3000, + "LOCERR_FILE_NAME_INVALID": 3001, + "LOCERR_FILE_CORRUPT": 3002, + "LOCERR_FILE_NOT_FOUND": 3003, + "LOCERR_FILE_FORMAT_UNSUPPORTED": 3004, + "LOCERR_FILE_OPENED_IN_UNSUPPORTED_MODE": 3005, + "LOCERR_USER_ACCESS_DENIED": 4000, + "LOCERR_USER_IMPERSONATION_FAILED": 4001, + "LOCERR_SERVER_OUT_OF_SESSION_AND_USER_CALS": 5000, + "LOCERR_SERVER_OUT_OF_SESSION_CALS": 5001, + "LOCERR_SERVER_OUT_OF_USAGE_CALS": 5002, + "LOCERR_SERVER_OUT_OF_CALS": 5003, + "LOCERR_SERVER_OUT_OF_NAMED_CALS": 5004, + "LOCERR_SERVER_OFF_DUTY": 5005, + "LOCERR_SERVER_BUSY": 5006, + "LOCERR_SERVER_LICENSE_EXPIRED": 5007, + "LOCERR_SERVER_AJAX_DISABLED": 5008, + "LOCERR_HC_INVALID_OBJECT": 6000, + "LOCERR_HC_RESULT_TOO_LARGE": 6001, + "LOCERR_HC_INVALID_OBJECT_STATE": 6002, + "LOCERR_HC_MODAL_OBJECT_ERROR": 6003, + "LOCERR_CALC_INVALID_DEF": 7000, + "LOCERR_CALC_NOT_IN_LIB": 7001, + "LOCERR_CALC_HEAP_ERROR": 7002, + "LOCERR_CALC_TOO_LARGE": 7003, + "LOCERR_CALC_TIMEOUT": 7004, + "LOCERR_CALC_EVAL_CONDITION_FAILED": 7005, + "LOCERR_CALC_MIXED_LINKED_AGGREGATION": 7006, + "LOCERR_CALC_MISSING_LINKED": 7007, + "LOCERR_CALC_INVALID_COL_SORT": 7008, + "LOCERR_CALC_PAGES_TOO_LARGE": 7009, + "LOCERR_CALC_SEMANTIC_FIELD_NOT_ALLOWED": 7010, + "LOCERR_CALC_VALIDATION_STATE_INVALID": 7011, + "LOCERR_CALC_PIVOT_DIMENSIONS_ALREADY_EXISTS": 7012, + "LOCERR_CALC_MISSING_LINKED_FIELD": 7013, + "LOCERR_LAYOUT_EXTENDS_INVALID_ID": 8000, + "LOCERR_LAYOUT_LINKED_OBJECT_NOT_FOUND": 8001, + "LOCERR_LAYOUT_LINKED_OBJECT_INVALID": 8002, + "LOCERR_PERSISTENCE_WRITE_FAILED": 9000, + "LOCERR_PERSISTENCE_READ_FAILED": 9001, + "LOCERR_PERSISTENCE_DELETE_FAILED": 9002, + "LOCERR_PERSISTENCE_NOT_FOUND": 9003, + "LOCERR_PERSISTENCE_UNSUPPORTED_VERSION": 9004, + "LOCERR_PERSISTENCE_MIGRATION_FAILED_READ_ONLY": 9005, + "LOCERR_PERSISTENCE_MIGRATION_CANCELLED": 9006, + "LOCERR_PERSISTENCE_MIGRATION_BACKUP_FAILED": 9007, + "LOCERR_PERSISTENCE_DISK_FULL": 9008, + "LOCERR_PERSISTENCE_NOT_SUPPORTED_FOR_SESSION_APP": 9009, + "LOCERR_PERSISTENCE_SYNC_SET_CHUNK_INVALID_PARAMETERS": 9510, + "LOCERR_PERSISTENCE_SYNC_GET_CHUNK_INVALID_PARAMETERS": 9511, + "LOCERR_SCRIPT_DATASOURCE_ACCESS_DENIED": 10000, + "LOCERR_RELOAD_IN_PROGRESS": 11000, + "LOCERR_PERSONAL_NEW_VERSION_AVAILABLE": 12000, + "LOCERR_PERSONAL_VERSION_EXPIRED": 12001, + "LOCERR_PERSONAL_SECTION_ACCESS_DETECTED": 12002, + "LOCERR_PERSONAL_APP_DELETION_FAILED": 12003, + "LOCERR_EXPORT_OUT_OF_MEMORY": 13000, + "LOCERR_EXPORT_NO_DATA": 13001, + "LOCERR_SYNC_INVALID_OFFSET": 14000, + "LOCERR_SEARCH_TIMEOUT": 15000, + "LOCERR_DIRECT_DISCOVERY_LINKED_EXPRESSION_FAIL": 16000, + "LOCERR_DIRECT_DISCOVERY_ROWCOUNT_OVERFLOW": 16001, + "LOCERR_DIRECT_DISCOVERY_EMPTY_RESULT": 16002, + "LOCERR_DIRECT_DISCOVERY_DB_CONNECTION_FAILED": 16003, + "LOCERR_DIRECT_DISCOVERY_MEASURE_NOT_ALLOWED": 16004, + "LOCERR_DIRECT_DISCOVERY_DETAIL_NOT_ALLOWED": 16005, + "LOCERR_DIRECT_DISCOVERY_NOT_SYNTH_CIRCULAR_ALLOWED": 16006, + "LOCERR_DIRECT_DISCOVERY_ONLY_ONE_DD_TABLE_ALLOWED": 16007, + "LOCERR_DIRECT_DISCOVERY_DB_AUTHORIZATION_FAILED": 16008, + "LOCERR_SMART_LOAD_TABLE_NOT_FOUND": 17000, + "LOCERR_SMART_LOAD_TABLE_DUPLICATED": 17001, + "LOCERR_VARIABLE_NO_NAME": 18000, + "LOCERR_VARIABLE_DUPLICATE_NAME": 18001, + "LOCERR_VARIABLE_INCONSISTENCY": 18002, + "LOCERR_MEDIA_LIBRARY_LIST_FAILED": 19000, + "LOCERR_MEDIA_LIBRARY_CONTENT_FAILED": 19001, + "LOCERR_MEDIA_BUNDLING_FAILED": 19002, + "LOCERR_MEDIA_UNBUNDLING_FAILED": 19003, + "LOCERR_MEDIA_LIBRARY_NOT_FOUND": 19004, + "LOCERR_FEATURE_DISABLED": 20000, + "LOCERR_JSON_RPC_INVALID_REQUEST": -32600, + "LOCERR_JSON_RPC_METHOD_NOT_FOUND": -32601, + "LOCERR_JSON_RPC_INVALID_PARAMETERS": -32602, + "LOCERR_JSON_RPC_INTERNAL_ERROR": -32603, + "LOCERR_JSON_RPC_PARSE_ERROR": -32700 + }, + "LocalizedWarningCode": { + "LOCWARN_PERSONAL_RELOAD_REQUIRED": 0, + "LOCWARN_PERSONAL_VERSION_EXPIRES_SOON": 1, + "LOCWARN_EXPORT_DATA_TRUNCATED": 1000, + "LOCWARN_COULD_NOT_OPEN_ALL_OBJECTS": 2000 + }, + "GrpType": { + "GRP_NX_NONE": 0, + "GRP_NX_HIEARCHY": 1, + "GRP_NX_COLLECTION": 2 + }, + "ExportFileType": { + "EXPORT_CSV_C": 0, + "EXPORT_CSV_T": 1, + "EXPORT_OOXML": 2 + }, + "ExportState": { + "EXPORT_POSSIBLE": 0, + "EXPORT_ALL": 1 + }, + "DimCellType": { + "NX_DIM_CELL_VALUE": 0, + "NX_DIM_CELL_EMPTY": 1, + "NX_DIM_CELL_NORMAL": 2, + "NX_DIM_CELL_TOTAL": 3, + "NX_DIM_CELL_OTHER": 4, + "NX_DIM_CELL_AGGR": 5, + "NX_DIM_CELL_PSEUDO": 6, + "NX_DIM_CELL_ROOT": 7, + "NX_DIM_CELL_NULL": 8 + }, + "StackElemType": { + "NX_STACK_CELL_NORMAL": 0, + "NX_STACK_CELL_TOTAL": 1, + "NX_STACK_CELL_OTHER": 2, + "NX_STACK_CELL_SUM": 3, + "NX_STACK_CELL_VALUE": 4, + "NX_STACK_CELL_PSEUDO": 5 + }, + "SortIndicatorType": { + "NX_SORT_INDICATE_NONE": 0, + "NX_SORT_INDICATE_ASC": 1, + "NX_SORT_INDICATE_DESC": 2 + }, + "DimensionType": { + "NX_DIMENSION_TYPE_DISCRETE": 0, + "NX_DIMENSION_TYPE_NUMERIC": 1, + "NX_DIMENSION_TYPE_TIME": 2 + }, + "FieldSelectionMode": { + "SELECTION_MODE_NORMAL": 0, + "SELECTION_MODE_AND": 1, + "SELECTION_MODE_NOT": 2 + }, + "FrequencyMode": { + "NX_FREQUENCY_NONE": 0, + "NX_FREQUENCY_VALUE": 1, + "NX_FREQUENCY_PERCENT": 2, + "NX_FREQUENCY_RELATIVE": 3 + }, + "DataReductionMode": { + "DATA_REDUCTION_NONE": 0, + "DATA_REDUCTION_ONEDIM": 1, + "DATA_REDUCTION_SCATTERED": 2, + "DATA_REDUCTION_CLUSTERED": 3, + "DATA_REDUCTION_STACKED": 4 + }, + "HypercubeMode": { + "DATA_MODE_STRAIGHT": 0, + "DATA_MODE_PIVOT": 1, + "DATA_MODE_PIVOT_STACK": 2 + }, + "PatchOperationType": { + "Add": 0, + "Remove": 1, + "Replace": 2 + }, + "SelectionCellType": { + "NX_CELL_DATA": 0, + "NX_CELL_TOP": 1, + "NX_CELL_LEFT": 2 + }, + "MatchingFieldMode": { + "MATCHINGFIELDMODE_MATCH_ALL": 0, + "MATCHINGFIELDMODE_MATCH_ONE": 1 + }, + "ExtEngineDataType": { + "NX_EXT_DATATYPE_STRING": 0, + "NX_EXT_DATATYPE_DOUBLE": 1, + "NX_EXT_DATATYPE_BOTH": 2 + }, + "ExtEngineFunctionType": { + "NX_EXT_FUNCTIONTYPE_SCALAR": 0, + "NX_EXT_FUNCTIONTYPE_AGGR": 1, + "NX_EXT_FUNCTIONTYPE_TENSOR": 2 + }, + "ExtEngineMsgType": { + "NX_EXT_MSGTYPE_FUNCTION_CALL": 1, + "NX_EXT_MSGTYPE_SCRIPT_CALL": 2, + "NX_EXT_MSGTYPE_RETURN_VALUE": 3, + "NX_EXT_MSGTYPE_RETURN_MULTIPLE": 4, + "NX_EXT_MSGTYPE_RETURN_ERROR": 5 + } + }, + "version": "3.0" +} diff --git a/jwt-scratch/src/js/node_modules/enigma.js/schemas/3.1.json b/jwt-scratch/src/js/node_modules/enigma.js/schemas/3.1.json new file mode 100644 index 0000000..4d7675d --- /dev/null +++ b/jwt-scratch/src/js/node_modules/enigma.js/schemas/3.1.json @@ -0,0 +1,1506 @@ +{ + "structs": { + "Field":{ + "GetCardinal": { + "In": [], + "Out": [] + }, + "GetAndMode": { + "In": [], + "Out": [] + }, + "SelectValues": { + "In": [{ "Name": "qFieldValues","DefaultValue": [{"qText": "", "qIsNumeric": false, "qNumber": 0}] }, { "Name": "qToggleMode","DefaultValue": false, "Optional": true }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Select": { + "In": [{ "Name": "qMatch","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qExcludedValuesMode","DefaultValue": 0, "Optional": true }], + "Out": [] + }, + "ToggleSelect": { + "In": [{ "Name": "qMatch","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qExcludedValuesMode","DefaultValue": 0, "Optional": true }], + "Out": [] + }, + "ClearAllButThis": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectPossible": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectExcluded": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectAll": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Lock": { + "In": [], + "Out": [] + }, + "Unlock": { + "In": [], + "Out": [] + }, + "GetNxProperties": { + "In": [], + "Out": [{ "Name": "qProperties" }] + }, + "SetNxProperties": { + "In": [{ "Name": "qProperties","DefaultValue": {"qOneAndOnlyOne": false} }], + "Out": [] + }, + "SetAndMode": { + "In": [{ "Name": "qAndMode","DefaultValue": false }], + "Out": [] + }, + "SelectAlternative": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "LowLevelSelect": { + "In": [{ "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Clear": { + "In": [], + "Out": [] + } + }, + "Variable":{ + "GetContent": { + "In": [], + "Out": [{ "Name": "qContent" }] + }, + "GetRawContent": { + "In": [], + "Out": [] + }, + "SetContent": { + "In": [{ "Name": "qContent","DefaultValue": "" }, { "Name": "qUpdateMRU","DefaultValue": false }], + "Out": [] + }, + "ForceContent": { + "In": [{ "Name": "qs","DefaultValue": "" }, { "Name": "qd","DefaultValue": 0 }], + "Out": [] + }, + "GetNxProperties": { + "In": [], + "Out": [{ "Name": "qProperties" }] + }, + "SetNxProperties": { + "In": [{ "Name": "qProperties","DefaultValue": {"qName": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qUsePredefListedValues": false, "qPreDefinedList": [""]} }], + "Out": [] + } + }, + "GenericObject":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "GetListObjectData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeReducedData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qZoomFactor","DefaultValue": 0 }, { "Name": "qReductionMode","DefaultValue": 0 }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubePivotData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeStackData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qMaxNbrCells","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeContinuousData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qOptions","DefaultValue": {"qStart": 0, "qEnd": 0, "qNbrPoints": 0, "qMaxNbrTicks": 0, "qMaxNumberLines": 0} }, { "Name": "qReverseSort","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qDataPages" }, { "Name": "qAxisData" }] + }, + "GetHyperCubeBinnedData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qViewport","DefaultValue": {"qWidth": 0, "qHeight": 0, "qZoomLevel": 0} }, { "Name": "qDataRanges","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qMaxNbrCells","DefaultValue": 0 }, { "Name": "qQueryLevel","DefaultValue": 0 }, { "Name": "qBinningMethod","DefaultValue": 0 }], + "Out": [{ "Name": "qDataPages" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }, { "Name": "qSoftPatch","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "ClearSoftPatches": { + "In": [], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetEffectiveProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "SetFullPropertyTree": { + "In": [{ "Name": "qPropEntry","DefaultValue": {"qProperty": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}}, "qChildren": [], "qEmbeddedSnapshotRef": null} }], + "Out": [] + }, + "GetFullPropertyTree": { + "In": [], + "Out": [{ "Name": "qPropEntry" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "ClearSelections": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "ExportData": { + "In": [{ "Name": "qFileType","DefaultValue": 0 }, { "Name": "qPath","DefaultValue": "", "Optional": true }, { "Name": "qFileName","DefaultValue": "", "Optional": true }, { "Name": "qExportState","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qUrl" }, { "Name": "qWarnings" }] + }, + "SelectListObjectValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectPossible": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectExcluded": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectAlternative": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectAll": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectContinuousRange": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SearchListObjectFor": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qMatch","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "AbortListObjectSearch": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [] + }, + "AcceptListObjectSearch": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "ExpandLeft": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "ExpandTop": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "CollapseLeft": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "CollapseTop": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "DrillUp": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qDimNo","DefaultValue": 0 }, { "Name": "qNbrSteps","DefaultValue": 0 }], + "Out": [] + }, + "Lock": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "Unlock": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "SelectHyperCubeValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qDimNo","DefaultValue": 0 }, { "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectHyperCubeCells": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRowIndices","DefaultValue": [0] }, { "Name": "qColIndices","DefaultValue": [0] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectPivotCells": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSelections","DefaultValue": [{"qType": 0, "qCol": 0, "qRow": 0}] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "RangeSelectHyperCubeValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qRange": {"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}, "qMeasureIx": 0}] }, { "Name": "qColumnsToSelect","DefaultValue": [0], "Optional": true }, { "Name": "qOrMode","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "MultiRangeSelectHyperCubeValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qRanges": [{"qRange": {"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}, "qMeasureIx": 0}], "qColumnsToSelect": [0]}] }, { "Name": "qOrMode","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectHyperCubeContinuousRange": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qRange": {"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}, "qDimIx": 0}] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetChild": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetChildInfos": { + "In": [], + "Out": [{ "Name": "qInfos" }] + }, + "CreateChild": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }, { "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyChild": { + "In": [{ "Name": "qId","DefaultValue": "" }, { "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "DestroyAllChildren": { + "In": [{ "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [] + }, + "SetChildArrayOrder": { + "In": [{ "Name": "qIds","DefaultValue": [""] }], + "Out": [] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "CopyFrom": { + "In": [{ "Name": "qFromId","DefaultValue": "" }], + "Out": [] + }, + "BeginSelections": { + "In": [{ "Name": "qPaths","DefaultValue": [""] }], + "Out": [] + }, + "EndSelections": { + "In": [{ "Name": "qAccept","DefaultValue": false }], + "Out": [] + }, + "ResetMadeSelections": { + "In": [], + "Out": [] + }, + "EmbedSnapshotObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetSnapshotObject": { + "In": [], + "Out": [] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericDimension":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDim": {"qGrouping": 0, "qFieldDefs": [""], "qFieldLabels": [""]}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetDimension": { + "In": [], + "Out": [{ "Name": "qDim" }] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericBookmark":{ + "GetFieldValues": { + "In": [{ "Name": "qField","DefaultValue": "" }, { "Name": "qGetExcludedValues","DefaultValue": false }, { "Name": "qDataPage","DefaultValue": {"qStartIndex": 0, "qEndIndex": 0} }], + "Out": [{ "Name": "qFieldValues" }] + }, + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "Apply": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericVariable":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "SetStringValue": { + "In": [{ "Name": "qVal","DefaultValue": "" }], + "Out": [] + }, + "SetNumValue": { + "In": [{ "Name": "qVal","DefaultValue": 0 }], + "Out": [] + }, + "SetDualValue": { + "In": [{ "Name": "qText","DefaultValue": "" }, { "Name": "qNum","DefaultValue": 0 }], + "Out": [] + } + }, + "GenericMeasure":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMeasure": {"qLabel": "", "qDef": "", "qGrouping": 0, "qExpressions": [""], "qActiveExpression": 0}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetMeasure": { + "In": [], + "Out": [{ "Name": "qMeasure" }] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericDerivedFields":{ + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDerivedDefinitionId": "", "qFieldName": [""], "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetDerivedFieldData": { + "In": [], + "Out": [{ "Name": "qData" }] + }, + "GetDerivedField": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qFields" }] + }, + "GetListData": { + "In": [], + "Out": [{ "Name": "qListData" }] + }, + "GetDerivedFields": { + "In": [], + "Out": [{ "Name": "qFields" }] + }, + "GetDerivedGroups": { + "In": [], + "Out": [{ "Name": "qGroups" }] + } + }, + "Doc":{ + "GetProperties": { + "In": [], + "Out": [] + }, + "GetField": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }, { "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "GetFieldDescription": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }], + "Out": [] + }, + "GetVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "GetLooselyCoupledVector": { + "In": [], + "Out": [{ "Name": "qv" }] + }, + "SetLooselyCoupledVector": { + "In": [{ "Name": "qv","DefaultValue": [0] }], + "Out": [] + }, + "Evaluate": { + "In": [{ "Name": "qExpression","DefaultValue": "" }], + "Out": [] + }, + "EvaluateEx": { + "In": [{ "Name": "qExpression","DefaultValue": "" }], + "Out": [{ "Name": "qValue" }] + }, + "ClearAll": { + "In": [{ "Name": "qLockedAlso","DefaultValue": false, "Optional": true }, { "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "LockAll": { + "In": [{ "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "UnlockAll": { + "In": [{ "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "Back": { + "In": [], + "Out": [] + }, + "Forward": { + "In": [], + "Out": [] + }, + "ReduceData": { + "In": [{ "Name": "qConfirm","DefaultValue": false, "Optional": true }, { "Name": "qDropFieldNames","DefaultValue": [""], "Optional": true }], + "Out": [] + }, + "RemoveAllData": { + "In": [{ "Name": "qConfirm","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "CreateVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "RemoveVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "GetLocaleInfo": { + "In": [], + "Out": [] + }, + "GetTablesAndKeys": { + "In": [{ "Name": "qWindowSize","DefaultValue": {"qcx": 0, "qcy": 0} }, { "Name": "qNullSize","DefaultValue": {"qcx": 0, "qcy": 0} }, { "Name": "qCellHeight","DefaultValue": 0 }, { "Name": "qSyntheticMode","DefaultValue": false }, { "Name": "qIncludeSysVars","DefaultValue": false }], + "Out": [{ "Name": "qtr" }, { "Name": "qk" }] + }, + "GetViewDlgSaveInfo": { + "In": [], + "Out": [] + }, + "SetViewDlgSaveInfo": { + "In": [{ "Name": "qInfo","DefaultValue": {"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCtlInfo": {"qInternalView": {"qTables": [{"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCaption": ""}], "qBroomPoints": [{"qPos": {"qx": 0, "qy": 0}, "qTable": "", "qFields": [""]}], "qConnectionPoints": [{"qPos": {"qx": 0, "qy": 0}, "qFields": [""]}], "qZoomFactor": 0}, "qSourceView": {"qTables": [{"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCaption": ""}], "qBroomPoints": [{"qPos": {"qx": 0, "qy": 0}, "qTable": "", "qFields": [""]}], "qConnectionPoints": [{"qPos": {"qx": 0, "qy": 0}, "qFields": [""]}], "qZoomFactor": 0}}, "qMode": 0} }], + "Out": [] + }, + "GetEmptyScript": { + "In": [{ "Name": "qLocalizedMainSection","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "DoReload": { + "In": [{ "Name": "qMode","DefaultValue": 0, "Optional": true }, { "Name": "qPartial","DefaultValue": false, "Optional": true }, { "Name": "qDebug","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "GetScriptBreakpoints": { + "In": [], + "Out": [{ "Name": "qBreakpoints" }] + }, + "SetScriptBreakpoints": { + "In": [{ "Name": "qBreakpoints","DefaultValue": [{"qbufferName": "", "qlineIx": 0, "qEnabled": false}] }], + "Out": [] + }, + "GetScript": { + "In": [], + "Out": [{ "Name": "qScript" }] + }, + "GetTextMacros": { + "In": [], + "Out": [{ "Name": "qMacros" }] + }, + "SetFetchLimit": { + "In": [{ "Name": "qLimit","DefaultValue": 0 }], + "Out": [] + }, + "DoSave": { + "In": [{ "Name": "qFileName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "GetTableData": { + "In": [{ "Name": "qOffset","DefaultValue": 0 }, { "Name": "qRows","DefaultValue": 0 }, { "Name": "qSyntheticMode","DefaultValue": false }, { "Name": "qTableName","DefaultValue": "" }], + "Out": [{ "Name": "qData" }] + }, + "GetAppLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "SetAppProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qTitle": "", "qLastReloadTime": "", "qMigrationHash": "", "qSavedInProductVersion": "", "qThumbnail": {"qUrl": ""}} }], + "Out": [] + }, + "GetAppProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "CreateSessionObject": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }], + "Out": [] + }, + "DestroySessionObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CreateObject": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "CloneObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qDraftId" }] + }, + "CommitDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "DestroyDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }, { "Name": "qSourceId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "Undo": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "Redo": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "ClearUndoBuffer": { + "In": [], + "Out": [] + }, + "CreateDimension": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDim": {"qGrouping": 0, "qFieldDefs": [""], "qFieldLabels": [""]}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "CloneDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateMeasure": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMeasure": {"qLabel": "", "qDef": "", "qGrouping": 0, "qExpressions": [""], "qActiveExpression": 0}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "CloneMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateSessionVariable": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [] + }, + "DestroySessionVariable": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CreateVariableEx": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyVariableById": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "DestroyVariableByName": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetVariableById": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetVariableByName": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "MigrateVariables": { + "In": [], + "Out": [] + }, + "MigrateDerivedFields": { + "In": [], + "Out": [] + }, + "CheckExpression": { + "In": [{ "Name": "qExpr","DefaultValue": "" }, { "Name": "qLabels","DefaultValue": [""], "Optional": true }], + "Out": [{ "Name": "qErrorMsg" }, { "Name": "qBadFieldNames" }, { "Name": "qDangerousFieldNames" }] + }, + "CheckNumberOrExpression": { + "In": [{ "Name": "qExpr","DefaultValue": "" }], + "Out": [{ "Name": "qErrorMsg" }, { "Name": "qBadFieldNames" }] + }, + "AddAlternateState": { + "In": [{ "Name": "qStateName","DefaultValue": "" }], + "Out": [] + }, + "RemoveAlternateState": { + "In": [{ "Name": "qStateName","DefaultValue": "" }], + "Out": [] + }, + "CreateBookmark": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "ApplyBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CloneBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "AddFieldFromExpression": { + "In": [{ "Name": "qName","DefaultValue": "" }, { "Name": "qExpr","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetAllInfos": { + "In": [], + "Out": [{ "Name": "qInfos" }] + }, + "Resume": { + "In": [], + "Out": [] + }, + "AbortModal": { + "In": [{ "Name": "qAccept","DefaultValue": false }], + "Out": [] + }, + "Publish": { + "In": [{ "Name": "qStreamId","DefaultValue": "" }, { "Name": "qName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + }, + "GetMatchingFields": { + "In": [{ "Name": "qTags","DefaultValue": [""] }, { "Name": "qMatchingFieldMode","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qFieldNames" }] + }, + "FindMatchingFields": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }, { "Name": "qTags","DefaultValue": [""] }], + "Out": [{ "Name": "qFieldNames" }] + }, + "SaveObjects": { + "In": [], + "Out": [] + }, + "GetAssociationScores": { + "In": [{ "Name": "qTable1","DefaultValue": "" }, { "Name": "qTable2","DefaultValue": "" }], + "Out": [{ "Name": "qScore" }] + }, + "GetMediaList": { + "In": [], + "Out": [{ "Name": "qList" }] + }, + "GetContentLibraries": { + "In": [], + "Out": [{ "Name": "qList" }] + }, + "GetLibraryContent": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [{ "Name": "qList" }] + }, + "DoReloadEx": { + "In": [{ "Name": "qParams","DefaultValue": {"qMode": 0, "qPartial": false, "qDebug": false}, "Optional": true }], + "Out": [{ "Name": "qResult" }] + }, + "BackCount": { + "In": [], + "Out": [] + }, + "ForwardCount": { + "In": [], + "Out": [] + }, + "SetScript": { + "In": [{ "Name": "qScript","DefaultValue": "" }], + "Out": [] + }, + "CheckScriptSyntax": { + "In": [], + "Out": [{ "Name": "qErrors" }] + }, + "GetFavoriteVariables": { + "In": [], + "Out": [{ "Name": "qNames" }] + }, + "SetFavoriteVariables": { + "In": [{ "Name": "qNames","DefaultValue": [""] }], + "Out": [] + }, + "GetIncludeFileContent": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [{ "Name": "qContent" }] + }, + "CreateConnection": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }], + "Out": [{ "Name": "qConnectionId" }] + }, + "ModifyConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }, { "Name": "qOverrideCredentials","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "DeleteConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [] + }, + "GetConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qConnection" }] + }, + "GetConnections": { + "In": [], + "Out": [{ "Name": "qConnections" }] + }, + "GetDatabaseInfo": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qInfo" }] + }, + "GetDatabases": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qDatabases" }] + }, + "GetDatabaseOwners": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qOwners" }] + }, + "GetDatabaseTables": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qTables" }] + }, + "GetDatabaseTableFields": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qFields" }] + }, + "GetDatabaseTablePreview": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qPreview" }] + }, + "GetFolderItemsForConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qFolderItems" }] + }, + "GuessFileType": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qDataFormat" }] + }, + "GetFileTables": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }], + "Out": [{ "Name": "qTables" }] + }, + "GetFileTableFields": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qFields" }, { "Name": "qFormatSpec" }] + }, + "GetFileTablePreview": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qPreview" }, { "Name": "qFormatSpec" }] + }, + "GetFileTablesEx": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }], + "Out": [{ "Name": "qTables" }] + }, + "SendGenericCommandToCustomConnector": { + "In": [{ "Name": "qProvider","DefaultValue": "" }, { "Name": "qCommand","DefaultValue": "" }, { "Name": "qMethod","DefaultValue": "" }, { "Name": "qParameters","DefaultValue": [""] }, { "Name": "qAppendConnection","DefaultValue": "" }], + "Out": [{ "Name": "qResult" }] + }, + "SearchSuggest": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0} }, { "Name": "qTerms","DefaultValue": [""] }], + "Out": [{ "Name": "qResult" }] + }, + "SearchAssociations": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qPage","DefaultValue": {"qOffset": 0, "qCount": 0, "qMaxNbrFieldMatches": 0, "qGroupOptions": [{"qGroupType": 0, "qOffset": 0, "qCount": 0}], "qGroupItemOptions": [{"qGroupItemType": 0, "qOffset": 0, "qCount": 0}]} }], + "Out": [{ "Name": "qResults" }] + }, + "SelectAssociations": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qMatchIx","DefaultValue": 0 }, { "Name": "qSoftLock","DefaultValue": null, "Optional": true }], + "Out": [] + }, + "SearchResults": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qPage","DefaultValue": {"qOffset": 0, "qCount": 0, "qMaxNbrFieldMatches": 0, "qGroupOptions": [{"qGroupType": 0, "qOffset": 0, "qCount": 0}], "qGroupItemOptions": [{"qGroupItemType": 0, "qOffset": 0, "qCount": 0}]} }], + "Out": [{ "Name": "qResult" }] + }, + "SearchObjects": { + "In": [{ "Name": "qOptions","DefaultValue": {"qAttributes": [""]} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qPage","DefaultValue": {"qOffset": 0, "qCount": 0, "qMaxNbrFieldMatches": 0, "qGroupOptions": [{"qGroupType": 0, "qOffset": 0, "qCount": 0}], "qGroupItemOptions": [{"qGroupItemType": 0, "qOffset": 0, "qCount": 0}]} }], + "Out": [{ "Name": "qResult" }] + } + }, + "Global":{ + "AbortRequest": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [] + }, + "AbortAll": { + "In": [], + "Out": [] + }, + "GetProgress": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [{ "Name": "qProgressData" }] + }, + "QvVersion": { + "In": [], + "Out": [] + }, + "OSVersion": { + "In": [], + "Out": [] + }, + "OSName": { + "In": [], + "Out": [] + }, + "QTProduct": { + "In": [], + "Out": [] + }, + "GetDocList": { + "In": [], + "Out": [{ "Name": "qDocList" }] + }, + "GetInteract": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [{ "Name": "qDef" }] + }, + "InteractDone": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }, { "Name": "qDef","DefaultValue": {"qType": 0, "qTitle": "", "qMsg": "", "qButtons": 0, "qLine": "", "qOldLineNr": 0, "qNewLineNr": 0, "qPath": "", "qHidden": false, "qResult": 0, "qInput": ""} }], + "Out": [] + }, + "GetAuthenticatedUser": { + "In": [], + "Out": [] + }, + "GetStreamList": { + "In": [], + "Out": [{ "Name": "qStreamList" }] + }, + "UploadToContentService": { + "In": [{ "Name": "qDirectory","DefaultValue": "" }, { "Name": "qAppId","DefaultValue": "" }, { "Name": "qQrsObjects","DefaultValue": [{"qEngineObjectID": "", "qItemID": ""}] }], + "Out": [{ "Name": "qUploadedObjects" }] + }, + "CreateDocEx": { + "In": [{ "Name": "qDocName","DefaultValue": "" }, { "Name": "qUserName","DefaultValue": "", "Optional": true }, { "Name": "qPassword","DefaultValue": "", "Optional": true }, { "Name": "qSerial","DefaultValue": "", "Optional": true }, { "Name": "qLocalizedScriptMainSection","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qDocId" }] + }, + "GetActiveDoc": { + "In": [], + "Out": [] + }, + "AllowCreateApp": { + "In": [], + "Out": [] + }, + "CreateApp": { + "In": [{ "Name": "qAppName","DefaultValue": "" }, { "Name": "qLocalizedScriptMainSection","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qSuccess" }, { "Name": "qAppId" }] + }, + "DeleteApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "IsDesktopMode": { + "In": [], + "Out": [] + }, + "GetConfiguration": { + "In": [], + "Out": [{ "Name": "qConfig" }] + }, + "CancelRequest": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [] + }, + "ShutdownProcess": { + "In": [], + "Out": [] + }, + "ReloadExtensionList": { + "In": [], + "Out": [] + }, + "ReplaceAppFromID": { + "In": [{ "Name": "qTargetAppId","DefaultValue": "" }, { "Name": "qSrcAppID","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "CopyApp": { + "In": [{ "Name": "qTargetAppId","DefaultValue": "" }, { "Name": "qSrcAppId","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "ImportApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qSrcPath","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "ImportAppEx": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qSrcPath","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }, { "Name": "qExcludeConnections","DefaultValue": false }], + "Out": [] + }, + "ExportApp": { + "In": [{ "Name": "qTargetPath","DefaultValue": "" }, { "Name": "qSrcAppId","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "PublishApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qName","DefaultValue": "" }, { "Name": "qStreamId","DefaultValue": "" }], + "Out": [] + }, + "IsPersonalMode": { + "In": [], + "Out": [] + }, + "GetUniqueID": { + "In": [], + "Out": [{ "Name": "qUniqueID" }] + }, + "OpenDoc": { + "In": [{ "Name": "qDocName","DefaultValue": "" }, { "Name": "qUserName","DefaultValue": "", "Optional": true }, { "Name": "qPassword","DefaultValue": "", "Optional": true }, { "Name": "qSerial","DefaultValue": "", "Optional": true }, { "Name": "qNoData","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "CreateSessionApp": { + "In": [], + "Out": [{ "Name": "qSessionAppId" }] + }, + "CreateSessionAppFromApp": { + "In": [{ "Name": "qSrcAppId","DefaultValue": "" }], + "Out": [{ "Name": "qSessionAppId" }] + }, + "ProductVersion": { + "In": [], + "Out": [] + }, + "GetAppEntry": { + "In": [{ "Name": "qAppID","DefaultValue": "" }], + "Out": [{ "Name": "qEntry" }] + }, + "ConfigureReload": { + "In": [{ "Name": "qCancelOnScriptError","DefaultValue": false }, { "Name": "qUseErrorData","DefaultValue": false }, { "Name": "qInteractOnError","DefaultValue": false }], + "Out": [] + }, + "CancelReload": { + "In": [], + "Out": [] + }, + "GetBNF": { + "In": [{ "Name": "qBnfType","DefaultValue": 0 }], + "Out": [{ "Name": "qBnfDefs" }] + }, + "GetFunctions": { + "In": [{ "Name": "qGroup","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qFunctions" }] + }, + "GetOdbcDsns": { + "In": [], + "Out": [{ "Name": "qOdbcDsns" }] + }, + "GetOleDbProviders": { + "In": [], + "Out": [{ "Name": "qOleDbProviders" }] + }, + "GetDatabasesFromConnectionString": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }], + "Out": [{ "Name": "qDatabases" }] + }, + "IsValidConnectionString": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }], + "Out": [] + }, + "GetDefaultAppFolder": { + "In": [], + "Out": [{ "Name": "qPath" }] + }, + "GetMyDocumentsFolder": { + "In": [], + "Out": [{ "Name": "qFolder" }] + }, + "GetLogicalDriveStrings": { + "In": [], + "Out": [{ "Name": "qDrives" }] + }, + "GetFolderItemsForPath": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [{ "Name": "qFolderItems" }] + }, + "GetSupportedCodePages": { + "In": [], + "Out": [{ "Name": "qCodePages" }] + }, + "GetCustomConnectors": { + "In": [{ "Name": "qReloadList","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qConnectors" }] + } + } + }, + "enums": { + "LocalizedMessageCode": { + "LOCMSG_SCRIPTEDITOR_EMPTY_MESSAGE": 0, + "LOCMSG_SCRIPTEDITOR_PROGRESS_SAVING_STARTED": 1, + "LOCMSG_SCRIPTEDITOR_PROGRESS_BYTES_LEFT": 2, + "LOCMSG_SCRIPTEDITOR_PROGRESS_STORING_TABLES": 3, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_ROWS_SO_FAR": 4, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECTED": 5, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECTING_TO": 6, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECT_FAILED": 7, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_ROWISH": 8, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_COLUMNAR": 9, + "LOCMSG_SCRIPTEDITOR_ERROR": 10, + "LOCMSG_SCRIPTEDITOR_DONE": 11, + "LOCMSG_SCRIPTEDITOR_LOAD_EXTERNAL_DATA": 12, + "LOCMSG_SCRIPTEDITOR_PROGRESS_OLD_QVD_ISLOADING": 13, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_LOADING": 14, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_BUFFERED": 15, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_PREPARING": 16, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_APPENDING": 17, + "LOCMSG_SCRIPTEDITOR_REMOVE_SYNTHETIC": 18, + "LOCMSG_SCRIPTEDITOR_PENDING_LINKEDTABLE_FETCHING": 19, + "LOCMSG_SCRIPTEDITOR_RELOAD": 20, + "LOCMSG_SCRIPTEDITOR_LINES_FETCHED": 21, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_START": 22, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_FIELD": 23, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_SUCCESS": 24, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_FAILURE": 25, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_STARTABORT": 26, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_ENDABORT": 27, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_TIMEOUT": 28, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_OUTOFMEMORY": 29 + }, + "QrsChangeType": { + "QRS_CHANGE_UNDEFINED": 0, + "QRS_CHANGE_ADD": 1, + "QRS_CHANGE_UPDATE": 2, + "QRS_CHANGE_DELETE": 3 + }, + "LocalizedErrorCode": { + "LOCERR_INTERNAL_ERROR": -128, + "LOCERR_GENERIC_UNKNOWN": -1, + "LOCERR_GENERIC_OK": 0, + "LOCERR_GENERIC_NOT_SET": 1, + "LOCERR_GENERIC_NOT_FOUND": 2, + "LOCERR_GENERIC_ALREADY_EXISTS": 3, + "LOCERR_GENERIC_INVALID_PATH": 4, + "LOCERR_GENERIC_ACCESS_DENIED": 5, + "LOCERR_GENERIC_OUT_OF_MEMORY": 6, + "LOCERR_GENERIC_NOT_INITIALIZED": 7, + "LOCERR_GENERIC_INVALID_PARAMETERS": 8, + "LOCERR_GENERIC_EMPTY_PARAMETERS": 9, + "LOCERR_GENERIC_INTERNAL_ERROR": 10, + "LOCERR_GENERIC_CORRUPT_DATA": 11, + "LOCERR_GENERIC_MEMORY_INCONSISTENCY": 12, + "LOCERR_GENERIC_INVISIBLE_OWNER_ABORT": 13, + "LOCERR_GENERIC_PROHIBIT_VALIDATE": 14, + "LOCERR_GENERIC_ABORTED": 15, + "LOCERR_GENERIC_CONNECTION_LOST": 16, + "LOCERR_GENERIC_UNSUPPORTED_IN_PRODUCT_VERSION": 17, + "LOCERR_GENERIC_REST_CONNECTION_FAILURE": 18, + "LOCERR_HTTP_400": 400, + "LOCERR_HTTP_401": 401, + "LOCERR_HTTP_402": 402, + "LOCERR_HTTP_403": 403, + "LOCERR_HTTP_404": 404, + "LOCERR_HTTP_405": 405, + "LOCERR_HTTP_406": 406, + "LOCERR_HTTP_407": 407, + "LOCERR_HTTP_408": 408, + "LOCERR_HTTP_409": 409, + "LOCERR_HTTP_410": 410, + "LOCERR_HTTP_411": 411, + "LOCERR_HTTP_412": 412, + "LOCERR_HTTP_413": 413, + "LOCERR_HTTP_414": 414, + "LOCERR_HTTP_415": 415, + "LOCERR_HTTP_416": 416, + "LOCERR_HTTP_417": 417, + "LOCERR_HTTP_500": 500, + "LOCERR_HTTP_501": 501, + "LOCERR_HTTP_502": 502, + "LOCERR_HTTP_503": 503, + "LOCERR_HTTP_504": 504, + "LOCERR_HTTP_505": 505, + "LOCERR_HTTP_509": 509, + "LOCERR_APP_ALREADY_EXISTS": 1000, + "LOCERR_APP_INVALID_NAME": 1001, + "LOCERR_APP_ALREADY_OPEN": 1002, + "LOCERR_APP_NOT_FOUND": 1003, + "LOCERR_APP_IMPORT_FAILED": 1004, + "LOCERR_APP_SAVE_FAILED": 1005, + "LOCERR_APP_CREATE_FAILED": 1006, + "LOCERR_APP_INVALID": 1007, + "LOCERR_APP_CONNECT_FAILED": 1008, + "LOCERR_APP_ALREADY_OPEN_IN_DIFFERENT_MODE": 1009, + "LOCERR_APP_MIGRATION_COULD_NOT_CONTACT_MIGRATION_SERVICE": 1010, + "LOCERR_APP_MIGRATION_COULD_NOT_START_MIGRATION": 1011, + "LOCERR_APP_MIGRATION_FAILURE": 1012, + "LOCERR_APP_SCRIPT_MISSING": 1013, + "LOCERR_CONNECTION_ALREADY_EXISTS": 2000, + "LOCERR_CONNECTION_NOT_FOUND": 2001, + "LOCERR_CONNECTION_FAILED_TO_LOAD": 2002, + "LOCERR_CONNECTION_FAILED_TO_IMPORT": 2003, + "LOCERR_CONNECTION_NAME_IS_INVALID": 2004, + "LOCERR_FILE_ACCESS_DENIED": 3000, + "LOCERR_FILE_NAME_INVALID": 3001, + "LOCERR_FILE_CORRUPT": 3002, + "LOCERR_FILE_NOT_FOUND": 3003, + "LOCERR_FILE_FORMAT_UNSUPPORTED": 3004, + "LOCERR_FILE_OPENED_IN_UNSUPPORTED_MODE": 3005, + "LOCERR_USER_ACCESS_DENIED": 4000, + "LOCERR_USER_IMPERSONATION_FAILED": 4001, + "LOCERR_SERVER_OUT_OF_SESSION_AND_USER_CALS": 5000, + "LOCERR_SERVER_OUT_OF_SESSION_CALS": 5001, + "LOCERR_SERVER_OUT_OF_USAGE_CALS": 5002, + "LOCERR_SERVER_OUT_OF_CALS": 5003, + "LOCERR_SERVER_OUT_OF_NAMED_CALS": 5004, + "LOCERR_SERVER_OFF_DUTY": 5005, + "LOCERR_SERVER_BUSY": 5006, + "LOCERR_SERVER_LICENSE_EXPIRED": 5007, + "LOCERR_SERVER_AJAX_DISABLED": 5008, + "LOCERR_HC_INVALID_OBJECT": 6000, + "LOCERR_HC_RESULT_TOO_LARGE": 6001, + "LOCERR_HC_INVALID_OBJECT_STATE": 6002, + "LOCERR_HC_MODAL_OBJECT_ERROR": 6003, + "LOCERR_CALC_INVALID_DEF": 7000, + "LOCERR_CALC_NOT_IN_LIB": 7001, + "LOCERR_CALC_HEAP_ERROR": 7002, + "LOCERR_CALC_TOO_LARGE": 7003, + "LOCERR_CALC_TIMEOUT": 7004, + "LOCERR_CALC_EVAL_CONDITION_FAILED": 7005, + "LOCERR_CALC_MIXED_LINKED_AGGREGATION": 7006, + "LOCERR_CALC_MISSING_LINKED": 7007, + "LOCERR_CALC_INVALID_COL_SORT": 7008, + "LOCERR_CALC_PAGES_TOO_LARGE": 7009, + "LOCERR_CALC_SEMANTIC_FIELD_NOT_ALLOWED": 7010, + "LOCERR_CALC_VALIDATION_STATE_INVALID": 7011, + "LOCERR_CALC_PIVOT_DIMENSIONS_ALREADY_EXISTS": 7012, + "LOCERR_CALC_MISSING_LINKED_FIELD": 7013, + "LOCERR_LAYOUT_EXTENDS_INVALID_ID": 8000, + "LOCERR_LAYOUT_LINKED_OBJECT_NOT_FOUND": 8001, + "LOCERR_LAYOUT_LINKED_OBJECT_INVALID": 8002, + "LOCERR_PERSISTENCE_WRITE_FAILED": 9000, + "LOCERR_PERSISTENCE_READ_FAILED": 9001, + "LOCERR_PERSISTENCE_DELETE_FAILED": 9002, + "LOCERR_PERSISTENCE_NOT_FOUND": 9003, + "LOCERR_PERSISTENCE_UNSUPPORTED_VERSION": 9004, + "LOCERR_PERSISTENCE_MIGRATION_FAILED_READ_ONLY": 9005, + "LOCERR_PERSISTENCE_MIGRATION_CANCELLED": 9006, + "LOCERR_PERSISTENCE_MIGRATION_BACKUP_FAILED": 9007, + "LOCERR_PERSISTENCE_DISK_FULL": 9008, + "LOCERR_PERSISTENCE_NOT_SUPPORTED_FOR_SESSION_APP": 9009, + "LOCERR_PERSISTENCE_SYNC_SET_CHUNK_INVALID_PARAMETERS": 9510, + "LOCERR_PERSISTENCE_SYNC_GET_CHUNK_INVALID_PARAMETERS": 9511, + "LOCERR_SCRIPT_DATASOURCE_ACCESS_DENIED": 10000, + "LOCERR_RELOAD_IN_PROGRESS": 11000, + "LOCERR_RELOAD_TABLE_X_NOT_FOUND": 11001, + "LOCERR_RELOAD_UNKNOWN_STATEMENT": 11002, + "LOCERR_RELOAD_EXPECTED_SOMETHING_FOUND_UNKNOWN": 11003, + "LOCERR_RELOAD_EXPECTED_NOTHING_FOUND_UNKNOWN": 11004, + "LOCERR_RELOAD_EXPECTED_ONE_OF_1_TOKENS_FOUND_UNKNOWN": 11005, + "LOCERR_RELOAD_EXPECTED_ONE_OF_2_TOKENS_FOUND_UNKNOWN": 11006, + "LOCERR_RELOAD_EXPECTED_ONE_OF_3_TOKENS_FOUND_UNKNOWN": 11007, + "LOCERR_RELOAD_EXPECTED_ONE_OF_4_TOKENS_FOUND_UNKNOWN": 11008, + "LOCERR_RELOAD_EXPECTED_ONE_OF_5_TOKENS_FOUND_UNKNOWN": 11009, + "LOCERR_RELOAD_EXPECTED_ONE_OF_6_TOKENS_FOUND_UNKNOWN": 11010, + "LOCERR_RELOAD_EXPECTED_ONE_OF_7_TOKENS_FOUND_UNKNOWN": 11011, + "LOCERR_RELOAD_EXPECTED_ONE_OF_8_OR_MORE_TOKENS_FOUND_UNKNOWN": 11012, + "LOCERR_RELOAD_FIELD_X_NOT_FOUND": 11013, + "LOCERR_RELOAD_MAPPING_TABLE_X_NOT_FOUND": 11014, + "LOCERR_RELOAD_LIB_CONNECTION_X_NOT_FOUND": 11015, + "LOCERR_RELOAD_NAME_ALREADY_TAKEN": 11016, + "LOCERR_RELOAD_WRONG_FILE_FORMAT_DIF": 11017, + "LOCERR_RELOAD_WRONG_FILE_FORMAT_BIFF": 11018, + "LOCERR_RELOAD_WRONG_FILE_FORMAT_ENCRYPTED": 11019, + "LOCERR_RELOAD_OPEN_FILE_ERROR": 11020, + "LOCERR_RELOAD_AUTO_GENERATE_COUNT": 11021, + "LOCERR_RELOAD_PE_ILLEGAL_PREFIX_COMB": 11022, + "LOCERR_RELOAD_MATCHING_CONTROL_STATEMENT_ERROR": 11023, + "LOCERR_RELOAD_MATCHING_LIBPATH_X_NOT_FOUND": 11024, + "LOCERR_RELOAD_MATCHING_LIBPATH_X_INVALID": 11025, + "LOCERR_RELOAD_MATCHING_LIBPATH_X_OUTSIDE": 11026, + "LOCERR_RELOAD_NO_QUALIFIED_PATH_FOR_FILE": 11027, + "LOCERR_RELOAD_MODE_STATEMENT_ONLY_FOR_LIB_PATHS": 11028, + "LOCERR_RELOAD_INCONSISTENT_USE_OF_SEMANTIC_FIELDS": 11029, + "LOCERR_RELOAD_NO_OPEN_DATABASE": 11030, + "LOCERR_RELOAD_AGGREGATION_REQUIRED_BY_GROUP_BY": 11031, + "LOCERR_RELOAD_CONNECT_MUST_USE_LIB_PREFIX_IN_THIS_MODE": 11032, + "LOCERR_RELOAD_ODBC_CONNECT_FAILED": 11033, + "LOCERR_RELOAD_OLEDB_CONNECT_FAILED": 11034, + "LOCERR_RELOAD_CUSTOM_CONNECT_FAILED": 11035, + "LOCERR_RELOAD_ODBC_READ_FAILED": 11036, + "LOCERR_RELOAD_OLEDB_READ_FAILED": 11037, + "LOCERR_RELOAD_CUSTOM_READ_FAILED": 11038, + "LOCERR_RELOAD_BINARY_LOAD_PROHIBITED": 11039, + "LOCERR_RELOAD_CONNECTOR_START_FAILED": 11040, + "LOCERR_RELOAD_CONNECTOR_NOT_RESPONDING": 11041, + "LOCERR_RELOAD_CONNECTOR_REPLY_ERROR": 11042, + "LOCERR_PERSONAL_NEW_VERSION_AVAILABLE": 12000, + "LOCERR_PERSONAL_VERSION_EXPIRED": 12001, + "LOCERR_PERSONAL_SECTION_ACCESS_DETECTED": 12002, + "LOCERR_PERSONAL_APP_DELETION_FAILED": 12003, + "LOCERR_EXPORT_OUT_OF_MEMORY": 13000, + "LOCERR_EXPORT_NO_DATA": 13001, + "LOCERR_SYNC_INVALID_OFFSET": 14000, + "LOCERR_SEARCH_TIMEOUT": 15000, + "LOCERR_DIRECT_DISCOVERY_LINKED_EXPRESSION_FAIL": 16000, + "LOCERR_DIRECT_DISCOVERY_ROWCOUNT_OVERFLOW": 16001, + "LOCERR_DIRECT_DISCOVERY_EMPTY_RESULT": 16002, + "LOCERR_DIRECT_DISCOVERY_DB_CONNECTION_FAILED": 16003, + "LOCERR_DIRECT_DISCOVERY_MEASURE_NOT_ALLOWED": 16004, + "LOCERR_DIRECT_DISCOVERY_DETAIL_NOT_ALLOWED": 16005, + "LOCERR_DIRECT_DISCOVERY_NOT_SYNTH_CIRCULAR_ALLOWED": 16006, + "LOCERR_DIRECT_DISCOVERY_ONLY_ONE_DD_TABLE_ALLOWED": 16007, + "LOCERR_DIRECT_DISCOVERY_DB_AUTHORIZATION_FAILED": 16008, + "LOCERR_SMART_LOAD_TABLE_NOT_FOUND": 17000, + "LOCERR_SMART_LOAD_TABLE_DUPLICATED": 17001, + "LOCERR_VARIABLE_NO_NAME": 18000, + "LOCERR_VARIABLE_DUPLICATE_NAME": 18001, + "LOCERR_VARIABLE_INCONSISTENCY": 18002, + "LOCERR_MEDIA_LIBRARY_LIST_FAILED": 19000, + "LOCERR_MEDIA_LIBRARY_CONTENT_FAILED": 19001, + "LOCERR_MEDIA_BUNDLING_FAILED": 19002, + "LOCERR_MEDIA_UNBUNDLING_FAILED": 19003, + "LOCERR_MEDIA_LIBRARY_NOT_FOUND": 19004, + "LOCERR_FEATURE_DISABLED": 20000, + "LOCERR_JSON_RPC_INVALID_REQUEST": -32600, + "LOCERR_JSON_RPC_METHOD_NOT_FOUND": -32601, + "LOCERR_JSON_RPC_INVALID_PARAMETERS": -32602, + "LOCERR_JSON_RPC_INTERNAL_ERROR": -32603, + "LOCERR_JSON_RPC_PARSE_ERROR": -32700 + }, + "LocalizedWarningCode": { + "LOCWARN_PERSONAL_RELOAD_REQUIRED": 0, + "LOCWARN_PERSONAL_VERSION_EXPIRES_SOON": 1, + "LOCWARN_EXPORT_DATA_TRUNCATED": 1000, + "LOCWARN_COULD_NOT_OPEN_ALL_OBJECTS": 2000 + }, + "GrpType": { + "GRP_NX_NONE": 0, + "GRP_NX_HIEARCHY": 1, + "GRP_NX_COLLECTION": 2 + }, + "ExportFileType": { + "EXPORT_CSV_C": 0, + "EXPORT_CSV_T": 1, + "EXPORT_OOXML": 2 + }, + "ExportState": { + "EXPORT_POSSIBLE": 0, + "EXPORT_ALL": 1 + }, + "DimCellType": { + "NX_DIM_CELL_VALUE": 0, + "NX_DIM_CELL_EMPTY": 1, + "NX_DIM_CELL_NORMAL": 2, + "NX_DIM_CELL_TOTAL": 3, + "NX_DIM_CELL_OTHER": 4, + "NX_DIM_CELL_AGGR": 5, + "NX_DIM_CELL_PSEUDO": 6, + "NX_DIM_CELL_ROOT": 7, + "NX_DIM_CELL_NULL": 8 + }, + "StackElemType": { + "NX_STACK_CELL_NORMAL": 0, + "NX_STACK_CELL_TOTAL": 1, + "NX_STACK_CELL_OTHER": 2, + "NX_STACK_CELL_SUM": 3, + "NX_STACK_CELL_VALUE": 4, + "NX_STACK_CELL_PSEUDO": 5 + }, + "SortIndicatorType": { + "NX_SORT_INDICATE_NONE": 0, + "NX_SORT_INDICATE_ASC": 1, + "NX_SORT_INDICATE_DESC": 2 + }, + "DimensionType": { + "NX_DIMENSION_TYPE_DISCRETE": 0, + "NX_DIMENSION_TYPE_NUMERIC": 1, + "NX_DIMENSION_TYPE_TIME": 2 + }, + "FieldSelectionMode": { + "SELECTION_MODE_NORMAL": 0, + "SELECTION_MODE_AND": 1, + "SELECTION_MODE_NOT": 2 + }, + "FrequencyMode": { + "NX_FREQUENCY_NONE": 0, + "NX_FREQUENCY_VALUE": 1, + "NX_FREQUENCY_PERCENT": 2, + "NX_FREQUENCY_RELATIVE": 3 + }, + "DataReductionMode": { + "DATA_REDUCTION_NONE": 0, + "DATA_REDUCTION_ONEDIM": 1, + "DATA_REDUCTION_SCATTERED": 2, + "DATA_REDUCTION_CLUSTERED": 3, + "DATA_REDUCTION_STACKED": 4 + }, + "HypercubeMode": { + "DATA_MODE_STRAIGHT": 0, + "DATA_MODE_PIVOT": 1, + "DATA_MODE_PIVOT_STACK": 2 + }, + "PatchOperationType": { + "Add": 0, + "Remove": 1, + "Replace": 2 + }, + "SelectionCellType": { + "NX_CELL_DATA": 0, + "NX_CELL_TOP": 1, + "NX_CELL_LEFT": 2 + }, + "MatchingFieldMode": { + "MATCHINGFIELDMODE_MATCH_ALL": 0, + "MATCHINGFIELDMODE_MATCH_ONE": 1 + }, + "ExtEngineDataType": { + "NX_EXT_DATATYPE_STRING": 0, + "NX_EXT_DATATYPE_DOUBLE": 1, + "NX_EXT_DATATYPE_BOTH": 2 + }, + "ExtEngineFunctionType": { + "NX_EXT_FUNCTIONTYPE_SCALAR": 0, + "NX_EXT_FUNCTIONTYPE_AGGR": 1, + "NX_EXT_FUNCTIONTYPE_TENSOR": 2 + }, + "ExtEngineMsgType": { + "NX_EXT_MSGTYPE_FUNCTION_CALL": 1, + "NX_EXT_MSGTYPE_SCRIPT_CALL": 2, + "NX_EXT_MSGTYPE_RETURN_VALUE": 3, + "NX_EXT_MSGTYPE_RETURN_MULTIPLE": 4, + "NX_EXT_MSGTYPE_RETURN_ERROR": 5 + } + }, + "version": "3.1" +} diff --git a/jwt-scratch/src/js/node_modules/enigma.js/schemas/3.2.json b/jwt-scratch/src/js/node_modules/enigma.js/schemas/3.2.json new file mode 100644 index 0000000..643734f --- /dev/null +++ b/jwt-scratch/src/js/node_modules/enigma.js/schemas/3.2.json @@ -0,0 +1,1515 @@ +{ + "structs": { + "Field":{ + "GetCardinal": { + "In": [], + "Out": [] + }, + "GetAndMode": { + "In": [], + "Out": [] + }, + "SelectValues": { + "In": [{ "Name": "qFieldValues","DefaultValue": [{"qText": "", "qIsNumeric": false, "qNumber": 0}] }, { "Name": "qToggleMode","DefaultValue": false, "Optional": true }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Select": { + "In": [{ "Name": "qMatch","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qExcludedValuesMode","DefaultValue": 0, "Optional": true }], + "Out": [] + }, + "ToggleSelect": { + "In": [{ "Name": "qMatch","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qExcludedValuesMode","DefaultValue": 0, "Optional": true }], + "Out": [] + }, + "ClearAllButThis": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectPossible": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectExcluded": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "SelectAll": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Lock": { + "In": [], + "Out": [] + }, + "Unlock": { + "In": [], + "Out": [] + }, + "GetNxProperties": { + "In": [], + "Out": [{ "Name": "qProperties" }] + }, + "SetNxProperties": { + "In": [{ "Name": "qProperties","DefaultValue": {"qOneAndOnlyOne": false} }], + "Out": [] + }, + "SetAndMode": { + "In": [{ "Name": "qAndMode","DefaultValue": false }], + "Out": [] + }, + "SelectAlternative": { + "In": [{ "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "LowLevelSelect": { + "In": [{ "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "Clear": { + "In": [], + "Out": [] + } + }, + "Variable":{ + "GetContent": { + "In": [], + "Out": [{ "Name": "qContent" }] + }, + "GetRawContent": { + "In": [], + "Out": [] + }, + "SetContent": { + "In": [{ "Name": "qContent","DefaultValue": "" }, { "Name": "qUpdateMRU","DefaultValue": false }], + "Out": [] + }, + "ForceContent": { + "In": [{ "Name": "qs","DefaultValue": "" }, { "Name": "qd","DefaultValue": 0 }], + "Out": [] + }, + "GetNxProperties": { + "In": [], + "Out": [{ "Name": "qProperties" }] + }, + "SetNxProperties": { + "In": [{ "Name": "qProperties","DefaultValue": {"qName": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qUsePredefListedValues": false, "qPreDefinedList": [""]} }], + "Out": [] + } + }, + "GenericObject":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "GetListObjectData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeReducedData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qZoomFactor","DefaultValue": 0 }, { "Name": "qReductionMode","DefaultValue": 0 }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubePivotData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeStackData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qMaxNbrCells","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qDataPages" }] + }, + "GetHyperCubeContinuousData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qOptions","DefaultValue": {"qStart": 0, "qEnd": 0, "qNbrPoints": 0, "qMaxNbrTicks": 0, "qMaxNumberLines": 0} }, { "Name": "qReverseSort","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qDataPages" }, { "Name": "qAxisData" }] + }, + "GetHyperCubeBinnedData": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qPages","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qViewport","DefaultValue": {"qWidth": 0, "qHeight": 0, "qZoomLevel": 0} }, { "Name": "qDataRanges","DefaultValue": [{"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}] }, { "Name": "qMaxNbrCells","DefaultValue": 0 }, { "Name": "qQueryLevel","DefaultValue": 0 }, { "Name": "qBinningMethod","DefaultValue": 0 }], + "Out": [{ "Name": "qDataPages" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }, { "Name": "qSoftPatch","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "ClearSoftPatches": { + "In": [], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetEffectiveProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "SetFullPropertyTree": { + "In": [{ "Name": "qPropEntry","DefaultValue": {"qProperty": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}}, "qChildren": [], "qEmbeddedSnapshotRef": null} }], + "Out": [] + }, + "GetFullPropertyTree": { + "In": [], + "Out": [{ "Name": "qPropEntry" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "ClearSelections": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "ExportData": { + "In": [{ "Name": "qFileType","DefaultValue": 0 }, { "Name": "qPath","DefaultValue": "", "Optional": true }, { "Name": "qFileName","DefaultValue": "", "Optional": true }, { "Name": "qExportState","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qUrl" }, { "Name": "qWarnings" }] + }, + "SelectListObjectValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectPossible": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectExcluded": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectAlternative": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectAll": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectListObjectContinuousRange": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SearchListObjectFor": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qMatch","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "AbortListObjectSearch": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [] + }, + "AcceptListObjectSearch": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qToggleMode","DefaultValue": false }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "ExpandLeft": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "ExpandTop": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "CollapseLeft": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "CollapseTop": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRow","DefaultValue": 0 }, { "Name": "qCol","DefaultValue": 0 }, { "Name": "qAll","DefaultValue": false }], + "Out": [] + }, + "DrillUp": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qDimNo","DefaultValue": 0 }, { "Name": "qNbrSteps","DefaultValue": 0 }], + "Out": [] + }, + "Lock": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "Unlock": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qColIndices","DefaultValue": [0], "Optional": true }], + "Out": [] + }, + "SelectHyperCubeValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qDimNo","DefaultValue": 0 }, { "Name": "qValues","DefaultValue": [0] }, { "Name": "qToggleMode","DefaultValue": false }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectHyperCubeCells": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRowIndices","DefaultValue": [0] }, { "Name": "qColIndices","DefaultValue": [0] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectPivotCells": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qSelections","DefaultValue": [{"qType": 0, "qCol": 0, "qRow": 0}] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "RangeSelectHyperCubeValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qRange": {"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}, "qMeasureIx": 0}] }, { "Name": "qColumnsToSelect","DefaultValue": [0], "Optional": true }, { "Name": "qOrMode","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "MultiRangeSelectHyperCubeValues": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qRanges": [{"qRange": {"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}, "qMeasureIx": 0}], "qColumnsToSelect": [0]}] }, { "Name": "qOrMode","DefaultValue": false, "Optional": true }, { "Name": "qDeselectOnlyOneSelected","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "SelectHyperCubeContinuousRange": { + "In": [{ "Name": "qPath","DefaultValue": "" }, { "Name": "qRanges","DefaultValue": [{"qRange": {"qMin": 0, "qMax": 0, "qMinInclEq": false, "qMaxInclEq": false}, "qDimIx": 0}] }, { "Name": "qSoftLock","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetChild": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetChildInfos": { + "In": [], + "Out": [{ "Name": "qInfos" }] + }, + "CreateChild": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }, { "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyChild": { + "In": [{ "Name": "qId","DefaultValue": "" }, { "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [{ "Name": "qSuccess" }] + }, + "DestroyAllChildren": { + "In": [{ "Name": "qPropForThis","DefaultValue": null, "Optional": true }], + "Out": [] + }, + "SetChildArrayOrder": { + "In": [{ "Name": "qIds","DefaultValue": [""] }], + "Out": [] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "CopyFrom": { + "In": [{ "Name": "qFromId","DefaultValue": "" }], + "Out": [] + }, + "BeginSelections": { + "In": [{ "Name": "qPaths","DefaultValue": [""] }], + "Out": [] + }, + "EndSelections": { + "In": [{ "Name": "qAccept","DefaultValue": false }], + "Out": [] + }, + "ResetMadeSelections": { + "In": [], + "Out": [] + }, + "EmbedSnapshotObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetSnapshotObject": { + "In": [], + "Out": [] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericDimension":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDim": {"qGrouping": 0, "qFieldDefs": [""], "qFieldLabels": [""]}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetDimension": { + "In": [], + "Out": [{ "Name": "qDim" }] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericBookmark":{ + "GetFieldValues": { + "In": [{ "Name": "qField","DefaultValue": "" }, { "Name": "qGetExcludedValues","DefaultValue": false }, { "Name": "qDataPage","DefaultValue": {"qStartIndex": 0, "qEndIndex": 0} }], + "Out": [{ "Name": "qFieldValues" }] + }, + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "Apply": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericVariable":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "SetStringValue": { + "In": [{ "Name": "qVal","DefaultValue": "" }], + "Out": [] + }, + "SetNumValue": { + "In": [{ "Name": "qVal","DefaultValue": 0 }], + "Out": [] + }, + "SetDualValue": { + "In": [{ "Name": "qText","DefaultValue": "" }, { "Name": "qNum","DefaultValue": 0 }], + "Out": [] + } + }, + "GenericMeasure":{ + "GetLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "ApplyPatches": { + "In": [{ "Name": "qPatches","DefaultValue": [{"qOp": 0, "qPath": "", "qValue": ""}] }], + "Out": [] + }, + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMeasure": {"qLabel": "", "qDef": "", "qGrouping": 0, "qExpressions": [""], "qActiveExpression": 0}, "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetMeasure": { + "In": [], + "Out": [{ "Name": "qMeasure" }] + }, + "GetLinkedObjects": { + "In": [], + "Out": [{ "Name": "qItems" }] + }, + "Publish": { + "In": [], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + } + }, + "GenericDerivedFields":{ + "SetProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDerivedDefinitionId": "", "qFieldName": [""], "qMetaDef": {}} }], + "Out": [] + }, + "GetProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "GetInfo": { + "In": [], + "Out": [{ "Name": "qInfo" }] + }, + "GetDerivedFieldData": { + "In": [], + "Out": [{ "Name": "qData" }] + }, + "GetDerivedField": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qFields" }] + }, + "GetListData": { + "In": [], + "Out": [{ "Name": "qListData" }] + }, + "GetDerivedFields": { + "In": [], + "Out": [{ "Name": "qFields" }] + }, + "GetDerivedGroups": { + "In": [], + "Out": [{ "Name": "qGroups" }] + } + }, + "Doc":{ + "GetField": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }, { "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "GetFieldDescription": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }], + "Out": [] + }, + "GetVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "GetLooselyCoupledVector": { + "In": [], + "Out": [{ "Name": "qv" }] + }, + "SetLooselyCoupledVector": { + "In": [{ "Name": "qv","DefaultValue": [0] }], + "Out": [] + }, + "Evaluate": { + "In": [{ "Name": "qExpression","DefaultValue": "" }], + "Out": [] + }, + "EvaluateEx": { + "In": [{ "Name": "qExpression","DefaultValue": "" }], + "Out": [{ "Name": "qValue" }] + }, + "ClearAll": { + "In": [{ "Name": "qLockedAlso","DefaultValue": false, "Optional": true }, { "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "LockAll": { + "In": [{ "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "UnlockAll": { + "In": [{ "Name": "qStateName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "Back": { + "In": [], + "Out": [] + }, + "Forward": { + "In": [], + "Out": [] + }, + "ReduceData": { + "In": [{ "Name": "qConfirm","DefaultValue": false, "Optional": true }, { "Name": "qDropFieldNames","DefaultValue": [""], "Optional": true }], + "Out": [] + }, + "RemoveAllData": { + "In": [{ "Name": "qConfirm","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "CreateVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "RemoveVariable": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "GetLocaleInfo": { + "In": [], + "Out": [] + }, + "GetTablesAndKeys": { + "In": [{ "Name": "qWindowSize","DefaultValue": {"qcx": 0, "qcy": 0} }, { "Name": "qNullSize","DefaultValue": {"qcx": 0, "qcy": 0} }, { "Name": "qCellHeight","DefaultValue": 0 }, { "Name": "qSyntheticMode","DefaultValue": false }, { "Name": "qIncludeSysVars","DefaultValue": false }], + "Out": [{ "Name": "qtr" }, { "Name": "qk" }] + }, + "GetViewDlgSaveInfo": { + "In": [], + "Out": [] + }, + "SetViewDlgSaveInfo": { + "In": [{ "Name": "qInfo","DefaultValue": {"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCtlInfo": {"qInternalView": {"qTables": [{"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCaption": ""}], "qBroomPoints": [{"qPos": {"qx": 0, "qy": 0}, "qTable": "", "qFields": [""]}], "qConnectionPoints": [{"qPos": {"qx": 0, "qy": 0}, "qFields": [""]}], "qZoomFactor": 0}, "qSourceView": {"qTables": [{"qPos": {"qLeft": 0, "qTop": 0, "qWidth": 0, "qHeight": 0}, "qCaption": ""}], "qBroomPoints": [{"qPos": {"qx": 0, "qy": 0}, "qTable": "", "qFields": [""]}], "qConnectionPoints": [{"qPos": {"qx": 0, "qy": 0}, "qFields": [""]}], "qZoomFactor": 0}}, "qMode": 0} }], + "Out": [] + }, + "GetEmptyScript": { + "In": [{ "Name": "qLocalizedMainSection","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "DoReload": { + "In": [{ "Name": "qMode","DefaultValue": 0, "Optional": true }, { "Name": "qPartial","DefaultValue": false, "Optional": true }, { "Name": "qDebug","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "GetScriptBreakpoints": { + "In": [], + "Out": [{ "Name": "qBreakpoints" }] + }, + "SetScriptBreakpoints": { + "In": [{ "Name": "qBreakpoints","DefaultValue": [{"qbufferName": "", "qlineIx": 0, "qEnabled": false}] }], + "Out": [] + }, + "GetScript": { + "In": [], + "Out": [{ "Name": "qScript" }] + }, + "GetTextMacros": { + "In": [], + "Out": [{ "Name": "qMacros" }] + }, + "SetFetchLimit": { + "In": [{ "Name": "qLimit","DefaultValue": 0 }], + "Out": [] + }, + "DoSave": { + "In": [{ "Name": "qFileName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "GetTableData": { + "In": [{ "Name": "qOffset","DefaultValue": 0 }, { "Name": "qRows","DefaultValue": 0 }, { "Name": "qSyntheticMode","DefaultValue": false }, { "Name": "qTableName","DefaultValue": "" }], + "Out": [{ "Name": "qData" }] + }, + "GetAppLayout": { + "In": [], + "Out": [{ "Name": "qLayout" }] + }, + "SetAppProperties": { + "In": [{ "Name": "qProp","DefaultValue": {"qTitle": "", "qLastReloadTime": "", "qMigrationHash": "", "qSavedInProductVersion": "", "qThumbnail": {"qUrl": ""}} }], + "Out": [] + }, + "GetAppProperties": { + "In": [], + "Out": [{ "Name": "qProp" }] + }, + "CreateSessionObject": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }], + "Out": [] + }, + "DestroySessionObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CreateObject": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qExtendsId": "", "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "CloneObject": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qDraftId" }] + }, + "CommitDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "DestroyDraft": { + "In": [{ "Name": "qId","DefaultValue": "" }, { "Name": "qSourceId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "Undo": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "Redo": { + "In": [], + "Out": [{ "Name": "qSuccess" }] + }, + "ClearUndoBuffer": { + "In": [], + "Out": [] + }, + "CreateDimension": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qDim": {"qGrouping": 0, "qFieldDefs": [""], "qFieldLabels": [""]}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "CloneDimension": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateMeasure": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMeasure": {"qLabel": "", "qDef": "", "qGrouping": 0, "qExpressions": [""], "qActiveExpression": 0}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "CloneMeasure": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "CreateSessionVariable": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [] + }, + "DestroySessionVariable": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CreateVariableEx": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}, "qName": "", "qComment": "", "qNumberPresentation": {"qType": 0, "qnDec": 0, "qUseThou": 0, "qFmt": "", "qDec": "", "qThou": ""}, "qIncludeInBookmark": false, "qDefinition": ""} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyVariableById": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "DestroyVariableByName": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetVariableById": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "GetVariableByName": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [] + }, + "MigrateVariables": { + "In": [], + "Out": [] + }, + "MigrateDerivedFields": { + "In": [], + "Out": [] + }, + "CheckExpression": { + "In": [{ "Name": "qExpr","DefaultValue": "" }, { "Name": "qLabels","DefaultValue": [""], "Optional": true }], + "Out": [{ "Name": "qErrorMsg" }, { "Name": "qBadFieldNames" }, { "Name": "qDangerousFieldNames" }] + }, + "CheckNumberOrExpression": { + "In": [{ "Name": "qExpr","DefaultValue": "" }], + "Out": [{ "Name": "qErrorMsg" }, { "Name": "qBadFieldNames" }] + }, + "AddAlternateState": { + "In": [{ "Name": "qStateName","DefaultValue": "" }], + "Out": [] + }, + "RemoveAlternateState": { + "In": [{ "Name": "qStateName","DefaultValue": "" }], + "Out": [] + }, + "CreateBookmark": { + "In": [{ "Name": "qProp","DefaultValue": {"qInfo": {"qId": "", "qType": ""}, "qMetaDef": {}} }], + "Out": [{ "Name": "qInfo" }] + }, + "DestroyBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [] + }, + "ApplyBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "CloneBookmark": { + "In": [{ "Name": "qId","DefaultValue": "" }], + "Out": [{ "Name": "qCloneId" }] + }, + "AddFieldFromExpression": { + "In": [{ "Name": "qName","DefaultValue": "" }, { "Name": "qExpr","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "GetAllInfos": { + "In": [], + "Out": [{ "Name": "qInfos" }] + }, + "Resume": { + "In": [], + "Out": [] + }, + "AbortModal": { + "In": [{ "Name": "qAccept","DefaultValue": false }], + "Out": [] + }, + "Publish": { + "In": [{ "Name": "qStreamId","DefaultValue": "" }, { "Name": "qName","DefaultValue": "", "Optional": true }], + "Out": [] + }, + "UnPublish": { + "In": [], + "Out": [] + }, + "GetMatchingFields": { + "In": [{ "Name": "qTags","DefaultValue": [""] }, { "Name": "qMatchingFieldMode","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qFieldNames" }] + }, + "FindMatchingFields": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }, { "Name": "qTags","DefaultValue": [""] }], + "Out": [{ "Name": "qFieldNames" }] + }, + "Scramble": { + "In": [{ "Name": "qFieldName","DefaultValue": "" }], + "Out": [] + }, + "SaveObjects": { + "In": [], + "Out": [] + }, + "GetAssociationScores": { + "In": [{ "Name": "qTable1","DefaultValue": "" }, { "Name": "qTable2","DefaultValue": "" }], + "Out": [{ "Name": "qScore" }] + }, + "GetMediaList": { + "In": [], + "Out": [{ "Name": "qList" }] + }, + "GetContentLibraries": { + "In": [], + "Out": [{ "Name": "qList" }] + }, + "GetLibraryContent": { + "In": [{ "Name": "qName","DefaultValue": "" }], + "Out": [{ "Name": "qList" }] + }, + "DoReloadEx": { + "In": [{ "Name": "qParams","DefaultValue": {"qMode": 0, "qPartial": false, "qDebug": false}, "Optional": true }], + "Out": [{ "Name": "qResult" }] + }, + "BackCount": { + "In": [], + "Out": [] + }, + "ForwardCount": { + "In": [], + "Out": [] + }, + "SetScript": { + "In": [{ "Name": "qScript","DefaultValue": "" }], + "Out": [] + }, + "CheckScriptSyntax": { + "In": [], + "Out": [{ "Name": "qErrors" }] + }, + "GetFavoriteVariables": { + "In": [], + "Out": [{ "Name": "qNames" }] + }, + "SetFavoriteVariables": { + "In": [{ "Name": "qNames","DefaultValue": [""] }], + "Out": [] + }, + "GetIncludeFileContent": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [{ "Name": "qContent" }] + }, + "CreateConnection": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }], + "Out": [{ "Name": "qConnectionId" }] + }, + "ModifyConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }, { "Name": "qOverrideCredentials","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "DeleteConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [] + }, + "GetConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qConnection" }] + }, + "GetConnections": { + "In": [], + "Out": [{ "Name": "qConnections" }] + }, + "GetDatabaseInfo": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qInfo" }] + }, + "GetDatabases": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }], + "Out": [{ "Name": "qDatabases" }] + }, + "GetDatabaseOwners": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qOwners" }] + }, + "GetDatabaseTables": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qTables" }] + }, + "GetDatabaseTableFields": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qFields" }] + }, + "GetDatabaseTablePreview": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qDatabase","DefaultValue": "", "Optional": true }, { "Name": "qOwner","DefaultValue": "", "Optional": true }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qPreview" }] + }, + "GetFolderItemsForConnection": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qFolderItems" }] + }, + "GuessFileType": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qDataFormat" }] + }, + "GetFileTables": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }], + "Out": [{ "Name": "qTables" }] + }, + "GetFileTableFields": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qFields" }, { "Name": "qFormatSpec" }] + }, + "GetFileTablePreview": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }, { "Name": "qTable","DefaultValue": "" }], + "Out": [{ "Name": "qPreview" }, { "Name": "qFormatSpec" }] + }, + "GetFileTablesEx": { + "In": [{ "Name": "qConnectionId","DefaultValue": "" }, { "Name": "qRelativePath","DefaultValue": "", "Optional": true }, { "Name": "qDataFormat","DefaultValue": {"qType": 0, "qLabel": "", "qQuote": "", "qComment": "", "qDelimiter": {"qName": "", "qScriptCode": "", "qNumber": 0, "qIsMultiple": false}, "qCodePage": 0, "qHeaderSize": 0, "qRecordSize": 0, "qTabSize": 0, "qIgnoreEOF": false, "qFixedWidthDelimiters": ""} }], + "Out": [{ "Name": "qTables" }] + }, + "SendGenericCommandToCustomConnector": { + "In": [{ "Name": "qProvider","DefaultValue": "" }, { "Name": "qCommand","DefaultValue": "" }, { "Name": "qMethod","DefaultValue": "" }, { "Name": "qParameters","DefaultValue": [""] }, { "Name": "qAppendConnection","DefaultValue": "" }], + "Out": [{ "Name": "qResult" }] + }, + "SearchSuggest": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0} }, { "Name": "qTerms","DefaultValue": [""] }], + "Out": [{ "Name": "qResult" }] + }, + "SearchAssociations": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qPage","DefaultValue": {"qOffset": 0, "qCount": 0, "qMaxNbrFieldMatches": 0, "qGroupOptions": [{"qGroupType": 0, "qOffset": 0, "qCount": 0}], "qGroupItemOptions": [{"qGroupItemType": 0, "qOffset": 0, "qCount": 0}]} }], + "Out": [{ "Name": "qResults" }] + }, + "SelectAssociations": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qMatchIx","DefaultValue": 0 }, { "Name": "qSoftLock","DefaultValue": null, "Optional": true }], + "Out": [] + }, + "SearchResults": { + "In": [{ "Name": "qOptions","DefaultValue": {"qSearchFields": [""], "qContext": 0} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qPage","DefaultValue": {"qOffset": 0, "qCount": 0, "qMaxNbrFieldMatches": 0, "qGroupOptions": [{"qGroupType": 0, "qOffset": 0, "qCount": 0}], "qGroupItemOptions": [{"qGroupItemType": 0, "qOffset": 0, "qCount": 0}]} }], + "Out": [{ "Name": "qResult" }] + }, + "SearchObjects": { + "In": [{ "Name": "qOptions","DefaultValue": {"qAttributes": [""]} }, { "Name": "qTerms","DefaultValue": [""] }, { "Name": "qPage","DefaultValue": {"qOffset": 0, "qCount": 0, "qMaxNbrFieldMatches": 0, "qGroupOptions": [{"qGroupType": 0, "qOffset": 0, "qCount": 0}], "qGroupItemOptions": [{"qGroupItemType": 0, "qOffset": 0, "qCount": 0}]} }], + "Out": [{ "Name": "qResult" }] + } + }, + "Global":{ + "AbortRequest": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [] + }, + "AbortAll": { + "In": [], + "Out": [] + }, + "GetProgress": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [{ "Name": "qProgressData" }] + }, + "QvVersion": { + "In": [], + "Out": [] + }, + "OSVersion": { + "In": [], + "Out": [] + }, + "OSName": { + "In": [], + "Out": [] + }, + "QTProduct": { + "In": [], + "Out": [] + }, + "GetDocList": { + "In": [], + "Out": [{ "Name": "qDocList" }] + }, + "GetInteract": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [{ "Name": "qDef" }] + }, + "InteractDone": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }, { "Name": "qDef","DefaultValue": {"qType": 0, "qTitle": "", "qMsg": "", "qButtons": 0, "qLine": "", "qOldLineNr": 0, "qNewLineNr": 0, "qPath": "", "qHidden": false, "qResult": 0, "qInput": ""} }], + "Out": [] + }, + "GetAuthenticatedUser": { + "In": [], + "Out": [] + }, + "GetStreamList": { + "In": [], + "Out": [{ "Name": "qStreamList" }] + }, + "UploadToContentService": { + "In": [{ "Name": "qDirectory","DefaultValue": "" }, { "Name": "qAppId","DefaultValue": "" }, { "Name": "qQrsObjects","DefaultValue": [{"qEngineObjectID": "", "qItemID": ""}] }], + "Out": [{ "Name": "qUploadedObjects" }] + }, + "CreateDocEx": { + "In": [{ "Name": "qDocName","DefaultValue": "" }, { "Name": "qUserName","DefaultValue": "", "Optional": true }, { "Name": "qPassword","DefaultValue": "", "Optional": true }, { "Name": "qSerial","DefaultValue": "", "Optional": true }, { "Name": "qLocalizedScriptMainSection","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qDocId" }] + }, + "GetActiveDoc": { + "In": [], + "Out": [] + }, + "AllowCreateApp": { + "In": [], + "Out": [] + }, + "CreateApp": { + "In": [{ "Name": "qAppName","DefaultValue": "" }, { "Name": "qLocalizedScriptMainSection","DefaultValue": "", "Optional": true }], + "Out": [{ "Name": "qSuccess" }, { "Name": "qAppId" }] + }, + "DeleteApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }], + "Out": [{ "Name": "qSuccess" }] + }, + "IsDesktopMode": { + "In": [], + "Out": [] + }, + "GetConfiguration": { + "In": [], + "Out": [{ "Name": "qConfig" }] + }, + "CancelRequest": { + "In": [{ "Name": "qRequestId","DefaultValue": 0 }], + "Out": [] + }, + "ShutdownProcess": { + "In": [], + "Out": [] + }, + "ReloadExtensionList": { + "In": [], + "Out": [] + }, + "ReplaceAppFromID": { + "In": [{ "Name": "qTargetAppId","DefaultValue": "" }, { "Name": "qSrcAppID","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "CopyApp": { + "In": [{ "Name": "qTargetAppId","DefaultValue": "" }, { "Name": "qSrcAppId","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "ImportApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qSrcPath","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "ImportAppEx": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qSrcPath","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }, { "Name": "qExcludeConnections","DefaultValue": false }], + "Out": [] + }, + "ExportApp": { + "In": [{ "Name": "qTargetPath","DefaultValue": "" }, { "Name": "qSrcAppId","DefaultValue": "" }, { "Name": "qIds","DefaultValue": [""] }], + "Out": [{ "Name": "qSuccess" }] + }, + "PublishApp": { + "In": [{ "Name": "qAppId","DefaultValue": "" }, { "Name": "qName","DefaultValue": "" }, { "Name": "qStreamId","DefaultValue": "" }], + "Out": [] + }, + "IsPersonalMode": { + "In": [], + "Out": [] + }, + "GetUniqueID": { + "In": [], + "Out": [{ "Name": "qUniqueID" }] + }, + "OpenDoc": { + "In": [{ "Name": "qDocName","DefaultValue": "" }, { "Name": "qUserName","DefaultValue": "", "Optional": true }, { "Name": "qPassword","DefaultValue": "", "Optional": true }, { "Name": "qSerial","DefaultValue": "", "Optional": true }, { "Name": "qNoData","DefaultValue": false, "Optional": true }], + "Out": [] + }, + "CreateSessionApp": { + "In": [], + "Out": [{ "Name": "qSessionAppId" }] + }, + "CreateSessionAppFromApp": { + "In": [{ "Name": "qSrcAppId","DefaultValue": "" }], + "Out": [{ "Name": "qSessionAppId" }] + }, + "ProductVersion": { + "In": [], + "Out": [] + }, + "GetAppEntry": { + "In": [{ "Name": "qAppID","DefaultValue": "" }], + "Out": [{ "Name": "qEntry" }] + }, + "ConfigureReload": { + "In": [{ "Name": "qCancelOnScriptError","DefaultValue": false }, { "Name": "qUseErrorData","DefaultValue": false }, { "Name": "qInteractOnError","DefaultValue": false }], + "Out": [] + }, + "CancelReload": { + "In": [], + "Out": [] + }, + "GetBNF": { + "In": [{ "Name": "qBnfType","DefaultValue": 0 }], + "Out": [{ "Name": "qBnfDefs" }] + }, + "GetFunctions": { + "In": [{ "Name": "qGroup","DefaultValue": 0, "Optional": true }], + "Out": [{ "Name": "qFunctions" }] + }, + "GetOdbcDsns": { + "In": [], + "Out": [{ "Name": "qOdbcDsns" }] + }, + "GetOleDbProviders": { + "In": [], + "Out": [{ "Name": "qOleDbProviders" }] + }, + "GetDatabasesFromConnectionString": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }], + "Out": [{ "Name": "qDatabases" }] + }, + "IsValidConnectionString": { + "In": [{ "Name": "qConnection","DefaultValue": {"qId": "", "qName": "", "qConnectionString": "", "qType": "", "qUserName": "", "qPassword": "", "qModifiedDate": "", "qMeta": {"qName": ""}, "qLogOn": 0} }], + "Out": [] + }, + "GetDefaultAppFolder": { + "In": [], + "Out": [{ "Name": "qPath" }] + }, + "GetMyDocumentsFolder": { + "In": [], + "Out": [{ "Name": "qFolder" }] + }, + "GetLogicalDriveStrings": { + "In": [], + "Out": [{ "Name": "qDrives" }] + }, + "GetFolderItemsForPath": { + "In": [{ "Name": "qPath","DefaultValue": "" }], + "Out": [{ "Name": "qFolderItems" }] + }, + "GetSupportedCodePages": { + "In": [], + "Out": [{ "Name": "qCodePages" }] + }, + "GetCustomConnectors": { + "In": [{ "Name": "qReloadList","DefaultValue": false, "Optional": true }], + "Out": [{ "Name": "qConnectors" }] + }, + "EngineVersion": { + "In": [], + "Out": [{ "Name": "qVersion" }] + } + } + }, + "enums": { + "LocalizedMessageCode": { + "LOCMSG_SCRIPTEDITOR_EMPTY_MESSAGE": 0, + "LOCMSG_SCRIPTEDITOR_PROGRESS_SAVING_STARTED": 1, + "LOCMSG_SCRIPTEDITOR_PROGRESS_BYTES_LEFT": 2, + "LOCMSG_SCRIPTEDITOR_PROGRESS_STORING_TABLES": 3, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_ROWS_SO_FAR": 4, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECTED": 5, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECTING_TO": 6, + "LOCMSG_SCRIPTEDITOR_PROGRESS_CONNECT_FAILED": 7, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_ROWISH": 8, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_COLUMNAR": 9, + "LOCMSG_SCRIPTEDITOR_ERROR": 10, + "LOCMSG_SCRIPTEDITOR_DONE": 11, + "LOCMSG_SCRIPTEDITOR_LOAD_EXTERNAL_DATA": 12, + "LOCMSG_SCRIPTEDITOR_PROGRESS_OLD_QVD_ISLOADING": 13, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_LOADING": 14, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVD_BUFFERED": 15, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_PREPARING": 16, + "LOCMSG_SCRIPTEDITOR_PROGRESS_QVC_APPENDING": 17, + "LOCMSG_SCRIPTEDITOR_REMOVE_SYNTHETIC": 18, + "LOCMSG_SCRIPTEDITOR_PENDING_LINKEDTABLE_FETCHING": 19, + "LOCMSG_SCRIPTEDITOR_RELOAD": 20, + "LOCMSG_SCRIPTEDITOR_LINES_FETCHED": 21, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_START": 22, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_FIELD": 23, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_SUCCESS": 24, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_FAILURE": 25, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_STARTABORT": 26, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_ENDABORT": 27, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_TIMEOUT": 28, + "LOCMSG_SCRIPTEDITOR_SEARCHINDEX_OUTOFMEMORY": 29 + }, + "QrsChangeType": { + "QRS_CHANGE_UNDEFINED": 0, + "QRS_CHANGE_ADD": 1, + "QRS_CHANGE_UPDATE": 2, + "QRS_CHANGE_DELETE": 3 + }, + "LocalizedErrorCode": { + "LOCERR_INTERNAL_ERROR": -128, + "LOCERR_GENERIC_UNKNOWN": -1, + "LOCERR_GENERIC_OK": 0, + "LOCERR_GENERIC_NOT_SET": 1, + "LOCERR_GENERIC_NOT_FOUND": 2, + "LOCERR_GENERIC_ALREADY_EXISTS": 3, + "LOCERR_GENERIC_INVALID_PATH": 4, + "LOCERR_GENERIC_ACCESS_DENIED": 5, + "LOCERR_GENERIC_OUT_OF_MEMORY": 6, + "LOCERR_GENERIC_NOT_INITIALIZED": 7, + "LOCERR_GENERIC_INVALID_PARAMETERS": 8, + "LOCERR_GENERIC_EMPTY_PARAMETERS": 9, + "LOCERR_GENERIC_INTERNAL_ERROR": 10, + "LOCERR_GENERIC_CORRUPT_DATA": 11, + "LOCERR_GENERIC_MEMORY_INCONSISTENCY": 12, + "LOCERR_GENERIC_INVISIBLE_OWNER_ABORT": 13, + "LOCERR_GENERIC_PROHIBIT_VALIDATE": 14, + "LOCERR_GENERIC_ABORTED": 15, + "LOCERR_GENERIC_CONNECTION_LOST": 16, + "LOCERR_GENERIC_UNSUPPORTED_IN_PRODUCT_VERSION": 17, + "LOCERR_GENERIC_REST_CONNECTION_FAILURE": 18, + "LOCERR_HTTP_400": 400, + "LOCERR_HTTP_401": 401, + "LOCERR_HTTP_402": 402, + "LOCERR_HTTP_403": 403, + "LOCERR_HTTP_404": 404, + "LOCERR_HTTP_405": 405, + "LOCERR_HTTP_406": 406, + "LOCERR_HTTP_407": 407, + "LOCERR_HTTP_408": 408, + "LOCERR_HTTP_409": 409, + "LOCERR_HTTP_410": 410, + "LOCERR_HTTP_411": 411, + "LOCERR_HTTP_412": 412, + "LOCERR_HTTP_413": 413, + "LOCERR_HTTP_414": 414, + "LOCERR_HTTP_415": 415, + "LOCERR_HTTP_416": 416, + "LOCERR_HTTP_417": 417, + "LOCERR_HTTP_500": 500, + "LOCERR_HTTP_501": 501, + "LOCERR_HTTP_502": 502, + "LOCERR_HTTP_503": 503, + "LOCERR_HTTP_504": 504, + "LOCERR_HTTP_505": 505, + "LOCERR_HTTP_509": 509, + "LOCERR_HTTP_COULDNT_RESOLVE_HOST": 700, + "LOCERR_APP_ALREADY_EXISTS": 1000, + "LOCERR_APP_INVALID_NAME": 1001, + "LOCERR_APP_ALREADY_OPEN": 1002, + "LOCERR_APP_NOT_FOUND": 1003, + "LOCERR_APP_IMPORT_FAILED": 1004, + "LOCERR_APP_SAVE_FAILED": 1005, + "LOCERR_APP_CREATE_FAILED": 1006, + "LOCERR_APP_INVALID": 1007, + "LOCERR_APP_CONNECT_FAILED": 1008, + "LOCERR_APP_ALREADY_OPEN_IN_DIFFERENT_MODE": 1009, + "LOCERR_APP_MIGRATION_COULD_NOT_CONTACT_MIGRATION_SERVICE": 1010, + "LOCERR_APP_MIGRATION_COULD_NOT_START_MIGRATION": 1011, + "LOCERR_APP_MIGRATION_FAILURE": 1012, + "LOCERR_APP_SCRIPT_MISSING": 1013, + "LOCERR_CONNECTION_ALREADY_EXISTS": 2000, + "LOCERR_CONNECTION_NOT_FOUND": 2001, + "LOCERR_CONNECTION_FAILED_TO_LOAD": 2002, + "LOCERR_CONNECTION_FAILED_TO_IMPORT": 2003, + "LOCERR_CONNECTION_NAME_IS_INVALID": 2004, + "LOCERR_FILE_ACCESS_DENIED": 3000, + "LOCERR_FILE_NAME_INVALID": 3001, + "LOCERR_FILE_CORRUPT": 3002, + "LOCERR_FILE_NOT_FOUND": 3003, + "LOCERR_FILE_FORMAT_UNSUPPORTED": 3004, + "LOCERR_FILE_OPENED_IN_UNSUPPORTED_MODE": 3005, + "LOCERR_FILE_TABLE_NOT_FOUND": 3006, + "LOCERR_USER_ACCESS_DENIED": 4000, + "LOCERR_USER_IMPERSONATION_FAILED": 4001, + "LOCERR_SERVER_OUT_OF_SESSION_AND_USER_CALS": 5000, + "LOCERR_SERVER_OUT_OF_SESSION_CALS": 5001, + "LOCERR_SERVER_OUT_OF_USAGE_CALS": 5002, + "LOCERR_SERVER_OUT_OF_CALS": 5003, + "LOCERR_SERVER_OUT_OF_NAMED_CALS": 5004, + "LOCERR_SERVER_OFF_DUTY": 5005, + "LOCERR_SERVER_BUSY": 5006, + "LOCERR_SERVER_LICENSE_EXPIRED": 5007, + "LOCERR_SERVER_AJAX_DISABLED": 5008, + "LOCERR_HC_INVALID_OBJECT": 6000, + "LOCERR_HC_RESULT_TOO_LARGE": 6001, + "LOCERR_HC_INVALID_OBJECT_STATE": 6002, + "LOCERR_HC_MODAL_OBJECT_ERROR": 6003, + "LOCERR_CALC_INVALID_DEF": 7000, + "LOCERR_CALC_NOT_IN_LIB": 7001, + "LOCERR_CALC_HEAP_ERROR": 7002, + "LOCERR_CALC_TOO_LARGE": 7003, + "LOCERR_CALC_TIMEOUT": 7004, + "LOCERR_CALC_EVAL_CONDITION_FAILED": 7005, + "LOCERR_CALC_MIXED_LINKED_AGGREGATION": 7006, + "LOCERR_CALC_MISSING_LINKED": 7007, + "LOCERR_CALC_INVALID_COL_SORT": 7008, + "LOCERR_CALC_PAGES_TOO_LARGE": 7009, + "LOCERR_CALC_SEMANTIC_FIELD_NOT_ALLOWED": 7010, + "LOCERR_CALC_VALIDATION_STATE_INVALID": 7011, + "LOCERR_CALC_PIVOT_DIMENSIONS_ALREADY_EXISTS": 7012, + "LOCERR_CALC_MISSING_LINKED_FIELD": 7013, + "LOCERR_CALC_NOT_CALCULATED": 7014, + "LOCERR_LAYOUT_EXTENDS_INVALID_ID": 8000, + "LOCERR_LAYOUT_LINKED_OBJECT_NOT_FOUND": 8001, + "LOCERR_LAYOUT_LINKED_OBJECT_INVALID": 8002, + "LOCERR_PERSISTENCE_WRITE_FAILED": 9000, + "LOCERR_PERSISTENCE_READ_FAILED": 9001, + "LOCERR_PERSISTENCE_DELETE_FAILED": 9002, + "LOCERR_PERSISTENCE_NOT_FOUND": 9003, + "LOCERR_PERSISTENCE_UNSUPPORTED_VERSION": 9004, + "LOCERR_PERSISTENCE_MIGRATION_FAILED_READ_ONLY": 9005, + "LOCERR_PERSISTENCE_MIGRATION_CANCELLED": 9006, + "LOCERR_PERSISTENCE_MIGRATION_BACKUP_FAILED": 9007, + "LOCERR_PERSISTENCE_DISK_FULL": 9008, + "LOCERR_PERSISTENCE_NOT_SUPPORTED_FOR_SESSION_APP": 9009, + "LOCERR_PERSISTENCE_SYNC_SET_CHUNK_INVALID_PARAMETERS": 9510, + "LOCERR_PERSISTENCE_SYNC_GET_CHUNK_INVALID_PARAMETERS": 9511, + "LOCERR_SCRIPT_DATASOURCE_ACCESS_DENIED": 10000, + "LOCERR_RELOAD_IN_PROGRESS": 11000, + "LOCERR_RELOAD_TABLE_X_NOT_FOUND": 11001, + "LOCERR_RELOAD_UNKNOWN_STATEMENT": 11002, + "LOCERR_RELOAD_EXPECTED_SOMETHING_FOUND_UNKNOWN": 11003, + "LOCERR_RELOAD_EXPECTED_NOTHING_FOUND_UNKNOWN": 11004, + "LOCERR_RELOAD_EXPECTED_ONE_OF_1_TOKENS_FOUND_UNKNOWN": 11005, + "LOCERR_RELOAD_EXPECTED_ONE_OF_2_TOKENS_FOUND_UNKNOWN": 11006, + "LOCERR_RELOAD_EXPECTED_ONE_OF_3_TOKENS_FOUND_UNKNOWN": 11007, + "LOCERR_RELOAD_EXPECTED_ONE_OF_4_TOKENS_FOUND_UNKNOWN": 11008, + "LOCERR_RELOAD_EXPECTED_ONE_OF_5_TOKENS_FOUND_UNKNOWN": 11009, + "LOCERR_RELOAD_EXPECTED_ONE_OF_6_TOKENS_FOUND_UNKNOWN": 11010, + "LOCERR_RELOAD_EXPECTED_ONE_OF_7_TOKENS_FOUND_UNKNOWN": 11011, + "LOCERR_RELOAD_EXPECTED_ONE_OF_8_OR_MORE_TOKENS_FOUND_UNKNOWN": 11012, + "LOCERR_RELOAD_FIELD_X_NOT_FOUND": 11013, + "LOCERR_RELOAD_MAPPING_TABLE_X_NOT_FOUND": 11014, + "LOCERR_RELOAD_LIB_CONNECTION_X_NOT_FOUND": 11015, + "LOCERR_RELOAD_NAME_ALREADY_TAKEN": 11016, + "LOCERR_RELOAD_WRONG_FILE_FORMAT_DIF": 11017, + "LOCERR_RELOAD_WRONG_FILE_FORMAT_BIFF": 11018, + "LOCERR_RELOAD_WRONG_FILE_FORMAT_ENCRYPTED": 11019, + "LOCERR_RELOAD_OPEN_FILE_ERROR": 11020, + "LOCERR_RELOAD_AUTO_GENERATE_COUNT": 11021, + "LOCERR_RELOAD_PE_ILLEGAL_PREFIX_COMB": 11022, + "LOCERR_RELOAD_MATCHING_CONTROL_STATEMENT_ERROR": 11023, + "LOCERR_RELOAD_MATCHING_LIBPATH_X_NOT_FOUND": 11024, + "LOCERR_RELOAD_MATCHING_LIBPATH_X_INVALID": 11025, + "LOCERR_RELOAD_MATCHING_LIBPATH_X_OUTSIDE": 11026, + "LOCERR_RELOAD_NO_QUALIFIED_PATH_FOR_FILE": 11027, + "LOCERR_RELOAD_MODE_STATEMENT_ONLY_FOR_LIB_PATHS": 11028, + "LOCERR_RELOAD_INCONSISTENT_USE_OF_SEMANTIC_FIELDS": 11029, + "LOCERR_RELOAD_NO_OPEN_DATABASE": 11030, + "LOCERR_RELOAD_AGGREGATION_REQUIRED_BY_GROUP_BY": 11031, + "LOCERR_RELOAD_CONNECT_MUST_USE_LIB_PREFIX_IN_THIS_MODE": 11032, + "LOCERR_RELOAD_ODBC_CONNECT_FAILED": 11033, + "LOCERR_RELOAD_OLEDB_CONNECT_FAILED": 11034, + "LOCERR_RELOAD_CUSTOM_CONNECT_FAILED": 11035, + "LOCERR_RELOAD_ODBC_READ_FAILED": 11036, + "LOCERR_RELOAD_OLEDB_READ_FAILED": 11037, + "LOCERR_RELOAD_CUSTOM_READ_FAILED": 11038, + "LOCERR_RELOAD_BINARY_LOAD_PROHIBITED": 11039, + "LOCERR_RELOAD_CONNECTOR_START_FAILED": 11040, + "LOCERR_RELOAD_CONNECTOR_NOT_RESPONDING": 11041, + "LOCERR_RELOAD_CONNECTOR_REPLY_ERROR": 11042, + "LOCERR_RELOAD_CONNECTOR_CONNECT_ERROR": 11043, + "LOCERR_PERSONAL_NEW_VERSION_AVAILABLE": 12000, + "LOCERR_PERSONAL_VERSION_EXPIRED": 12001, + "LOCERR_PERSONAL_SECTION_ACCESS_DETECTED": 12002, + "LOCERR_PERSONAL_APP_DELETION_FAILED": 12003, + "LOCERR_USER_AUTHENTICATION_FAILURE": 12004, + "LOCERR_EXPORT_OUT_OF_MEMORY": 13000, + "LOCERR_EXPORT_NO_DATA": 13001, + "LOCERR_SYNC_INVALID_OFFSET": 14000, + "LOCERR_SEARCH_TIMEOUT": 15000, + "LOCERR_DIRECT_DISCOVERY_LINKED_EXPRESSION_FAIL": 16000, + "LOCERR_DIRECT_DISCOVERY_ROWCOUNT_OVERFLOW": 16001, + "LOCERR_DIRECT_DISCOVERY_EMPTY_RESULT": 16002, + "LOCERR_DIRECT_DISCOVERY_DB_CONNECTION_FAILED": 16003, + "LOCERR_DIRECT_DISCOVERY_MEASURE_NOT_ALLOWED": 16004, + "LOCERR_DIRECT_DISCOVERY_DETAIL_NOT_ALLOWED": 16005, + "LOCERR_DIRECT_DISCOVERY_NOT_SYNTH_CIRCULAR_ALLOWED": 16006, + "LOCERR_DIRECT_DISCOVERY_ONLY_ONE_DD_TABLE_ALLOWED": 16007, + "LOCERR_DIRECT_DISCOVERY_DB_AUTHORIZATION_FAILED": 16008, + "LOCERR_SMART_LOAD_TABLE_NOT_FOUND": 17000, + "LOCERR_SMART_LOAD_TABLE_DUPLICATED": 17001, + "LOCERR_VARIABLE_NO_NAME": 18000, + "LOCERR_VARIABLE_DUPLICATE_NAME": 18001, + "LOCERR_VARIABLE_INCONSISTENCY": 18002, + "LOCERR_MEDIA_LIBRARY_LIST_FAILED": 19000, + "LOCERR_MEDIA_LIBRARY_CONTENT_FAILED": 19001, + "LOCERR_MEDIA_BUNDLING_FAILED": 19002, + "LOCERR_MEDIA_UNBUNDLING_FAILED": 19003, + "LOCERR_MEDIA_LIBRARY_NOT_FOUND": 19004, + "LOCERR_FEATURE_DISABLED": 20000, + "LOCERR_JSON_RPC_INVALID_REQUEST": -32600, + "LOCERR_JSON_RPC_METHOD_NOT_FOUND": -32601, + "LOCERR_JSON_RPC_INVALID_PARAMETERS": -32602, + "LOCERR_JSON_RPC_INTERNAL_ERROR": -32603, + "LOCERR_JSON_RPC_PARSE_ERROR": -32700 + }, + "LocalizedWarningCode": { + "LOCWARN_PERSONAL_RELOAD_REQUIRED": 0, + "LOCWARN_PERSONAL_VERSION_EXPIRES_SOON": 1, + "LOCWARN_EXPORT_DATA_TRUNCATED": 1000, + "LOCWARN_COULD_NOT_OPEN_ALL_OBJECTS": 2000 + }, + "GrpType": { + "GRP_NX_NONE": 0, + "GRP_NX_HIEARCHY": 1, + "GRP_NX_COLLECTION": 2 + }, + "ExportFileType": { + "EXPORT_CSV_C": 0, + "EXPORT_CSV_T": 1, + "EXPORT_OOXML": 2 + }, + "ExportState": { + "EXPORT_POSSIBLE": 0, + "EXPORT_ALL": 1 + }, + "DimCellType": { + "NX_DIM_CELL_VALUE": 0, + "NX_DIM_CELL_EMPTY": 1, + "NX_DIM_CELL_NORMAL": 2, + "NX_DIM_CELL_TOTAL": 3, + "NX_DIM_CELL_OTHER": 4, + "NX_DIM_CELL_AGGR": 5, + "NX_DIM_CELL_PSEUDO": 6, + "NX_DIM_CELL_ROOT": 7, + "NX_DIM_CELL_NULL": 8 + }, + "StackElemType": { + "NX_STACK_CELL_NORMAL": 0, + "NX_STACK_CELL_TOTAL": 1, + "NX_STACK_CELL_OTHER": 2, + "NX_STACK_CELL_SUM": 3, + "NX_STACK_CELL_VALUE": 4, + "NX_STACK_CELL_PSEUDO": 5 + }, + "SortIndicatorType": { + "NX_SORT_INDICATE_NONE": 0, + "NX_SORT_INDICATE_ASC": 1, + "NX_SORT_INDICATE_DESC": 2 + }, + "DimensionType": { + "NX_DIMENSION_TYPE_DISCRETE": 0, + "NX_DIMENSION_TYPE_NUMERIC": 1, + "NX_DIMENSION_TYPE_TIME": 2 + }, + "FieldSelectionMode": { + "SELECTION_MODE_NORMAL": 0, + "SELECTION_MODE_AND": 1, + "SELECTION_MODE_NOT": 2 + }, + "FrequencyMode": { + "NX_FREQUENCY_NONE": 0, + "NX_FREQUENCY_VALUE": 1, + "NX_FREQUENCY_PERCENT": 2, + "NX_FREQUENCY_RELATIVE": 3 + }, + "DataReductionMode": { + "DATA_REDUCTION_NONE": 0, + "DATA_REDUCTION_ONEDIM": 1, + "DATA_REDUCTION_SCATTERED": 2, + "DATA_REDUCTION_CLUSTERED": 3, + "DATA_REDUCTION_STACKED": 4 + }, + "HypercubeMode": { + "DATA_MODE_STRAIGHT": 0, + "DATA_MODE_PIVOT": 1, + "DATA_MODE_PIVOT_STACK": 2 + }, + "PatchOperationType": { + "Add": 0, + "Remove": 1, + "Replace": 2 + }, + "SelectionCellType": { + "NX_CELL_DATA": 0, + "NX_CELL_TOP": 1, + "NX_CELL_LEFT": 2 + }, + "MatchingFieldMode": { + "MATCHINGFIELDMODE_MATCH_ALL": 0, + "MATCHINGFIELDMODE_MATCH_ONE": 1 + }, + "ExtEngineDataType": { + "NX_EXT_DATATYPE_STRING": 0, + "NX_EXT_DATATYPE_DOUBLE": 1, + "NX_EXT_DATATYPE_BOTH": 2 + }, + "ExtEngineFunctionType": { + "NX_EXT_FUNCTIONTYPE_SCALAR": 0, + "NX_EXT_FUNCTIONTYPE_AGGR": 1, + "NX_EXT_FUNCTIONTYPE_TENSOR": 2 + }, + "ExtEngineMsgType": { + "NX_EXT_MSGTYPE_FUNCTION_CALL": 1, + "NX_EXT_MSGTYPE_SCRIPT_CALL": 2, + "NX_EXT_MSGTYPE_RETURN_VALUE": 3, + "NX_EXT_MSGTYPE_RETURN_MULTIPLE": 4, + "NX_EXT_MSGTYPE_RETURN_ERROR": 5 + } + }, + "version": "3.2" +} diff --git a/jwt-scratch/src/js/node_modules/enigma.js/sense-utilities.js b/jwt-scratch/src/js/node_modules/enigma.js/sense-utilities.js new file mode 100644 index 0000000..2cd2278 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/enigma.js/sense-utilities.js @@ -0,0 +1,261 @@ +/** + * enigma.js v2.7.2 + * Copyright (c) 2020 QlikTech International AB + * This library is licensed under MIT - See the LICENSE file for full details + */ + +(function (global, factory) { + typeof exports === 'object' && typeof module !== 'undefined' ? module.exports = factory() : + typeof define === 'function' && define.amd ? define(factory) : + (global = typeof globalThis !== 'undefined' ? globalThis : global || self, global.senseUtilities = factory()); +}(this, (function () { 'use strict'; + + function createCommonjsModule(fn, module) { + return module = { exports: {} }, fn(module, module.exports), module.exports; + } + + // Copyright Joyent, Inc. and other Node contributors. + + // If obj.hasOwnProperty has been overridden, then calling + // obj.hasOwnProperty(prop) will break. + // See: https://github.com/joyent/node/issues/1707 + function hasOwnProperty(obj, prop) { + return Object.prototype.hasOwnProperty.call(obj, prop); + } + + var decode = function(qs, sep, eq, options) { + sep = sep || '&'; + eq = eq || '='; + var obj = {}; + + if (typeof qs !== 'string' || qs.length === 0) { + return obj; + } + + var regexp = /\+/g; + qs = qs.split(sep); + + var maxKeys = 1000; + if (options && typeof options.maxKeys === 'number') { + maxKeys = options.maxKeys; + } + + var len = qs.length; + // maxKeys <= 0 means that we should not limit keys count + if (maxKeys > 0 && len > maxKeys) { + len = maxKeys; + } + + for (var i = 0; i < len; ++i) { + var x = qs[i].replace(regexp, '%20'), + idx = x.indexOf(eq), + kstr, vstr, k, v; + + if (idx >= 0) { + kstr = x.substr(0, idx); + vstr = x.substr(idx + 1); + } else { + kstr = x; + vstr = ''; + } + + k = decodeURIComponent(kstr); + v = decodeURIComponent(vstr); + + if (!hasOwnProperty(obj, k)) { + obj[k] = v; + } else if (Array.isArray(obj[k])) { + obj[k].push(v); + } else { + obj[k] = [obj[k], v]; + } + } + + return obj; + }; + + // Copyright Joyent, Inc. and other Node contributors. + + var stringifyPrimitive = function(v) { + switch (typeof v) { + case 'string': + return v; + + case 'boolean': + return v ? 'true' : 'false'; + + case 'number': + return isFinite(v) ? v : ''; + + default: + return ''; + } + }; + + var encode = function(obj, sep, eq, name) { + sep = sep || '&'; + eq = eq || '='; + if (obj === null) { + obj = undefined; + } + + if (typeof obj === 'object') { + return Object.keys(obj).map(function(k) { + var ks = encodeURIComponent(stringifyPrimitive(k)) + eq; + if (Array.isArray(obj[k])) { + return obj[k].map(function(v) { + return ks + encodeURIComponent(stringifyPrimitive(v)); + }).join(sep); + } else { + return ks + encodeURIComponent(stringifyPrimitive(obj[k])); + } + }).join(sep); + + } + + if (!name) return ''; + return encodeURIComponent(stringifyPrimitive(name)) + eq + + encodeURIComponent(stringifyPrimitive(obj)); + }; + + var querystring = createCommonjsModule(function (module, exports) { + + exports.decode = exports.parse = decode; + exports.encode = exports.stringify = encode; + }); + var querystring_1 = querystring.decode; + var querystring_2 = querystring.parse; + var querystring_3 = querystring.encode; + var querystring_4 = querystring.stringify; + + function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } } + + function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, descriptor.key, descriptor); } } + + function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); return Constructor; } + /** + * This object describes the configuration that is sent into `buildUrl(config)`. + * @typedef {Object} SenseConfiguration + * @property {String} [appId] The app id. If omitted, only the global object is returned. + * Otherwise both global and app object are returned. + * @property {Boolean} [noData=false] Whether to open the app without data. + * @property {Boolean} [secure=true] Set to false if an unsecure WebSocket should be used. + * @property {String} [host] Host address. + * @property {Number} [port] Port to connect to. + * @property {String} [prefix="/"] The absolute base path to use when connecting. + * Used for proxy prefixes. + * @property {String} [subpath=""] The subpath. + * @property {String} [route=""] Used to instruct Proxy to route to the correct receiver. + * @property {String} [identity=""] Identity to use. + * @property {Object} [urlParams={}] Used to add parameters to the WebSocket URL. + * @property {Number} [ttl] A value in seconds that QIX Engine should keep the session + * alive after socket disconnect (only works if QIX Engine supports it). + */ + + function replaceLeadingAndTrailingSlashes(str) { + return str.replace(/(^[/]+)|([/]+$)/g, ''); + } + + var SenseUtilities = /*#__PURE__*/function () { + function SenseUtilities() { + _classCallCheck(this, SenseUtilities); + } + + _createClass(SenseUtilities, null, [{ + key: "configureDefaults", + + /** + * Ensures that the configuration has defaults set. + * + * @private + * @param {SenseConfiguration} senseConfig The configuration to ensure defaults on. + */ + value: function configureDefaults(senseConfig) { + if (!senseConfig.host) { + senseConfig.host = 'localhost'; + } + + if (typeof senseConfig.secure === 'undefined') { + senseConfig.secure = true; + } + + if (!senseConfig.appId && !senseConfig.route) { + senseConfig.route = 'app/engineData'; + } + + if (typeof senseConfig.noData === 'undefined') { + senseConfig.noData = false; + } + } + /** + * Function used to build an URL. + * @entry + * @param {SenseConfiguration} urlConfig - The URL configuration object. + * @returns {String} Returns the websocket URL. + * @example Example of building and using a Qlik Sense-compatible WebSocket URL + * const enigma = require('enigma.js'); + * const schema = require('enigma.js/schemas/12.20.0.json'); + * const SenseUtilities = require('enigma.js/sense-utilities'); + * const url = SenseUtilities.buildUrl({ host: 'my-sense-host', appId: 'some-app' }); + * const session = enigma.create({ schema, url }); + */ + + }, { + key: "buildUrl", + value: function buildUrl(urlConfig) { + SenseUtilities.configureDefaults(urlConfig); + var secure = urlConfig.secure, + host = urlConfig.host, + port = urlConfig.port, + prefix = urlConfig.prefix, + subpath = urlConfig.subpath, + route = urlConfig.route, + identity = urlConfig.identity, + urlParams = urlConfig.urlParams, + ttl = urlConfig.ttl, + appId = urlConfig.appId; + var url = ''; + url += "".concat(secure ? 'wss' : 'ws', "://"); + url += host || 'localhost'; + + if (port) { + url += ":".concat(port); + } + + if (prefix) { + url += "/".concat(replaceLeadingAndTrailingSlashes(prefix)); + } + + if (subpath) { + url += "/".concat(replaceLeadingAndTrailingSlashes(subpath)); + } + + if (route) { + url += "/".concat(replaceLeadingAndTrailingSlashes(route)); + } else if (appId) { + url += "/app/".concat(encodeURIComponent(appId)); + } + + if (identity) { + url += "/identity/".concat(encodeURIComponent(identity)); + } + + if (ttl) { + url += "/ttl/".concat(ttl); + } + + if (urlParams) { + url += "?".concat(querystring.stringify(urlParams)); + } + + return url; + } + }]); + + return SenseUtilities; + }(); + + return SenseUtilities; + +}))); +//# sourceMappingURL=sense-utilities.js.map diff --git a/jwt-scratch/src/js/node_modules/enigma.js/sense-utilities.js.map b/jwt-scratch/src/js/node_modules/enigma.js/sense-utilities.js.map new file mode 100644 index 0000000..c7ed83a --- /dev/null +++ b/jwt-scratch/src/js/node_modules/enigma.js/sense-utilities.js.map @@ -0,0 +1 @@ +{"version":3,"file":"sense-utilities.js","sources":["node_modules/querystring/decode.js","node_modules/querystring/encode.js","node_modules/querystring/index.js","src/sense-utilities.js"],"sourcesContent":["// Copyright Joyent, Inc. and other Node contributors.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a\n// copy of this software and associated documentation files (the\n// \"Software\"), to deal in the Software without restriction, including\n// without limitation the rights to use, copy, modify, merge, publish,\n// distribute, sublicense, and/or sell copies of the Software, and to permit\n// persons to whom the Software is furnished to do so, subject to the\n// following conditions:\n//\n// The above copyright notice and this permission notice shall be included\n// in all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS\n// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\n// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN\n// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR\n// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE\n// USE OR OTHER DEALINGS IN THE SOFTWARE.\n\n'use strict';\n\n// If obj.hasOwnProperty has been overridden, then calling\n// obj.hasOwnProperty(prop) will break.\n// See: https://github.com/joyent/node/issues/1707\nfunction hasOwnProperty(obj, prop) {\n return Object.prototype.hasOwnProperty.call(obj, prop);\n}\n\nmodule.exports = function(qs, sep, eq, options) {\n sep = sep || '&';\n eq = eq || '=';\n var obj = {};\n\n if (typeof qs !== 'string' || qs.length === 0) {\n return obj;\n }\n\n var regexp = /\\+/g;\n qs = qs.split(sep);\n\n var maxKeys = 1000;\n if (options && typeof options.maxKeys === 'number') {\n maxKeys = options.maxKeys;\n }\n\n var len = qs.length;\n // maxKeys <= 0 means that we should not limit keys count\n if (maxKeys > 0 && len > maxKeys) {\n len = maxKeys;\n }\n\n for (var i = 0; i < len; ++i) {\n var x = qs[i].replace(regexp, '%20'),\n idx = x.indexOf(eq),\n kstr, vstr, k, v;\n\n if (idx >= 0) {\n kstr = x.substr(0, idx);\n vstr = x.substr(idx + 1);\n } else {\n kstr = x;\n vstr = '';\n }\n\n k = decodeURIComponent(kstr);\n v = decodeURIComponent(vstr);\n\n if (!hasOwnProperty(obj, k)) {\n obj[k] = v;\n } else if (Array.isArray(obj[k])) {\n obj[k].push(v);\n } else {\n obj[k] = [obj[k], v];\n }\n }\n\n return obj;\n};\n","// Copyright Joyent, Inc. and other Node contributors.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a\n// copy of this software and associated documentation files (the\n// \"Software\"), to deal in the Software without restriction, including\n// without limitation the rights to use, copy, modify, merge, publish,\n// distribute, sublicense, and/or sell copies of the Software, and to permit\n// persons to whom the Software is furnished to do so, subject to the\n// following conditions:\n//\n// The above copyright notice and this permission notice shall be included\n// in all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS\n// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\n// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN\n// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR\n// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE\n// USE OR OTHER DEALINGS IN THE SOFTWARE.\n\n'use strict';\n\nvar stringifyPrimitive = function(v) {\n switch (typeof v) {\n case 'string':\n return v;\n\n case 'boolean':\n return v ? 'true' : 'false';\n\n case 'number':\n return isFinite(v) ? v : '';\n\n default:\n return '';\n }\n};\n\nmodule.exports = function(obj, sep, eq, name) {\n sep = sep || '&';\n eq = eq || '=';\n if (obj === null) {\n obj = undefined;\n }\n\n if (typeof obj === 'object') {\n return Object.keys(obj).map(function(k) {\n var ks = encodeURIComponent(stringifyPrimitive(k)) + eq;\n if (Array.isArray(obj[k])) {\n return obj[k].map(function(v) {\n return ks + encodeURIComponent(stringifyPrimitive(v));\n }).join(sep);\n } else {\n return ks + encodeURIComponent(stringifyPrimitive(obj[k]));\n }\n }).join(sep);\n\n }\n\n if (!name) return '';\n return encodeURIComponent(stringifyPrimitive(name)) + eq +\n encodeURIComponent(stringifyPrimitive(obj));\n};\n","'use strict';\n\nexports.decode = exports.parse = require('./decode');\nexports.encode = exports.stringify = require('./encode');\n","import QueryString from 'querystring';\n\n/**\n* This object describes the configuration that is sent into `buildUrl(config)`.\n* @typedef {Object} SenseConfiguration\n* @property {String} [appId] The app id. If omitted, only the global object is returned.\n* Otherwise both global and app object are returned.\n* @property {Boolean} [noData=false] Whether to open the app without data.\n* @property {Boolean} [secure=true] Set to false if an unsecure WebSocket should be used.\n* @property {String} [host] Host address.\n* @property {Number} [port] Port to connect to.\n* @property {String} [prefix=\"/\"] The absolute base path to use when connecting.\n* Used for proxy prefixes.\n* @property {String} [subpath=\"\"] The subpath.\n* @property {String} [route=\"\"] Used to instruct Proxy to route to the correct receiver.\n* @property {String} [identity=\"\"] Identity to use.\n* @property {Object} [urlParams={}] Used to add parameters to the WebSocket URL.\n* @property {Number} [ttl] A value in seconds that QIX Engine should keep the session\n* alive after socket disconnect (only works if QIX Engine supports it).\n*/\n\nfunction replaceLeadingAndTrailingSlashes(str) {\n return str.replace(/(^[/]+)|([/]+$)/g, '');\n}\n\nclass SenseUtilities {\n /**\n * Ensures that the configuration has defaults set.\n *\n * @private\n * @param {SenseConfiguration} senseConfig The configuration to ensure defaults on.\n */\n static configureDefaults(senseConfig) {\n if (!senseConfig.host) {\n senseConfig.host = 'localhost';\n }\n\n if (typeof senseConfig.secure === 'undefined') {\n senseConfig.secure = true;\n }\n\n if (!senseConfig.appId && !senseConfig.route) {\n senseConfig.route = 'app/engineData';\n }\n\n if (typeof senseConfig.noData === 'undefined') {\n senseConfig.noData = false;\n }\n }\n\n /**\n * Function used to build an URL.\n * @entry\n * @param {SenseConfiguration} urlConfig - The URL configuration object.\n * @returns {String} Returns the websocket URL.\n * @example Example of building and using a Qlik Sense-compatible WebSocket URL\n * const enigma = require('enigma.js');\n * const schema = require('enigma.js/schemas/12.20.0.json');\n * const SenseUtilities = require('enigma.js/sense-utilities');\n * const url = SenseUtilities.buildUrl({ host: 'my-sense-host', appId: 'some-app' });\n * const session = enigma.create({ schema, url });\n */\n static buildUrl(urlConfig) {\n SenseUtilities.configureDefaults(urlConfig);\n\n const {\n secure,\n host,\n port,\n prefix,\n subpath,\n route,\n identity,\n urlParams,\n ttl,\n appId,\n } = urlConfig;\n\n let url = '';\n\n url += `${secure ? 'wss' : 'ws'}://`;\n url += host || 'localhost';\n\n if (port) {\n url += `:${port}`;\n }\n\n if (prefix) {\n url += `/${replaceLeadingAndTrailingSlashes(prefix)}`;\n }\n\n if (subpath) {\n url += `/${replaceLeadingAndTrailingSlashes(subpath)}`;\n }\n\n if (route) {\n url += `/${replaceLeadingAndTrailingSlashes(route)}`;\n } else if (appId) {\n url += `/app/${encodeURIComponent(appId)}`;\n }\n\n if (identity) {\n url += `/identity/${encodeURIComponent(identity)}`;\n }\n\n if (ttl) {\n url += `/ttl/${ttl}`;\n }\n\n if (urlParams) {\n url += `?${QueryString.stringify(urlParams)}`;\n }\n\n return url;\n }\n}\n\nexport default SenseUtilities;\n"],"names":["require$$0","require$$1","replaceLeadingAndTrailingSlashes","str","replace","SenseUtilities","senseConfig","host","secure","appId","route","noData","urlConfig","configureDefaults","port","prefix","subpath","identity","urlParams","ttl","url","encodeURIComponent","QueryString","stringify"],"mappings":";;;;;;;;;;;;;;;;CAAA;;;;;CA0BA,SAAS,cAAc,CAAC,GAAG,EAAE,IAAI,EAAE;GACjC,OAAO,MAAM,CAAC,SAAS,CAAC,cAAc,CAAC,IAAI,CAAC,GAAG,EAAE,IAAI,CAAC,CAAC;EACxD;;CAED,UAAc,GAAG,SAAS,EAAE,EAAE,GAAG,EAAE,EAAE,EAAE,OAAO,EAAE;GAC9C,GAAG,GAAG,GAAG,IAAI,GAAG,CAAC;GACjB,EAAE,GAAG,EAAE,IAAI,GAAG,CAAC;GACf,IAAI,GAAG,GAAG,EAAE,CAAC;;GAEb,IAAI,OAAO,EAAE,KAAK,QAAQ,IAAI,EAAE,CAAC,MAAM,KAAK,CAAC,EAAE;KAC7C,OAAO,GAAG,CAAC;IACZ;;GAED,IAAI,MAAM,GAAG,KAAK,CAAC;GACnB,EAAE,GAAG,EAAE,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC;;GAEnB,IAAI,OAAO,GAAG,IAAI,CAAC;GACnB,IAAI,OAAO,IAAI,OAAO,OAAO,CAAC,OAAO,KAAK,QAAQ,EAAE;KAClD,OAAO,GAAG,OAAO,CAAC,OAAO,CAAC;IAC3B;;GAED,IAAI,GAAG,GAAG,EAAE,CAAC,MAAM,CAAC;;GAEpB,IAAI,OAAO,GAAG,CAAC,IAAI,GAAG,GAAG,OAAO,EAAE;KAChC,GAAG,GAAG,OAAO,CAAC;IACf;;GAED,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,GAAG,EAAE,EAAE,CAAC,EAAE;KAC5B,IAAI,CAAC,GAAG,EAAE,CAAC,CAAC,CAAC,CAAC,OAAO,CAAC,MAAM,EAAE,KAAK,CAAC;S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G,KAAH,GAAW,IAAxB,QAAH;CACAY,MAAAA,GAAG,IAAIb,IAAI,IAAI,WAAf;;CAEA,UAAIO,IAAJ,EAAU;CACRM,QAAAA,GAAG,eAAQN,IAAR,CAAH;CACD;;CAED,UAAIC,MAAJ,EAAY;CACVK,QAAAA,GAAG,eAAQlB,gCAAgC,CAACa,MAAD,CAAxC,CAAH;CACD;;CAED,UAAIC,OAAJ,EAAa;CACXI,QAAAA,GAAG,eAAQlB,gCAAgC,CAACc,OAAD,CAAxC,CAAH;CACD;;CAED,UAAIN,KAAJ,EAAW;CACTU,QAAAA,GAAG,eAAQlB,gCAAgC,CAACQ,KAAD,CAAxC,CAAH;CACD,OAFD,MAEO,IAAID,KAAJ,EAAW;CAChBW,QAAAA,GAAG,mBAAYC,kBAAkB,CAACZ,KAAD,CAA9B,CAAH;CACD;;CAED,UAAIQ,QAAJ,EAAc;CACZG,QAAAA,GAAG,wBAAiBC,kBAAkB,CAACJ,QAAD,CAAnC,CAAH;CACD;;CAED,UAAIE,GAAJ,EAAS;CACPC,QAAAA,GAAG,mBAAYD,GAAZ,CAAH;CACD;;CAED,UAAID,SAAJ,EAAe;CACbE,QAAAA,GAAG,eAAQE,WAAW,CAACC,SAAZ,CAAsBL,SAAtB,CAAR,CAAH;CACD;;CAED,aAAOE,GAAP;CACD;;;;;;;;"} \ No newline at end of file diff --git a/jwt-scratch/src/js/node_modules/enigma.js/sense-utilities.min.js b/jwt-scratch/src/js/node_modules/enigma.js/sense-utilities.min.js new file mode 100644 index 0000000..c8ff785 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/enigma.js/sense-utilities.min.js @@ -0,0 +1,2 @@ +!function(e,n){"object"==typeof exports&&"undefined"!=typeof module?module.exports=n():"function"==typeof define&&define.amd?define(n):(e="undefined"!=typeof globalThis?globalThis:e||self).senseUtilities=n()}(this,function(){"use strict";var e,t=function(e,n,t,o){n=n||"&",t=t||"=";var r={};if("string"!=typeof e||0===e.length)return r;var a=/\+/g;e=e.split(n);var c=1e3;o&&"number"==typeof o.maxKeys&&(c=o.maxKeys);var i,u,s=e.length;0 0 && len > maxKeys) {\n len = maxKeys;\n }\n\n for (var i = 0; i < len; ++i) {\n var x = qs[i].replace(regexp, '%20'),\n idx = x.indexOf(eq),\n kstr, vstr, k, v;\n\n if (idx >= 0) {\n kstr = x.substr(0, idx);\n vstr = x.substr(idx + 1);\n } else {\n kstr = x;\n vstr = '';\n }\n\n k = decodeURIComponent(kstr);\n v = decodeURIComponent(vstr);\n\n if (!hasOwnProperty(obj, k)) {\n obj[k] = v;\n } else if (Array.isArray(obj[k])) {\n obj[k].push(v);\n } else {\n obj[k] = [obj[k], v];\n }\n }\n\n return obj;\n};\n","// Copyright Joyent, Inc. and other Node contributors.\n//\n// Permission is hereby granted, free of charge, to any person obtaining a\n// copy of this software and associated documentation files (the\n// \"Software\"), to deal in the Software without restriction, including\n// without limitation the rights to use, copy, modify, merge, publish,\n// distribute, sublicense, and/or sell copies of the Software, and to permit\n// persons to whom the Software is furnished to do so, subject to the\n// following conditions:\n//\n// The above copyright notice and this permission notice shall be included\n// in all copies or substantial portions of the Software.\n//\n// THE SOFTWARE IS PROVIDED \"AS IS\", WITHOUT WARRANTY OF ANY KIND, EXPRESS\n// OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF\n// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN\n// NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM,\n// DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR\n// OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE\n// USE OR OTHER DEALINGS IN THE SOFTWARE.\n\n'use strict';\n\nvar stringifyPrimitive = function(v) {\n switch (typeof v) {\n case 'string':\n return v;\n\n case 'boolean':\n return v ? 'true' : 'false';\n\n case 'number':\n return isFinite(v) ? v : '';\n\n default:\n return '';\n }\n};\n\nmodule.exports = function(obj, sep, eq, name) {\n sep = sep || '&';\n eq = eq || '=';\n if (obj === null) {\n obj = undefined;\n }\n\n if (typeof obj === 'object') {\n return Object.keys(obj).map(function(k) {\n var ks = encodeURIComponent(stringifyPrimitive(k)) + eq;\n if (Array.isArray(obj[k])) {\n return obj[k].map(function(v) {\n return ks + encodeURIComponent(stringifyPrimitive(v));\n }).join(sep);\n } else {\n return ks + encodeURIComponent(stringifyPrimitive(obj[k]));\n }\n }).join(sep);\n\n }\n\n if (!name) return '';\n return encodeURIComponent(stringifyPrimitive(name)) + eq +\n encodeURIComponent(stringifyPrimitive(obj));\n};\n","'use strict';\n\nexports.decode = exports.parse = require('./decode');\nexports.encode = exports.stringify = require('./encode');\n","import QueryString from 'querystring';\n\n/**\n* This object describes the configuration that is sent into `buildUrl(config)`.\n* @typedef {Object} SenseConfiguration\n* @property {String} [appId] The app id. If omitted, only the global object is returned.\n* Otherwise both global and app object are returned.\n* @property {Boolean} [noData=false] Whether to open the app without data.\n* @property {Boolean} [secure=true] Set to false if an unsecure WebSocket should be used.\n* @property {String} [host] Host address.\n* @property {Number} [port] Port to connect to.\n* @property {String} [prefix=\"/\"] The absolute base path to use when connecting.\n* Used for proxy prefixes.\n* @property {String} [subpath=\"\"] The subpath.\n* @property {String} [route=\"\"] Used to instruct Proxy to route to the correct receiver.\n* @property {String} [identity=\"\"] Identity to use.\n* @property {Object} [urlParams={}] Used to add parameters to the WebSocket URL.\n* @property {Number} [ttl] A value in seconds that QIX Engine should keep the session\n* alive after socket disconnect (only works if QIX Engine supports it).\n*/\n\nfunction replaceLeadingAndTrailingSlashes(str) {\n return str.replace(/(^[/]+)|([/]+$)/g, '');\n}\n\nclass SenseUtilities {\n /**\n * Ensures that the configuration has defaults set.\n *\n * @private\n * @param {SenseConfiguration} senseConfig The configuration to ensure defaults on.\n */\n static configureDefaults(senseConfig) {\n if (!senseConfig.host) {\n senseConfig.host = 'localhost';\n }\n\n if (typeof senseConfig.secure === 'undefined') {\n senseConfig.secure = true;\n }\n\n if (!senseConfig.appId && !senseConfig.route) {\n senseConfig.route = 'app/engineData';\n }\n\n if (typeof senseConfig.noData === 'undefined') {\n senseConfig.noData = false;\n }\n }\n\n /**\n * Function used to build an URL.\n * @entry\n * @param {SenseConfiguration} urlConfig - The URL configuration object.\n * @returns {String} Returns the websocket URL.\n * @example Example of building and using a Qlik Sense-compatible WebSocket URL\n * const enigma = require('enigma.js');\n * const schema = require('enigma.js/schemas/12.20.0.json');\n * const SenseUtilities = require('enigma.js/sense-utilities');\n * const url = SenseUtilities.buildUrl({ host: 'my-sense-host', appId: 'some-app' });\n * const session = enigma.create({ schema, url });\n */\n static buildUrl(urlConfig) {\n SenseUtilities.configureDefaults(urlConfig);\n\n const {\n secure,\n host,\n port,\n prefix,\n subpath,\n route,\n identity,\n urlParams,\n ttl,\n appId,\n } = urlConfig;\n\n let url = '';\n\n url += `${secure ? 'wss' : 'ws'}://`;\n url += host || 'localhost';\n\n if (port) {\n url += `:${port}`;\n }\n\n if (prefix) {\n url += `/${replaceLeadingAndTrailingSlashes(prefix)}`;\n }\n\n if (subpath) {\n url += `/${replaceLeadingAndTrailingSlashes(subpath)}`;\n }\n\n if (route) {\n url += `/${replaceLeadingAndTrailingSlashes(route)}`;\n } else if (appId) {\n url += `/app/${encodeURIComponent(appId)}`;\n }\n\n if (identity) {\n url += `/identity/${encodeURIComponent(identity)}`;\n }\n\n if (ttl) {\n url += `/ttl/${ttl}`;\n }\n\n if (urlParams) {\n url += `?${QueryString.stringify(urlParams)}`;\n }\n\n return url;\n }\n}\n\nexport default SenseUtilities;\n"],"names":["qs","sep","eq","options","obj","length","regexp","split","maxKeys","prop","len","i","kstr","vstr","k","v","x","replace","idx","indexOf","substr","decodeURIComponent","Object","prototype","hasOwnProperty","call","Array","isArray","push","stringifyPrimitive","isFinite","name","undefined","keys","map","ks","encodeURIComponent","join","exports","require$$0","require$$1","replaceLeadingAndTrailingSlashes","str","senseConfig","host","secure","appId","route","noData","urlConfig","SenseUtilities","configureDefaults","port","prefix","subpath","identity","urlParams","ttl","url","QueryString","stringify"],"mappings":"8OA8BA,QAAiB,SAASA,EAAIC,EAAKC,EAAIC,GACrCF,EAAMA,GAAO,IACbC,EAAKA,GAAM,IACX,IAAIE,EAAM,GAEV,GAAkB,iBAAPJ,GAAiC,IAAdA,EAAGK,OAC/B,OAAOD,EAGT,IAAIE,EAAS,MACbN,EAAKA,EAAGO,MAAMN,GAEd,IAAIO,EAAU,IACVL,GAAsC,iBAApBA,EAAQK,UAC5BA,EAAUL,EAAQK,SAGpB,IArBsBJ,EAAKK,EAqBvBC,EAAMV,EAAGK,OAEC,EAAVG,GAAqBA,EAANE,IACjBA,EAAMF,GAGR,IAAK,IAAIG,EAAI,EAAGA,EAAID,IAAOC,EAAG,CAC5B,IAEIC,EAAMC,EAAMC,EAAGC,EAFfC,EAAIhB,EAAGW,GAAGM,QAAQX,EAAQ,OAC1BY,EAAMF,EAAEG,QAAQjB,GAKlBW,EAFS,GAAPK,GACFN,EAAOI,EAAEI,OAAO,EAAGF,GACZF,EAAEI,OAAOF,EAAM,KAEtBN,EAAOI,EACA,IAGTF,EAAIO,mBAAmBT,GACvBG,EAAIM,mBAAmBR,GAzCHT,EA2CAA,EA3CKK,EA2CAK,EA1CpBQ,OAAOC,UAAUC,eAAeC,KAAKrB,EAAKK,GA4CpCiB,MAAMC,QAAQvB,EAAIU,IAC3BV,EAAIU,GAAGc,KAAKb,GAEZX,EAAIU,GAAK,CAACV,EAAIU,GAAIC,GAJlBX,EAAIU,GAAKC,EAQb,OAAOX,GCvDLyB,EAAqB,SAASd,GAChC,cAAeA,GACb,IAAK,SACH,OAAOA,EAET,IAAK,UACH,OAAOA,EAAI,OAAS,QAEtB,IAAK,SACH,OAAOe,SAASf,GAAKA,EAAI,GAE3B,QACE,MAAO,OAII,SAASX,EAAKH,EAAKC,EAAI6B,GAOtC,OANA9B,EAAMA,GAAO,IACbC,EAAKA,GAAM,IAC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KAG5BE"} \ No newline at end of file diff --git a/jwt-scratch/src/js/node_modules/jsonwebtoken/CHANGELOG.md b/jwt-scratch/src/js/node_modules/jsonwebtoken/CHANGELOG.md new file mode 100644 index 0000000..54364a2 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/jsonwebtoken/CHANGELOG.md @@ -0,0 +1,476 @@ +# Change Log + + +All notable changes to this project will be documented in this file starting from version **v4.0.0**. +This project adheres to [Semantic Versioning](http://semver.org/). + +## 8.5.1 - 2019-03-18 + +### Bug fix + + - fix: ensure correct PS signing and verification (#585) ([e5874ae428ffc0465e6bd4e660f89f78b56a74a6](https://github.com/auth0/node-jsonwebtoken/commit/e5874ae428ffc0465e6bd4e660f89f78b56a74a6)), closes [#585](https://github.com/auth0/node-jsonwebtoken/issues/585) + +### Docs + + - README: fix markdown for algorithms table ([84e03ef70f9c44a3aef95a1dc122c8238854f683](https://github.com/auth0/node-jsonwebtoken/commit/84e03ef70f9c44a3aef95a1dc122c8238854f683)) + +## 8.5.0 - 2019-02-20 + +### New Functionality + + - feat: add PS JWA support for applicable node versions (#573) ([eefb9d9c6eec54718fa6e41306bda84788df7bec](https://github.com/auth0/node-jsonwebtoken/commit/eefb9d9c6eec54718fa6e41306bda84788df7bec)), closes [#573](https://github.com/auth0/node-jsonwebtoken/issues/573) + - Add complete option in jwt.verify (#522) ([8737789dd330cf9e7870f4df97fd52479adbac22](https://github.com/auth0/node-jsonwebtoken/commit/8737789dd330cf9e7870f4df97fd52479adbac22)), closes [#522](https://github.com/auth0/node-jsonwebtoken/issues/522) + + ### Test Improvements + + - Add tests for private claims in the payload (#555) ([5147852896755dc1291825e2e40556f964411fb2](https://github.com/auth0/node-jsonwebtoken/commit/5147852896755dc1291825e2e40556f964411fb2)), closes [#555](https://github.com/auth0/node-jsonwebtoken/issues/555) + - Force use_strict during testing (#577) ([7b60c127ceade36c33ff33be066e435802001c94](https://github.com/auth0/node-jsonwebtoken/commit/7b60c127ceade36c33ff33be066e435802001c94)), closes [#577](https://github.com/auth0/node-jsonwebtoken/issues/577) + - Refactor tests related to jti and jwtid (#544) ([7eebbc75ab89e01af5dacf2aae90fe05a13a1454](https://github.com/auth0/node-jsonwebtoken/commit/7eebbc75ab89e01af5dacf2aae90fe05a13a1454)), closes [#544](https://github.com/auth0/node-jsonwebtoken/issues/544) + - ci: remove nsp from tests (#569) ([da8f55c3c7b4dd0bfc07a2df228500fdd050242a](https://github.com/auth0/node-jsonwebtoken/commit/da8f55c3c7b4dd0bfc07a2df228500fdd050242a)), closes [#569](https://github.com/auth0/node-jsonwebtoken/issues/569) + +### Docs + +- Fix 'cert' token which isn't a cert (#554) ([0c24fe68cd2866cea6322016bf993cd897fefc98](https://github.com/auth0/node-jsonwebtoken/commit/0c24fe68cd2866cea6322016bf993cd897fefc98)), closes [#554](https://github.com/auth0/node-jsonwebtoken/issues/554) + + +## 8.4.0 - 2018-11-14 + +### New Functionality + + - Add verify option for nonce validation (#540) ([e7938f06fdf2ed3aa88745b72b8ae4ee66c2d0d0](https://github.com/auth0/node-jsonwebtoken/commit/e7938f06fdf2ed3aa88745b72b8ae4ee66c2d0d0)), closes [#540](https://github.com/auth0/node-jsonwebtoken/issues/540) + +### Bug Fixes + + - Updating Node version in Engines spec in package.json (#528) ([cfd1079305170a897dee6a5f55039783e6ee2711](https://github.com/auth0/node-jsonwebtoken/commit/cfd1079305170a897dee6a5f55039783e6ee2711)), closes [#528](https://github.com/auth0/node-jsonwebtoken/issues/528) [#509](https://github.com/auth0/node-jsonwebtoken/issues/509) + - Fixed error message when empty string passed as expiresIn or notBefore option (#531) ([7f9604ac98d4d0ff8d873c3d2b2ea64bd285cb76](https://github.com/auth0/node-jsonwebtoken/commit/7f9604ac98d4d0ff8d873c3d2b2ea64bd285cb76)), closes [#531](https://github.com/auth0/node-jsonwebtoken/issues/531) + +### Docs + + - Update README.md (#527) ([b76f2a80f5229ee5cde321dd2ff14aa5df16d283](https://github.com/auth0/node-jsonwebtoken/commit/b76f2a80f5229ee5cde321dd2ff14aa5df16d283)), closes [#527](https://github.com/auth0/node-jsonwebtoken/issues/527) + - Update README.md (#538) ([1956c4006472fd285b8a85074257cbdbe9131cbf](https://github.com/auth0/node-jsonwebtoken/commit/1956c4006472fd285b8a85074257cbdbe9131cbf)), closes [#538](https://github.com/auth0/node-jsonwebtoken/issues/538) + - Edited the README.md to make certain parts of the document for the api easier to read, emphasizing the examples. (#548) ([dc89a641293d42f72ecfc623ce2eabc33954cb9d](https://github.com/auth0/node-jsonwebtoken/commit/dc89a641293d42f72ecfc623ce2eabc33954cb9d)), closes [#548](https://github.com/auth0/node-jsonwebtoken/issues/548) + - Document NotBeforeError (#529) ([29cd654b956529e939ae8f8c30b9da7063aad501](https://github.com/auth0/node-jsonwebtoken/commit/29cd654b956529e939ae8f8c30b9da7063aad501)), closes [#529](https://github.com/auth0/node-jsonwebtoken/issues/529) + +### Test Improvements + + - Use lolex for faking date in tests (#491) ([677ead6d64482f2067b11437dda07309abe73cfa](https://github.com/auth0/node-jsonwebtoken/commit/677ead6d64482f2067b11437dda07309abe73cfa)), closes [#491](https://github.com/auth0/node-jsonwebtoken/issues/491) + - Update dependencies used for running tests (#518) ([5498bdc4865ffb2ba2fd44d889fad7e83873bb33](https://github.com/auth0/node-jsonwebtoken/commit/5498bdc4865ffb2ba2fd44d889fad7e83873bb33)), closes [#518](https://github.com/auth0/node-jsonwebtoken/issues/518) + - Minor test refactoring for recently added tests (#504) ([e2860a9d2a412627d79741a95bc7159971b923b9](https://github.com/auth0/node-jsonwebtoken/commit/e2860a9d2a412627d79741a95bc7159971b923b9)), closes [#504](https://github.com/auth0/node-jsonwebtoken/issues/504) + - Create and implement async/sync test helpers (#523) ([683d8a9b31ad6327948f84268bd2c8e4350779d1](https://github.com/auth0/node-jsonwebtoken/commit/683d8a9b31ad6327948f84268bd2c8e4350779d1)), closes [#523](https://github.com/auth0/node-jsonwebtoken/issues/523) + - Refactor tests related to audience and aud (#503) ([53d405e0223cce7c83cb51ecf290ca6bec1e9679](https://github.com/auth0/node-jsonwebtoken/commit/53d405e0223cce7c83cb51ecf290ca6bec1e9679)), closes [#503](https://github.com/auth0/node-jsonwebtoken/issues/503) + - Refactor tests related to expiresIn and exp (#501) ([72f0d9e5b11a99082250665d1200c58182903fa6](https://github.com/auth0/node-jsonwebtoken/commit/72f0d9e5b11a99082250665d1200c58182903fa6)), closes [#501](https://github.com/auth0/node-jsonwebtoken/issues/501) + - Refactor tests related to iat and maxAge (#507) ([877bd57ab2aca9b7d230805b21f921baed3da169](https://github.com/auth0/node-jsonwebtoken/commit/877bd57ab2aca9b7d230805b21f921baed3da169)), closes [#507](https://github.com/auth0/node-jsonwebtoken/issues/507) + - Refactor tests related to iss and issuer (#543) ([0906a3fa80f52f959ac1b6343d3024ce5c7e9dea](https://github.com/auth0/node-jsonwebtoken/commit/0906a3fa80f52f959ac1b6343d3024ce5c7e9dea)), closes [#543](https://github.com/auth0/node-jsonwebtoken/issues/543) + - Refactor tests related to kid and keyid (#545) ([88645427a0adb420bd3e149199a2a6bf1e17277e](https://github.com/auth0/node-jsonwebtoken/commit/88645427a0adb420bd3e149199a2a6bf1e17277e)), closes [#545](https://github.com/auth0/node-jsonwebtoken/issues/545) + - Refactor tests related to notBefore and nbf (#497) ([39adf87a6faef3df984140f88e6724ddd709fd89](https://github.com/auth0/node-jsonwebtoken/commit/39adf87a6faef3df984140f88e6724ddd709fd89)), closes [#497](https://github.com/auth0/node-jsonwebtoken/issues/497) + - Refactor tests related to subject and sub (#505) ([5a7fa23c0b4ac6c25304dab8767ef840b43a0eca](https://github.com/auth0/node-jsonwebtoken/commit/5a7fa23c0b4ac6c25304dab8767ef840b43a0eca)), closes [#505](https://github.com/auth0/node-jsonwebtoken/issues/505) + - Implement async/sync tests for exp claim (#536) ([9ae3f207ac64b7450ea0a3434418f5ca58d8125e](https://github.com/auth0/node-jsonwebtoken/commit/9ae3f207ac64b7450ea0a3434418f5ca58d8125e)), closes [#536](https://github.com/auth0/node-jsonwebtoken/issues/536) + - Implement async/sync tests for nbf claim (#537) ([88bc965061ed65299a395f42a100fb8f8c3c683e](https://github.com/auth0/node-jsonwebtoken/commit/88bc965061ed65299a395f42a100fb8f8c3c683e)), closes [#537](https://github.com/auth0/node-jsonwebtoken/issues/537) + - Implement async/sync tests for sub claim (#534) ([342b07bb105a35739eb91265ba5b9dd33c300fc6](https://github.com/auth0/node-jsonwebtoken/commit/342b07bb105a35739eb91265ba5b9dd33c300fc6)), closes [#534](https://github.com/auth0/node-jsonwebtoken/issues/534) + - Implement async/sync tests for the aud claim (#535) ([1c8ff5a68e6da73af2809c9d87faaf78602c99bb](https://github.com/auth0/node-jsonwebtoken/commit/1c8ff5a68e6da73af2809c9d87faaf78602c99bb)), closes [#535](https://github.com/auth0/node-jsonwebtoken/issues/535) + +### CI + + - Added Istanbul to check test-coverage (#468) ([9676a8306428a045e34c3987bd0680fb952b44e3](https://github.com/auth0/node-jsonwebtoken/commit/9676a8306428a045e34c3987bd0680fb952b44e3)), closes [#468](https://github.com/auth0/node-jsonwebtoken/issues/468) + - Complete ESLint conversion and cleanup (#490) ([cb1d2e1e40547f7ecf29fa6635041df6cbba7f40](https://github.com/auth0/node-jsonwebtoken/commit/cb1d2e1e40547f7ecf29fa6635041df6cbba7f40)), closes [#490](https://github.com/auth0/node-jsonwebtoken/issues/490) + - Make code-coverage mandatory when running tests (#495) ([fb0084a78535bfea8d0087c0870e7e3614a2cbe5](https://github.com/auth0/node-jsonwebtoken/commit/fb0084a78535bfea8d0087c0870e7e3614a2cbe5)), closes [#495](https://github.com/auth0/node-jsonwebtoken/issues/495) + + +## 8.3.0 - 2018-06-11 + + - docs: add some clarifications (#473) ([cd33cc81f06068b9df6c224d300dc6f70d8904ab](https://github.com/auth0/node-jsonwebtoken/commit/cd33cc81f06068b9df6c224d300dc6f70d8904ab)), closes [#473](https://github.com/auth0/node-jsonwebtoken/issues/473) + - ci: fix ci execution, remove not needed script (#472) ([c8ff7b2c3ffcd954a64a0273c20a7d1b22339aa5](https://github.com/auth0/node-jsonwebtoken/commit/c8ff7b2c3ffcd954a64a0273c20a7d1b22339aa5)), closes [#472](https://github.com/auth0/node-jsonwebtoken/issues/472) + - new feature: Secret callback revisited (#480) ([d01cc7bcbdeb606d997a580f967b3169fcc622ba](https://github.com/auth0/node-jsonwebtoken/commit/d01cc7bcbdeb606d997a580f967b3169fcc622ba)), closes [#480](https://github.com/auth0/node-jsonwebtoken/issues/480) + - docs:Update README.md (#461) ([f0e0954505f274da95a8d9603598e455b4d2c894](https://github.com/auth0/node-jsonwebtoken/commit/f0e0954505f274da95a8d9603598e455b4d2c894)), closes [#461](https://github.com/auth0/node-jsonwebtoken/issues/461) + + +## 8.2.2 - 2018-05-30 + + - security: deps: jws@3.1.5 (#477) ([ebde9b7cc75cb7ab5176de7ebc4a1d6a8f05bd51](https://github.com/auth0/node-jsonwebtoken/commit/ebde9b7cc75cb7ab5176de7ebc4a1d6a8f05bd51)), closes [#465](https://github.com/auth0/node-jsonwebtoken/issues/465) + - docs: add some clarifications (#473) ([cd33cc81f06068b9df6c224d300dc6f70d8904ab](https://github.com/auth0/node-jsonwebtoken/commit/cd33cc81f06068b9df6c224d300dc6f70d8904ab)), closes [#473](https://github.com/auth0/node-jsonwebtoken/issues/473) + - ci: fix ci execution, remove not needed script (#472) ([c8ff7b2c3ffcd954a64a0273c20a7d1b22339aa5](https://github.com/auth0/node-jsonwebtoken/commit/c8ff7b2c3ffcd954a64a0273c20a7d1b22339aa5)), closes [#472](https://github.com/auth0/node-jsonwebtoken/issues/472) + - docs: Update README.md (#461) ([f0e0954505f274da95a8d9603598e455b4d2c894](https://github.com/auth0/node-jsonwebtoken/commit/f0e0954505f274da95a8d9603598e455b4d2c894)), closes [#461](https://github.com/auth0/node-jsonwebtoken/issues/461) + + +## 8.2.1 - 2018-04-05 + + - bug fix: Check payload is not null when decoded. (#444) ([1232ae9352ce5fd1ca6c593291ce6ad0834a1ff5](https://github.com/auth0/node-jsonwebtoken/commit/1232ae9352ce5fd1ca6c593291ce6ad0834a1ff5)) + - docs: Clarify that buffer/string payloads must be JSON (#442) ([e8ac1be7565a3fd986d40cb5e31a9f6c4d9aed1b](https://github.com/auth0/node-jsonwebtoken/commit/e8ac1be7565a3fd986d40cb5e31a9f6c4d9aed1b)) + + +## 8.2.0 - 2018-03-02 + + - Add a new mutatePayload option (#446) ([d6d7c5e5103f05a92d3633ac190d3025a0455be0](https://github.com/auth0/node-jsonwebtoken/commit/d6d7c5e5103f05a92d3633ac190d3025a0455be0)) + + +## 8.1.1 - 2018-01-22 + + - ci: add newer node versions to build matrix (#428) ([83f3eee44e122da06f812d7da4ace1fa26c24d9d](https://github.com/auth0/node-jsonwebtoken/commit/83f3eee44e122da06f812d7da4ace1fa26c24d9d)) + - deps: Bump ms version to add support for negative numbers (#438) ([25e0e624545eaef76f3c324a134bf103bc394724](https://github.com/auth0/node-jsonwebtoken/commit/25e0e624545eaef76f3c324a134bf103bc394724)) + - docs: Minor typo (#424) ([dddcb73ac05de11b81feeb629f6cf78dd03d2047](https://github.com/auth0/node-jsonwebtoken/commit/dddcb73ac05de11b81feeb629f6cf78dd03d2047)) + - bug fix: Not Before (nbf) calculated based on iat/timestamp (#437) ([2764a64908d97c043d62eba0bf6c600674f9a6d6](https://github.com/auth0/node-jsonwebtoken/commit/2764a64908d97c043d62eba0bf6c600674f9a6d6)), closes [#435](https://github.com/auth0/node-jsonwebtoken/issues/435) + + +## 8.1.0 - 2017-10-09 + + - #402: Don't fail if captureStackTrace is not a function (#410) ([77ee965d9081faaf21650f266399f203f69533c5](https://github.com/auth0/node-jsonwebtoken/commit/77ee965d9081faaf21650f266399f203f69533c5)) + - #403: Clarify error wording for "Expected object" error. (#409) ([bb27eb346f0ff675a320b2de16b391a7cfeadc58](https://github.com/auth0/node-jsonwebtoken/commit/bb27eb346f0ff675a320b2de16b391a7cfeadc58)) + - Enhance audience check to verify against regular expressions (#398) ([81501a17da230af7b74a3f7535ab5cd3a19c8315](https://github.com/auth0/node-jsonwebtoken/commit/81501a17da230af7b74a3f7535ab5cd3a19c8315)) + + +## 8.0.1 - 2017-09-12 + + - Remove `lodash.isarray` dependency (#394) ([7508e8957cb1c778f72fa9a363a7b135b3c9c36d](https://github.com/auth0/node-jsonwebtoken/commit/7508e8957cb1c778f72fa9a363a7b135b3c9c36d)) + +## 8.0.0 - 2017-09-06 + + **Breaking changes: See [Migration notes from v7](https://github.com/auth0/node-jsonwebtoken/wiki/Migration-Notes:-v7-to-v8)** + + - docs: readme, migration notes ([12cd8f7f47224f904f6b8f39d1dee73775de4f6f](https://github.com/auth0/node-jsonwebtoken/commit/12cd8f7f47224f904f6b8f39d1dee73775de4f6f)) + - verify: remove process.nextTick (#302) ([3305cf04e3f674b9fb7e27c9b14ddd159650ff82](https://github.com/auth0/node-jsonwebtoken/commit/3305cf04e3f674b9fb7e27c9b14ddd159650ff82)) + - Reduce size of NPM package (#347) ([0be5409ac6592eeaae373dce91ec992fa101bd8a](https://github.com/auth0/node-jsonwebtoken/commit/0be5409ac6592eeaae373dce91ec992fa101bd8a)) + - Remove joi to shrink module size (#348) ([2e7e68dbd59e845cdd940afae0a296f48438445f](https://github.com/auth0/node-jsonwebtoken/commit/2e7e68dbd59e845cdd940afae0a296f48438445f)) + - maxAge: Add validation to timespan result ([66a4f8b996c8357727ce62a84605a005b2f5eb18](https://github.com/auth0/node-jsonwebtoken/commit/66a4f8b996c8357727ce62a84605a005b2f5eb18)) + +## 7.4.3 - 2017-08-17 + + - Fix breaking change on 7.4.2 for empty secret + "none" algorithm (sync code style) ([PR 386](https://github.com/auth0/node-jsonwebtoken/pull/386)) + +## 7.4.2 - 2017-08-04 + + - bugfix: sign: add check to be sure secret has a value ([c584d1cbc34b788977b36f17cd57ab2212f1230e](https://github.com/auth0/node-jsonwebtoken/commit/c584d1cbc34b788977b36f17cd57ab2212f1230e)) + - docs: about refreshing tokens ([016fc10b847bfbb76b82171cb530f32d7da2001b](https://github.com/auth0/node-jsonwebtoken/commit/016fc10b847bfbb76b82171cb530f32d7da2001b)) + - docs: verifying with base64 encoded secrets ([c25e9906801f89605080cc71b3ee23a5e45a5811](https://github.com/auth0/node-jsonwebtoken/commit/c25e9906801f89605080cc71b3ee23a5e45a5811)) + - tests: Add tests for ES256 ([89900ea00735f76b04f437c9f542285b420fa9cb](https://github.com/auth0/node-jsonwebtoken/commit/89900ea00735f76b04f437c9f542285b420fa9cb)) + - docs: document keyid as option (#361) ([00086c2c006d7fc1a47bae02fa87d194d79aa558](https://github.com/auth0/node-jsonwebtoken/commit/00086c2c006d7fc1a47bae02fa87d194d79aa558)) + - docs: readme: Using private key with passpharase (#353) ([27a7f1d4f35b662426ff0270526d48658da4c8b7](https://github.com/auth0/node-jsonwebtoken/commit/27a7f1d4f35b662426ff0270526d48658da4c8b7)) + +## 7.4.1 - 2017-05-17 + + - bump ms to v2 due a ReDoS vulnerability (#352) ([adcfd6ae4088c838769d169f8cd9154265aa13e0](https://github.com/auth0/node-jsonwebtoken/commit/adcfd6ae4088c838769d169f8cd9154265aa13e0)) + +## 7.4.0 - 2017-04-24 + + - Add docs about numeric date fields ([659f73119900a4d837650d9b3f5af4e64a2f843b](https://github.com/auth0/node-jsonwebtoken/commit/659f73119900a4d837650d9b3f5af4e64a2f843b)) + - Make Options object optional for callback-ish sign ([e202c4fd00c35a24e9ab606eab89186ade13d0cc](https://github.com/auth0/node-jsonwebtoken/commit/e202c4fd00c35a24e9ab606eab89186ade13d0cc)) + +## 7.3.0 - 2017-02-13 + + - Add more information to `maxAge` option in README ([1b0592e99cc8def293eed177e2575fa7f1cf7aa5](https://github.com/auth0/node-jsonwebtoken/commit/1b0592e99cc8def293eed177e2575fa7f1cf7aa5)) + - Add `clockTimestamp` option to `verify()` you can set the current time in seconds with it (#274) ([8fdc1504f4325e7003894ffea078da9cba5208d9](https://github.com/auth0/node-jsonwebtoken/commit/8fdc1504f4325e7003894ffea078da9cba5208d9)) + - Fix handling non string tokens on `verify()` input (#305) ([1b6ec8d466504f58c5a6e2dae3360c828bad92fb](https://github.com/auth0/node-jsonwebtoken/commit/1b6ec8d466504f58c5a6e2dae3360c828bad92fb)), closes [#305](https://github.com/auth0/node-jsonwebtoken/issues/305) + - Fixed a simple typo in docs (#287) ([a54240384e24e18c00e75884295306db311d0cb7](https://github.com/auth0/node-jsonwebtoken/commit/a54240384e24e18c00e75884295306db311d0cb7)), closes [#287](https://github.com/auth0/node-jsonwebtoken/issues/287) + - Raise jws.decode error to avoid confusion with "invalid token" error (#294) ([7f68fe06c88d5c5653785bd66bc68c5b20e1bd8e](https://github.com/auth0/node-jsonwebtoken/commit/7f68fe06c88d5c5653785bd66bc68c5b20e1bd8e)) + - rauchg/ms.js changed to zeit/ms (#303) ([35d84152a6b716d757cb5b1dd3c79fe3a1bc0628](https://github.com/auth0/node-jsonwebtoken/commit/35d84152a6b716d757cb5b1dd3c79fe3a1bc0628)) + +## 7.2.1 - 2016-12-07 + + - add nsp check to find vulnerabilities on npm test ([4219c34b5346811c07f520f10516cc495bcc70dd](https://github.com/auth0/node-jsonwebtoken/commit/4219c34b5346811c07f520f10516cc495bcc70dd)) + - revert to joi@^6 to keep ES5 compatibility ([51d4796c07344bf817687f7ccfeef78f00bf5b4f](https://github.com/auth0/node-jsonwebtoken/commit/51d4796c07344bf817687f7ccfeef78f00bf5b4f)) + +## 7.2.0 - 2016-12-06 + + - improve the documentation for expiration ([771e0b5f9bed90771fb79140eb38e51a3ecac8f0](https://github.com/auth0/node-jsonwebtoken/commit/771e0b5f9bed90771fb79140eb38e51a3ecac8f0)) + - Restructured a sentence ([ccc7610187a862f7a50177eadc9152eef26cd065](https://github.com/auth0/node-jsonwebtoken/commit/ccc7610187a862f7a50177eadc9152eef26cd065)) + - Allow `keyid` on `sign`. ([b412be91b89acb3a742bb609d3b54e47e1dfc441](https://github.com/auth0/node-jsonwebtoken/commit/b412be91b89acb3a742bb609d3b54e47e1dfc441)) + - upgrade joi ([715e3d928023d414d45c6dc3f096a7c8448139ae](https://github.com/auth0/node-jsonwebtoken/commit/715e3d928023d414d45c6dc3f096a7c8448139ae)) + - upgrade to latest nodes and Travis infrastructure ([3febcc1dd23ecdec1abbf89313959941d15eb47a](https://github.com/auth0/node-jsonwebtoken/commit/3febcc1dd23ecdec1abbf89313959941d15eb47a)) + + +## 7.1.10 - 2016-12-06 + + - Bump node-jws version number ([07813dd7194630c9f452684279178af76464a759](https://github.com/auth0/node-jsonwebtoken/commit/07813dd7194630c9f452684279178af76464a759)) + - improve the documentation for expiration ([771e0b5f9bed90771fb79140eb38e51a3ecac8f0](https://github.com/auth0/node-jsonwebtoken/commit/771e0b5f9bed90771fb79140eb38e51a3ecac8f0)) + +## 7.1.9 - 2016-08-11 + + - Revert "Merge branch 'venatir-master'" ([d06359ef3b4e619680e043ee7c16adda16598f52](https://github.com/auth0/node-jsonwebtoken/commit/d06359ef3b4e619680e043ee7c16adda16598f52)) + + + +## 7.1.8 - 2016-08-10 + + - Fixed tests, however typ: 'JWT' should not be in the options at all, so please review other tests ([01903bcdc61b4ed429acbbd1fe0ffe0db364473b](https://github.com/auth0/node-jsonwebtoken/commit/01903bcdc61b4ed429acbbd1fe0ffe0db364473b)) + - Removing unnecessary extra decoding. jwtString is already verified as valid and signature checked ([55d5834f7b637011e1d8b927ff78a92a5fd521cf](https://github.com/auth0/node-jsonwebtoken/commit/55d5834f7b637011e1d8b927ff78a92a5fd521cf)) + - update changelog ([5117aacd0118a10331889a64e61d8186112d8a23](https://github.com/auth0/node-jsonwebtoken/commit/5117aacd0118a10331889a64e61d8186112d8a23)) + + +## 7.1.7 - 2016-07-29 + + - Use lodash.once instead of unlicensed/unmaintained cb ([3ac95ad93ef3068a64e03d8d14deff231b1ed529](https://github.com/auth0/node-jsonwebtoken/commit/3ac95ad93ef3068a64e03d8d14deff231b1ed529)) + +## 7.1.6 - 2016-07-15 + + - fix issue with buffer payload. closes #216 ([6b50ff324b4dfd2cb0e49b666f14a6672d015b22](https://github.com/auth0/node-jsonwebtoken/commit/6b50ff324b4dfd2cb0e49b666f14a6672d015b22)), closes [#216](https://github.com/auth0/node-jsonwebtoken/issues/216) + + +## 7.1.5 - 2016-07-15 + + - update jws in package.json ([b6260951eefc68aae5f4ede359210761f901ff7a](https://github.com/auth0/node-jsonwebtoken/commit/b6260951eefc68aae5f4ede359210761f901ff7a)) + + +## 7.1.4 - 2016-07-14 + + - add redundant test ([bece8816096f324511c3efcb8db0e64b75d757a1](https://github.com/auth0/node-jsonwebtoken/commit/bece8816096f324511c3efcb8db0e64b75d757a1)) + - fix an issue of double callback on error ([758ca5eeca2f1b06c32c9fce70642bf488b2e52b](https://github.com/auth0/node-jsonwebtoken/commit/758ca5eeca2f1b06c32c9fce70642bf488b2e52b)) + +## 7.1.2 - 2016-07-12 + + - do not stringify the payload when signing async - closes #224 ([084f537d3dfbcef2bea411cc0a1515899cc8aa21](https://github.com/auth0/node-jsonwebtoken/commit/084f537d3dfbcef2bea411cc0a1515899cc8aa21)), closes [#224](https://github.com/auth0/node-jsonwebtoken/issues/224) + +## 7.1.1 - 2016-07-12 + + - do not mutate options in jwt.verify, closes #227 ([63263a28a268624dab0927b9ad86fffa44a10f84](https://github.com/auth0/node-jsonwebtoken/commit/63263a28a268624dab0927b9ad86fffa44a10f84)), closes [#227](https://github.com/auth0/node-jsonwebtoken/issues/227) + - refactor into multiple files ([e11d505207fa33501298300c9accbfb809d8748d](https://github.com/auth0/node-jsonwebtoken/commit/e11d505207fa33501298300c9accbfb809d8748d)) + +## 7.1.0 - 2016-07-12 + + - Exp calculated based on iat. fix #217 ([757a16e0e35ad19f9e456820f55d5d9f3fc76aee](https://github.com/auth0/node-jsonwebtoken/commit/757a16e0e35ad19f9e456820f55d5d9f3fc76aee)), closes [#217](https://github.com/auth0/node-jsonwebtoken/issues/217) + +## 7.0.0 - 2016-05-19 + + - change jwt.sign to return errors on callback instead of throwing errors ([1e46c5a42aa3dab8478efa4081d8f8f5c5485d56](https://github.com/auth0/node-jsonwebtoken/commit/1e46c5a42aa3dab8478efa4081d8f8f5c5485d56)) + +## 6.2.0 - 2016-04-29 + + - add support for `options.clockTolerance` to `jwt.verify` ([65ddea934f226bf06bc9d6a55be9587515cfc38d](https://github.com/auth0/node-jsonwebtoken/commit/65ddea934f226bf06bc9d6a55be9587515cfc38d)) + +## 6.1.2 - 2016-04-29 + + - fix sign method for node.js 0.12. closes #193 ([9c38374142d3929be3c9314b5e9bc5d963c5955f](https://github.com/auth0/node-jsonwebtoken/commit/9c38374142d3929be3c9314b5e9bc5d963c5955f)), closes [#193](https://github.com/auth0/node-jsonwebtoken/issues/193) + - improve async test ([7b0981380ddc40a5f1208df520631785b5ffb85a](https://github.com/auth0/node-jsonwebtoken/commit/7b0981380ddc40a5f1208df520631785b5ffb85a)) + +## 6.1.0 - 2016-04-27 + + - verify unsigned tokens ([ec880791c10ed5ef7c8df7bf28ebb95c810479ed](https://github.com/auth0/node-jsonwebtoken/commit/ec880791c10ed5ef7c8df7bf28ebb95c810479ed)) + +## 6.0.1 - 2016-04-27 + +This was an immediate change after publishing 6.0.0. + + - throw error on invalid options when the payload is not an object ([304f1b33075f79ed66f784e27dc4f5307aa39e27](https://github.com/auth0/node-jsonwebtoken/commit/304f1b33075f79ed66f784e27dc4f5307aa39e27)) + +## 6.0.0 - 2016-04-27 + + - Change .sign to standard async callback ([50873c7d45d2733244d5da8afef3d1872e657a60](https://github.com/auth0/node-jsonwebtoken/commit/50873c7d45d2733244d5da8afef3d1872e657a60)) + - Improved the options for the `sign` method ([53c3987b3cc34e95eb396b26fc9b051276e2f6f9](https://github.com/auth0/node-jsonwebtoken/commit/53c3987b3cc34e95eb396b26fc9b051276e2f6f9)) + + - throw error on invalid options like `expiresIn` when the payload is not an object ([304f1b33075f79ed66f784e27dc4f5307aa39e27](https://github.com/auth0/node-jsonwebtoken/commit/304f1b33075f79ed66f784e27dc4f5307aa39e27)) + - `expiresInMinutes` and `expiresInSeconds` are deprecated and no longer supported. + - `notBeforeInMinutes` and `notBeforeInSeconds` are deprecated and no longer supported. + - `options` are strongly validated. + - `options.expiresIn`, `options.notBefore`, `options.audience`, `options.issuer`, `options.subject` and `options.jwtid` are mutually exclusive with `payload.exp`, `payload.nbf`, `payload.aud`, `payload.iss` + - `options.algorithm` is properly validated. + - `options.headers` is renamed to `options.header`. + + - update CHANGELOG to reflect most of the changes. closes #136 ([b87a1a8d2e2533fbfab518765a54f00077918eb7](https://github.com/auth0/node-jsonwebtoken/commit/b87a1a8d2e2533fbfab518765a54f00077918eb7)), closes [#136](https://github.com/auth0/node-jsonwebtoken/issues/136) + - update readme ([53a88ecf4494e30e1d62a1cf3cc354650349f486](https://github.com/auth0/node-jsonwebtoken/commit/53a88ecf4494e30e1d62a1cf3cc354650349f486)) + +## 5.7.0 - 2016-02-16 + + + - add support for validating multiples issuers. closes #163 ([39d9309ae05648dbd72e5fd1993df064ad0e8fa5](https://github.com/auth0/node-jsonwebtoken/commit/39d9309ae05648dbd72e5fd1993df064ad0e8fa5)), closes [#163](https://github.com/auth0/node-jsonwebtoken/issues/163) + + +## 5.6.1 - 2016-02-16 + + + - 5.6.1 ([06d8209d499dbc9a8dd978ab6cbb9c6818fde203](https://github.com/auth0/node-jsonwebtoken/commit/06d8209d499dbc9a8dd978ab6cbb9c6818fde203)) + - fix wrong error when setting expiration on non-object payload. closes #153 ([7f7d76edfd918d6afc7c7cead888caa42ccaceb4](https://github.com/auth0/node-jsonwebtoken/commit/7f7d76edfd918d6afc7c7cead888caa42ccaceb4)), closes [#153](https://github.com/auth0/node-jsonwebtoken/issues/153) + + + +## 5.6.0 - 2016-02-16 + + + - added missing validations of sub and jti ([a1affe960d0fc52e9042bcbdedb65734f8855580](https://github.com/auth0/node-jsonwebtoken/commit/a1affe960d0fc52e9042bcbdedb65734f8855580)) + - Fix tests in jwt.rs.tests.js which causes 4 to fail ([8aedf2b1f575b0d9575c1fc9f2ac7bc868f75ff1](https://github.com/auth0/node-jsonwebtoken/commit/8aedf2b1f575b0d9575c1fc9f2ac7bc868f75ff1)) + - Update README.md ([349b7cd00229789b138928ca060d3ef015aedaf9](https://github.com/auth0/node-jsonwebtoken/commit/349b7cd00229789b138928ca060d3ef015aedaf9)) + + + +## 5.5.4 - 2016-01-04 + + + - minor ([46552e7c45025c76e3f647680d7539a66bfac612](https://github.com/auth0/node-jsonwebtoken/commit/46552e7c45025c76e3f647680d7539a66bfac612)) + + + +## 5.5.3 - 2016-01-04 + + + - add a console.warn on invalid options for string payloads ([71200f14deba0533d3261266348338fac2d14661](https://github.com/auth0/node-jsonwebtoken/commit/71200f14deba0533d3261266348338fac2d14661)) + - minor ([65b1f580382dc58dd3da6f47a52713776fd7cdf2](https://github.com/auth0/node-jsonwebtoken/commit/65b1f580382dc58dd3da6f47a52713776fd7cdf2)) + + + +## 5.5.2 - 2016-01-04 + + + - fix signing method with sealed objects, do not modify the params object. closes #147 ([be9c09af83b09c9e72da8b2c6166fa51d92aeab6](https://github.com/auth0/node-jsonwebtoken/commit/be9c09af83b09c9e72da8b2c6166fa51d92aeab6)), closes [#147](https://github.com/auth0/node-jsonwebtoken/issues/147) + + + +## 5.5.1 - 2016-01-04 + + + - fix nbf verification. fix #152 ([786d37b299c67771b5e71a2ca476666ab0f97d98](https://github.com/auth0/node-jsonwebtoken/commit/786d37b299c67771b5e71a2ca476666ab0f97d98)), closes [#152](https://github.com/auth0/node-jsonwebtoken/issues/152) + + + +## 5.5.0 - 2015-12-28 + + + - improvements to nbf and jti claims ([46372e928f6d2e7398f9b88022ca617d2a3b0699](https://github.com/auth0/node-jsonwebtoken/commit/46372e928f6d2e7398f9b88022ca617d2a3b0699)) + - Remove duplicate payload line (fix bug in IE strict mode) ([8163d698e0c5ad8c44817a5dcd42a15d7e9c6bc8](https://github.com/auth0/node-jsonwebtoken/commit/8163d698e0c5ad8c44817a5dcd42a15d7e9c6bc8)) + - Remove duplicate require('ms') line ([7c00bcbcbf8f7503a1070b394a165eccd41de66f](https://github.com/auth0/node-jsonwebtoken/commit/7c00bcbcbf8f7503a1070b394a165eccd41de66f)) + - Update README to reflect addition of async sign ([d661d4b6f68eb417834c99b36769444723041ccf](https://github.com/auth0/node-jsonwebtoken/commit/d661d4b6f68eb417834c99b36769444723041ccf)) + + + +## 5.4.0 - 2015-10-02 + + + - deprecate expireInMinutes and expireInSeconds - in favor of expiresIn ([39ecc6f8f310f8462e082f1d53de0b4222b29b6f](https://github.com/auth0/node-jsonwebtoken/commit/39ecc6f8f310f8462e082f1d53de0b4222b29b6f)) + + +## 5.3.0 - 2015-10-02 + + + - 5.3.0 ([5d559ced3fbf10c1adae2e5792deda06ea89bcd3](https://github.com/auth0/node-jsonwebtoken/commit/5d559ced3fbf10c1adae2e5792deda06ea89bcd3)) + - minor ([6e81ff87a3799b0e56db09cbae42a97e784716c4](https://github.com/auth0/node-jsonwebtoken/commit/6e81ff87a3799b0e56db09cbae42a97e784716c4)) + + + +## 5.1.0 - 2015-10-02 + + + - added async signing ([9414fbcb15a1f9cf4fe147d070e9424c547dabba](https://github.com/auth0/node-jsonwebtoken/commit/9414fbcb15a1f9cf4fe147d070e9424c547dabba)) + - Update README.md ([40b2aaaa843442dfb8ee7b574f0a788177e7c904](https://github.com/auth0/node-jsonwebtoken/commit/40b2aaaa843442dfb8ee7b574f0a788177e7c904)) + + + +## 5.0.5 - 2015-08-19 + + + - add ms dep to package.json ([f13b3fb7f29dff787e7c91ebe2eb5adeeb05f251](https://github.com/auth0/node-jsonwebtoken/commit/f13b3fb7f29dff787e7c91ebe2eb5adeeb05f251)) + - add note to explain, related to #96 #101 #6 ([dd8969e0e6ed0bcb9cae905d2b1a96476bd85da3](https://github.com/auth0/node-jsonwebtoken/commit/dd8969e0e6ed0bcb9cae905d2b1a96476bd85da3)) + - add tests for options.headers ([7787dd74e705787c39a871ca29c75a2e0a3948ac](https://github.com/auth0/node-jsonwebtoken/commit/7787dd74e705787c39a871ca29c75a2e0a3948ac)) + - add tests for verify expires ([d7c5793d98c300603440ab460c11665f661ad3a0](https://github.com/auth0/node-jsonwebtoken/commit/d7c5793d98c300603440ab460c11665f661ad3a0)) + - add verify option maxAge (with tests) ([49d54e54f7e70b1c53a2e4ee67e116c907d75319](https://github.com/auth0/node-jsonwebtoken/commit/49d54e54f7e70b1c53a2e4ee67e116c907d75319)) + - fix spelling error in error message ([8078b11b224fa05ac9003ca5aa2c85e9f0128cfb](https://github.com/auth0/node-jsonwebtoken/commit/8078b11b224fa05ac9003ca5aa2c85e9f0128cfb)) + - Fix typo options.header is not a documented option + ([5feaa5b962ccbddeff054817a410f7b0c1e6ce7f](https://github.com/auth0/node-jsonwebtoken/commit/5feaa5b962ccbddeff054817a410f7b0c1e6ce7f)) + - update JWT spec link. closes #112 ([f5fa50f797456a12240589161835c7ea30807195](https://github.com/auth0/node-jsonwebtoken/commit/f5fa50f797456a12240589161835c7ea30807195)), closes [#112](https://github.com/auth0/node-jsonwebtoken/issues/112) + + +## 5.0.3 - 2015-07-15 + + - Added nbf support ([f26ba4e2fa197a20497632b63ffcd13ae93aacc4](https://github.com/auth0/node-jsonwebtoken/commit/f26ba4e2fa197a20497632b63ffcd13ae93aacc4)) + - Added support for subject and jwt id ([ab76ec5bc554e2d1e25376ddb7cea711d86af651](https://github.com/auth0/node-jsonwebtoken/commit/ab76ec5bc554e2d1e25376ddb7cea711d86af651)) + - Fix `this` referring to the global object instead of `module.exports` in `verify()` ([93f554312e37129027fcf4916f48cb8d1b53588c](https://github.com/auth0/node-jsonwebtoken/commit/93f554312e37129027fcf4916f48cb8d1b53588c)) + - Fix typo, line 139 README, complete option for .decode. ([59c110aeb8c7c1847ef2ffd77702d13627c89e10](https://github.com/auth0/node-jsonwebtoken/commit/59c110aeb8c7c1847ef2ffd77702d13627c89e10)) + - minor ([61ff1172272b582902313e958058ff22413494af](https://github.com/auth0/node-jsonwebtoken/commit/61ff1172272b582902313e958058ff22413494af)) + + + +## 5.0.2 - 2015-06-15 + + + - fix typo in docs . closes #86 ([3d3413221f36acef4dfd1cbed87f1f3565cd6f84](https://github.com/auth0/node-jsonwebtoken/commit/3d3413221f36acef4dfd1cbed87f1f3565cd6f84)), closes [#86](https://github.com/auth0/node-jsonwebtoken/issues/86) + + + +## 5.0.1 - 2015-05-15 + + + - Add option to return header and payload when decoding. ([7254e011b59f892d1947e6c11819281adac7069d](https://github.com/auth0/node-jsonwebtoken/commit/7254e011b59f892d1947e6c11819281adac7069d)) + - Avoid uncaught "SyntaxError: Unexpected token ͧ" error. ([0dc59cd6ee15d83a606acffa7909ee76176ae186](https://github.com/auth0/node-jsonwebtoken/commit/0dc59cd6ee15d83a606acffa7909ee76176ae186)) + - Document complete option in README. ([ec32b20241a74d9681ea26e1a7024b4642468c00](https://github.com/auth0/node-jsonwebtoken/commit/ec32b20241a74d9681ea26e1a7024b4642468c00)) + - Fix example in README, silence verbose logging. ([ba3174d10033c41e9c211a38f1cc67f74fbd7f69](https://github.com/auth0/node-jsonwebtoken/commit/ba3174d10033c41e9c211a38f1cc67f74fbd7f69)) + - Fix link to auth0.com in README ([1b3c5ff72c9bc25e9271646e679f3080f2a042a0](https://github.com/auth0/node-jsonwebtoken/commit/1b3c5ff72c9bc25e9271646e679f3080f2a042a0)) + - Immediate return if not decoded. ([851bda2b10168f3269c3da6e74d310742f31a193](https://github.com/auth0/node-jsonwebtoken/commit/851bda2b10168f3269c3da6e74d310742f31a193)) + - Prevent throw on undefined/null secret ([0fdf78d4dbf609455f3277d6169a987aef0384d4](https://github.com/auth0/node-jsonwebtoken/commit/0fdf78d4dbf609455f3277d6169a987aef0384d4)) + - Removed path from test ([d6240e24186732d368bffe21143becf44c38f0d6](https://github.com/auth0/node-jsonwebtoken/commit/d6240e24186732d368bffe21143becf44c38f0d6)) + - Simplified checking for missing key ([f1cffd033bffc44f20558eda4a797c3fa2f4ee05](https://github.com/auth0/node-jsonwebtoken/commit/f1cffd033bffc44f20558eda4a797c3fa2f4ee05)) + - Typo ([ffe68dbe0219bab535c1018448eb4c0b22f1f902](https://github.com/auth0/node-jsonwebtoken/commit/ffe68dbe0219bab535c1018448eb4c0b22f1f902)) + - Update CHANGELOG.md ([927cce0dad1bc9aad75aeef53e276cf4cfc0d776](https://github.com/auth0/node-jsonwebtoken/commit/927cce0dad1bc9aad75aeef53e276cf4cfc0d776)) + - Update CHANGELOG.md ([6879e0fdde222995c70a3a69a4af94993d9c667e](https://github.com/auth0/node-jsonwebtoken/commit/6879e0fdde222995c70a3a69a4af94993d9c667e)) + - Update CHANGELOG.md ([c5596c10e8705727fa13e0394184a606083078bc](https://github.com/auth0/node-jsonwebtoken/commit/c5596c10e8705727fa13e0394184a606083078bc)) + - Update CHANGELOG.md ([07541f0315f26d179e1cde92732b6124d6869b6f](https://github.com/auth0/node-jsonwebtoken/commit/07541f0315f26d179e1cde92732b6124d6869b6f)) + - Update CHANGELOG.md ([e6465d48ddd1dc2c3297229b28c78fd5490a2ba9](https://github.com/auth0/node-jsonwebtoken/commit/e6465d48ddd1dc2c3297229b28c78fd5490a2ba9)) + +## [5.0.0] - 2015-04-11 + +### Changed + + - [sign] Only set defautl `iat` if the user does not specify that argument. + + https://github.com/auth0/node-jsonwebtoken/commit/e900282a8d2dff1d4dec815f7e6aa7782e867d91 + https://github.com/auth0/node-jsonwebtoken/commit/35036b188b4ee6b42df553bbb93bc8a6b19eae9d + https://github.com/auth0/node-jsonwebtoken/commit/954bd7a312934f03036b6bb6f00edd41f29e54d9 + https://github.com/auth0/node-jsonwebtoken/commit/24a370080e0b75f11d4717cd2b11b2949d95fc2e + https://github.com/auth0/node-jsonwebtoken/commit/a77df6d49d4ec688dfd0a1cc723586bffe753516 + +### Security + + - [verify] Update to jws@^3.0.0 and renaming `header.alg` mismatch exception to `invalid algorithm` and adding more mismatch tests. + + As `jws@3.0.0` changed the verify method signature to be `jws.verify(signature, algorithm, secretOrKey)`, the token header must be decoded first in order to make sure that the `alg` field matches one of the allowed `options.algorithms`. After that, the now validated `header.alg` is passed to `jws.verify` + + As the order of steps has changed, the error that was thrown when the JWT was invalid is no longer the `jws` one: + ``` + { [Error: Invalid token: no header in signature 'a.b.c'] code: 'MISSING_HEADER', signature: 'a.b.c' } + ``` + + That old error (removed from jws) has been replaced by a `JsonWebTokenError` with message `invalid token`. + + > Important: versions >= 4.2.2 this library are safe to use but we decided to deprecate everything `< 5.0.0` to prevent security warnings from library `node-jws` when doing `npm install`. + + https://github.com/auth0/node-jsonwebtoken/commit/634b8ed0ff5267dc25da5c808634208af109824e + https://github.com/auth0/node-jsonwebtoken/commit/9f24ffd5791febb449d4d03ff58d7807da9b9b7e + https://github.com/auth0/node-jsonwebtoken/commit/19e6cc6a1f2fd90356f89b074223b9665f2aa8a2 + https://github.com/auth0/node-jsonwebtoken/commit/1e4623420159c6410616f02a44ed240f176287a9 + https://github.com/auth0/node-jsonwebtoken/commit/954bd7a312934f03036b6bb6f00edd41f29e54d9 + https://github.com/auth0/node-jsonwebtoken/commit/24a370080e0b75f11d4717cd2b11b2949d95fc2e + https://github.com/auth0/node-jsonwebtoken/commit/a77df6d49d4ec688dfd0a1cc723586bffe753516 + +## [4.2.2] - 2015-03-26 +### Fixed + + - [asymmetric-keys] Fix verify for RSAPublicKey formated keys (`jfromaniello - awlayton`) + https://github.com/auth0/node-jsonwebtoken/commit/402794663b9521bf602fcc6f2e811e7d3912f9dc + https://github.com/auth0/node-jsonwebtoken/commit/8df6aabbc7e1114c8fb3917931078254eb52c222 + +## [4.2.1] - 2015-03-17 +### Fixed + + - [asymmetric-keys] Fixed issue when public key starts with BEING PUBLIC KEY (https://github.com/auth0/node-jsonwebtoken/issues/70) (`jfromaniello`) + https://github.com/auth0/node-jsonwebtoken/commit/7017e74db9b194448ff488b3e16468ada60c4ee5 + +## [4.2.0] - 2015-03-16 +### Security + + - [asymmetric-keys] Making sure a token signed with an asymmetric key will be verified using a asymmetric key. + When the verification part was expecting a token digitally signed with an asymmetric key (RS/ES family) of algorithms an attacker could send a token signed with a symmetric algorithm (HS* family). + + The issue was caused because the same signature was used to verify both type of tokens (`verify` method parameter: `secretOrPublicKey`). + + This change adds a new parameter to the verify called `algorithms`. This can be used to specify a list of supported algorithms, but the default value depends on the secret used: if the secretOrPublicKey contains the string `BEGIN CERTIFICATE` the default is `[ 'RS256','RS384','RS512','ES256','ES384','ES512' ]` otherwise is `[ 'HS256','HS384','HS512' ]`. (`jfromaniello`) + https://github.com/auth0/node-jsonwebtoken/commit/c2bf7b2cd7e8daf66298c2d168a008690bc4bdd3 + https://github.com/auth0/node-jsonwebtoken/commit/1bb584bc382295eeb7ee8c4452a673a77a68b687 + +## [4.1.0] - 2015-03-10 +### Changed +- Assume the payload is JSON even when there is no `typ` property. [5290db1](https://github.com/auth0/node-jsonwebtoken/commit/5290db1bd74f74cd38c90b19e2355ef223a4d931) + +## [4.0.0] - 2015-03-06 +### Changed +- The default encoding is now utf8 instead of binary. [92d33bd](https://github.com/auth0/node-jsonwebtoken/commit/92d33bd99a3416e9e5a8897d9ad8ff7d70a00bfd) +- Add `encoding` as a new option to `sign`. [1fc385e](https://github.com/auth0/node-jsonwebtoken/commit/1fc385ee10bd0018cd1441552dce6c2e5a16375f) +- Add `ignoreExpiration` to `verify`. [8d4da27](https://github.com/auth0/node-jsonwebtoken/commit/8d4da279e1b351ac71ace276285c9255186d549f) +- Add `expiresInSeconds` to `sign`. [dd156cc](https://github.com/auth0/node-jsonwebtoken/commit/dd156cc30f17028744e60aec0502897e34609329) + +### Fixed +- Fix wrong error message when the audience doesn't match. [44e3c8d](https://github.com/auth0/node-jsonwebtoken/commit/44e3c8d757e6b4e2a57a69a035f26b4abec3e327) +- Fix wrong error message when the issuer doesn't match. [44e3c8d](https://github.com/auth0/node-jsonwebtoken/commit/44e3c8d757e6b4e2a57a69a035f26b4abec3e327) +- Fix wrong `iat` and `exp` values when signing with `noTimestamp`. [331b7bc](https://github.com/auth0/node-jsonwebtoken/commit/331b7bc9cc335561f8806f2c4558e105cb53e0a6) diff --git a/jwt-scratch/src/js/node_modules/jsonwebtoken/LICENSE b/jwt-scratch/src/js/node_modules/jsonwebtoken/LICENSE new file mode 100644 index 0000000..bcd1854 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/jsonwebtoken/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2015 Auth0, Inc. (http://auth0.com) + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/jwt-scratch/src/js/node_modules/jsonwebtoken/README.md b/jwt-scratch/src/js/node_modules/jsonwebtoken/README.md new file mode 100644 index 0000000..f966435 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/jsonwebtoken/README.md @@ -0,0 +1,375 @@ +# jsonwebtoken + +| **Build** | **Dependency** | +|-----------|---------------| +| [![Build Status](https://secure.travis-ci.org/auth0/node-jsonwebtoken.svg?branch=master)](http://travis-ci.org/auth0/node-jsonwebtoken) | [![Dependency Status](https://david-dm.org/auth0/node-jsonwebtoken.svg)](https://david-dm.org/auth0/node-jsonwebtoken) | + + +An implementation of [JSON Web Tokens](https://tools.ietf.org/html/rfc7519). + +This was developed against `draft-ietf-oauth-json-web-token-08`. It makes use of [node-jws](https://github.com/brianloveswords/node-jws) + +# Install + +```bash +$ npm install jsonwebtoken +``` + +# Migration notes + +* [From v7 to v8](https://github.com/auth0/node-jsonwebtoken/wiki/Migration-Notes:-v7-to-v8) + +# Usage + +### jwt.sign(payload, secretOrPrivateKey, [options, callback]) + +(Asynchronous) If a callback is supplied, the callback is called with the `err` or the JWT. + +(Synchronous) Returns the JsonWebToken as string + +`payload` could be an object literal, buffer or string representing valid JSON. +> **Please _note_ that** `exp` or any other claim is only set if the payload is an object literal. Buffer or string payloads are not checked for JSON validity. + +> If `payload` is not a buffer or a string, it will be coerced into a string using `JSON.stringify`. + +`secretOrPrivateKey` is a string, buffer, or object containing either the secret for HMAC algorithms or the PEM +encoded private key for RSA and ECDSA. In case of a private key with passphrase an object `{ key, passphrase }` can be used (based on [crypto documentation](https://nodejs.org/api/crypto.html#crypto_sign_sign_private_key_output_format)), in this case be sure you pass the `algorithm` option. + +`options`: + +* `algorithm` (default: `HS256`) +* `expiresIn`: expressed in seconds or a string describing a time span [zeit/ms](https://github.com/zeit/ms). + > Eg: `60`, `"2 days"`, `"10h"`, `"7d"`. A numeric value is interpreted as a seconds count. If you use a string be sure you provide the time units (days, hours, etc), otherwise milliseconds unit is used by default (`"120"` is equal to `"120ms"`). +* `notBefore`: expressed in seconds or a string describing a time span [zeit/ms](https://github.com/zeit/ms). + > Eg: `60`, `"2 days"`, `"10h"`, `"7d"`. A numeric value is interpreted as a seconds count. If you use a string be sure you provide the time units (days, hours, etc), otherwise milliseconds unit is used by default (`"120"` is equal to `"120ms"`). +* `audience` +* `issuer` +* `jwtid` +* `subject` +* `noTimestamp` +* `header` +* `keyid` +* `mutatePayload`: if true, the sign function will modify the payload object directly. This is useful if you need a raw reference to the payload after claims have been applied to it but before it has been encoded into a token. + + + +> There are no default values for `expiresIn`, `notBefore`, `audience`, `subject`, `issuer`. These claims can also be provided in the payload directly with `exp`, `nbf`, `aud`, `sub` and `iss` respectively, but you **_can't_** include in both places. + +Remember that `exp`, `nbf` and `iat` are **NumericDate**, see related [Token Expiration (exp claim)](#token-expiration-exp-claim) + + +The header can be customized via the `options.header` object. + +Generated jwts will include an `iat` (issued at) claim by default unless `noTimestamp` is specified. If `iat` is inserted in the payload, it will be used instead of the real timestamp for calculating other things like `exp` given a timespan in `options.expiresIn`. + +Synchronous Sign with default (HMAC SHA256) + +```js +var jwt = require('jsonwebtoken'); +var token = jwt.sign({ foo: 'bar' }, 'shhhhh'); +``` + +Synchronous Sign with RSA SHA256 +```js +// sign with RSA SHA256 +var privateKey = fs.readFileSync('private.key'); +var token = jwt.sign({ foo: 'bar' }, privateKey, { algorithm: 'RS256'}); +``` + +Sign asynchronously +```js +jwt.sign({ foo: 'bar' }, privateKey, { algorithm: 'RS256' }, function(err, token) { + console.log(token); +}); +``` + +Backdate a jwt 30 seconds +```js +var older_token = jwt.sign({ foo: 'bar', iat: Math.floor(Date.now() / 1000) - 30 }, 'shhhhh'); +``` + +#### Token Expiration (exp claim) + +The standard for JWT defines an `exp` claim for expiration. The expiration is represented as a **NumericDate**: + +> A JSON numeric value representing the number of seconds from 1970-01-01T00:00:00Z UTC until the specified UTC date/time, ignoring leap seconds. This is equivalent to the IEEE Std 1003.1, 2013 Edition [POSIX.1] definition "Seconds Since the Epoch", in which each day is accounted for by exactly 86400 seconds, other than that non-integer values can be represented. See RFC 3339 [RFC3339] for details regarding date/times in general and UTC in particular. + +This means that the `exp` field should contain the number of seconds since the epoch. + +Signing a token with 1 hour of expiration: + +```javascript +jwt.sign({ + exp: Math.floor(Date.now() / 1000) + (60 * 60), + data: 'foobar' +}, 'secret'); +``` + +Another way to generate a token like this with this library is: + +```javascript +jwt.sign({ + data: 'foobar' +}, 'secret', { expiresIn: 60 * 60 }); + +//or even better: + +jwt.sign({ + data: 'foobar' +}, 'secret', { expiresIn: '1h' }); +``` + +### jwt.verify(token, secretOrPublicKey, [options, callback]) + +(Asynchronous) If a callback is supplied, function acts asynchronously. The callback is called with the decoded payload if the signature is valid and optional expiration, audience, or issuer are valid. If not, it will be called with the error. + +(Synchronous) If a callback is not supplied, function acts synchronously. Returns the payload decoded if the signature is valid and optional expiration, audience, or issuer are valid. If not, it will throw the error. + +`token` is the JsonWebToken string + +`secretOrPublicKey` is a string or buffer containing either the secret for HMAC algorithms, or the PEM +encoded public key for RSA and ECDSA. +If `jwt.verify` is called asynchronous, `secretOrPublicKey` can be a function that should fetch the secret or public key. See below for a detailed example + +As mentioned in [this comment](https://github.com/auth0/node-jsonwebtoken/issues/208#issuecomment-231861138), there are other libraries that expect base64 encoded secrets (random bytes encoded using base64), if that is your case you can pass `Buffer.from(secret, 'base64')`, by doing this the secret will be decoded using base64 and the token verification will use the original random bytes. + +`options` + +* `algorithms`: List of strings with the names of the allowed algorithms. For instance, `["HS256", "HS384"]`. +* `audience`: if you want to check audience (`aud`), provide a value here. The audience can be checked against a string, a regular expression or a list of strings and/or regular expressions. + > Eg: `"urn:foo"`, `/urn:f[o]{2}/`, `[/urn:f[o]{2}/, "urn:bar"]` +* `complete`: return an object with the decoded `{ payload, header, signature }` instead of only the usual content of the payload. +* `issuer` (optional): string or array of strings of valid values for the `iss` field. +* `ignoreExpiration`: if `true` do not validate the expiration of the token. +* `ignoreNotBefore`... +* `subject`: if you want to check subject (`sub`), provide a value here +* `clockTolerance`: number of seconds to tolerate when checking the `nbf` and `exp` claims, to deal with small clock differences among different servers +* `maxAge`: the maximum allowed age for tokens to still be valid. It is expressed in seconds or a string describing a time span [zeit/ms](https://github.com/zeit/ms). + > Eg: `1000`, `"2 days"`, `"10h"`, `"7d"`. A numeric value is interpreted as a seconds count. If you use a string be sure you provide the time units (days, hours, etc), otherwise milliseconds unit is used by default (`"120"` is equal to `"120ms"`). +* `clockTimestamp`: the time in seconds that should be used as the current time for all necessary comparisons. +* `nonce`: if you want to check `nonce` claim, provide a string value here. It is used on Open ID for the ID Tokens. ([Open ID implementation notes](https://openid.net/specs/openid-connect-core-1_0.html#NonceNotes)) + + +```js +// verify a token symmetric - synchronous +var decoded = jwt.verify(token, 'shhhhh'); +console.log(decoded.foo) // bar + +// verify a token symmetric +jwt.verify(token, 'shhhhh', function(err, decoded) { + console.log(decoded.foo) // bar +}); + +// invalid token - synchronous +try { + var decoded = jwt.verify(token, 'wrong-secret'); +} catch(err) { + // err +} + +// invalid token +jwt.verify(token, 'wrong-secret', function(err, decoded) { + // err + // decoded undefined +}); + +// verify a token asymmetric +var cert = fs.readFileSync('public.pem'); // get public key +jwt.verify(token, cert, function(err, decoded) { + console.log(decoded.foo) // bar +}); + +// verify audience +var cert = fs.readFileSync('public.pem'); // get public key +jwt.verify(token, cert, { audience: 'urn:foo' }, function(err, decoded) { + // if audience mismatch, err == invalid audience +}); + +// verify issuer +var cert = fs.readFileSync('public.pem'); // get public key +jwt.verify(token, cert, { audience: 'urn:foo', issuer: 'urn:issuer' }, function(err, decoded) { + // if issuer mismatch, err == invalid issuer +}); + +// verify jwt id +var cert = fs.readFileSync('public.pem'); // get public key +jwt.verify(token, cert, { audience: 'urn:foo', issuer: 'urn:issuer', jwtid: 'jwtid' }, function(err, decoded) { + // if jwt id mismatch, err == invalid jwt id +}); + +// verify subject +var cert = fs.readFileSync('public.pem'); // get public key +jwt.verify(token, cert, { audience: 'urn:foo', issuer: 'urn:issuer', jwtid: 'jwtid', subject: 'subject' }, function(err, decoded) { + // if subject mismatch, err == invalid subject +}); + +// alg mismatch +var cert = fs.readFileSync('public.pem'); // get public key +jwt.verify(token, cert, { algorithms: ['RS256'] }, function (err, payload) { + // if token alg != RS256, err == invalid signature +}); + +// Verify using getKey callback +// Example uses https://github.com/auth0/node-jwks-rsa as a way to fetch the keys. +var jwksClient = require('jwks-rsa'); +var client = jwksClient({ + jwksUri: 'https://sandrino.auth0.com/.well-known/jwks.json' +}); +function getKey(header, callback){ + client.getSigningKey(header.kid, function(err, key) { + var signingKey = key.publicKey || key.rsaPublicKey; + callback(null, signingKey); + }); +} + +jwt.verify(token, getKey, options, function(err, decoded) { + console.log(decoded.foo) // bar +}); + +``` + +### jwt.decode(token [, options]) + +(Synchronous) Returns the decoded payload without verifying if the signature is valid. + +> __Warning:__ This will __not__ verify whether the signature is valid. You should __not__ use this for untrusted messages. You most likely want to use `jwt.verify` instead. + +`token` is the JsonWebToken string + +`options`: + +* `json`: force JSON.parse on the payload even if the header doesn't contain `"typ":"JWT"`. +* `complete`: return an object with the decoded payload and header. + +Example + +```js +// get the decoded payload ignoring signature, no secretOrPrivateKey needed +var decoded = jwt.decode(token); + +// get the decoded payload and header +var decoded = jwt.decode(token, {complete: true}); +console.log(decoded.header); +console.log(decoded.payload) +``` + +## Errors & Codes +Possible thrown errors during verification. +Error is the first argument of the verification callback. + +### TokenExpiredError + +Thrown error if the token is expired. + +Error object: + +* name: 'TokenExpiredError' +* message: 'jwt expired' +* expiredAt: [ExpDate] + +```js +jwt.verify(token, 'shhhhh', function(err, decoded) { + if (err) { + /* + err = { + name: 'TokenExpiredError', + message: 'jwt expired', + expiredAt: 1408621000 + } + */ + } +}); +``` + +### JsonWebTokenError +Error object: + +* name: 'JsonWebTokenError' +* message: + * 'jwt malformed' + * 'jwt signature is required' + * 'invalid signature' + * 'jwt audience invalid. expected: [OPTIONS AUDIENCE]' + * 'jwt issuer invalid. expected: [OPTIONS ISSUER]' + * 'jwt id invalid. expected: [OPTIONS JWT ID]' + * 'jwt subject invalid. expected: [OPTIONS SUBJECT]' + +```js +jwt.verify(token, 'shhhhh', function(err, decoded) { + if (err) { + /* + err = { + name: 'JsonWebTokenError', + message: 'jwt malformed' + } + */ + } +}); +``` + +### NotBeforeError +Thrown if current time is before the nbf claim. + +Error object: + +* name: 'NotBeforeError' +* message: 'jwt not active' +* date: 2018-10-04T16:10:44.000Z + +```js +jwt.verify(token, 'shhhhh', function(err, decoded) { + if (err) { + /* + err = { + name: 'NotBeforeError', + message: 'jwt not active', + date: 2018-10-04T16:10:44.000Z + } + */ + } +}); +``` + + +## Algorithms supported + +Array of supported algorithms. The following algorithms are currently supported. + +alg Parameter Value | Digital Signature or MAC Algorithm +----------------|---------------------------- +HS256 | HMAC using SHA-256 hash algorithm +HS384 | HMAC using SHA-384 hash algorithm +HS512 | HMAC using SHA-512 hash algorithm +RS256 | RSASSA-PKCS1-v1_5 using SHA-256 hash algorithm +RS384 | RSASSA-PKCS1-v1_5 using SHA-384 hash algorithm +RS512 | RSASSA-PKCS1-v1_5 using SHA-512 hash algorithm +PS256 | RSASSA-PSS using SHA-256 hash algorithm (only node ^6.12.0 OR >=8.0.0) +PS384 | RSASSA-PSS using SHA-384 hash algorithm (only node ^6.12.0 OR >=8.0.0) +PS512 | RSASSA-PSS using SHA-512 hash algorithm (only node ^6.12.0 OR >=8.0.0) +ES256 | ECDSA using P-256 curve and SHA-256 hash algorithm +ES384 | ECDSA using P-384 curve and SHA-384 hash algorithm +ES512 | ECDSA using P-521 curve and SHA-512 hash algorithm +none | No digital signature or MAC value included + +## Refreshing JWTs + +First of all, we recommend you to think carefully if auto-refreshing a JWT will not introduce any vulnerability in your system. + +We are not comfortable including this as part of the library, however, you can take a look at [this example](https://gist.github.com/ziluvatar/a3feb505c4c0ec37059054537b38fc48) to show how this could be accomplished. +Apart from that example there are [an issue](https://github.com/auth0/node-jsonwebtoken/issues/122) and [a pull request](https://github.com/auth0/node-jsonwebtoken/pull/172) to get more knowledge about this topic. + +# TODO + +* X.509 certificate chain is not checked + +## Issue Reporting + +If you have found a bug or if you have a feature request, please report them at this repository issues section. Please do not report security vulnerabilities on the public GitHub issue tracker. The [Responsible Disclosure Program](https://auth0.com/whitehat) details the procedure for disclosing security issues. + +## Author + +[Auth0](https://auth0.com) + +## License + +This project is licensed under the MIT license. See the [LICENSE](LICENSE) file for more info. diff --git a/jwt-scratch/src/js/node_modules/jsonwebtoken/decode.js b/jwt-scratch/src/js/node_modules/jsonwebtoken/decode.js new file mode 100644 index 0000000..8fe1adc --- /dev/null +++ b/jwt-scratch/src/js/node_modules/jsonwebtoken/decode.js @@ -0,0 +1,30 @@ +var jws = require('jws'); + +module.exports = function (jwt, options) { + options = options || {}; + var decoded = jws.decode(jwt, options); + if (!decoded) { return null; } + var payload = decoded.payload; + + //try parse the payload + if(typeof payload === 'string') { + try { + var obj = JSON.parse(payload); + if(obj !== null && typeof obj === 'object') { + payload = obj; + } + } catch (e) { } + } + + //return header if `complete` option is enabled. header includes claims + //such as `kid` and `alg` used to select the key within a JWKS needed to + //verify the signature + if (options.complete === true) { + return { + header: decoded.header, + payload: payload, + signature: decoded.signature + }; + } + return payload; +}; diff --git a/jwt-scratch/src/js/node_modules/jsonwebtoken/index.js b/jwt-scratch/src/js/node_modules/jsonwebtoken/index.js new file mode 100644 index 0000000..161eb2d --- /dev/null +++ b/jwt-scratch/src/js/node_modules/jsonwebtoken/index.js @@ -0,0 +1,8 @@ +module.exports = { + decode: require('./decode'), + verify: require('./verify'), + sign: require('./sign'), + JsonWebTokenError: require('./lib/JsonWebTokenError'), + NotBeforeError: require('./lib/NotBeforeError'), + TokenExpiredError: require('./lib/TokenExpiredError'), +}; diff --git a/jwt-scratch/src/js/node_modules/jsonwebtoken/lib/JsonWebTokenError.js b/jwt-scratch/src/js/node_modules/jsonwebtoken/lib/JsonWebTokenError.js new file mode 100644 index 0000000..e068222 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/jsonwebtoken/lib/JsonWebTokenError.js @@ -0,0 +1,14 @@ +var JsonWebTokenError = function (message, error) { + Error.call(this, message); + if(Error.captureStackTrace) { + Error.captureStackTrace(this, this.constructor); + } + this.name = 'JsonWebTokenError'; + this.message = message; + if (error) this.inner = error; +}; + +JsonWebTokenError.prototype = Object.create(Error.prototype); +JsonWebTokenError.prototype.constructor = JsonWebTokenError; + +module.exports = JsonWebTokenError; diff --git a/jwt-scratch/src/js/node_modules/jsonwebtoken/lib/NotBeforeError.js b/jwt-scratch/src/js/node_modules/jsonwebtoken/lib/NotBeforeError.js new file mode 100644 index 0000000..7b30084 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/jsonwebtoken/lib/NotBeforeError.js @@ -0,0 +1,13 @@ +var JsonWebTokenError = require('./JsonWebTokenError'); + +var NotBeforeError = function (message, date) { + JsonWebTokenError.call(this, message); + this.name = 'NotBeforeError'; + this.date = date; +}; + +NotBeforeError.prototype = Object.create(JsonWebTokenError.prototype); + +NotBeforeError.prototype.constructor = NotBeforeError; + +module.exports = NotBeforeError; \ No newline at end of file diff --git a/jwt-scratch/src/js/node_modules/jsonwebtoken/lib/TokenExpiredError.js b/jwt-scratch/src/js/node_modules/jsonwebtoken/lib/TokenExpiredError.js new file mode 100644 index 0000000..abb704f --- /dev/null +++ b/jwt-scratch/src/js/node_modules/jsonwebtoken/lib/TokenExpiredError.js @@ -0,0 +1,13 @@ +var JsonWebTokenError = require('./JsonWebTokenError'); + +var TokenExpiredError = function (message, expiredAt) { + JsonWebTokenError.call(this, message); + this.name = 'TokenExpiredError'; + this.expiredAt = expiredAt; +}; + +TokenExpiredError.prototype = Object.create(JsonWebTokenError.prototype); + +TokenExpiredError.prototype.constructor = TokenExpiredError; + +module.exports = TokenExpiredError; \ No newline at end of file diff --git a/jwt-scratch/src/js/node_modules/jsonwebtoken/lib/psSupported.js b/jwt-scratch/src/js/node_modules/jsonwebtoken/lib/psSupported.js new file mode 100644 index 0000000..8c04144 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/jsonwebtoken/lib/psSupported.js @@ -0,0 +1,3 @@ +var semver = require('semver'); + +module.exports = semver.satisfies(process.version, '^6.12.0 || >=8.0.0'); diff --git a/jwt-scratch/src/js/node_modules/jsonwebtoken/lib/timespan.js b/jwt-scratch/src/js/node_modules/jsonwebtoken/lib/timespan.js new file mode 100644 index 0000000..e509869 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/jsonwebtoken/lib/timespan.js @@ -0,0 +1,18 @@ +var ms = require('ms'); + +module.exports = function (time, iat) { + var timestamp = iat || Math.floor(Date.now() / 1000); + + if (typeof time === 'string') { + var milliseconds = ms(time); + if (typeof milliseconds === 'undefined') { + return; + } + return Math.floor(timestamp + milliseconds / 1000); + } else if (typeof time === 'number') { + return timestamp + time; + } else { + return; + } + +}; \ No newline at end of file diff --git a/jwt-scratch/src/js/node_modules/jsonwebtoken/package.json b/jwt-scratch/src/js/node_modules/jsonwebtoken/package.json new file mode 100644 index 0000000..083466a --- /dev/null +++ b/jwt-scratch/src/js/node_modules/jsonwebtoken/package.json @@ -0,0 +1,100 @@ +{ + "_from": "jsonwebtoken", + "_id": "jsonwebtoken@8.5.1", + "_inBundle": false, + "_integrity": "sha512-XjwVfRS6jTMsqYs0EsuJ4LGxXV14zQybNd4L2r0UvbVnSF9Af8x7p5MzbJ90Ioz/9TI41/hTCvznF/loiSzn8w==", + "_location": "/jsonwebtoken", + "_phantomChildren": {}, + "_requested": { + "type": "tag", + "registry": true, + "raw": "jsonwebtoken", + "name": "jsonwebtoken", + "escapedName": "jsonwebtoken", + "rawSpec": "", + "saveSpec": null, + "fetchSpec": "latest" + }, + "_requiredBy": [ + "#USER", + "/" + ], + "_resolved": "https://registry.npmjs.org/jsonwebtoken/-/jsonwebtoken-8.5.1.tgz", + "_shasum": "00e71e0b8df54c2121a1f26137df2280673bcc0d", + "_spec": "jsonwebtoken", + "_where": "/home/rock64/git/qseow-scripts/jwt-scratch/src/js", + "author": { + "name": "auth0" + }, + "bugs": { + "url": "https://github.com/auth0/node-jsonwebtoken/issues" + }, + "bundleDependencies": false, + "dependencies": { + "jws": "^3.2.2", + "lodash.includes": "^4.3.0", + "lodash.isboolean": "^3.0.3", + "lodash.isinteger": "^4.0.4", + "lodash.isnumber": "^3.0.3", + "lodash.isplainobject": "^4.0.6", + "lodash.isstring": "^4.0.1", + "lodash.once": "^4.0.0", + "ms": "^2.1.1", + "semver": "^5.6.0" + }, + "deprecated": false, + "description": "JSON Web Token implementation (symmetric and asymmetric)", + "devDependencies": { + "atob": "^2.1.2", + "chai": "^4.1.2", + "conventional-changelog": "~1.1.0", + "cost-of-modules": "^1.0.1", + "eslint": "^4.19.1", + "mocha": "^5.2.0", + "nsp": "^2.6.2", + "nyc": "^11.9.0", + "sinon": "^6.0.0" + }, + "engines": { + "node": ">=4", + "npm": ">=1.4.28" + }, + "files": [ + "lib", + "decode.js", + "sign.js", + "verify.js" + ], + "homepage": "https://github.com/auth0/node-jsonwebtoken#readme", + "keywords": [ + "jwt" + ], + "license": "MIT", + "main": "index.js", + "name": "jsonwebtoken", + "nyc": { + "check-coverage": true, + "lines": 95, + "statements": 95, + "functions": 100, + "branches": 95, + "exclude": [ + "./test/**" + ], + "reporter": [ + "json", + "lcov", + "text-summary" + ] + }, + "repository": { + "type": "git", + "url": "git+https://github.com/auth0/node-jsonwebtoken.git" + }, + "scripts": { + "coverage": "nyc mocha --use_strict", + "lint": "eslint .", + "test": "npm run lint && npm run coverage && cost-of-modules" + }, + "version": "8.5.1" +} diff --git a/jwt-scratch/src/js/node_modules/jsonwebtoken/sign.js b/jwt-scratch/src/js/node_modules/jsonwebtoken/sign.js new file mode 100644 index 0000000..f649ce4 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/jsonwebtoken/sign.js @@ -0,0 +1,206 @@ +var timespan = require('./lib/timespan'); +var PS_SUPPORTED = require('./lib/psSupported'); +var jws = require('jws'); +var includes = require('lodash.includes'); +var isBoolean = require('lodash.isboolean'); +var isInteger = require('lodash.isinteger'); +var isNumber = require('lodash.isnumber'); +var isPlainObject = require('lodash.isplainobject'); +var isString = require('lodash.isstring'); +var once = require('lodash.once'); + +var SUPPORTED_ALGS = ['RS256', 'RS384', 'RS512', 'ES256', 'ES384', 'ES512', 'HS256', 'HS384', 'HS512', 'none'] +if (PS_SUPPORTED) { + SUPPORTED_ALGS.splice(3, 0, 'PS256', 'PS384', 'PS512'); +} + +var sign_options_schema = { + expiresIn: { isValid: function(value) { return isInteger(value) || (isString(value) && value); }, message: '"expiresIn" should be a number of seconds or string representing a timespan' }, + notBefore: { isValid: function(value) { return isInteger(value) || (isString(value) && value); }, message: '"notBefore" should be a number of seconds or string representing a timespan' }, + audience: { isValid: function(value) { return isString(value) || Array.isArray(value); }, message: '"audience" must be a string or array' }, + algorithm: { isValid: includes.bind(null, SUPPORTED_ALGS), message: '"algorithm" must be a valid string enum value' }, + header: { isValid: isPlainObject, message: '"header" must be an object' }, + encoding: { isValid: isString, message: '"encoding" must be a string' }, + issuer: { isValid: isString, message: '"issuer" must be a string' }, + subject: { isValid: isString, message: '"subject" must be a string' }, + jwtid: { isValid: isString, message: '"jwtid" must be a string' }, + noTimestamp: { isValid: isBoolean, message: '"noTimestamp" must be a boolean' }, + keyid: { isValid: isString, message: '"keyid" must be a string' }, + mutatePayload: { isValid: isBoolean, message: '"mutatePayload" must be a boolean' } +}; + +var registered_claims_schema = { + iat: { isValid: isNumber, message: '"iat" should be a number of seconds' }, + exp: { isValid: isNumber, message: '"exp" should be a number of seconds' }, + nbf: { isValid: isNumber, message: '"nbf" should be a number of seconds' } +}; + +function validate(schema, allowUnknown, object, parameterName) { + if (!isPlainObject(object)) { + throw new Error('Expected "' + parameterName + '" to be a plain object.'); + } + Object.keys(object) + .forEach(function(key) { + var validator = schema[key]; + if (!validator) { + if (!allowUnknown) { + throw new Error('"' + key + '" is not allowed in "' + parameterName + '"'); + } + return; + } + if (!validator.isValid(object[key])) { + throw new Error(validator.message); + } + }); +} + +function validateOptions(options) { + return validate(sign_options_schema, false, options, 'options'); +} + +function validatePayload(payload) { + return validate(registered_claims_schema, true, payload, 'payload'); +} + +var options_to_payload = { + 'audience': 'aud', + 'issuer': 'iss', + 'subject': 'sub', + 'jwtid': 'jti' +}; + +var options_for_objects = [ + 'expiresIn', + 'notBefore', + 'noTimestamp', + 'audience', + 'issuer', + 'subject', + 'jwtid', +]; + +module.exports = function (payload, secretOrPrivateKey, options, callback) { + if (typeof options === 'function') { + callback = options; + options = {}; + } else { + options = options || {}; + } + + var isObjectPayload = typeof payload === 'object' && + !Buffer.isBuffer(payload); + + var header = Object.assign({ + alg: options.algorithm || 'HS256', + typ: isObjectPayload ? 'JWT' : undefined, + kid: options.keyid + }, options.header); + + function failure(err) { + if (callback) { + return callback(err); + } + throw err; + } + + if (!secretOrPrivateKey && options.algorithm !== 'none') { + return failure(new Error('secretOrPrivateKey must have a value')); + } + + if (typeof payload === 'undefined') { + return failure(new Error('payload is required')); + } else if (isObjectPayload) { + try { + validatePayload(payload); + } + catch (error) { + return failure(error); + } + if (!options.mutatePayload) { + payload = Object.assign({},payload); + } + } else { + var invalid_options = options_for_objects.filter(function (opt) { + return typeof options[opt] !== 'undefined'; + }); + + if (invalid_options.length > 0) { + return failure(new Error('invalid ' + invalid_options.join(',') + ' option for ' + (typeof payload ) + ' payload')); + } + } + + if (typeof payload.exp !== 'undefined' && typeof options.expiresIn !== 'undefined') { + return failure(new Error('Bad "options.expiresIn" option the payload already has an "exp" property.')); + } + + if (typeof payload.nbf !== 'undefined' && typeof options.notBefore !== 'undefined') { + return failure(new Error('Bad "options.notBefore" option the payload already has an "nbf" property.')); + } + + try { + validateOptions(options); + } + catch (error) { + return failure(error); + } + + var timestamp = payload.iat || Math.floor(Date.now() / 1000); + + if (options.noTimestamp) { + delete payload.iat; + } else if (isObjectPayload) { + payload.iat = timestamp; + } + + if (typeof options.notBefore !== 'undefined') { + try { + payload.nbf = timespan(options.notBefore, timestamp); + } + catch (err) { + return failure(err); + } + if (typeof payload.nbf === 'undefined') { + return failure(new Error('"notBefore" should be a number of seconds or string representing a timespan eg: "1d", "20h", 60')); + } + } + + if (typeof options.expiresIn !== 'undefined' && typeof payload === 'object') { + try { + payload.exp = timespan(options.expiresIn, timestamp); + } + catch (err) { + return failure(err); + } + if (typeof payload.exp === 'undefined') { + return failure(new Error('"expiresIn" should be a number of seconds or string representing a timespan eg: "1d", "20h", 60')); + } + } + + Object.keys(options_to_payload).forEach(function (key) { + var claim = options_to_payload[key]; + if (typeof options[key] !== 'undefined') { + if (typeof payload[claim] !== 'undefined') { + return failure(new Error('Bad "options.' + key + '" option. The payload already has an "' + claim + '" property.')); + } + payload[claim] = options[key]; + } + }); + + var encoding = options.encoding || 'utf8'; + + if (typeof callback === 'function') { + callback = callback && once(callback); + + jws.createSign({ + header: header, + privateKey: secretOrPrivateKey, + payload: payload, + encoding: encoding + }).once('error', callback) + .once('done', function (signature) { + callback(null, signature); + }); + } else { + return jws.sign({header: header, payload: payload, secret: secretOrPrivateKey, encoding: encoding}); + } +}; diff --git a/jwt-scratch/src/js/node_modules/jsonwebtoken/verify.js b/jwt-scratch/src/js/node_modules/jsonwebtoken/verify.js new file mode 100644 index 0000000..1df99f8 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/jsonwebtoken/verify.js @@ -0,0 +1,225 @@ +var JsonWebTokenError = require('./lib/JsonWebTokenError'); +var NotBeforeError = require('./lib/NotBeforeError'); +var TokenExpiredError = require('./lib/TokenExpiredError'); +var decode = require('./decode'); +var timespan = require('./lib/timespan'); +var PS_SUPPORTED = require('./lib/psSupported'); +var jws = require('jws'); + +var PUB_KEY_ALGS = ['RS256', 'RS384', 'RS512', 'ES256', 'ES384', 'ES512']; +var RSA_KEY_ALGS = ['RS256', 'RS384', 'RS512']; +var HS_ALGS = ['HS256', 'HS384', 'HS512']; + +if (PS_SUPPORTED) { + PUB_KEY_ALGS.splice(3, 0, 'PS256', 'PS384', 'PS512'); + RSA_KEY_ALGS.splice(3, 0, 'PS256', 'PS384', 'PS512'); +} + +module.exports = function (jwtString, secretOrPublicKey, options, callback) { + if ((typeof options === 'function') && !callback) { + callback = options; + options = {}; + } + + if (!options) { + options = {}; + } + + //clone this object since we are going to mutate it. + options = Object.assign({}, options); + + var done; + + if (callback) { + done = callback; + } else { + done = function(err, data) { + if (err) throw err; + return data; + }; + } + + if (options.clockTimestamp && typeof options.clockTimestamp !== 'number') { + return done(new JsonWebTokenError('clockTimestamp must be a number')); + } + + if (options.nonce !== undefined && (typeof options.nonce !== 'string' || options.nonce.trim() === '')) { + return done(new JsonWebTokenError('nonce must be a non-empty string')); + } + + var clockTimestamp = options.clockTimestamp || Math.floor(Date.now() / 1000); + + if (!jwtString){ + return done(new JsonWebTokenError('jwt must be provided')); + } + + if (typeof jwtString !== 'string') { + return done(new JsonWebTokenError('jwt must be a string')); + } + + var parts = jwtString.split('.'); + + if (parts.length !== 3){ + return done(new JsonWebTokenError('jwt malformed')); + } + + var decodedToken; + + try { + decodedToken = decode(jwtString, { complete: true }); + } catch(err) { + return done(err); + } + + if (!decodedToken) { + return done(new JsonWebTokenError('invalid token')); + } + + var header = decodedToken.header; + var getSecret; + + if(typeof secretOrPublicKey === 'function') { + if(!callback) { + return done(new JsonWebTokenError('verify must be called asynchronous if secret or public key is provided as a callback')); + } + + getSecret = secretOrPublicKey; + } + else { + getSecret = function(header, secretCallback) { + return secretCallback(null, secretOrPublicKey); + }; + } + + return getSecret(header, function(err, secretOrPublicKey) { + if(err) { + return done(new JsonWebTokenError('error in secret or public key callback: ' + err.message)); + } + + var hasSignature = parts[2].trim() !== ''; + + if (!hasSignature && secretOrPublicKey){ + return done(new JsonWebTokenError('jwt signature is required')); + } + + if (hasSignature && !secretOrPublicKey) { + return done(new JsonWebTokenError('secret or public key must be provided')); + } + + if (!hasSignature && !options.algorithms) { + options.algorithms = ['none']; + } + + if (!options.algorithms) { + options.algorithms = ~secretOrPublicKey.toString().indexOf('BEGIN CERTIFICATE') || + ~secretOrPublicKey.toString().indexOf('BEGIN PUBLIC KEY') ? PUB_KEY_ALGS : + ~secretOrPublicKey.toString().indexOf('BEGIN RSA PUBLIC KEY') ? RSA_KEY_ALGS : HS_ALGS; + + } + + if (!~options.algorithms.indexOf(decodedToken.header.alg)) { + return done(new JsonWebTokenError('invalid algorithm')); + } + + var valid; + + try { + valid = jws.verify(jwtString, decodedToken.header.alg, secretOrPublicKey); + } catch (e) { + return done(e); + } + + if (!valid) { + return done(new JsonWebTokenError('invalid signature')); + } + + var payload = decodedToken.payload; + + if (typeof payload.nbf !== 'undefined' && !options.ignoreNotBefore) { + if (typeof payload.nbf !== 'number') { + return done(new JsonWebTokenError('invalid nbf value')); + } + if (payload.nbf > clockTimestamp + (options.clockTolerance || 0)) { + return done(new NotBeforeError('jwt not active', new Date(payload.nbf * 1000))); + } + } + + if (typeof payload.exp !== 'undefined' && !options.ignoreExpiration) { + if (typeof payload.exp !== 'number') { + return done(new JsonWebTokenError('invalid exp value')); + } + if (clockTimestamp >= payload.exp + (options.clockTolerance || 0)) { + return done(new TokenExpiredError('jwt expired', new Date(payload.exp * 1000))); + } + } + + if (options.audience) { + var audiences = Array.isArray(options.audience) ? options.audience : [options.audience]; + var target = Array.isArray(payload.aud) ? payload.aud : [payload.aud]; + + var match = target.some(function (targetAudience) { + return audiences.some(function (audience) { + return audience instanceof RegExp ? audience.test(targetAudience) : audience === targetAudience; + }); + }); + + if (!match) { + return done(new JsonWebTokenError('jwt audience invalid. expected: ' + audiences.join(' or '))); + } + } + + if (options.issuer) { + var invalid_issuer = + (typeof options.issuer === 'string' && payload.iss !== options.issuer) || + (Array.isArray(options.issuer) && options.issuer.indexOf(payload.iss) === -1); + + if (invalid_issuer) { + return done(new JsonWebTokenError('jwt issuer invalid. expected: ' + options.issuer)); + } + } + + if (options.subject) { + if (payload.sub !== options.subject) { + return done(new JsonWebTokenError('jwt subject invalid. expected: ' + options.subject)); + } + } + + if (options.jwtid) { + if (payload.jti !== options.jwtid) { + return done(new JsonWebTokenError('jwt jwtid invalid. expected: ' + options.jwtid)); + } + } + + if (options.nonce) { + if (payload.nonce !== options.nonce) { + return done(new JsonWebTokenError('jwt nonce invalid. expected: ' + options.nonce)); + } + } + + if (options.maxAge) { + if (typeof payload.iat !== 'number') { + return done(new JsonWebTokenError('iat required when maxAge is specified')); + } + + var maxAgeTimestamp = timespan(options.maxAge, payload.iat); + if (typeof maxAgeTimestamp === 'undefined') { + return done(new JsonWebTokenError('"maxAge" should be a number of seconds or string representing a timespan eg: "1d", "20h", 60')); + } + if (clockTimestamp >= maxAgeTimestamp + (options.clockTolerance || 0)) { + return done(new TokenExpiredError('maxAge exceeded', new Date(maxAgeTimestamp * 1000))); + } + } + + if (options.complete === true) { + var signature = decodedToken.signature; + + return done(null, { + header: header, + payload: payload, + signature: signature + }); + } + + return done(null, payload); + }); +}; diff --git a/jwt-scratch/src/js/node_modules/jwa/LICENSE b/jwt-scratch/src/js/node_modules/jwa/LICENSE new file mode 100644 index 0000000..caeb849 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/jwa/LICENSE @@ -0,0 +1,17 @@ +Copyright (c) 2013 Brian J. Brennan + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to use, +copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the +Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, +INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR +PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE +FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, +ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/jwt-scratch/src/js/node_modules/jwa/README.md b/jwt-scratch/src/js/node_modules/jwa/README.md new file mode 100644 index 0000000..fb433e2 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/jwa/README.md @@ -0,0 +1,150 @@ +# node-jwa [![Build Status](https://travis-ci.org/brianloveswords/node-jwa.svg?branch=master)](https://travis-ci.org/brianloveswords/node-jwa) + +A +[JSON Web Algorithms](http://tools.ietf.org/id/draft-ietf-jose-json-web-algorithms-08.html) +implementation focusing (exclusively, at this point) on the algorithms necessary for +[JSON Web Signatures](http://self-issued.info/docs/draft-ietf-jose-json-web-signature.html). + +This library supports all of the required, recommended and optional cryptographic algorithms for JWS: + +alg Parameter Value | Digital Signature or MAC Algorithm +----------------|---------------------------- +HS256 | HMAC using SHA-256 hash algorithm +HS384 | HMAC using SHA-384 hash algorithm +HS512 | HMAC using SHA-512 hash algorithm +RS256 | RSASSA using SHA-256 hash algorithm +RS384 | RSASSA using SHA-384 hash algorithm +RS512 | RSASSA using SHA-512 hash algorithm +PS256 | RSASSA-PSS using SHA-256 hash algorithm +PS384 | RSASSA-PSS using SHA-384 hash algorithm +PS512 | RSASSA-PSS using SHA-512 hash algorithm +ES256 | ECDSA using P-256 curve and SHA-256 hash algorithm +ES384 | ECDSA using P-384 curve and SHA-384 hash algorithm +ES512 | ECDSA using P-521 curve and SHA-512 hash algorithm +none | No digital signature or MAC value included + +Please note that PS* only works on Node 6.12+ (excluding 7.x). + +# Requirements + +In order to run the tests, a recent version of OpenSSL is +required. **The version that comes with OS X (OpenSSL 0.9.8r 8 Feb +2011) is not recent enough**, as it does not fully support ECDSA +keys. You'll need to use a version > 1.0.0; I tested with OpenSSL 1.0.1c 10 May 2012. + +# Testing + +To run the tests, do + +```bash +$ npm test +``` + +This will generate a bunch of keypairs to use in testing. If you want to +generate new keypairs, do `make clean` before running `npm test` again. + +## Methodology + +I spawn `openssl dgst -sign` to test OpenSSL sign → JS verify and +`openssl dgst -verify` to test JS sign → OpenSSL verify for each of the +RSA and ECDSA algorithms. + +# Usage + +## jwa(algorithm) + +Creates a new `jwa` object with `sign` and `verify` methods for the +algorithm. Valid values for algorithm can be found in the table above +(`'HS256'`, `'HS384'`, etc) and are case-insensitive. Passing an invalid +algorithm value will throw a `TypeError`. + + +## jwa#sign(input, secretOrPrivateKey) + +Sign some input with either a secret for HMAC algorithms, or a private +key for RSA and ECDSA algorithms. + +If input is not already a string or buffer, `JSON.stringify` will be +called on it to attempt to coerce it. + +For the HMAC algorithm, `secretOrPrivateKey` should be a string or a +buffer. For ECDSA and RSA, the value should be a string representing a +PEM encoded **private** key. + +Output [base64url](http://en.wikipedia.org/wiki/Base64#URL_applications) +formatted. This is for convenience as JWS expects the signature in this +format. If your application needs the output in a different format, +[please open an issue](https://github.com/brianloveswords/node-jwa/issues). In +the meantime, you can use +[brianloveswords/base64url](https://github.com/brianloveswords/base64url) +to decode the signature. + +As of nodejs *v0.11.8*, SPKAC support was introduce. If your nodeJs +version satisfies, then you can pass an object `{ key: '..', passphrase: '...' }` + + +## jwa#verify(input, signature, secretOrPublicKey) + +Verify a signature. Returns `true` or `false`. + +`signature` should be a base64url encoded string. + +For the HMAC algorithm, `secretOrPublicKey` should be a string or a +buffer. For ECDSA and RSA, the value should be a string represented a +PEM encoded **public** key. + + +# Example + +HMAC +```js +const jwa = require('jwa'); + +const hmac = jwa('HS256'); +const input = 'super important stuff'; +const secret = 'shhhhhh'; + +const signature = hmac.sign(input, secret); +hmac.verify(input, signature, secret) // === true +hmac.verify(input, signature, 'trickery!') // === false +``` + +With keys +```js +const fs = require('fs'); +const jwa = require('jwa'); +const privateKey = fs.readFileSync(__dirname + '/ecdsa-p521-private.pem'); +const publicKey = fs.readFileSync(__dirname + '/ecdsa-p521-public.pem'); + +const ecdsa = jwa('ES512'); +const input = 'very important stuff'; + +const signature = ecdsa.sign(input, privateKey); +ecdsa.verify(input, signature, publicKey) // === true +``` +## License + +MIT + +``` +Copyright (c) 2013 Brian J. Brennan + +Permission is hereby granted, free of charge, to any person obtaining a +copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be included +in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +``` diff --git a/jwt-scratch/src/js/node_modules/jwa/index.js b/jwt-scratch/src/js/node_modules/jwa/index.js new file mode 100644 index 0000000..e71e6d1 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/jwa/index.js @@ -0,0 +1,252 @@ +var bufferEqual = require('buffer-equal-constant-time'); +var Buffer = require('safe-buffer').Buffer; +var crypto = require('crypto'); +var formatEcdsa = require('ecdsa-sig-formatter'); +var util = require('util'); + +var MSG_INVALID_ALGORITHM = '"%s" is not a valid algorithm.\n Supported algorithms are:\n "HS256", "HS384", "HS512", "RS256", "RS384", "RS512", "PS256", "PS384", "PS512", "ES256", "ES384", "ES512" and "none".' +var MSG_INVALID_SECRET = 'secret must be a string or buffer'; +var MSG_INVALID_VERIFIER_KEY = 'key must be a string or a buffer'; +var MSG_INVALID_SIGNER_KEY = 'key must be a string, a buffer or an object'; + +var supportsKeyObjects = typeof crypto.createPublicKey === 'function'; +if (supportsKeyObjects) { + MSG_INVALID_VERIFIER_KEY += ' or a KeyObject'; + MSG_INVALID_SECRET += 'or a KeyObject'; +} + +function checkIsPublicKey(key) { + if (Buffer.isBuffer(key)) { + return; + } + + if (typeof key === 'string') { + return; + } + + if (!supportsKeyObjects) { + throw typeError(MSG_INVALID_VERIFIER_KEY); + } + + if (typeof key !== 'object') { + throw typeError(MSG_INVALID_VERIFIER_KEY); + } + + if (typeof key.type !== 'string') { + throw typeError(MSG_INVALID_VERIFIER_KEY); + } + + if (typeof key.asymmetricKeyType !== 'string') { + throw typeError(MSG_INVALID_VERIFIER_KEY); + } + + if (typeof key.export !== 'function') { + throw typeError(MSG_INVALID_VERIFIER_KEY); + } +}; + +function checkIsPrivateKey(key) { + if (Buffer.isBuffer(key)) { + return; + } + + if (typeof key === 'string') { + return; + } + + if (typeof key === 'object') { + return; + } + + throw typeError(MSG_INVALID_SIGNER_KEY); +}; + +function checkIsSecretKey(key) { + if (Buffer.isBuffer(key)) { + return; + } + + if (typeof key === 'string') { + return key; + } + + if (!supportsKeyObjects) { + throw typeError(MSG_INVALID_SECRET); + } + + if (typeof key !== 'object') { + throw typeError(MSG_INVALID_SECRET); + } + + if (key.type !== 'secret') { + throw typeError(MSG_INVALID_SECRET); + } + + if (typeof key.export !== 'function') { + throw typeError(MSG_INVALID_SECRET); + } +} + +function fromBase64(base64) { + return base64 + .replace(/=/g, '') + .replace(/\+/g, '-') + .replace(/\//g, '_'); +} + +function toBase64(base64url) { + base64url = base64url.toString(); + + var padding = 4 - base64url.length % 4; + if (padding !== 4) { + for (var i = 0; i < padding; ++i) { + base64url += '='; + } + } + + return base64url + .replace(/\-/g, '+') + .replace(/_/g, '/'); +} + +function typeError(template) { + var args = [].slice.call(arguments, 1); + var errMsg = util.format.bind(util, template).apply(null, args); + return new TypeError(errMsg); +} + +function bufferOrString(obj) { + return Buffer.isBuffer(obj) || typeof obj === 'string'; +} + +function normalizeInput(thing) { + if (!bufferOrString(thing)) + thing = JSON.stringify(thing); + return thing; +} + +function createHmacSigner(bits) { + return function sign(thing, secret) { + checkIsSecretKey(secret); + thing = normalizeInput(thing); + var hmac = crypto.createHmac('sha' + bits, secret); + var sig = (hmac.update(thing), hmac.digest('base64')) + return fromBase64(sig); + } +} + +function createHmacVerifier(bits) { + return function verify(thing, signature, secret) { + var computedSig = createHmacSigner(bits)(thing, secret); + return bufferEqual(Buffer.from(signature), Buffer.from(computedSig)); + } +} + +function createKeySigner(bits) { + return function sign(thing, privateKey) { + checkIsPrivateKey(privateKey); + thing = normalizeInput(thing); + // Even though we are specifying "RSA" here, this works with ECDSA + // keys as well. + var signer = crypto.createSign('RSA-SHA' + bits); + var sig = (signer.update(thing), signer.sign(privateKey, 'base64')); + return fromBase64(sig); + } +} + +function createKeyVerifier(bits) { + return function verify(thing, signature, publicKey) { + checkIsPublicKey(publicKey); + thing = normalizeInput(thing); + signature = toBase64(signature); + var verifier = crypto.createVerify('RSA-SHA' + bits); + verifier.update(thing); + return verifier.verify(publicKey, signature, 'base64'); + } +} + +function createPSSKeySigner(bits) { + return function sign(thing, privateKey) { + checkIsPrivateKey(privateKey); + thing = normalizeInput(thing); + var signer = crypto.createSign('RSA-SHA' + bits); + var sig = (signer.update(thing), signer.sign({ + key: privateKey, + padding: crypto.constants.RSA_PKCS1_PSS_PADDING, + saltLength: crypto.constants.RSA_PSS_SALTLEN_DIGEST + }, 'base64')); + return fromBase64(sig); + } +} + +function createPSSKeyVerifier(bits) { + return function verify(thing, signature, publicKey) { + checkIsPublicKey(publicKey); + thing = normalizeInput(thing); + signature = toBase64(signature); + var verifier = crypto.createVerify('RSA-SHA' + bits); + verifier.update(thing); + return verifier.verify({ + key: publicKey, + padding: crypto.constants.RSA_PKCS1_PSS_PADDING, + saltLength: crypto.constants.RSA_PSS_SALTLEN_DIGEST + }, signature, 'base64'); + } +} + +function createECDSASigner(bits) { + var inner = createKeySigner(bits); + return function sign() { + var signature = inner.apply(null, arguments); + signature = formatEcdsa.derToJose(signature, 'ES' + bits); + return signature; + }; +} + +function createECDSAVerifer(bits) { + var inner = createKeyVerifier(bits); + return function verify(thing, signature, publicKey) { + signature = formatEcdsa.joseToDer(signature, 'ES' + bits).toString('base64'); + var result = inner(thing, signature, publicKey); + return result; + }; +} + +function createNoneSigner() { + return function sign() { + return ''; + } +} + +function createNoneVerifier() { + return function verify(thing, signature) { + return signature === ''; + } +} + +module.exports = function jwa(algorithm) { + var signerFactories = { + hs: createHmacSigner, + rs: createKeySigner, + ps: createPSSKeySigner, + es: createECDSASigner, + none: createNoneSigner, + } + var verifierFactories = { + hs: createHmacVerifier, + rs: createKeyVerifier, + ps: createPSSKeyVerifier, + es: createECDSAVerifer, + none: createNoneVerifier, + } + var match = algorithm.match(/^(RS|PS|ES|HS)(256|384|512)$|^(none)$/i); + if (!match) + throw typeError(MSG_INVALID_ALGORITHM, algorithm); + var algo = (match[1] || match[3]).toLowerCase(); + var bits = match[2]; + + return { + sign: signerFactories[algo](bits), + verify: verifierFactories[algo](bits), + } +}; diff --git a/jwt-scratch/src/js/node_modules/jwa/package.json b/jwt-scratch/src/js/node_modules/jwa/package.json new file mode 100644 index 0000000..3225dcd --- /dev/null +++ b/jwt-scratch/src/js/node_modules/jwa/package.json @@ -0,0 +1,69 @@ +{ + "_from": "jwa@^1.4.1", + "_id": "jwa@1.4.1", + "_inBundle": false, + "_integrity": "sha512-qiLX/xhEEFKUAJ6FiBMbes3w9ATzyk5W7Hvzpa/SLYdxNtng+gcurvrI7TbACjIXlsJyr05/S1oUhZrc63evQA==", + "_location": "/jwa", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "jwa@^1.4.1", + "name": "jwa", + "escapedName": "jwa", + "rawSpec": "^1.4.1", + "saveSpec": null, + "fetchSpec": "^1.4.1" + }, + "_requiredBy": [ + "/jws" + ], + "_resolved": "https://registry.npmjs.org/jwa/-/jwa-1.4.1.tgz", + "_shasum": "743c32985cb9e98655530d53641b66c8645b039a", + "_spec": "jwa@^1.4.1", + "_where": "/home/rock64/git/qseow-scripts/jwt-scratch/src/js/node_modules/jws", + "author": { + "name": "Brian J. Brennan", + "email": "brianloveswords@gmail.com" + }, + "bugs": { + "url": "https://github.com/brianloveswords/node-jwa/issues" + }, + "bundleDependencies": false, + "dependencies": { + "buffer-equal-constant-time": "1.0.1", + "ecdsa-sig-formatter": "1.0.11", + "safe-buffer": "^5.0.1" + }, + "deprecated": false, + "description": "JWA implementation (supports all JWS algorithms)", + "devDependencies": { + "base64url": "^2.0.0", + "jwk-to-pem": "^2.0.1", + "semver": "4.3.6", + "tap": "6.2.0" + }, + "directories": { + "test": "test" + }, + "homepage": "https://github.com/brianloveswords/node-jwa#readme", + "keywords": [ + "jwa", + "jws", + "jwt", + "rsa", + "ecdsa", + "hmac" + ], + "license": "MIT", + "main": "index.js", + "name": "jwa", + "repository": { + "type": "git", + "url": "git://github.com/brianloveswords/node-jwa.git" + }, + "scripts": { + "test": "make test" + }, + "version": "1.4.1" +} diff --git a/jwt-scratch/src/js/node_modules/jws/CHANGELOG.md b/jwt-scratch/src/js/node_modules/jws/CHANGELOG.md new file mode 100644 index 0000000..af8fc28 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/jws/CHANGELOG.md @@ -0,0 +1,34 @@ +# Change Log +All notable changes to this project will be documented in this file. + +## [3.0.0] +### Changed +- **BREAKING**: `jwt.verify` now requires an `algorithm` parameter, and + `jws.createVerify` requires an `algorithm` option. The `"alg"` field + signature headers is ignored. This mitigates a critical security flaw + in the library which would allow an attacker to generate signatures with + arbitrary contents that would be accepted by `jwt.verify`. See + https://auth0.com/blog/2015/03/31/critical-vulnerabilities-in-json-web-token-libraries/ + for details. + +## [2.0.0] - 2015-01-30 +### Changed +- **BREAKING**: Default payload encoding changed from `binary` to + `utf8`. `utf8` is a is a more sensible default than `binary` because + many payloads, as far as I can tell, will contain user-facing + strings that could be in any language. ([6b6de48]) + +- Code reorganization, thanks [@fearphage]! ([7880050]) + +### Added +- Option in all relevant methods for `encoding`. For those few users + that might be depending on a `binary` encoding of the messages, this + is for them. ([6b6de48]) + +[unreleased]: https://github.com/brianloveswords/node-jws/compare/v2.0.0...HEAD +[2.0.0]: https://github.com/brianloveswords/node-jws/compare/v1.0.1...v2.0.0 + +[7880050]: https://github.com/brianloveswords/node-jws/commit/7880050 +[6b6de48]: https://github.com/brianloveswords/node-jws/commit/6b6de48 + +[@fearphage]: https://github.com/fearphage diff --git a/jwt-scratch/src/js/node_modules/jws/LICENSE b/jwt-scratch/src/js/node_modules/jws/LICENSE new file mode 100644 index 0000000..caeb849 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/jws/LICENSE @@ -0,0 +1,17 @@ +Copyright (c) 2013 Brian J. Brennan + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal in +the Software without restriction, including without limitation the rights to use, +copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the +Software, and to permit persons to whom the Software is furnished to do so, +subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, +INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR +PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE +FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, +ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/jwt-scratch/src/js/node_modules/jws/index.js b/jwt-scratch/src/js/node_modules/jws/index.js new file mode 100644 index 0000000..8c8da93 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/jws/index.js @@ -0,0 +1,22 @@ +/*global exports*/ +var SignStream = require('./lib/sign-stream'); +var VerifyStream = require('./lib/verify-stream'); + +var ALGORITHMS = [ + 'HS256', 'HS384', 'HS512', + 'RS256', 'RS384', 'RS512', + 'PS256', 'PS384', 'PS512', + 'ES256', 'ES384', 'ES512' +]; + +exports.ALGORITHMS = ALGORITHMS; +exports.sign = SignStream.sign; +exports.verify = VerifyStream.verify; +exports.decode = VerifyStream.decode; +exports.isValid = VerifyStream.isValid; +exports.createSign = function createSign(opts) { + return new SignStream(opts); +}; +exports.createVerify = function createVerify(opts) { + return new VerifyStream(opts); +}; diff --git a/jwt-scratch/src/js/node_modules/jws/lib/data-stream.js b/jwt-scratch/src/js/node_modules/jws/lib/data-stream.js new file mode 100644 index 0000000..3535d31 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/jws/lib/data-stream.js @@ -0,0 +1,55 @@ +/*global module, process*/ +var Buffer = require('safe-buffer').Buffer; +var Stream = require('stream'); +var util = require('util'); + +function DataStream(data) { + this.buffer = null; + this.writable = true; + this.readable = true; + + // No input + if (!data) { + this.buffer = Buffer.alloc(0); + return this; + } + + // Stream + if (typeof data.pipe === 'function') { + this.buffer = Buffer.alloc(0); + data.pipe(this); + return this; + } + + // Buffer or String + // or Object (assumedly a passworded key) + if (data.length || typeof data === 'object') { + this.buffer = data; + this.writable = false; + process.nextTick(function () { + this.emit('end', data); + this.readable = false; + this.emit('close'); + }.bind(this)); + return this; + } + + throw new TypeError('Unexpected data type ('+ typeof data + ')'); +} +util.inherits(DataStream, Stream); + +DataStream.prototype.write = function write(data) { + this.buffer = Buffer.concat([this.buffer, Buffer.from(data)]); + this.emit('data', data); +}; + +DataStream.prototype.end = function end(data) { + if (data) + this.write(data); + this.emit('end', data); + this.emit('close'); + this.writable = false; + this.readable = false; +}; + +module.exports = DataStream; diff --git a/jwt-scratch/src/js/node_modules/jws/lib/sign-stream.js b/jwt-scratch/src/js/node_modules/jws/lib/sign-stream.js new file mode 100644 index 0000000..6a7ee42 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/jws/lib/sign-stream.js @@ -0,0 +1,78 @@ +/*global module*/ +var Buffer = require('safe-buffer').Buffer; +var DataStream = require('./data-stream'); +var jwa = require('jwa'); +var Stream = require('stream'); +var toString = require('./tostring'); +var util = require('util'); + +function base64url(string, encoding) { + return Buffer + .from(string, encoding) + .toString('base64') + .replace(/=/g, '') + .replace(/\+/g, '-') + .replace(/\//g, '_'); +} + +function jwsSecuredInput(header, payload, encoding) { + encoding = encoding || 'utf8'; + var encodedHeader = base64url(toString(header), 'binary'); + var encodedPayload = base64url(toString(payload), encoding); + return util.format('%s.%s', encodedHeader, encodedPayload); +} + +function jwsSign(opts) { + var header = opts.header; + var payload = opts.payload; + var secretOrKey = opts.secret || opts.privateKey; + var encoding = opts.encoding; + var algo = jwa(header.alg); + var securedInput = jwsSecuredInput(header, payload, encoding); + var signature = algo.sign(securedInput, secretOrKey); + return util.format('%s.%s', securedInput, signature); +} + +function SignStream(opts) { + var secret = opts.secret||opts.privateKey||opts.key; + var secretStream = new DataStream(secret); + this.readable = true; + this.header = opts.header; + this.encoding = opts.encoding; + this.secret = this.privateKey = this.key = secretStream; + this.payload = new DataStream(opts.payload); + this.secret.once('close', function () { + if (!this.payload.writable && this.readable) + this.sign(); + }.bind(this)); + + this.payload.once('close', function () { + if (!this.secret.writable && this.readable) + this.sign(); + }.bind(this)); +} +util.inherits(SignStream, Stream); + +SignStream.prototype.sign = function sign() { + try { + var signature = jwsSign({ + header: this.header, + payload: this.payload.buffer, + secret: this.secret.buffer, + encoding: this.encoding + }); + this.emit('done', signature); + this.emit('data', signature); + this.emit('end'); + this.readable = false; + return signature; + } catch (e) { + this.readable = false; + this.emit('error', e); + this.emit('close'); + } +}; + +SignStream.sign = jwsSign; + +module.exports = SignStream; diff --git a/jwt-scratch/src/js/node_modules/jws/lib/tostring.js b/jwt-scratch/src/js/node_modules/jws/lib/tostring.js new file mode 100644 index 0000000..f5a49a3 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/jws/lib/tostring.js @@ -0,0 +1,10 @@ +/*global module*/ +var Buffer = require('buffer').Buffer; + +module.exports = function toString(obj) { + if (typeof obj === 'string') + return obj; + if (typeof obj === 'number' || Buffer.isBuffer(obj)) + return obj.toString(); + return JSON.stringify(obj); +}; diff --git a/jwt-scratch/src/js/node_modules/jws/lib/verify-stream.js b/jwt-scratch/src/js/node_modules/jws/lib/verify-stream.js new file mode 100644 index 0000000..39f7c73 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/jws/lib/verify-stream.js @@ -0,0 +1,120 @@ +/*global module*/ +var Buffer = require('safe-buffer').Buffer; +var DataStream = require('./data-stream'); +var jwa = require('jwa'); +var Stream = require('stream'); +var toString = require('./tostring'); +var util = require('util'); +var JWS_REGEX = /^[a-zA-Z0-9\-_]+?\.[a-zA-Z0-9\-_]+?\.([a-zA-Z0-9\-_]+)?$/; + +function isObject(thing) { + return Object.prototype.toString.call(thing) === '[object Object]'; +} + +function safeJsonParse(thing) { + if (isObject(thing)) + return thing; + try { return JSON.parse(thing); } + catch (e) { return undefined; } +} + +function headerFromJWS(jwsSig) { + var encodedHeader = jwsSig.split('.', 1)[0]; + return safeJsonParse(Buffer.from(encodedHeader, 'base64').toString('binary')); +} + +function securedInputFromJWS(jwsSig) { + return jwsSig.split('.', 2).join('.'); +} + +function signatureFromJWS(jwsSig) { + return jwsSig.split('.')[2]; +} + +function payloadFromJWS(jwsSig, encoding) { + encoding = encoding || 'utf8'; + var payload = jwsSig.split('.')[1]; + return Buffer.from(payload, 'base64').toString(encoding); +} + +function isValidJws(string) { + return JWS_REGEX.test(string) && !!headerFromJWS(string); +} + +function jwsVerify(jwsSig, algorithm, secretOrKey) { + if (!algorithm) { + var err = new Error("Missing algorithm parameter for jws.verify"); + err.code = "MISSING_ALGORITHM"; + throw err; + } + jwsSig = toString(jwsSig); + var signature = signatureFromJWS(jwsSig); + var securedInput = securedInputFromJWS(jwsSig); + var algo = jwa(algorithm); + return algo.verify(securedInput, signature, secretOrKey); +} + +function jwsDecode(jwsSig, opts) { + opts = opts || {}; + jwsSig = toString(jwsSig); + + if (!isValidJws(jwsSig)) + return null; + + var header = headerFromJWS(jwsSig); + + if (!header) + return null; + + var payload = payloadFromJWS(jwsSig); + if (header.typ === 'JWT' || opts.json) + payload = JSON.parse(payload, opts.encoding); + + return { + header: header, + payload: payload, + signature: signatureFromJWS(jwsSig) + }; +} + +function VerifyStream(opts) { + opts = opts || {}; + var secretOrKey = opts.secret||opts.publicKey||opts.key; + var secretStream = new DataStream(secretOrKey); + this.readable = true; + this.algorithm = opts.algorithm; + this.encoding = opts.encoding; + this.secret = this.publicKey = this.key = secretStream; + this.signature = new DataStream(opts.signature); + this.secret.once('close', function () { + if (!this.signature.writable && this.readable) + this.verify(); + }.bind(this)); + + this.signature.once('close', function () { + if (!this.secret.writable && this.readable) + this.verify(); + }.bind(this)); +} +util.inherits(VerifyStream, Stream); +VerifyStream.prototype.verify = function verify() { + try { + var valid = jwsVerify(this.signature.buffer, this.algorithm, this.key.buffer); + var obj = jwsDecode(this.signature.buffer, this.encoding); + this.emit('done', valid, obj); + this.emit('data', valid); + this.emit('end'); + this.readable = false; + return valid; + } catch (e) { + this.readable = false; + this.emit('error', e); + this.emit('close'); + } +}; + +VerifyStream.decode = jwsDecode; +VerifyStream.isValid = isValidJws; +VerifyStream.verify = jwsVerify; + +module.exports = VerifyStream; diff --git a/jwt-scratch/src/js/node_modules/jws/package.json b/jwt-scratch/src/js/node_modules/jws/package.json new file mode 100644 index 0000000..1a07409 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/jws/package.json @@ -0,0 +1,64 @@ +{ + "_from": "jws@^3.2.2", + "_id": "jws@3.2.2", + "_inBundle": false, + "_integrity": "sha512-YHlZCB6lMTllWDtSPHz/ZXTsi8S00usEV6v1tjq8tOUZzw7DpSDWVXjXDre6ed1w/pd495ODpHZYSdkRTsa0HA==", + "_location": "/jws", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "jws@^3.2.2", + "name": "jws", + "escapedName": "jws", + "rawSpec": "^3.2.2", + "saveSpec": null, + "fetchSpec": "^3.2.2" + }, + "_requiredBy": [ + "/jsonwebtoken" + ], + "_resolved": "https://registry.npmjs.org/jws/-/jws-3.2.2.tgz", + "_shasum": "001099f3639468c9414000e99995fa52fb478304", + "_spec": "jws@^3.2.2", + "_where": "/home/rock64/git/qseow-scripts/jwt-scratch/src/js/node_modules/jsonwebtoken", + "author": { + "name": "Brian J Brennan" + }, + "bugs": { + "url": "https://github.com/brianloveswords/node-jws/issues" + }, + "bundleDependencies": false, + "dependencies": { + "jwa": "^1.4.1", + "safe-buffer": "^5.0.1" + }, + "deprecated": false, + "description": "Implementation of JSON Web Signatures", + "devDependencies": { + "semver": "^5.1.0", + "tape": "~2.14.0" + }, + "directories": { + "test": "test" + }, + "gitHead": "c0f6b27bcea5a2ad2e304d91c2e842e4076a6b03", + "homepage": "https://github.com/brianloveswords/node-jws#readme", + "keywords": [ + "jws", + "json", + "web", + "signatures" + ], + "license": "MIT", + "main": "index.js", + "name": "jws", + "repository": { + "type": "git", + "url": "git://github.com/brianloveswords/node-jws.git" + }, + "scripts": { + "test": "make test" + }, + "version": "3.2.2" +} diff --git a/jwt-scratch/src/js/node_modules/jws/readme.md b/jwt-scratch/src/js/node_modules/jws/readme.md new file mode 100644 index 0000000..1910c9a --- /dev/null +++ b/jwt-scratch/src/js/node_modules/jws/readme.md @@ -0,0 +1,255 @@ +# node-jws [![Build Status](https://secure.travis-ci.org/brianloveswords/node-jws.png)](http://travis-ci.org/brianloveswords/node-jws) + +An implementation of [JSON Web Signatures](http://self-issued.info/docs/draft-ietf-jose-json-web-signature.html). + +This was developed against `draft-ietf-jose-json-web-signature-08` and +implements the entire spec **except** X.509 Certificate Chain +signing/verifying (patches welcome). + +There are both synchronous (`jws.sign`, `jws.verify`) and streaming +(`jws.createSign`, `jws.createVerify`) APIs. + +# Install + +```bash +$ npm install jws +``` + +# Usage + +## jws.ALGORITHMS + +Array of supported algorithms. The following algorithms are currently supported. + +alg Parameter Value | Digital Signature or MAC Algorithm +----------------|---------------------------- +HS256 | HMAC using SHA-256 hash algorithm +HS384 | HMAC using SHA-384 hash algorithm +HS512 | HMAC using SHA-512 hash algorithm +RS256 | RSASSA using SHA-256 hash algorithm +RS384 | RSASSA using SHA-384 hash algorithm +RS512 | RSASSA using SHA-512 hash algorithm +PS256 | RSASSA-PSS using SHA-256 hash algorithm +PS384 | RSASSA-PSS using SHA-384 hash algorithm +PS512 | RSASSA-PSS using SHA-512 hash algorithm +ES256 | ECDSA using P-256 curve and SHA-256 hash algorithm +ES384 | ECDSA using P-384 curve and SHA-384 hash algorithm +ES512 | ECDSA using P-521 curve and SHA-512 hash algorithm +none | No digital signature or MAC value included + +## jws.sign(options) + +(Synchronous) Return a JSON Web Signature for a header and a payload. + +Options: + +* `header` +* `payload` +* `secret` or `privateKey` +* `encoding` (Optional, defaults to 'utf8') + +`header` must be an object with an `alg` property. `header.alg` must be +one a value found in `jws.ALGORITHMS`. See above for a table of +supported algorithms. + +If `payload` is not a buffer or a string, it will be coerced into a string +using `JSON.stringify`. + +Example + +```js +const signature = jws.sign({ + header: { alg: 'HS256' }, + payload: 'h. jon benjamin', + secret: 'has a van', +}); +``` + +## jws.verify(signature, algorithm, secretOrKey) + +(Synchronous) Returns `true` or `false` for whether a signature matches a +secret or key. + +`signature` is a JWS Signature. `header.alg` must be a value found in `jws.ALGORITHMS`. +See above for a table of supported algorithms. `secretOrKey` is a string or +buffer containing either the secret for HMAC algorithms, or the PEM +encoded public key for RSA and ECDSA. + +Note that the `"alg"` value from the signature header is ignored. + + +## jws.decode(signature) + +(Synchronous) Returns the decoded header, decoded payload, and signature +parts of the JWS Signature. + +Returns an object with three properties, e.g. +```js +{ header: { alg: 'HS256' }, + payload: 'h. jon benjamin', + signature: 'YOWPewyGHKu4Y_0M_vtlEnNlqmFOclqp4Hy6hVHfFT4' +} +``` + +## jws.createSign(options) + +Returns a new SignStream object. + +Options: + +* `header` (required) +* `payload` +* `key` || `privateKey` || `secret` +* `encoding` (Optional, defaults to 'utf8') + +Other than `header`, all options expect a string or a buffer when the +value is known ahead of time, or a stream for convenience. +`key`/`privateKey`/`secret` may also be an object when using an encrypted +private key, see the [crypto documentation][encrypted-key-docs]. + +Example: + +```js + +// This... +jws.createSign({ + header: { alg: 'RS256' }, + privateKey: privateKeyStream, + payload: payloadStream, +}).on('done', function(signature) { + // ... +}); + +// is equivalent to this: +const signer = jws.createSign({ + header: { alg: 'RS256' }, +}); +privateKeyStream.pipe(signer.privateKey); +payloadStream.pipe(signer.payload); +signer.on('done', function(signature) { + // ... +}); +``` + +## jws.createVerify(options) + +Returns a new VerifyStream object. + +Options: + +* `signature` +* `algorithm` +* `key` || `publicKey` || `secret` +* `encoding` (Optional, defaults to 'utf8') + +All options expect a string or a buffer when the value is known ahead of +time, or a stream for convenience. + +Example: + +```js + +// This... +jws.createVerify({ + publicKey: pubKeyStream, + signature: sigStream, +}).on('done', function(verified, obj) { + // ... +}); + +// is equivilant to this: +const verifier = jws.createVerify(); +pubKeyStream.pipe(verifier.publicKey); +sigStream.pipe(verifier.signature); +verifier.on('done', function(verified, obj) { + // ... +}); +``` + +## Class: SignStream + +A `Readable Stream` that emits a single data event (the calculated +signature) when done. + +### Event: 'done' +`function (signature) { }` + +### signer.payload + +A `Writable Stream` that expects the JWS payload. Do *not* use if you +passed a `payload` option to the constructor. + +Example: + +```js +payloadStream.pipe(signer.payload); +``` + +### signer.secret
signer.key
signer.privateKey + +A `Writable Stream`. Expects the JWS secret for HMAC, or the privateKey +for ECDSA and RSA. Do *not* use if you passed a `secret` or `key` option +to the constructor. + +Example: + +```js +privateKeyStream.pipe(signer.privateKey); +``` + +## Class: VerifyStream + +This is a `Readable Stream` that emits a single data event, the result +of whether or not that signature was valid. + +### Event: 'done' +`function (valid, obj) { }` + +`valid` is a boolean for whether or not the signature is valid. + +### verifier.signature + +A `Writable Stream` that expects a JWS Signature. Do *not* use if you +passed a `signature` option to the constructor. + +### verifier.secret
verifier.key
verifier.publicKey + +A `Writable Stream` that expects a public key or secret. Do *not* use if you +passed a `key` or `secret` option to the constructor. + +# TODO + +* It feels like there should be some convenience options/APIs for + defining the algorithm rather than having to define a header object + with `{ alg: 'ES512' }` or whatever every time. + +* X.509 support, ugh + +# License + +MIT + +``` +Copyright (c) 2013-2015 Brian J. Brennan + +Permission is hereby granted, free of charge, to any person obtaining a +copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be included +in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS +OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +``` + +[encrypted-key-docs]: https://nodejs.org/api/crypto.html#crypto_sign_sign_private_key_output_format diff --git a/jwt-scratch/src/js/node_modules/lodash.includes/LICENSE b/jwt-scratch/src/js/node_modules/lodash.includes/LICENSE new file mode 100644 index 0000000..e0c69d5 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/lodash.includes/LICENSE @@ -0,0 +1,47 @@ +Copyright jQuery Foundation and other contributors + +Based on Underscore.js, copyright Jeremy Ashkenas, +DocumentCloud and Investigative Reporters & Editors + +This software consists of voluntary contributions made by many +individuals. For exact contribution history, see the revision history +available at https://github.com/lodash/lodash + +The following license applies to all parts of this software except as +documented below: + +==== + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +==== + +Copyright and related rights for sample code are waived via CC0. Sample +code is defined as all source code displayed within the prose of the +documentation. + +CC0: http://creativecommons.org/publicdomain/zero/1.0/ + +==== + +Files located in the node_modules and vendor directories are externally +maintained libraries used by this software which have their own +licenses; we recommend you read them, as their terms may differ from the +terms above. diff --git a/jwt-scratch/src/js/node_modules/lodash.includes/README.md b/jwt-scratch/src/js/node_modules/lodash.includes/README.md new file mode 100644 index 0000000..26e9377 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/lodash.includes/README.md @@ -0,0 +1,18 @@ +# lodash.includes v4.3.0 + +The [lodash](https://lodash.com/) method `_.includes` exported as a [Node.js](https://nodejs.org/) module. + +## Installation + +Using npm: +```bash +$ {sudo -H} npm i -g npm +$ npm i --save lodash.includes +``` + +In Node.js: +```js +var includes = require('lodash.includes'); +``` + +See the [documentation](https://lodash.com/docs#includes) or [package source](https://github.com/lodash/lodash/blob/4.3.0-npm-packages/lodash.includes) for more details. diff --git a/jwt-scratch/src/js/node_modules/lodash.includes/index.js b/jwt-scratch/src/js/node_modules/lodash.includes/index.js new file mode 100644 index 0000000..e88d533 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/lodash.includes/index.js @@ -0,0 +1,745 @@ +/** + * lodash (Custom Build) + * Build: `lodash modularize exports="npm" -o ./` + * Copyright jQuery Foundation and other contributors + * Released under MIT license + * Based on Underscore.js 1.8.3 + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + */ + +/** Used as references for various `Number` constants. */ +var INFINITY = 1 / 0, + MAX_SAFE_INTEGER = 9007199254740991, + MAX_INTEGER = 1.7976931348623157e+308, + NAN = 0 / 0; + +/** `Object#toString` result references. */ +var argsTag = '[object Arguments]', + funcTag = '[object Function]', + genTag = '[object GeneratorFunction]', + stringTag = '[object String]', + symbolTag = '[object Symbol]'; + +/** Used to match leading and trailing whitespace. */ +var reTrim = /^\s+|\s+$/g; + +/** Used to detect bad signed hexadecimal string values. */ +var reIsBadHex = /^[-+]0x[0-9a-f]+$/i; + +/** Used to detect binary string values. */ +var reIsBinary = /^0b[01]+$/i; + +/** Used to detect octal string values. */ +var reIsOctal = /^0o[0-7]+$/i; + +/** Used to detect unsigned integer values. */ +var reIsUint = /^(?:0|[1-9]\d*)$/; + +/** Built-in method references without a dependency on `root`. */ +var freeParseInt = parseInt; + +/** + * A specialized version of `_.map` for arrays without support for iteratee + * shorthands. + * + * @private + * @param {Array} [array] The array to iterate over. + * @param {Function} iteratee The function invoked per iteration. + * @returns {Array} Returns the new mapped array. + */ +function arrayMap(array, iteratee) { + var index = -1, + length = array ? array.length : 0, + result = Array(length); + + while (++index < length) { + result[index] = iteratee(array[index], index, array); + } + return result; +} + +/** + * The base implementation of `_.findIndex` and `_.findLastIndex` without + * support for iteratee shorthands. + * + * @private + * @param {Array} array The array to inspect. + * @param {Function} predicate The function invoked per iteration. + * @param {number} fromIndex The index to search from. + * @param {boolean} [fromRight] Specify iterating from right to left. + * @returns {number} Returns the index of the matched value, else `-1`. + */ +function baseFindIndex(array, predicate, fromIndex, fromRight) { + var length = array.length, + index = fromIndex + (fromRight ? 1 : -1); + + while ((fromRight ? index-- : ++index < length)) { + if (predicate(array[index], index, array)) { + return index; + } + } + return -1; +} + +/** + * The base implementation of `_.indexOf` without `fromIndex` bounds checks. + * + * @private + * @param {Array} array The array to inspect. + * @param {*} value The value to search for. + * @param {number} fromIndex The index to search from. + * @returns {number} Returns the index of the matched value, else `-1`. + */ +function baseIndexOf(array, value, fromIndex) { + if (value !== value) { + return baseFindIndex(array, baseIsNaN, fromIndex); + } + var index = fromIndex - 1, + length = array.length; + + while (++index < length) { + if (array[index] === value) { + return index; + } + } + return -1; +} + +/** + * The base implementation of `_.isNaN` without support for number objects. + * + * @private + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is `NaN`, else `false`. + */ +function baseIsNaN(value) { + return value !== value; +} + +/** + * The base implementation of `_.times` without support for iteratee shorthands + * or max array length checks. + * + * @private + * @param {number} n The number of times to invoke `iteratee`. + * @param {Function} iteratee The function invoked per iteration. + * @returns {Array} Returns the array of results. + */ +function baseTimes(n, iteratee) { + var index = -1, + result = Array(n); + + while (++index < n) { + result[index] = iteratee(index); + } + return result; +} + +/** + * The base implementation of `_.values` and `_.valuesIn` which creates an + * array of `object` property values corresponding to the property names + * of `props`. + * + * @private + * @param {Object} object The object to query. + * @param {Array} props The property names to get values for. + * @returns {Object} Returns the array of property values. + */ +function baseValues(object, props) { + return arrayMap(props, function(key) { + return object[key]; + }); +} + +/** + * Creates a unary function that invokes `func` with its argument transformed. + * + * @private + * @param {Function} func The function to wrap. + * @param {Function} transform The argument transform. + * @returns {Function} Returns the new function. + */ +function overArg(func, transform) { + return function(arg) { + return func(transform(arg)); + }; +} + +/** Used for built-in method references. */ +var objectProto = Object.prototype; + +/** Used to check objects for own properties. */ +var hasOwnProperty = objectProto.hasOwnProperty; + +/** + * Used to resolve the + * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) + * of values. + */ +var objectToString = objectProto.toString; + +/** Built-in value references. */ +var propertyIsEnumerable = objectProto.propertyIsEnumerable; + +/* Built-in method references for those with the same name as other `lodash` methods. */ +var nativeKeys = overArg(Object.keys, Object), + nativeMax = Math.max; + +/** + * Creates an array of the enumerable property names of the array-like `value`. + * + * @private + * @param {*} value The value to query. + * @param {boolean} inherited Specify returning inherited property names. + * @returns {Array} Returns the array of property names. + */ +function arrayLikeKeys(value, inherited) { + // Safari 8.1 makes `arguments.callee` enumerable in strict mode. + // Safari 9 makes `arguments.length` enumerable in strict mode. + var result = (isArray(value) || isArguments(value)) + ? baseTimes(value.length, String) + : []; + + var length = result.length, + skipIndexes = !!length; + + for (var key in value) { + if ((inherited || hasOwnProperty.call(value, key)) && + !(skipIndexes && (key == 'length' || isIndex(key, length)))) { + result.push(key); + } + } + return result; +} + +/** + * The base implementation of `_.keys` which doesn't treat sparse arrays as dense. + * + * @private + * @param {Object} object The object to query. + * @returns {Array} Returns the array of property names. + */ +function baseKeys(object) { + if (!isPrototype(object)) { + return nativeKeys(object); + } + var result = []; + for (var key in Object(object)) { + if (hasOwnProperty.call(object, key) && key != 'constructor') { + result.push(key); + } + } + return result; +} + +/** + * Checks if `value` is a valid array-like index. + * + * @private + * @param {*} value The value to check. + * @param {number} [length=MAX_SAFE_INTEGER] The upper bounds of a valid index. + * @returns {boolean} Returns `true` if `value` is a valid index, else `false`. + */ +function isIndex(value, length) { + length = length == null ? MAX_SAFE_INTEGER : length; + return !!length && + (typeof value == 'number' || reIsUint.test(value)) && + (value > -1 && value % 1 == 0 && value < length); +} + +/** + * Checks if `value` is likely a prototype object. + * + * @private + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a prototype, else `false`. + */ +function isPrototype(value) { + var Ctor = value && value.constructor, + proto = (typeof Ctor == 'function' && Ctor.prototype) || objectProto; + + return value === proto; +} + +/** + * Checks if `value` is in `collection`. If `collection` is a string, it's + * checked for a substring of `value`, otherwise + * [`SameValueZero`](http://ecma-international.org/ecma-262/7.0/#sec-samevaluezero) + * is used for equality comparisons. If `fromIndex` is negative, it's used as + * the offset from the end of `collection`. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Collection + * @param {Array|Object|string} collection The collection to inspect. + * @param {*} value The value to search for. + * @param {number} [fromIndex=0] The index to search from. + * @param- {Object} [guard] Enables use as an iteratee for methods like `_.reduce`. + * @returns {boolean} Returns `true` if `value` is found, else `false`. + * @example + * + * _.includes([1, 2, 3], 1); + * // => true + * + * _.includes([1, 2, 3], 1, 2); + * // => false + * + * _.includes({ 'a': 1, 'b': 2 }, 1); + * // => true + * + * _.includes('abcd', 'bc'); + * // => true + */ +function includes(collection, value, fromIndex, guard) { + collection = isArrayLike(collection) ? collection : values(collection); + fromIndex = (fromIndex && !guard) ? toInteger(fromIndex) : 0; + + var length = collection.length; + if (fromIndex < 0) { + fromIndex = nativeMax(length + fromIndex, 0); + } + return isString(collection) + ? (fromIndex <= length && collection.indexOf(value, fromIndex) > -1) + : (!!length && baseIndexOf(collection, value, fromIndex) > -1); +} + +/** + * Checks if `value` is likely an `arguments` object. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an `arguments` object, + * else `false`. + * @example + * + * _.isArguments(function() { return arguments; }()); + * // => true + * + * _.isArguments([1, 2, 3]); + * // => false + */ +function isArguments(value) { + // Safari 8.1 makes `arguments.callee` enumerable in strict mode. + return isArrayLikeObject(value) && hasOwnProperty.call(value, 'callee') && + (!propertyIsEnumerable.call(value, 'callee') || objectToString.call(value) == argsTag); +} + +/** + * Checks if `value` is classified as an `Array` object. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an array, else `false`. + * @example + * + * _.isArray([1, 2, 3]); + * // => true + * + * _.isArray(document.body.children); + * // => false + * + * _.isArray('abc'); + * // => false + * + * _.isArray(_.noop); + * // => false + */ +var isArray = Array.isArray; + +/** + * Checks if `value` is array-like. A value is considered array-like if it's + * not a function and has a `value.length` that's an integer greater than or + * equal to `0` and less than or equal to `Number.MAX_SAFE_INTEGER`. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is array-like, else `false`. + * @example + * + * _.isArrayLike([1, 2, 3]); + * // => true + * + * _.isArrayLike(document.body.children); + * // => true + * + * _.isArrayLike('abc'); + * // => true + * + * _.isArrayLike(_.noop); + * // => false + */ +function isArrayLike(value) { + return value != null && isLength(value.length) && !isFunction(value); +} + +/** + * This method is like `_.isArrayLike` except that it also checks if `value` + * is an object. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an array-like object, + * else `false`. + * @example + * + * _.isArrayLikeObject([1, 2, 3]); + * // => true + * + * _.isArrayLikeObject(document.body.children); + * // => true + * + * _.isArrayLikeObject('abc'); + * // => false + * + * _.isArrayLikeObject(_.noop); + * // => false + */ +function isArrayLikeObject(value) { + return isObjectLike(value) && isArrayLike(value); +} + +/** + * Checks if `value` is classified as a `Function` object. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a function, else `false`. + * @example + * + * _.isFunction(_); + * // => true + * + * _.isFunction(/abc/); + * // => false + */ +function isFunction(value) { + // The use of `Object#toString` avoids issues with the `typeof` operator + // in Safari 8-9 which returns 'object' for typed array and other constructors. + var tag = isObject(value) ? objectToString.call(value) : ''; + return tag == funcTag || tag == genTag; +} + +/** + * Checks if `value` is a valid array-like length. + * + * **Note:** This method is loosely based on + * [`ToLength`](http://ecma-international.org/ecma-262/7.0/#sec-tolength). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a valid length, else `false`. + * @example + * + * _.isLength(3); + * // => true + * + * _.isLength(Number.MIN_VALUE); + * // => false + * + * _.isLength(Infinity); + * // => false + * + * _.isLength('3'); + * // => false + */ +function isLength(value) { + return typeof value == 'number' && + value > -1 && value % 1 == 0 && value <= MAX_SAFE_INTEGER; +} + +/** + * Checks if `value` is the + * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types) + * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an object, else `false`. + * @example + * + * _.isObject({}); + * // => true + * + * _.isObject([1, 2, 3]); + * // => true + * + * _.isObject(_.noop); + * // => true + * + * _.isObject(null); + * // => false + */ +function isObject(value) { + var type = typeof value; + return !!value && (type == 'object' || type == 'function'); +} + +/** + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} + +/** + * Checks if `value` is classified as a `String` primitive or object. + * + * @static + * @since 0.1.0 + * @memberOf _ + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a string, else `false`. + * @example + * + * _.isString('abc'); + * // => true + * + * _.isString(1); + * // => false + */ +function isString(value) { + return typeof value == 'string' || + (!isArray(value) && isObjectLike(value) && objectToString.call(value) == stringTag); +} + +/** + * Checks if `value` is classified as a `Symbol` primitive or object. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a symbol, else `false`. + * @example + * + * _.isSymbol(Symbol.iterator); + * // => true + * + * _.isSymbol('abc'); + * // => false + */ +function isSymbol(value) { + return typeof value == 'symbol' || + (isObjectLike(value) && objectToString.call(value) == symbolTag); +} + +/** + * Converts `value` to a finite number. + * + * @static + * @memberOf _ + * @since 4.12.0 + * @category Lang + * @param {*} value The value to convert. + * @returns {number} Returns the converted number. + * @example + * + * _.toFinite(3.2); + * // => 3.2 + * + * _.toFinite(Number.MIN_VALUE); + * // => 5e-324 + * + * _.toFinite(Infinity); + * // => 1.7976931348623157e+308 + * + * _.toFinite('3.2'); + * // => 3.2 + */ +function toFinite(value) { + if (!value) { + return value === 0 ? value : 0; + } + value = toNumber(value); + if (value === INFINITY || value === -INFINITY) { + var sign = (value < 0 ? -1 : 1); + return sign * MAX_INTEGER; + } + return value === value ? value : 0; +} + +/** + * Converts `value` to an integer. + * + * **Note:** This method is loosely based on + * [`ToInteger`](http://www.ecma-international.org/ecma-262/7.0/#sec-tointeger). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to convert. + * @returns {number} Returns the converted integer. + * @example + * + * _.toInteger(3.2); + * // => 3 + * + * _.toInteger(Number.MIN_VALUE); + * // => 0 + * + * _.toInteger(Infinity); + * // => 1.7976931348623157e+308 + * + * _.toInteger('3.2'); + * // => 3 + */ +function toInteger(value) { + var result = toFinite(value), + remainder = result % 1; + + return result === result ? (remainder ? result - remainder : result) : 0; +} + +/** + * Converts `value` to a number. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to process. + * @returns {number} Returns the number. + * @example + * + * _.toNumber(3.2); + * // => 3.2 + * + * _.toNumber(Number.MIN_VALUE); + * // => 5e-324 + * + * _.toNumber(Infinity); + * // => Infinity + * + * _.toNumber('3.2'); + * // => 3.2 + */ +function toNumber(value) { + if (typeof value == 'number') { + return value; + } + if (isSymbol(value)) { + return NAN; + } + if (isObject(value)) { + var other = typeof value.valueOf == 'function' ? value.valueOf() : value; + value = isObject(other) ? (other + '') : other; + } + if (typeof value != 'string') { + return value === 0 ? value : +value; + } + value = value.replace(reTrim, ''); + var isBinary = reIsBinary.test(value); + return (isBinary || reIsOctal.test(value)) + ? freeParseInt(value.slice(2), isBinary ? 2 : 8) + : (reIsBadHex.test(value) ? NAN : +value); +} + +/** + * Creates an array of the own enumerable property names of `object`. + * + * **Note:** Non-object values are coerced to objects. See the + * [ES spec](http://ecma-international.org/ecma-262/7.0/#sec-object.keys) + * for more details. + * + * @static + * @since 0.1.0 + * @memberOf _ + * @category Object + * @param {Object} object The object to query. + * @returns {Array} Returns the array of property names. + * @example + * + * function Foo() { + * this.a = 1; + * this.b = 2; + * } + * + * Foo.prototype.c = 3; + * + * _.keys(new Foo); + * // => ['a', 'b'] (iteration order is not guaranteed) + * + * _.keys('hi'); + * // => ['0', '1'] + */ +function keys(object) { + return isArrayLike(object) ? arrayLikeKeys(object) : baseKeys(object); +} + +/** + * Creates an array of the own enumerable string keyed property values of `object`. + * + * **Note:** Non-object values are coerced to objects. + * + * @static + * @since 0.1.0 + * @memberOf _ + * @category Object + * @param {Object} object The object to query. + * @returns {Array} Returns the array of property values. + * @example + * + * function Foo() { + * this.a = 1; + * this.b = 2; + * } + * + * Foo.prototype.c = 3; + * + * _.values(new Foo); + * // => [1, 2] (iteration order is not guaranteed) + * + * _.values('hi'); + * // => ['h', 'i'] + */ +function values(object) { + return object ? baseValues(object, keys(object)) : []; +} + +module.exports = includes; diff --git a/jwt-scratch/src/js/node_modules/lodash.includes/package.json b/jwt-scratch/src/js/node_modules/lodash.includes/package.json new file mode 100644 index 0000000..8341de2 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/lodash.includes/package.json @@ -0,0 +1,69 @@ +{ + "_from": "lodash.includes@^4.3.0", + "_id": "lodash.includes@4.3.0", + "_inBundle": false, + "_integrity": "sha1-YLuYqHy5I8aMoeUTJUgzFISfVT8=", + "_location": "/lodash.includes", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "lodash.includes@^4.3.0", + "name": "lodash.includes", + "escapedName": "lodash.includes", + "rawSpec": "^4.3.0", + "saveSpec": null, + "fetchSpec": "^4.3.0" + }, + "_requiredBy": [ + "/jsonwebtoken" + ], + "_resolved": "https://registry.npmjs.org/lodash.includes/-/lodash.includes-4.3.0.tgz", + "_shasum": "60bb98a87cb923c68ca1e51325483314849f553f", + "_spec": "lodash.includes@^4.3.0", + "_where": "/home/rock64/git/qseow-scripts/jwt-scratch/src/js/node_modules/jsonwebtoken", + "author": { + "name": "John-David Dalton", + "email": "john.david.dalton@gmail.com", + "url": "http://allyoucanleet.com/" + }, + "bugs": { + "url": "https://github.com/lodash/lodash/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "John-David Dalton", + "email": "john.david.dalton@gmail.com", + "url": "http://allyoucanleet.com/" + }, + { + "name": "Blaine Bublitz", + "email": "blaine.bublitz@gmail.com", + "url": "https://github.com/phated" + }, + { + "name": "Mathias Bynens", + "email": "mathias@qiwi.be", + "url": "https://mathiasbynens.be/" + } + ], + "deprecated": false, + "description": "The lodash method `_.includes` exported as a module.", + "homepage": "https://lodash.com/", + "icon": "https://lodash.com/icon.svg", + "keywords": [ + "lodash-modularized", + "includes" + ], + "license": "MIT", + "name": "lodash.includes", + "repository": { + "type": "git", + "url": "git+https://github.com/lodash/lodash.git" + }, + "scripts": { + "test": "echo \"See https://travis-ci.org/lodash/lodash-cli for testing details.\"" + }, + "version": "4.3.0" +} diff --git a/jwt-scratch/src/js/node_modules/lodash.isboolean/LICENSE b/jwt-scratch/src/js/node_modules/lodash.isboolean/LICENSE new file mode 100644 index 0000000..b054ca5 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/lodash.isboolean/LICENSE @@ -0,0 +1,22 @@ +Copyright 2012-2016 The Dojo Foundation +Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, +DocumentCloud and Investigative Reporters & Editors + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/jwt-scratch/src/js/node_modules/lodash.isboolean/README.md b/jwt-scratch/src/js/node_modules/lodash.isboolean/README.md new file mode 100644 index 0000000..b3c476b --- /dev/null +++ b/jwt-scratch/src/js/node_modules/lodash.isboolean/README.md @@ -0,0 +1,18 @@ +# lodash.isboolean v3.0.3 + +The [lodash](https://lodash.com/) method `_.isBoolean` exported as a [Node.js](https://nodejs.org/) module. + +## Installation + +Using npm: +```bash +$ {sudo -H} npm i -g npm +$ npm i --save lodash.isboolean +``` + +In Node.js: +```js +var isBoolean = require('lodash.isboolean'); +``` + +See the [documentation](https://lodash.com/docs#isBoolean) or [package source](https://github.com/lodash/lodash/blob/3.0.3-npm-packages/lodash.isboolean) for more details. diff --git a/jwt-scratch/src/js/node_modules/lodash.isboolean/index.js b/jwt-scratch/src/js/node_modules/lodash.isboolean/index.js new file mode 100644 index 0000000..23bbabd --- /dev/null +++ b/jwt-scratch/src/js/node_modules/lodash.isboolean/index.js @@ -0,0 +1,70 @@ +/** + * lodash 3.0.3 (Custom Build) + * Build: `lodash modularize exports="npm" -o ./` + * Copyright 2012-2016 The Dojo Foundation + * Based on Underscore.js 1.8.3 + * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + * Available under MIT license + */ + +/** `Object#toString` result references. */ +var boolTag = '[object Boolean]'; + +/** Used for built-in method references. */ +var objectProto = Object.prototype; + +/** + * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) + * of values. + */ +var objectToString = objectProto.toString; + +/** + * Checks if `value` is classified as a boolean primitive or object. + * + * @static + * @memberOf _ + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. + * @example + * + * _.isBoolean(false); + * // => true + * + * _.isBoolean(null); + * // => false + */ +function isBoolean(value) { + return value === true || value === false || + (isObjectLike(value) && objectToString.call(value) == boolTag); +} + +/** + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". + * + * @static + * @memberOf _ + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} + +module.exports = isBoolean; diff --git a/jwt-scratch/src/js/node_modules/lodash.isboolean/package.json b/jwt-scratch/src/js/node_modules/lodash.isboolean/package.json new file mode 100644 index 0000000..6236af6 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/lodash.isboolean/package.json @@ -0,0 +1,69 @@ +{ + "_from": "lodash.isboolean@^3.0.3", + "_id": "lodash.isboolean@3.0.3", + "_inBundle": false, + "_integrity": "sha1-bC4XHbKiV82WgC/UOwGyDV9YcPY=", + "_location": "/lodash.isboolean", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "lodash.isboolean@^3.0.3", + "name": "lodash.isboolean", + "escapedName": "lodash.isboolean", + "rawSpec": "^3.0.3", + "saveSpec": null, + "fetchSpec": "^3.0.3" + }, + "_requiredBy": [ + "/jsonwebtoken" + ], + "_resolved": "https://registry.npmjs.org/lodash.isboolean/-/lodash.isboolean-3.0.3.tgz", + "_shasum": "6c2e171db2a257cd96802fd43b01b20d5f5870f6", + "_spec": "lodash.isboolean@^3.0.3", + "_where": "/home/rock64/git/qseow-scripts/jwt-scratch/src/js/node_modules/jsonwebtoken", + "author": { + "name": "John-David Dalton", + "email": "john.david.dalton@gmail.com", + "url": "http://allyoucanleet.com/" + }, + "bugs": { + "url": "https://github.com/lodash/lodash/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "John-David Dalton", + "email": "john.david.dalton@gmail.com", + "url": "http://allyoucanleet.com/" + }, + { + "name": "Blaine Bublitz", + "email": "blaine@iceddev.com", + "url": "https://github.com/phated" + }, + { + "name": "Mathias Bynens", + "email": "mathias@qiwi.be", + "url": "https://mathiasbynens.be/" + } + ], + "deprecated": false, + "description": "The lodash method `_.isBoolean` exported as a module.", + "homepage": "https://lodash.com/", + "icon": "https://lodash.com/icon.svg", + "keywords": [ + "lodash-modularized", + "isboolean" + ], + "license": "MIT", + "name": "lodash.isboolean", + "repository": { + "type": "git", + "url": "git+https://github.com/lodash/lodash.git" + }, + "scripts": { + "test": "echo \"See https://travis-ci.org/lodash/lodash-cli for testing details.\"" + }, + "version": "3.0.3" +} diff --git a/jwt-scratch/src/js/node_modules/lodash.isinteger/LICENSE b/jwt-scratch/src/js/node_modules/lodash.isinteger/LICENSE new file mode 100644 index 0000000..e0c69d5 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/lodash.isinteger/LICENSE @@ -0,0 +1,47 @@ +Copyright jQuery Foundation and other contributors + +Based on Underscore.js, copyright Jeremy Ashkenas, +DocumentCloud and Investigative Reporters & Editors + +This software consists of voluntary contributions made by many +individuals. For exact contribution history, see the revision history +available at https://github.com/lodash/lodash + +The following license applies to all parts of this software except as +documented below: + +==== + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +==== + +Copyright and related rights for sample code are waived via CC0. Sample +code is defined as all source code displayed within the prose of the +documentation. + +CC0: http://creativecommons.org/publicdomain/zero/1.0/ + +==== + +Files located in the node_modules and vendor directories are externally +maintained libraries used by this software which have their own +licenses; we recommend you read them, as their terms may differ from the +terms above. diff --git a/jwt-scratch/src/js/node_modules/lodash.isinteger/README.md b/jwt-scratch/src/js/node_modules/lodash.isinteger/README.md new file mode 100644 index 0000000..3a78567 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/lodash.isinteger/README.md @@ -0,0 +1,18 @@ +# lodash.isinteger v4.0.4 + +The [lodash](https://lodash.com/) method `_.isInteger` exported as a [Node.js](https://nodejs.org/) module. + +## Installation + +Using npm: +```bash +$ {sudo -H} npm i -g npm +$ npm i --save lodash.isinteger +``` + +In Node.js: +```js +var isInteger = require('lodash.isinteger'); +``` + +See the [documentation](https://lodash.com/docs#isInteger) or [package source](https://github.com/lodash/lodash/blob/4.0.4-npm-packages/lodash.isinteger) for more details. diff --git a/jwt-scratch/src/js/node_modules/lodash.isinteger/index.js b/jwt-scratch/src/js/node_modules/lodash.isinteger/index.js new file mode 100644 index 0000000..3bf06f0 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/lodash.isinteger/index.js @@ -0,0 +1,265 @@ +/** + * lodash (Custom Build) + * Build: `lodash modularize exports="npm" -o ./` + * Copyright jQuery Foundation and other contributors + * Released under MIT license + * Based on Underscore.js 1.8.3 + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + */ + +/** Used as references for various `Number` constants. */ +var INFINITY = 1 / 0, + MAX_INTEGER = 1.7976931348623157e+308, + NAN = 0 / 0; + +/** `Object#toString` result references. */ +var symbolTag = '[object Symbol]'; + +/** Used to match leading and trailing whitespace. */ +var reTrim = /^\s+|\s+$/g; + +/** Used to detect bad signed hexadecimal string values. */ +var reIsBadHex = /^[-+]0x[0-9a-f]+$/i; + +/** Used to detect binary string values. */ +var reIsBinary = /^0b[01]+$/i; + +/** Used to detect octal string values. */ +var reIsOctal = /^0o[0-7]+$/i; + +/** Built-in method references without a dependency on `root`. */ +var freeParseInt = parseInt; + +/** Used for built-in method references. */ +var objectProto = Object.prototype; + +/** + * Used to resolve the + * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) + * of values. + */ +var objectToString = objectProto.toString; + +/** + * Checks if `value` is an integer. + * + * **Note:** This method is based on + * [`Number.isInteger`](https://mdn.io/Number/isInteger). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an integer, else `false`. + * @example + * + * _.isInteger(3); + * // => true + * + * _.isInteger(Number.MIN_VALUE); + * // => false + * + * _.isInteger(Infinity); + * // => false + * + * _.isInteger('3'); + * // => false + */ +function isInteger(value) { + return typeof value == 'number' && value == toInteger(value); +} + +/** + * Checks if `value` is the + * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types) + * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an object, else `false`. + * @example + * + * _.isObject({}); + * // => true + * + * _.isObject([1, 2, 3]); + * // => true + * + * _.isObject(_.noop); + * // => true + * + * _.isObject(null); + * // => false + */ +function isObject(value) { + var type = typeof value; + return !!value && (type == 'object' || type == 'function'); +} + +/** + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} + +/** + * Checks if `value` is classified as a `Symbol` primitive or object. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a symbol, else `false`. + * @example + * + * _.isSymbol(Symbol.iterator); + * // => true + * + * _.isSymbol('abc'); + * // => false + */ +function isSymbol(value) { + return typeof value == 'symbol' || + (isObjectLike(value) && objectToString.call(value) == symbolTag); +} + +/** + * Converts `value` to a finite number. + * + * @static + * @memberOf _ + * @since 4.12.0 + * @category Lang + * @param {*} value The value to convert. + * @returns {number} Returns the converted number. + * @example + * + * _.toFinite(3.2); + * // => 3.2 + * + * _.toFinite(Number.MIN_VALUE); + * // => 5e-324 + * + * _.toFinite(Infinity); + * // => 1.7976931348623157e+308 + * + * _.toFinite('3.2'); + * // => 3.2 + */ +function toFinite(value) { + if (!value) { + return value === 0 ? value : 0; + } + value = toNumber(value); + if (value === INFINITY || value === -INFINITY) { + var sign = (value < 0 ? -1 : 1); + return sign * MAX_INTEGER; + } + return value === value ? value : 0; +} + +/** + * Converts `value` to an integer. + * + * **Note:** This method is loosely based on + * [`ToInteger`](http://www.ecma-international.org/ecma-262/7.0/#sec-tointeger). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to convert. + * @returns {number} Returns the converted integer. + * @example + * + * _.toInteger(3.2); + * // => 3 + * + * _.toInteger(Number.MIN_VALUE); + * // => 0 + * + * _.toInteger(Infinity); + * // => 1.7976931348623157e+308 + * + * _.toInteger('3.2'); + * // => 3 + */ +function toInteger(value) { + var result = toFinite(value), + remainder = result % 1; + + return result === result ? (remainder ? result - remainder : result) : 0; +} + +/** + * Converts `value` to a number. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to process. + * @returns {number} Returns the number. + * @example + * + * _.toNumber(3.2); + * // => 3.2 + * + * _.toNumber(Number.MIN_VALUE); + * // => 5e-324 + * + * _.toNumber(Infinity); + * // => Infinity + * + * _.toNumber('3.2'); + * // => 3.2 + */ +function toNumber(value) { + if (typeof value == 'number') { + return value; + } + if (isSymbol(value)) { + return NAN; + } + if (isObject(value)) { + var other = typeof value.valueOf == 'function' ? value.valueOf() : value; + value = isObject(other) ? (other + '') : other; + } + if (typeof value != 'string') { + return value === 0 ? value : +value; + } + value = value.replace(reTrim, ''); + var isBinary = reIsBinary.test(value); + return (isBinary || reIsOctal.test(value)) + ? freeParseInt(value.slice(2), isBinary ? 2 : 8) + : (reIsBadHex.test(value) ? NAN : +value); +} + +module.exports = isInteger; diff --git a/jwt-scratch/src/js/node_modules/lodash.isinteger/package.json b/jwt-scratch/src/js/node_modules/lodash.isinteger/package.json new file mode 100644 index 0000000..16bbbe1 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/lodash.isinteger/package.json @@ -0,0 +1,69 @@ +{ + "_from": "lodash.isinteger@^4.0.4", + "_id": "lodash.isinteger@4.0.4", + "_inBundle": false, + "_integrity": "sha1-YZwK89A/iwTDH1iChAt3sRzWg0M=", + "_location": "/lodash.isinteger", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "lodash.isinteger@^4.0.4", + "name": "lodash.isinteger", + "escapedName": "lodash.isinteger", + "rawSpec": "^4.0.4", + "saveSpec": null, + "fetchSpec": "^4.0.4" + }, + "_requiredBy": [ + "/jsonwebtoken" + ], + "_resolved": "https://registry.npmjs.org/lodash.isinteger/-/lodash.isinteger-4.0.4.tgz", + "_shasum": "619c0af3d03f8b04c31f5882840b77b11cd68343", + "_spec": "lodash.isinteger@^4.0.4", + "_where": "/home/rock64/git/qseow-scripts/jwt-scratch/src/js/node_modules/jsonwebtoken", + "author": { + "name": "John-David Dalton", + "email": "john.david.dalton@gmail.com", + "url": "http://allyoucanleet.com/" + }, + "bugs": { + "url": "https://github.com/lodash/lodash/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "John-David Dalton", + "email": "john.david.dalton@gmail.com", + "url": "http://allyoucanleet.com/" + }, + { + "name": "Blaine Bublitz", + "email": "blaine.bublitz@gmail.com", + "url": "https://github.com/phated" + }, + { + "name": "Mathias Bynens", + "email": "mathias@qiwi.be", + "url": "https://mathiasbynens.be/" + } + ], + "deprecated": false, + "description": "The lodash method `_.isInteger` exported as a module.", + "homepage": "https://lodash.com/", + "icon": "https://lodash.com/icon.svg", + "keywords": [ + "lodash-modularized", + "isinteger" + ], + "license": "MIT", + "name": "lodash.isinteger", + "repository": { + "type": "git", + "url": "git+https://github.com/lodash/lodash.git" + }, + "scripts": { + "test": "echo \"See https://travis-ci.org/lodash/lodash-cli for testing details.\"" + }, + "version": "4.0.4" +} diff --git a/jwt-scratch/src/js/node_modules/lodash.isnumber/LICENSE b/jwt-scratch/src/js/node_modules/lodash.isnumber/LICENSE new file mode 100644 index 0000000..b054ca5 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/lodash.isnumber/LICENSE @@ -0,0 +1,22 @@ +Copyright 2012-2016 The Dojo Foundation +Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, +DocumentCloud and Investigative Reporters & Editors + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/jwt-scratch/src/js/node_modules/lodash.isnumber/README.md b/jwt-scratch/src/js/node_modules/lodash.isnumber/README.md new file mode 100644 index 0000000..a1d434d --- /dev/null +++ b/jwt-scratch/src/js/node_modules/lodash.isnumber/README.md @@ -0,0 +1,18 @@ +# lodash.isnumber v3.0.3 + +The [lodash](https://lodash.com/) method `_.isNumber` exported as a [Node.js](https://nodejs.org/) module. + +## Installation + +Using npm: +```bash +$ {sudo -H} npm i -g npm +$ npm i --save lodash.isnumber +``` + +In Node.js: +```js +var isNumber = require('lodash.isnumber'); +``` + +See the [documentation](https://lodash.com/docs#isNumber) or [package source](https://github.com/lodash/lodash/blob/3.0.3-npm-packages/lodash.isnumber) for more details. diff --git a/jwt-scratch/src/js/node_modules/lodash.isnumber/index.js b/jwt-scratch/src/js/node_modules/lodash.isnumber/index.js new file mode 100644 index 0000000..35a8573 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/lodash.isnumber/index.js @@ -0,0 +1,79 @@ +/** + * lodash 3.0.3 (Custom Build) + * Build: `lodash modularize exports="npm" -o ./` + * Copyright 2012-2016 The Dojo Foundation + * Based on Underscore.js 1.8.3 + * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + * Available under MIT license + */ + +/** `Object#toString` result references. */ +var numberTag = '[object Number]'; + +/** Used for built-in method references. */ +var objectProto = Object.prototype; + +/** + * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) + * of values. + */ +var objectToString = objectProto.toString; + +/** + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". + * + * @static + * @memberOf _ + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} + +/** + * Checks if `value` is classified as a `Number` primitive or object. + * + * **Note:** To exclude `Infinity`, `-Infinity`, and `NaN`, which are classified + * as numbers, use the `_.isFinite` method. + * + * @static + * @memberOf _ + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. + * @example + * + * _.isNumber(3); + * // => true + * + * _.isNumber(Number.MIN_VALUE); + * // => true + * + * _.isNumber(Infinity); + * // => true + * + * _.isNumber('3'); + * // => false + */ +function isNumber(value) { + return typeof value == 'number' || + (isObjectLike(value) && objectToString.call(value) == numberTag); +} + +module.exports = isNumber; diff --git a/jwt-scratch/src/js/node_modules/lodash.isnumber/package.json b/jwt-scratch/src/js/node_modules/lodash.isnumber/package.json new file mode 100644 index 0000000..a4dc7e8 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/lodash.isnumber/package.json @@ -0,0 +1,69 @@ +{ + "_from": "lodash.isnumber@^3.0.3", + "_id": "lodash.isnumber@3.0.3", + "_inBundle": false, + "_integrity": "sha1-POdoEMWSjQM1IwGsKHMX8RwLH/w=", + "_location": "/lodash.isnumber", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "lodash.isnumber@^3.0.3", + "name": "lodash.isnumber", + "escapedName": "lodash.isnumber", + "rawSpec": "^3.0.3", + "saveSpec": null, + "fetchSpec": "^3.0.3" + }, + "_requiredBy": [ + "/jsonwebtoken" + ], + "_resolved": "https://registry.npmjs.org/lodash.isnumber/-/lodash.isnumber-3.0.3.tgz", + "_shasum": "3ce76810c5928d03352301ac287317f11c0b1ffc", + "_spec": "lodash.isnumber@^3.0.3", + "_where": "/home/rock64/git/qseow-scripts/jwt-scratch/src/js/node_modules/jsonwebtoken", + "author": { + "name": "John-David Dalton", + "email": "john.david.dalton@gmail.com", + "url": "http://allyoucanleet.com/" + }, + "bugs": { + "url": "https://github.com/lodash/lodash/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "John-David Dalton", + "email": "john.david.dalton@gmail.com", + "url": "http://allyoucanleet.com/" + }, + { + "name": "Blaine Bublitz", + "email": "blaine@iceddev.com", + "url": "https://github.com/phated" + }, + { + "name": "Mathias Bynens", + "email": "mathias@qiwi.be", + "url": "https://mathiasbynens.be/" + } + ], + "deprecated": false, + "description": "The lodash method `_.isNumber` exported as a module.", + "homepage": "https://lodash.com/", + "icon": "https://lodash.com/icon.svg", + "keywords": [ + "lodash-modularized", + "isnumber" + ], + "license": "MIT", + "name": "lodash.isnumber", + "repository": { + "type": "git", + "url": "git+https://github.com/lodash/lodash.git" + }, + "scripts": { + "test": "echo \"See https://travis-ci.org/lodash/lodash-cli for testing details.\"" + }, + "version": "3.0.3" +} diff --git a/jwt-scratch/src/js/node_modules/lodash.isplainobject/LICENSE b/jwt-scratch/src/js/node_modules/lodash.isplainobject/LICENSE new file mode 100644 index 0000000..e0c69d5 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/lodash.isplainobject/LICENSE @@ -0,0 +1,47 @@ +Copyright jQuery Foundation and other contributors + +Based on Underscore.js, copyright Jeremy Ashkenas, +DocumentCloud and Investigative Reporters & Editors + +This software consists of voluntary contributions made by many +individuals. For exact contribution history, see the revision history +available at https://github.com/lodash/lodash + +The following license applies to all parts of this software except as +documented below: + +==== + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +==== + +Copyright and related rights for sample code are waived via CC0. Sample +code is defined as all source code displayed within the prose of the +documentation. + +CC0: http://creativecommons.org/publicdomain/zero/1.0/ + +==== + +Files located in the node_modules and vendor directories are externally +maintained libraries used by this software which have their own +licenses; we recommend you read them, as their terms may differ from the +terms above. diff --git a/jwt-scratch/src/js/node_modules/lodash.isplainobject/README.md b/jwt-scratch/src/js/node_modules/lodash.isplainobject/README.md new file mode 100644 index 0000000..aeefd74 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/lodash.isplainobject/README.md @@ -0,0 +1,18 @@ +# lodash.isplainobject v4.0.6 + +The [lodash](https://lodash.com/) method `_.isPlainObject` exported as a [Node.js](https://nodejs.org/) module. + +## Installation + +Using npm: +```bash +$ {sudo -H} npm i -g npm +$ npm i --save lodash.isplainobject +``` + +In Node.js: +```js +var isPlainObject = require('lodash.isplainobject'); +``` + +See the [documentation](https://lodash.com/docs#isPlainObject) or [package source](https://github.com/lodash/lodash/blob/4.0.6-npm-packages/lodash.isplainobject) for more details. diff --git a/jwt-scratch/src/js/node_modules/lodash.isplainobject/index.js b/jwt-scratch/src/js/node_modules/lodash.isplainobject/index.js new file mode 100644 index 0000000..0f820ee --- /dev/null +++ b/jwt-scratch/src/js/node_modules/lodash.isplainobject/index.js @@ -0,0 +1,139 @@ +/** + * lodash (Custom Build) + * Build: `lodash modularize exports="npm" -o ./` + * Copyright jQuery Foundation and other contributors + * Released under MIT license + * Based on Underscore.js 1.8.3 + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + */ + +/** `Object#toString` result references. */ +var objectTag = '[object Object]'; + +/** + * Checks if `value` is a host object in IE < 9. + * + * @private + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a host object, else `false`. + */ +function isHostObject(value) { + // Many host objects are `Object` objects that can coerce to strings + // despite having improperly defined `toString` methods. + var result = false; + if (value != null && typeof value.toString != 'function') { + try { + result = !!(value + ''); + } catch (e) {} + } + return result; +} + +/** + * Creates a unary function that invokes `func` with its argument transformed. + * + * @private + * @param {Function} func The function to wrap. + * @param {Function} transform The argument transform. + * @returns {Function} Returns the new function. + */ +function overArg(func, transform) { + return function(arg) { + return func(transform(arg)); + }; +} + +/** Used for built-in method references. */ +var funcProto = Function.prototype, + objectProto = Object.prototype; + +/** Used to resolve the decompiled source of functions. */ +var funcToString = funcProto.toString; + +/** Used to check objects for own properties. */ +var hasOwnProperty = objectProto.hasOwnProperty; + +/** Used to infer the `Object` constructor. */ +var objectCtorString = funcToString.call(Object); + +/** + * Used to resolve the + * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) + * of values. + */ +var objectToString = objectProto.toString; + +/** Built-in value references. */ +var getPrototype = overArg(Object.getPrototypeOf, Object); + +/** + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} + +/** + * Checks if `value` is a plain object, that is, an object created by the + * `Object` constructor or one with a `[[Prototype]]` of `null`. + * + * @static + * @memberOf _ + * @since 0.8.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a plain object, else `false`. + * @example + * + * function Foo() { + * this.a = 1; + * } + * + * _.isPlainObject(new Foo); + * // => false + * + * _.isPlainObject([1, 2, 3]); + * // => false + * + * _.isPlainObject({ 'x': 0, 'y': 0 }); + * // => true + * + * _.isPlainObject(Object.create(null)); + * // => true + */ +function isPlainObject(value) { + if (!isObjectLike(value) || + objectToString.call(value) != objectTag || isHostObject(value)) { + return false; + } + var proto = getPrototype(value); + if (proto === null) { + return true; + } + var Ctor = hasOwnProperty.call(proto, 'constructor') && proto.constructor; + return (typeof Ctor == 'function' && + Ctor instanceof Ctor && funcToString.call(Ctor) == objectCtorString); +} + +module.exports = isPlainObject; diff --git a/jwt-scratch/src/js/node_modules/lodash.isplainobject/package.json b/jwt-scratch/src/js/node_modules/lodash.isplainobject/package.json new file mode 100644 index 0000000..aed21e6 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/lodash.isplainobject/package.json @@ -0,0 +1,69 @@ +{ + "_from": "lodash.isplainobject@^4.0.6", + "_id": "lodash.isplainobject@4.0.6", + "_inBundle": false, + "_integrity": "sha1-fFJqUtibRcRcxpC4gWO+BJf1UMs=", + "_location": "/lodash.isplainobject", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "lodash.isplainobject@^4.0.6", + "name": "lodash.isplainobject", + "escapedName": "lodash.isplainobject", + "rawSpec": "^4.0.6", + "saveSpec": null, + "fetchSpec": "^4.0.6" + }, + "_requiredBy": [ + "/jsonwebtoken" + ], + "_resolved": "https://registry.npmjs.org/lodash.isplainobject/-/lodash.isplainobject-4.0.6.tgz", + "_shasum": "7c526a52d89b45c45cc690b88163be0497f550cb", + "_spec": "lodash.isplainobject@^4.0.6", + "_where": "/home/rock64/git/qseow-scripts/jwt-scratch/src/js/node_modules/jsonwebtoken", + "author": { + "name": "John-David Dalton", + "email": "john.david.dalton@gmail.com", + "url": "http://allyoucanleet.com/" + }, + "bugs": { + "url": "https://github.com/lodash/lodash/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "John-David Dalton", + "email": "john.david.dalton@gmail.com", + "url": "http://allyoucanleet.com/" + }, + { + "name": "Blaine Bublitz", + "email": "blaine.bublitz@gmail.com", + "url": "https://github.com/phated" + }, + { + "name": "Mathias Bynens", + "email": "mathias@qiwi.be", + "url": "https://mathiasbynens.be/" + } + ], + "deprecated": false, + "description": "The lodash method `_.isPlainObject` exported as a module.", + "homepage": "https://lodash.com/", + "icon": "https://lodash.com/icon.svg", + "keywords": [ + "lodash-modularized", + "isplainobject" + ], + "license": "MIT", + "name": "lodash.isplainobject", + "repository": { + "type": "git", + "url": "git+https://github.com/lodash/lodash.git" + }, + "scripts": { + "test": "echo \"See https://travis-ci.org/lodash/lodash-cli for testing details.\"" + }, + "version": "4.0.6" +} diff --git a/jwt-scratch/src/js/node_modules/lodash.isstring/LICENSE b/jwt-scratch/src/js/node_modules/lodash.isstring/LICENSE new file mode 100644 index 0000000..b054ca5 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/lodash.isstring/LICENSE @@ -0,0 +1,22 @@ +Copyright 2012-2016 The Dojo Foundation +Based on Underscore.js, copyright 2009-2016 Jeremy Ashkenas, +DocumentCloud and Investigative Reporters & Editors + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. diff --git a/jwt-scratch/src/js/node_modules/lodash.isstring/README.md b/jwt-scratch/src/js/node_modules/lodash.isstring/README.md new file mode 100644 index 0000000..f184029 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/lodash.isstring/README.md @@ -0,0 +1,18 @@ +# lodash.isstring v4.0.1 + +The [lodash](https://lodash.com/) method `_.isString` exported as a [Node.js](https://nodejs.org/) module. + +## Installation + +Using npm: +```bash +$ {sudo -H} npm i -g npm +$ npm i --save lodash.isstring +``` + +In Node.js: +```js +var isString = require('lodash.isstring'); +``` + +See the [documentation](https://lodash.com/docs#isString) or [package source](https://github.com/lodash/lodash/blob/4.0.1-npm-packages/lodash.isstring) for more details. diff --git a/jwt-scratch/src/js/node_modules/lodash.isstring/index.js b/jwt-scratch/src/js/node_modules/lodash.isstring/index.js new file mode 100644 index 0000000..408225c --- /dev/null +++ b/jwt-scratch/src/js/node_modules/lodash.isstring/index.js @@ -0,0 +1,95 @@ +/** + * lodash 4.0.1 (Custom Build) + * Build: `lodash modularize exports="npm" -o ./` + * Copyright 2012-2016 The Dojo Foundation + * Based on Underscore.js 1.8.3 + * Copyright 2009-2016 Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + * Available under MIT license + */ + +/** `Object#toString` result references. */ +var stringTag = '[object String]'; + +/** Used for built-in method references. */ +var objectProto = Object.prototype; + +/** + * Used to resolve the [`toStringTag`](http://ecma-international.org/ecma-262/6.0/#sec-object.prototype.tostring) + * of values. + */ +var objectToString = objectProto.toString; + +/** + * Checks if `value` is classified as an `Array` object. + * + * @static + * @memberOf _ + * @type Function + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. + * @example + * + * _.isArray([1, 2, 3]); + * // => true + * + * _.isArray(document.body.children); + * // => false + * + * _.isArray('abc'); + * // => false + * + * _.isArray(_.noop); + * // => false + */ +var isArray = Array.isArray; + +/** + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". + * + * @static + * @memberOf _ + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} + +/** + * Checks if `value` is classified as a `String` primitive or object. + * + * @static + * @memberOf _ + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is correctly classified, else `false`. + * @example + * + * _.isString('abc'); + * // => true + * + * _.isString(1); + * // => false + */ +function isString(value) { + return typeof value == 'string' || + (!isArray(value) && isObjectLike(value) && objectToString.call(value) == stringTag); +} + +module.exports = isString; diff --git a/jwt-scratch/src/js/node_modules/lodash.isstring/package.json b/jwt-scratch/src/js/node_modules/lodash.isstring/package.json new file mode 100644 index 0000000..7e40bb4 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/lodash.isstring/package.json @@ -0,0 +1,69 @@ +{ + "_from": "lodash.isstring@^4.0.1", + "_id": "lodash.isstring@4.0.1", + "_inBundle": false, + "_integrity": "sha1-1SfftUVuynzJu5XV2ur4i6VKVFE=", + "_location": "/lodash.isstring", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "lodash.isstring@^4.0.1", + "name": "lodash.isstring", + "escapedName": "lodash.isstring", + "rawSpec": "^4.0.1", + "saveSpec": null, + "fetchSpec": "^4.0.1" + }, + "_requiredBy": [ + "/jsonwebtoken" + ], + "_resolved": "https://registry.npmjs.org/lodash.isstring/-/lodash.isstring-4.0.1.tgz", + "_shasum": "d527dfb5456eca7cc9bb95d5daeaf88ba54a5451", + "_spec": "lodash.isstring@^4.0.1", + "_where": "/home/rock64/git/qseow-scripts/jwt-scratch/src/js/node_modules/jsonwebtoken", + "author": { + "name": "John-David Dalton", + "email": "john.david.dalton@gmail.com", + "url": "http://allyoucanleet.com/" + }, + "bugs": { + "url": "https://github.com/lodash/lodash/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "John-David Dalton", + "email": "john.david.dalton@gmail.com", + "url": "http://allyoucanleet.com/" + }, + { + "name": "Blaine Bublitz", + "email": "blaine@iceddev.com", + "url": "https://github.com/phated" + }, + { + "name": "Mathias Bynens", + "email": "mathias@qiwi.be", + "url": "https://mathiasbynens.be/" + } + ], + "deprecated": false, + "description": "The lodash method `_.isString` exported as a module.", + "homepage": "https://lodash.com/", + "icon": "https://lodash.com/icon.svg", + "keywords": [ + "lodash-modularized", + "isstring" + ], + "license": "MIT", + "name": "lodash.isstring", + "repository": { + "type": "git", + "url": "git+https://github.com/lodash/lodash.git" + }, + "scripts": { + "test": "echo \"See https://travis-ci.org/lodash/lodash-cli for testing details.\"" + }, + "version": "4.0.1" +} diff --git a/jwt-scratch/src/js/node_modules/lodash.once/LICENSE b/jwt-scratch/src/js/node_modules/lodash.once/LICENSE new file mode 100644 index 0000000..e0c69d5 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/lodash.once/LICENSE @@ -0,0 +1,47 @@ +Copyright jQuery Foundation and other contributors + +Based on Underscore.js, copyright Jeremy Ashkenas, +DocumentCloud and Investigative Reporters & Editors + +This software consists of voluntary contributions made by many +individuals. For exact contribution history, see the revision history +available at https://github.com/lodash/lodash + +The following license applies to all parts of this software except as +documented below: + +==== + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. + +==== + +Copyright and related rights for sample code are waived via CC0. Sample +code is defined as all source code displayed within the prose of the +documentation. + +CC0: http://creativecommons.org/publicdomain/zero/1.0/ + +==== + +Files located in the node_modules and vendor directories are externally +maintained libraries used by this software which have their own +licenses; we recommend you read them, as their terms may differ from the +terms above. diff --git a/jwt-scratch/src/js/node_modules/lodash.once/README.md b/jwt-scratch/src/js/node_modules/lodash.once/README.md new file mode 100644 index 0000000..c4a2f16 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/lodash.once/README.md @@ -0,0 +1,18 @@ +# lodash.once v4.1.1 + +The [lodash](https://lodash.com/) method `_.once` exported as a [Node.js](https://nodejs.org/) module. + +## Installation + +Using npm: +```bash +$ {sudo -H} npm i -g npm +$ npm i --save lodash.once +``` + +In Node.js: +```js +var once = require('lodash.once'); +``` + +See the [documentation](https://lodash.com/docs#once) or [package source](https://github.com/lodash/lodash/blob/4.1.1-npm-packages/lodash.once) for more details. diff --git a/jwt-scratch/src/js/node_modules/lodash.once/index.js b/jwt-scratch/src/js/node_modules/lodash.once/index.js new file mode 100644 index 0000000..414ceb3 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/lodash.once/index.js @@ -0,0 +1,294 @@ +/** + * lodash (Custom Build) + * Build: `lodash modularize exports="npm" -o ./` + * Copyright jQuery Foundation and other contributors + * Released under MIT license + * Based on Underscore.js 1.8.3 + * Copyright Jeremy Ashkenas, DocumentCloud and Investigative Reporters & Editors + */ + +/** Used as the `TypeError` message for "Functions" methods. */ +var FUNC_ERROR_TEXT = 'Expected a function'; + +/** Used as references for various `Number` constants. */ +var INFINITY = 1 / 0, + MAX_INTEGER = 1.7976931348623157e+308, + NAN = 0 / 0; + +/** `Object#toString` result references. */ +var symbolTag = '[object Symbol]'; + +/** Used to match leading and trailing whitespace. */ +var reTrim = /^\s+|\s+$/g; + +/** Used to detect bad signed hexadecimal string values. */ +var reIsBadHex = /^[-+]0x[0-9a-f]+$/i; + +/** Used to detect binary string values. */ +var reIsBinary = /^0b[01]+$/i; + +/** Used to detect octal string values. */ +var reIsOctal = /^0o[0-7]+$/i; + +/** Built-in method references without a dependency on `root`. */ +var freeParseInt = parseInt; + +/** Used for built-in method references. */ +var objectProto = Object.prototype; + +/** + * Used to resolve the + * [`toStringTag`](http://ecma-international.org/ecma-262/7.0/#sec-object.prototype.tostring) + * of values. + */ +var objectToString = objectProto.toString; + +/** + * Creates a function that invokes `func`, with the `this` binding and arguments + * of the created function, while it's called less than `n` times. Subsequent + * calls to the created function return the result of the last `func` invocation. + * + * @static + * @memberOf _ + * @since 3.0.0 + * @category Function + * @param {number} n The number of calls at which `func` is no longer invoked. + * @param {Function} func The function to restrict. + * @returns {Function} Returns the new restricted function. + * @example + * + * jQuery(element).on('click', _.before(5, addContactToList)); + * // => Allows adding up to 4 contacts to the list. + */ +function before(n, func) { + var result; + if (typeof func != 'function') { + throw new TypeError(FUNC_ERROR_TEXT); + } + n = toInteger(n); + return function() { + if (--n > 0) { + result = func.apply(this, arguments); + } + if (n <= 1) { + func = undefined; + } + return result; + }; +} + +/** + * Creates a function that is restricted to invoking `func` once. Repeat calls + * to the function return the value of the first invocation. The `func` is + * invoked with the `this` binding and arguments of the created function. + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Function + * @param {Function} func The function to restrict. + * @returns {Function} Returns the new restricted function. + * @example + * + * var initialize = _.once(createApplication); + * initialize(); + * initialize(); + * // => `createApplication` is invoked once + */ +function once(func) { + return before(2, func); +} + +/** + * Checks if `value` is the + * [language type](http://www.ecma-international.org/ecma-262/7.0/#sec-ecmascript-language-types) + * of `Object`. (e.g. arrays, functions, objects, regexes, `new Number(0)`, and `new String('')`) + * + * @static + * @memberOf _ + * @since 0.1.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is an object, else `false`. + * @example + * + * _.isObject({}); + * // => true + * + * _.isObject([1, 2, 3]); + * // => true + * + * _.isObject(_.noop); + * // => true + * + * _.isObject(null); + * // => false + */ +function isObject(value) { + var type = typeof value; + return !!value && (type == 'object' || type == 'function'); +} + +/** + * Checks if `value` is object-like. A value is object-like if it's not `null` + * and has a `typeof` result of "object". + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is object-like, else `false`. + * @example + * + * _.isObjectLike({}); + * // => true + * + * _.isObjectLike([1, 2, 3]); + * // => true + * + * _.isObjectLike(_.noop); + * // => false + * + * _.isObjectLike(null); + * // => false + */ +function isObjectLike(value) { + return !!value && typeof value == 'object'; +} + +/** + * Checks if `value` is classified as a `Symbol` primitive or object. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to check. + * @returns {boolean} Returns `true` if `value` is a symbol, else `false`. + * @example + * + * _.isSymbol(Symbol.iterator); + * // => true + * + * _.isSymbol('abc'); + * // => false + */ +function isSymbol(value) { + return typeof value == 'symbol' || + (isObjectLike(value) && objectToString.call(value) == symbolTag); +} + +/** + * Converts `value` to a finite number. + * + * @static + * @memberOf _ + * @since 4.12.0 + * @category Lang + * @param {*} value The value to convert. + * @returns {number} Returns the converted number. + * @example + * + * _.toFinite(3.2); + * // => 3.2 + * + * _.toFinite(Number.MIN_VALUE); + * // => 5e-324 + * + * _.toFinite(Infinity); + * // => 1.7976931348623157e+308 + * + * _.toFinite('3.2'); + * // => 3.2 + */ +function toFinite(value) { + if (!value) { + return value === 0 ? value : 0; + } + value = toNumber(value); + if (value === INFINITY || value === -INFINITY) { + var sign = (value < 0 ? -1 : 1); + return sign * MAX_INTEGER; + } + return value === value ? value : 0; +} + +/** + * Converts `value` to an integer. + * + * **Note:** This method is loosely based on + * [`ToInteger`](http://www.ecma-international.org/ecma-262/7.0/#sec-tointeger). + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to convert. + * @returns {number} Returns the converted integer. + * @example + * + * _.toInteger(3.2); + * // => 3 + * + * _.toInteger(Number.MIN_VALUE); + * // => 0 + * + * _.toInteger(Infinity); + * // => 1.7976931348623157e+308 + * + * _.toInteger('3.2'); + * // => 3 + */ +function toInteger(value) { + var result = toFinite(value), + remainder = result % 1; + + return result === result ? (remainder ? result - remainder : result) : 0; +} + +/** + * Converts `value` to a number. + * + * @static + * @memberOf _ + * @since 4.0.0 + * @category Lang + * @param {*} value The value to process. + * @returns {number} Returns the number. + * @example + * + * _.toNumber(3.2); + * // => 3.2 + * + * _.toNumber(Number.MIN_VALUE); + * // => 5e-324 + * + * _.toNumber(Infinity); + * // => Infinity + * + * _.toNumber('3.2'); + * // => 3.2 + */ +function toNumber(value) { + if (typeof value == 'number') { + return value; + } + if (isSymbol(value)) { + return NAN; + } + if (isObject(value)) { + var other = typeof value.valueOf == 'function' ? value.valueOf() : value; + value = isObject(other) ? (other + '') : other; + } + if (typeof value != 'string') { + return value === 0 ? value : +value; + } + value = value.replace(reTrim, ''); + var isBinary = reIsBinary.test(value); + return (isBinary || reIsOctal.test(value)) + ? freeParseInt(value.slice(2), isBinary ? 2 : 8) + : (reIsBadHex.test(value) ? NAN : +value); +} + +module.exports = once; diff --git a/jwt-scratch/src/js/node_modules/lodash.once/package.json b/jwt-scratch/src/js/node_modules/lodash.once/package.json new file mode 100644 index 0000000..d30103c --- /dev/null +++ b/jwt-scratch/src/js/node_modules/lodash.once/package.json @@ -0,0 +1,69 @@ +{ + "_from": "lodash.once@^4.0.0", + "_id": "lodash.once@4.1.1", + "_inBundle": false, + "_integrity": "sha1-DdOXEhPHxW34gJd9UEyI+0cal6w=", + "_location": "/lodash.once", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "lodash.once@^4.0.0", + "name": "lodash.once", + "escapedName": "lodash.once", + "rawSpec": "^4.0.0", + "saveSpec": null, + "fetchSpec": "^4.0.0" + }, + "_requiredBy": [ + "/jsonwebtoken" + ], + "_resolved": "https://registry.npmjs.org/lodash.once/-/lodash.once-4.1.1.tgz", + "_shasum": "0dd3971213c7c56df880977d504c88fb471a97ac", + "_spec": "lodash.once@^4.0.0", + "_where": "/home/rock64/git/qseow-scripts/jwt-scratch/src/js/node_modules/jsonwebtoken", + "author": { + "name": "John-David Dalton", + "email": "john.david.dalton@gmail.com", + "url": "http://allyoucanleet.com/" + }, + "bugs": { + "url": "https://github.com/lodash/lodash/issues" + }, + "bundleDependencies": false, + "contributors": [ + { + "name": "John-David Dalton", + "email": "john.david.dalton@gmail.com", + "url": "http://allyoucanleet.com/" + }, + { + "name": "Blaine Bublitz", + "email": "blaine.bublitz@gmail.com", + "url": "https://github.com/phated" + }, + { + "name": "Mathias Bynens", + "email": "mathias@qiwi.be", + "url": "https://mathiasbynens.be/" + } + ], + "deprecated": false, + "description": "The lodash method `_.once` exported as a module.", + "homepage": "https://lodash.com/", + "icon": "https://lodash.com/icon.svg", + "keywords": [ + "lodash-modularized", + "once" + ], + "license": "MIT", + "name": "lodash.once", + "repository": { + "type": "git", + "url": "git+https://github.com/lodash/lodash.git" + }, + "scripts": { + "test": "echo \"See https://travis-ci.org/lodash/lodash-cli for testing details.\"" + }, + "version": "4.1.1" +} diff --git a/jwt-scratch/src/js/node_modules/ms/index.js b/jwt-scratch/src/js/node_modules/ms/index.js new file mode 100644 index 0000000..ea734fb --- /dev/null +++ b/jwt-scratch/src/js/node_modules/ms/index.js @@ -0,0 +1,162 @@ +/** + * Helpers. + */ + +var s = 1000; +var m = s * 60; +var h = m * 60; +var d = h * 24; +var w = d * 7; +var y = d * 365.25; + +/** + * Parse or format the given `val`. + * + * Options: + * + * - `long` verbose formatting [false] + * + * @param {String|Number} val + * @param {Object} [options] + * @throws {Error} throw an error if val is not a non-empty string or a number + * @return {String|Number} + * @api public + */ + +module.exports = function (val, options) { + options = options || {}; + var type = typeof val; + if (type === 'string' && val.length > 0) { + return parse(val); + } else if (type === 'number' && isFinite(val)) { + return options.long ? fmtLong(val) : fmtShort(val); + } + throw new Error( + 'val is not a non-empty string or a valid number. val=' + + JSON.stringify(val) + ); +}; + +/** + * Parse the given `str` and return milliseconds. + * + * @param {String} str + * @return {Number} + * @api private + */ + +function parse(str) { + str = String(str); + if (str.length > 100) { + return; + } + var match = /^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec( + str + ); + if (!match) { + return; + } + var n = parseFloat(match[1]); + var type = (match[2] || 'ms').toLowerCase(); + switch (type) { + case 'years': + case 'year': + case 'yrs': + case 'yr': + case 'y': + return n * y; + case 'weeks': + case 'week': + case 'w': + return n * w; + case 'days': + case 'day': + case 'd': + return n * d; + case 'hours': + case 'hour': + case 'hrs': + case 'hr': + case 'h': + return n * h; + case 'minutes': + case 'minute': + case 'mins': + case 'min': + case 'm': + return n * m; + case 'seconds': + case 'second': + case 'secs': + case 'sec': + case 's': + return n * s; + case 'milliseconds': + case 'millisecond': + case 'msecs': + case 'msec': + case 'ms': + return n; + default: + return undefined; + } +} + +/** + * Short format for `ms`. + * + * @param {Number} ms + * @return {String} + * @api private + */ + +function fmtShort(ms) { + var msAbs = Math.abs(ms); + if (msAbs >= d) { + return Math.round(ms / d) + 'd'; + } + if (msAbs >= h) { + return Math.round(ms / h) + 'h'; + } + if (msAbs >= m) { + return Math.round(ms / m) + 'm'; + } + if (msAbs >= s) { + return Math.round(ms / s) + 's'; + } + return ms + 'ms'; +} + +/** + * Long format for `ms`. + * + * @param {Number} ms + * @return {String} + * @api private + */ + +function fmtLong(ms) { + var msAbs = Math.abs(ms); + if (msAbs >= d) { + return plural(ms, msAbs, d, 'day'); + } + if (msAbs >= h) { + return plural(ms, msAbs, h, 'hour'); + } + if (msAbs >= m) { + return plural(ms, msAbs, m, 'minute'); + } + if (msAbs >= s) { + return plural(ms, msAbs, s, 'second'); + } + return ms + ' ms'; +} + +/** + * Pluralization helper. + */ + +function plural(ms, msAbs, n, name) { + var isPlural = msAbs >= n * 1.5; + return Math.round(ms / n) + ' ' + name + (isPlural ? 's' : ''); +} diff --git a/jwt-scratch/src/js/node_modules/ms/license.md b/jwt-scratch/src/js/node_modules/ms/license.md new file mode 100644 index 0000000..fa5d39b --- /dev/null +++ b/jwt-scratch/src/js/node_modules/ms/license.md @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2020 Vercel, Inc. + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/jwt-scratch/src/js/node_modules/ms/package.json b/jwt-scratch/src/js/node_modules/ms/package.json new file mode 100644 index 0000000..6a69fb8 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/ms/package.json @@ -0,0 +1,70 @@ +{ + "_from": "ms@^2.1.1", + "_id": "ms@2.1.3", + "_inBundle": false, + "_integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==", + "_location": "/ms", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "ms@^2.1.1", + "name": "ms", + "escapedName": "ms", + "rawSpec": "^2.1.1", + "saveSpec": null, + "fetchSpec": "^2.1.1" + }, + "_requiredBy": [ + "/jsonwebtoken" + ], + "_resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", + "_shasum": "574c8138ce1d2b5861f0b44579dbadd60c6615b2", + "_spec": "ms@^2.1.1", + "_where": "/home/rock64/git/qseow-scripts/jwt-scratch/src/js/node_modules/jsonwebtoken", + "bugs": { + "url": "https://github.com/vercel/ms/issues" + }, + "bundleDependencies": false, + "deprecated": false, + "description": "Tiny millisecond conversion utility", + "devDependencies": { + "eslint": "4.18.2", + "expect.js": "0.3.1", + "husky": "0.14.3", + "lint-staged": "5.0.0", + "mocha": "4.0.1", + "prettier": "2.0.5" + }, + "eslintConfig": { + "extends": "eslint:recommended", + "env": { + "node": true, + "es6": true + } + }, + "files": [ + "index.js" + ], + "homepage": "https://github.com/vercel/ms#readme", + "license": "MIT", + "lint-staged": { + "*.js": [ + "npm run lint", + "prettier --single-quote --write", + "git add" + ] + }, + "main": "./index", + "name": "ms", + "repository": { + "type": "git", + "url": "git+https://github.com/vercel/ms.git" + }, + "scripts": { + "lint": "eslint lib/* bin/*", + "precommit": "lint-staged", + "test": "mocha tests.js" + }, + "version": "2.1.3" +} diff --git a/jwt-scratch/src/js/node_modules/ms/readme.md b/jwt-scratch/src/js/node_modules/ms/readme.md new file mode 100644 index 0000000..0fc1abb --- /dev/null +++ b/jwt-scratch/src/js/node_modules/ms/readme.md @@ -0,0 +1,59 @@ +# ms + +![CI](https://github.com/vercel/ms/workflows/CI/badge.svg) + +Use this package to easily convert various time formats to milliseconds. + +## Examples + +```js +ms('2 days') // 172800000 +ms('1d') // 86400000 +ms('10h') // 36000000 +ms('2.5 hrs') // 9000000 +ms('2h') // 7200000 +ms('1m') // 60000 +ms('5s') // 5000 +ms('1y') // 31557600000 +ms('100') // 100 +ms('-3 days') // -259200000 +ms('-1h') // -3600000 +ms('-200') // -200 +``` + +### Convert from Milliseconds + +```js +ms(60000) // "1m" +ms(2 * 60000) // "2m" +ms(-3 * 60000) // "-3m" +ms(ms('10 hours')) // "10h" +``` + +### Time Format Written-Out + +```js +ms(60000, { long: true }) // "1 minute" +ms(2 * 60000, { long: true }) // "2 minutes" +ms(-3 * 60000, { long: true }) // "-3 minutes" +ms(ms('10 hours'), { long: true }) // "10 hours" +``` + +## Features + +- Works both in [Node.js](https://nodejs.org) and in the browser +- If a number is supplied to `ms`, a string with a unit is returned +- If a string that contains the number is supplied, it returns it as a number (e.g.: it returns `100` for `'100'`) +- If you pass a string with a number and a valid unit, the number of equivalent milliseconds is returned + +## Related Packages + +- [ms.macro](https://github.com/knpwrs/ms.macro) - Run `ms` as a macro at build-time. + +## Caught a Bug? + +1. [Fork](https://help.github.com/articles/fork-a-repo/) this repository to your own GitHub account and then [clone](https://help.github.com/articles/cloning-a-repository/) it to your local device +2. Link the package to the global module directory: `npm link` +3. Within the module you want to test your local development instance of ms, just link it to the dependencies: `npm link ms`. Instead of the default one from npm, Node.js will now use your clone of ms! + +As always, you can run the tests using: `npm test` diff --git a/jwt-scratch/src/js/node_modules/safe-buffer/LICENSE b/jwt-scratch/src/js/node_modules/safe-buffer/LICENSE new file mode 100644 index 0000000..0c068ce --- /dev/null +++ b/jwt-scratch/src/js/node_modules/safe-buffer/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) Feross Aboukhadijeh + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in +all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN +THE SOFTWARE. diff --git a/jwt-scratch/src/js/node_modules/safe-buffer/README.md b/jwt-scratch/src/js/node_modules/safe-buffer/README.md new file mode 100644 index 0000000..e9a81af --- /dev/null +++ b/jwt-scratch/src/js/node_modules/safe-buffer/README.md @@ -0,0 +1,584 @@ +# safe-buffer [![travis][travis-image]][travis-url] [![npm][npm-image]][npm-url] [![downloads][downloads-image]][downloads-url] [![javascript style guide][standard-image]][standard-url] + +[travis-image]: https://img.shields.io/travis/feross/safe-buffer/master.svg +[travis-url]: https://travis-ci.org/feross/safe-buffer +[npm-image]: https://img.shields.io/npm/v/safe-buffer.svg +[npm-url]: https://npmjs.org/package/safe-buffer +[downloads-image]: https://img.shields.io/npm/dm/safe-buffer.svg +[downloads-url]: https://npmjs.org/package/safe-buffer +[standard-image]: https://img.shields.io/badge/code_style-standard-brightgreen.svg +[standard-url]: https://standardjs.com + +#### Safer Node.js Buffer API + +**Use the new Node.js Buffer APIs (`Buffer.from`, `Buffer.alloc`, +`Buffer.allocUnsafe`, `Buffer.allocUnsafeSlow`) in all versions of Node.js.** + +**Uses the built-in implementation when available.** + +## install + +``` +npm install safe-buffer +``` + +## usage + +The goal of this package is to provide a safe replacement for the node.js `Buffer`. + +It's a drop-in replacement for `Buffer`. You can use it by adding one `require` line to +the top of your node.js modules: + +```js +var Buffer = require('safe-buffer').Buffer + +// Existing buffer code will continue to work without issues: + +new Buffer('hey', 'utf8') +new Buffer([1, 2, 3], 'utf8') +new Buffer(obj) +new Buffer(16) // create an uninitialized buffer (potentially unsafe) + +// But you can use these new explicit APIs to make clear what you want: + +Buffer.from('hey', 'utf8') // convert from many types to a Buffer +Buffer.alloc(16) // create a zero-filled buffer (safe) +Buffer.allocUnsafe(16) // create an uninitialized buffer (potentially unsafe) +``` + +## api + +### Class Method: Buffer.from(array) + + +* `array` {Array} + +Allocates a new `Buffer` using an `array` of octets. + +```js +const buf = Buffer.from([0x62,0x75,0x66,0x66,0x65,0x72]); + // creates a new Buffer containing ASCII bytes + // ['b','u','f','f','e','r'] +``` + +A `TypeError` will be thrown if `array` is not an `Array`. + +### Class Method: Buffer.from(arrayBuffer[, byteOffset[, length]]) + + +* `arrayBuffer` {ArrayBuffer} The `.buffer` property of a `TypedArray` or + a `new ArrayBuffer()` +* `byteOffset` {Number} Default: `0` +* `length` {Number} Default: `arrayBuffer.length - byteOffset` + +When passed a reference to the `.buffer` property of a `TypedArray` instance, +the newly created `Buffer` will share the same allocated memory as the +TypedArray. + +```js +const arr = new Uint16Array(2); +arr[0] = 5000; +arr[1] = 4000; + +const buf = Buffer.from(arr.buffer); // shares the memory with arr; + +console.log(buf); + // Prints: + +// changing the TypedArray changes the Buffer also +arr[1] = 6000; + +console.log(buf); + // Prints: +``` + +The optional `byteOffset` and `length` arguments specify a memory range within +the `arrayBuffer` that will be shared by the `Buffer`. + +```js +const ab = new ArrayBuffer(10); +const buf = Buffer.from(ab, 0, 2); +console.log(buf.length); + // Prints: 2 +``` + +A `TypeError` will be thrown if `arrayBuffer` is not an `ArrayBuffer`. + +### Class Method: Buffer.from(buffer) + + +* `buffer` {Buffer} + +Copies the passed `buffer` data onto a new `Buffer` instance. + +```js +const buf1 = Buffer.from('buffer'); +const buf2 = Buffer.from(buf1); + +buf1[0] = 0x61; +console.log(buf1.toString()); + // 'auffer' +console.log(buf2.toString()); + // 'buffer' (copy is not changed) +``` + +A `TypeError` will be thrown if `buffer` is not a `Buffer`. + +### Class Method: Buffer.from(str[, encoding]) + + +* `str` {String} String to encode. +* `encoding` {String} Encoding to use, Default: `'utf8'` + +Creates a new `Buffer` containing the given JavaScript string `str`. If +provided, the `encoding` parameter identifies the character encoding. +If not provided, `encoding` defaults to `'utf8'`. + +```js +const buf1 = Buffer.from('this is a tést'); +console.log(buf1.toString()); + // prints: this is a tést +console.log(buf1.toString('ascii')); + // prints: this is a tC)st + +const buf2 = Buffer.from('7468697320697320612074c3a97374', 'hex'); +console.log(buf2.toString()); + // prints: this is a tést +``` + +A `TypeError` will be thrown if `str` is not a string. + +### Class Method: Buffer.alloc(size[, fill[, encoding]]) + + +* `size` {Number} +* `fill` {Value} Default: `undefined` +* `encoding` {String} Default: `utf8` + +Allocates a new `Buffer` of `size` bytes. If `fill` is `undefined`, the +`Buffer` will be *zero-filled*. + +```js +const buf = Buffer.alloc(5); +console.log(buf); + // +``` + +The `size` must be less than or equal to the value of +`require('buffer').kMaxLength` (on 64-bit architectures, `kMaxLength` is +`(2^31)-1`). Otherwise, a [`RangeError`][] is thrown. A zero-length Buffer will +be created if a `size` less than or equal to 0 is specified. + +If `fill` is specified, the allocated `Buffer` will be initialized by calling +`buf.fill(fill)`. See [`buf.fill()`][] for more information. + +```js +const buf = Buffer.alloc(5, 'a'); +console.log(buf); + // +``` + +If both `fill` and `encoding` are specified, the allocated `Buffer` will be +initialized by calling `buf.fill(fill, encoding)`. For example: + +```js +const buf = Buffer.alloc(11, 'aGVsbG8gd29ybGQ=', 'base64'); +console.log(buf); + // +``` + +Calling `Buffer.alloc(size)` can be significantly slower than the alternative +`Buffer.allocUnsafe(size)` but ensures that the newly created `Buffer` instance +contents will *never contain sensitive data*. + +A `TypeError` will be thrown if `size` is not a number. + +### Class Method: Buffer.allocUnsafe(size) + + +* `size` {Number} + +Allocates a new *non-zero-filled* `Buffer` of `size` bytes. The `size` must +be less than or equal to the value of `require('buffer').kMaxLength` (on 64-bit +architectures, `kMaxLength` is `(2^31)-1`). Otherwise, a [`RangeError`][] is +thrown. A zero-length Buffer will be created if a `size` less than or equal to +0 is specified. + +The underlying memory for `Buffer` instances created in this way is *not +initialized*. The contents of the newly created `Buffer` are unknown and +*may contain sensitive data*. Use [`buf.fill(0)`][] to initialize such +`Buffer` instances to zeroes. + +```js +const buf = Buffer.allocUnsafe(5); +console.log(buf); + // + // (octets will be different, every time) +buf.fill(0); +console.log(buf); + // +``` + +A `TypeError` will be thrown if `size` is not a number. + +Note that the `Buffer` module pre-allocates an internal `Buffer` instance of +size `Buffer.poolSize` that is used as a pool for the fast allocation of new +`Buffer` instances created using `Buffer.allocUnsafe(size)` (and the deprecated +`new Buffer(size)` constructor) only when `size` is less than or equal to +`Buffer.poolSize >> 1` (floor of `Buffer.poolSize` divided by two). The default +value of `Buffer.poolSize` is `8192` but can be modified. + +Use of this pre-allocated internal memory pool is a key difference between +calling `Buffer.alloc(size, fill)` vs. `Buffer.allocUnsafe(size).fill(fill)`. +Specifically, `Buffer.alloc(size, fill)` will *never* use the internal Buffer +pool, while `Buffer.allocUnsafe(size).fill(fill)` *will* use the internal +Buffer pool if `size` is less than or equal to half `Buffer.poolSize`. The +difference is subtle but can be important when an application requires the +additional performance that `Buffer.allocUnsafe(size)` provides. + +### Class Method: Buffer.allocUnsafeSlow(size) + + +* `size` {Number} + +Allocates a new *non-zero-filled* and non-pooled `Buffer` of `size` bytes. The +`size` must be less than or equal to the value of +`require('buffer').kMaxLength` (on 64-bit architectures, `kMaxLength` is +`(2^31)-1`). Otherwise, a [`RangeError`][] is thrown. A zero-length Buffer will +be created if a `size` less than or equal to 0 is specified. + +The underlying memory for `Buffer` instances created in this way is *not +initialized*. The contents of the newly created `Buffer` are unknown and +*may contain sensitive data*. Use [`buf.fill(0)`][] to initialize such +`Buffer` instances to zeroes. + +When using `Buffer.allocUnsafe()` to allocate new `Buffer` instances, +allocations under 4KB are, by default, sliced from a single pre-allocated +`Buffer`. This allows applications to avoid the garbage collection overhead of +creating many individually allocated Buffers. This approach improves both +performance and memory usage by eliminating the need to track and cleanup as +many `Persistent` objects. + +However, in the case where a developer may need to retain a small chunk of +memory from a pool for an indeterminate amount of time, it may be appropriate +to create an un-pooled Buffer instance using `Buffer.allocUnsafeSlow()` then +copy out the relevant bits. + +```js +// need to keep around a few small chunks of memory +const store = []; + +socket.on('readable', () => { + const data = socket.read(); + // allocate for retained data + const sb = Buffer.allocUnsafeSlow(10); + // copy the data into the new allocation + data.copy(sb, 0, 0, 10); + store.push(sb); +}); +``` + +Use of `Buffer.allocUnsafeSlow()` should be used only as a last resort *after* +a developer has observed undue memory retention in their applications. + +A `TypeError` will be thrown if `size` is not a number. + +### All the Rest + +The rest of the `Buffer` API is exactly the same as in node.js. +[See the docs](https://nodejs.org/api/buffer.html). + + +## Related links + +- [Node.js issue: Buffer(number) is unsafe](https://github.com/nodejs/node/issues/4660) +- [Node.js Enhancement Proposal: Buffer.from/Buffer.alloc/Buffer.zalloc/Buffer() soft-deprecate](https://github.com/nodejs/node-eps/pull/4) + +## Why is `Buffer` unsafe? + +Today, the node.js `Buffer` constructor is overloaded to handle many different argument +types like `String`, `Array`, `Object`, `TypedArrayView` (`Uint8Array`, etc.), +`ArrayBuffer`, and also `Number`. + +The API is optimized for convenience: you can throw any type at it, and it will try to do +what you want. + +Because the Buffer constructor is so powerful, you often see code like this: + +```js +// Convert UTF-8 strings to hex +function toHex (str) { + return new Buffer(str).toString('hex') +} +``` + +***But what happens if `toHex` is called with a `Number` argument?*** + +### Remote Memory Disclosure + +If an attacker can make your program call the `Buffer` constructor with a `Number` +argument, then they can make it allocate uninitialized memory from the node.js process. +This could potentially disclose TLS private keys, user data, or database passwords. + +When the `Buffer` constructor is passed a `Number` argument, it returns an +**UNINITIALIZED** block of memory of the specified `size`. When you create a `Buffer` like +this, you **MUST** overwrite the contents before returning it to the user. + +From the [node.js docs](https://nodejs.org/api/buffer.html#buffer_new_buffer_size): + +> `new Buffer(size)` +> +> - `size` Number +> +> The underlying memory for `Buffer` instances created in this way is not initialized. +> **The contents of a newly created `Buffer` are unknown and could contain sensitive +> data.** Use `buf.fill(0)` to initialize a Buffer to zeroes. + +(Emphasis our own.) + +Whenever the programmer intended to create an uninitialized `Buffer` you often see code +like this: + +```js +var buf = new Buffer(16) + +// Immediately overwrite the uninitialized buffer with data from another buffer +for (var i = 0; i < buf.length; i++) { + buf[i] = otherBuf[i] +} +``` + + +### Would this ever be a problem in real code? + +Yes. It's surprisingly common to forget to check the type of your variables in a +dynamically-typed language like JavaScript. + +Usually the consequences of assuming the wrong type is that your program crashes with an +uncaught exception. But the failure mode for forgetting to check the type of arguments to +the `Buffer` constructor is more catastrophic. + +Here's an example of a vulnerable service that takes a JSON payload and converts it to +hex: + +```js +// Take a JSON payload {str: "some string"} and convert it to hex +var server = http.createServer(function (req, res) { + var data = '' + req.setEncoding('utf8') + req.on('data', function (chunk) { + data += chunk + }) + req.on('end', function () { + var body = JSON.parse(data) + res.end(new Buffer(body.str).toString('hex')) + }) +}) + +server.listen(8080) +``` + +In this example, an http client just has to send: + +```json +{ + "str": 1000 +} +``` + +and it will get back 1,000 bytes of uninitialized memory from the server. + +This is a very serious bug. It's similar in severity to the +[the Heartbleed bug](http://heartbleed.com/) that allowed disclosure of OpenSSL process +memory by remote attackers. + + +### Which real-world packages were vulnerable? + +#### [`bittorrent-dht`](https://www.npmjs.com/package/bittorrent-dht) + +[Mathias Buus](https://github.com/mafintosh) and I +([Feross Aboukhadijeh](http://feross.org/)) found this issue in one of our own packages, +[`bittorrent-dht`](https://www.npmjs.com/package/bittorrent-dht). The bug would allow +anyone on the internet to send a series of messages to a user of `bittorrent-dht` and get +them to reveal 20 bytes at a time of uninitialized memory from the node.js process. + +Here's +[the commit](https://github.com/feross/bittorrent-dht/commit/6c7da04025d5633699800a99ec3fbadf70ad35b8) +that fixed it. We released a new fixed version, created a +[Node Security Project disclosure](https://nodesecurity.io/advisories/68), and deprecated all +vulnerable versions on npm so users will get a warning to upgrade to a newer version. + +#### [`ws`](https://www.npmjs.com/package/ws) + +That got us wondering if there were other vulnerable packages. Sure enough, within a short +period of time, we found the same issue in [`ws`](https://www.npmjs.com/package/ws), the +most popular WebSocket implementation in node.js. + +If certain APIs were called with `Number` parameters instead of `String` or `Buffer` as +expected, then uninitialized server memory would be disclosed to the remote peer. + +These were the vulnerable methods: + +```js +socket.send(number) +socket.ping(number) +socket.pong(number) +``` + +Here's a vulnerable socket server with some echo functionality: + +```js +server.on('connection', function (socket) { + socket.on('message', function (message) { + message = JSON.parse(message) + if (message.type === 'echo') { + socket.send(message.data) // send back the user's message + } + }) +}) +``` + +`socket.send(number)` called on the server, will disclose server memory. + +Here's [the release](https://github.com/websockets/ws/releases/tag/1.0.1) where the issue +was fixed, with a more detailed explanation. Props to +[Arnout Kazemier](https://github.com/3rd-Eden) for the quick fix. Here's the +[Node Security Project disclosure](https://nodesecurity.io/advisories/67). + + +### What's the solution? + +It's important that node.js offers a fast way to get memory otherwise performance-critical +applications would needlessly get a lot slower. + +But we need a better way to *signal our intent* as programmers. **When we want +uninitialized memory, we should request it explicitly.** + +Sensitive functionality should not be packed into a developer-friendly API that loosely +accepts many different types. This type of API encourages the lazy practice of passing +variables in without checking the type very carefully. + +#### A new API: `Buffer.allocUnsafe(number)` + +The functionality of creating buffers with uninitialized memory should be part of another +API. We propose `Buffer.allocUnsafe(number)`. This way, it's not part of an API that +frequently gets user input of all sorts of different types passed into it. + +```js +var buf = Buffer.allocUnsafe(16) // careful, uninitialized memory! + +// Immediately overwrite the uninitialized buffer with data from another buffer +for (var i = 0; i < buf.length; i++) { + buf[i] = otherBuf[i] +} +``` + + +### How do we fix node.js core? + +We sent [a PR to node.js core](https://github.com/nodejs/node/pull/4514) (merged as +`semver-major`) which defends against one case: + +```js +var str = 16 +new Buffer(str, 'utf8') +``` + +In this situation, it's implied that the programmer intended the first argument to be a +string, since they passed an encoding as a second argument. Today, node.js will allocate +uninitialized memory in the case of `new Buffer(number, encoding)`, which is probably not +what the programmer intended. + +But this is only a partial solution, since if the programmer does `new Buffer(variable)` +(without an `encoding` parameter) there's no way to know what they intended. If `variable` +is sometimes a number, then uninitialized memory will sometimes be returned. + +### What's the real long-term fix? + +We could deprecate and remove `new Buffer(number)` and use `Buffer.allocUnsafe(number)` when +we need uninitialized memory. But that would break 1000s of packages. + +~~We believe the best solution is to:~~ + +~~1. Change `new Buffer(number)` to return safe, zeroed-out memory~~ + +~~2. Create a new API for creating uninitialized Buffers. We propose: `Buffer.allocUnsafe(number)`~~ + +#### Update + +We now support adding three new APIs: + +- `Buffer.from(value)` - convert from any type to a buffer +- `Buffer.alloc(size)` - create a zero-filled buffer +- `Buffer.allocUnsafe(size)` - create an uninitialized buffer with given size + +This solves the core problem that affected `ws` and `bittorrent-dht` which is +`Buffer(variable)` getting tricked into taking a number argument. + +This way, existing code continues working and the impact on the npm ecosystem will be +minimal. Over time, npm maintainers can migrate performance-critical code to use +`Buffer.allocUnsafe(number)` instead of `new Buffer(number)`. + + +### Conclusion + +We think there's a serious design issue with the `Buffer` API as it exists today. It +promotes insecure software by putting high-risk functionality into a convenient API +with friendly "developer ergonomics". + +This wasn't merely a theoretical exercise because we found the issue in some of the +most popular npm packages. + +Fortunately, there's an easy fix that can be applied today. Use `safe-buffer` in place of +`buffer`. + +```js +var Buffer = require('safe-buffer').Buffer +``` + +Eventually, we hope that node.js core can switch to this new, safer behavior. We believe +the impact on the ecosystem would be minimal since it's not a breaking change. +Well-maintained, popular packages would be updated to use `Buffer.alloc` quickly, while +older, insecure packages would magically become safe from this attack vector. + + +## links + +- [Node.js PR: buffer: throw if both length and enc are passed](https://github.com/nodejs/node/pull/4514) +- [Node Security Project disclosure for `ws`](https://nodesecurity.io/advisories/67) +- [Node Security Project disclosure for`bittorrent-dht`](https://nodesecurity.io/advisories/68) + + +## credit + +The original issues in `bittorrent-dht` +([disclosure](https://nodesecurity.io/advisories/68)) and +`ws` ([disclosure](https://nodesecurity.io/advisories/67)) were discovered by +[Mathias Buus](https://github.com/mafintosh) and +[Feross Aboukhadijeh](http://feross.org/). + +Thanks to [Adam Baldwin](https://github.com/evilpacket) for helping disclose these issues +and for his work running the [Node Security Project](https://nodesecurity.io/). + +Thanks to [John Hiesey](https://github.com/jhiesey) for proofreading this README and +auditing the code. + + +## license + +MIT. Copyright (C) [Feross Aboukhadijeh](http://feross.org) diff --git a/jwt-scratch/src/js/node_modules/safe-buffer/index.d.ts b/jwt-scratch/src/js/node_modules/safe-buffer/index.d.ts new file mode 100644 index 0000000..e9fed80 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/safe-buffer/index.d.ts @@ -0,0 +1,187 @@ +declare module "safe-buffer" { + export class Buffer { + length: number + write(string: string, offset?: number, length?: number, encoding?: string): number; + toString(encoding?: string, start?: number, end?: number): string; + toJSON(): { type: 'Buffer', data: any[] }; + equals(otherBuffer: Buffer): boolean; + compare(otherBuffer: Buffer, targetStart?: number, targetEnd?: number, sourceStart?: number, sourceEnd?: number): number; + copy(targetBuffer: Buffer, targetStart?: number, sourceStart?: number, sourceEnd?: number): number; + slice(start?: number, end?: number): Buffer; + writeUIntLE(value: number, offset: number, byteLength: number, noAssert?: boolean): number; + writeUIntBE(value: number, offset: number, byteLength: number, noAssert?: boolean): number; + writeIntLE(value: number, offset: number, byteLength: number, noAssert?: boolean): number; + writeIntBE(value: number, offset: number, byteLength: number, noAssert?: boolean): number; + readUIntLE(offset: number, byteLength: number, noAssert?: boolean): number; + readUIntBE(offset: number, byteLength: number, noAssert?: boolean): number; + readIntLE(offset: number, byteLength: number, noAssert?: boolean): number; + readIntBE(offset: number, byteLength: number, noAssert?: boolean): number; + readUInt8(offset: number, noAssert?: boolean): number; + readUInt16LE(offset: number, noAssert?: boolean): number; + readUInt16BE(offset: number, noAssert?: boolean): number; + readUInt32LE(offset: number, noAssert?: boolean): number; + readUInt32BE(offset: number, noAssert?: boolean): number; + readInt8(offset: number, noAssert?: boolean): number; + readInt16LE(offset: number, noAssert?: boolean): number; + readInt16BE(offset: number, noAssert?: boolean): number; + readInt32LE(offset: number, noAssert?: boolean): number; + readInt32BE(offset: number, noAssert?: boolean): number; + readFloatLE(offset: number, noAssert?: boolean): number; + readFloatBE(offset: number, noAssert?: boolean): number; + readDoubleLE(offset: number, noAssert?: boolean): number; + readDoubleBE(offset: number, noAssert?: boolean): number; + swap16(): Buffer; + swap32(): Buffer; + swap64(): Buffer; + writeUInt8(value: number, offset: number, noAssert?: boolean): number; + writeUInt16LE(value: number, offset: number, noAssert?: boolean): number; + writeUInt16BE(value: number, offset: number, noAssert?: boolean): number; + writeUInt32LE(value: number, offset: number, noAssert?: boolean): number; + writeUInt32BE(value: number, offset: number, noAssert?: boolean): number; + writeInt8(value: number, offset: number, noAssert?: boolean): number; + writeInt16LE(value: number, offset: number, noAssert?: boolean): number; + writeInt16BE(value: number, offset: number, noAssert?: boolean): number; + writeInt32LE(value: number, offset: number, noAssert?: boolean): number; + writeInt32BE(value: number, offset: number, noAssert?: boolean): number; + writeFloatLE(value: number, offset: number, noAssert?: boolean): number; + writeFloatBE(value: number, offset: number, noAssert?: boolean): number; + writeDoubleLE(value: number, offset: number, noAssert?: boolean): number; + writeDoubleBE(value: number, offset: number, noAssert?: boolean): number; + fill(value: any, offset?: number, end?: number): this; + indexOf(value: string | number | Buffer, byteOffset?: number, encoding?: string): number; + lastIndexOf(value: string | number | Buffer, byteOffset?: number, encoding?: string): number; + includes(value: string | number | Buffer, byteOffset?: number, encoding?: string): boolean; + + /** + * Allocates a new buffer containing the given {str}. + * + * @param str String to store in buffer. + * @param encoding encoding to use, optional. Default is 'utf8' + */ + constructor (str: string, encoding?: string); + /** + * Allocates a new buffer of {size} octets. + * + * @param size count of octets to allocate. + */ + constructor (size: number); + /** + * Allocates a new buffer containing the given {array} of octets. + * + * @param array The octets to store. + */ + constructor (array: Uint8Array); + /** + * Produces a Buffer backed by the same allocated memory as + * the given {ArrayBuffer}. + * + * + * @param arrayBuffer The ArrayBuffer with which to share memory. + */ + constructor (arrayBuffer: ArrayBuffer); + /** + * Allocates a new buffer containing the given {array} of octets. + * + * @param array The octets to store. + */ + constructor (array: any[]); + /** + * Copies the passed {buffer} data onto a new {Buffer} instance. + * + * @param buffer The buffer to copy. + */ + constructor (buffer: Buffer); + prototype: Buffer; + /** + * Allocates a new Buffer using an {array} of octets. + * + * @param array + */ + static from(array: any[]): Buffer; + /** + * When passed a reference to the .buffer property of a TypedArray instance, + * the newly created Buffer will share the same allocated memory as the TypedArray. + * The optional {byteOffset} and {length} arguments specify a memory range + * within the {arrayBuffer} that will be shared by the Buffer. + * + * @param arrayBuffer The .buffer property of a TypedArray or a new ArrayBuffer() + * @param byteOffset + * @param length + */ + static from(arrayBuffer: ArrayBuffer, byteOffset?: number, length?: number): Buffer; + /** + * Copies the passed {buffer} data onto a new Buffer instance. + * + * @param buffer + */ + static from(buffer: Buffer): Buffer; + /** + * Creates a new Buffer containing the given JavaScript string {str}. + * If provided, the {encoding} parameter identifies the character encoding. + * If not provided, {encoding} defaults to 'utf8'. + * + * @param str + */ + static from(str: string, encoding?: string): Buffer; + /** + * Returns true if {obj} is a Buffer + * + * @param obj object to test. + */ + static isBuffer(obj: any): obj is Buffer; + /** + * Returns true if {encoding} is a valid encoding argument. + * Valid string encodings in Node 0.12: 'ascii'|'utf8'|'utf16le'|'ucs2'(alias of 'utf16le')|'base64'|'binary'(deprecated)|'hex' + * + * @param encoding string to test. + */ + static isEncoding(encoding: string): boolean; + /** + * Gives the actual byte length of a string. encoding defaults to 'utf8'. + * This is not the same as String.prototype.length since that returns the number of characters in a string. + * + * @param string string to test. + * @param encoding encoding used to evaluate (defaults to 'utf8') + */ + static byteLength(string: string, encoding?: string): number; + /** + * Returns a buffer which is the result of concatenating all the buffers in the list together. + * + * If the list has no items, or if the totalLength is 0, then it returns a zero-length buffer. + * If the list has exactly one item, then the first item of the list is returned. + * If the list has more than one item, then a new Buffer is created. + * + * @param list An array of Buffer objects to concatenate + * @param totalLength Total length of the buffers when concatenated. + * If totalLength is not provided, it is read from the buffers in the list. However, this adds an additional loop to the function, so it is faster to provide the length explicitly. + */ + static concat(list: Buffer[], totalLength?: number): Buffer; + /** + * The same as buf1.compare(buf2). + */ + static compare(buf1: Buffer, buf2: Buffer): number; + /** + * Allocates a new buffer of {size} octets. + * + * @param size count of octets to allocate. + * @param fill if specified, buffer will be initialized by calling buf.fill(fill). + * If parameter is omitted, buffer will be filled with zeros. + * @param encoding encoding used for call to buf.fill while initalizing + */ + static alloc(size: number, fill?: string | Buffer | number, encoding?: string): Buffer; + /** + * Allocates a new buffer of {size} octets, leaving memory not initialized, so the contents + * of the newly created Buffer are unknown and may contain sensitive data. + * + * @param size count of octets to allocate + */ + static allocUnsafe(size: number): Buffer; + /** + * Allocates a new non-pooled buffer of {size} octets, leaving memory not initialized, so the contents + * of the newly created Buffer are unknown and may contain sensitive data. + * + * @param size count of octets to allocate + */ + static allocUnsafeSlow(size: number): Buffer; + } +} \ No newline at end of file diff --git a/jwt-scratch/src/js/node_modules/safe-buffer/index.js b/jwt-scratch/src/js/node_modules/safe-buffer/index.js new file mode 100644 index 0000000..f8d3ec9 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/safe-buffer/index.js @@ -0,0 +1,65 @@ +/*! safe-buffer. MIT License. Feross Aboukhadijeh */ +/* eslint-disable node/no-deprecated-api */ +var buffer = require('buffer') +var Buffer = buffer.Buffer + +// alternative to using Object.keys for old browsers +function copyProps (src, dst) { + for (var key in src) { + dst[key] = src[key] + } +} +if (Buffer.from && Buffer.alloc && Buffer.allocUnsafe && Buffer.allocUnsafeSlow) { + module.exports = buffer +} else { + // Copy properties from require('buffer') + copyProps(buffer, exports) + exports.Buffer = SafeBuffer +} + +function SafeBuffer (arg, encodingOrOffset, length) { + return Buffer(arg, encodingOrOffset, length) +} + +SafeBuffer.prototype = Object.create(Buffer.prototype) + +// Copy static methods from Buffer +copyProps(Buffer, SafeBuffer) + +SafeBuffer.from = function (arg, encodingOrOffset, length) { + if (typeof arg === 'number') { + throw new TypeError('Argument must not be a number') + } + return Buffer(arg, encodingOrOffset, length) +} + +SafeBuffer.alloc = function (size, fill, encoding) { + if (typeof size !== 'number') { + throw new TypeError('Argument must be a number') + } + var buf = Buffer(size) + if (fill !== undefined) { + if (typeof encoding === 'string') { + buf.fill(fill, encoding) + } else { + buf.fill(fill) + } + } else { + buf.fill(0) + } + return buf +} + +SafeBuffer.allocUnsafe = function (size) { + if (typeof size !== 'number') { + throw new TypeError('Argument must be a number') + } + return Buffer(size) +} + +SafeBuffer.allocUnsafeSlow = function (size) { + if (typeof size !== 'number') { + throw new TypeError('Argument must be a number') + } + return buffer.SlowBuffer(size) +} diff --git a/jwt-scratch/src/js/node_modules/safe-buffer/package.json b/jwt-scratch/src/js/node_modules/safe-buffer/package.json new file mode 100644 index 0000000..c93d28e --- /dev/null +++ b/jwt-scratch/src/js/node_modules/safe-buffer/package.json @@ -0,0 +1,78 @@ +{ + "_from": "safe-buffer@^5.0.1", + "_id": "safe-buffer@5.2.1", + "_inBundle": false, + "_integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==", + "_location": "/safe-buffer", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "safe-buffer@^5.0.1", + "name": "safe-buffer", + "escapedName": "safe-buffer", + "rawSpec": "^5.0.1", + "saveSpec": null, + "fetchSpec": "^5.0.1" + }, + "_requiredBy": [ + "/ecdsa-sig-formatter", + "/jwa", + "/jws" + ], + "_resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "_shasum": "1eaf9fa9bdb1fdd4ec75f58f9cdb4e6b7827eec6", + "_spec": "safe-buffer@^5.0.1", + "_where": "/home/rock64/git/qseow-scripts/jwt-scratch/src/js/node_modules/jws", + "author": { + "name": "Feross Aboukhadijeh", + "email": "feross@feross.org", + "url": "https://feross.org" + }, + "bugs": { + "url": "https://github.com/feross/safe-buffer/issues" + }, + "bundleDependencies": false, + "deprecated": false, + "description": "Safer Node.js Buffer API", + "devDependencies": { + "standard": "*", + "tape": "^5.0.0" + }, + "funding": [ + { + "type": "github", + "url": "https://github.com/sponsors/feross" + }, + { + "type": "patreon", + "url": "https://www.patreon.com/feross" + }, + { + "type": "consulting", + "url": "https://feross.org/support" + } + ], + "homepage": "https://github.com/feross/safe-buffer", + "keywords": [ + "buffer", + "buffer allocate", + "node security", + "safe", + "safe-buffer", + "security", + "uninitialized" + ], + "license": "MIT", + "main": "index.js", + "name": "safe-buffer", + "repository": { + "type": "git", + "url": "git://github.com/feross/safe-buffer.git" + }, + "scripts": { + "test": "standard && tape test/*.js" + }, + "types": "index.d.ts", + "version": "5.2.1" +} diff --git a/jwt-scratch/src/js/node_modules/semver/CHANGELOG.md b/jwt-scratch/src/js/node_modules/semver/CHANGELOG.md new file mode 100644 index 0000000..66304fd --- /dev/null +++ b/jwt-scratch/src/js/node_modules/semver/CHANGELOG.md @@ -0,0 +1,39 @@ +# changes log + +## 5.7 + +* Add `minVersion` method + +## 5.6 + +* Move boolean `loose` param to an options object, with + backwards-compatibility protection. +* Add ability to opt out of special prerelease version handling with + the `includePrerelease` option flag. + +## 5.5 + +* Add version coercion capabilities + +## 5.4 + +* Add intersection checking + +## 5.3 + +* Add `minSatisfying` method + +## 5.2 + +* Add `prerelease(v)` that returns prerelease components + +## 5.1 + +* Add Backus-Naur for ranges +* Remove excessively cute inspection methods + +## 5.0 + +* Remove AMD/Browserified build artifacts +* Fix ltr and gtr when using the `*` range +* Fix for range `*` with a prerelease identifier diff --git a/jwt-scratch/src/js/node_modules/semver/LICENSE b/jwt-scratch/src/js/node_modules/semver/LICENSE new file mode 100644 index 0000000..19129e3 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/semver/LICENSE @@ -0,0 +1,15 @@ +The ISC License + +Copyright (c) Isaac Z. Schlueter and Contributors + +Permission to use, copy, modify, and/or distribute this software for any +purpose with or without fee is hereby granted, provided that the above +copyright notice and this permission notice appear in all copies. + +THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR +IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. diff --git a/jwt-scratch/src/js/node_modules/semver/README.md b/jwt-scratch/src/js/node_modules/semver/README.md new file mode 100644 index 0000000..f8dfa5a --- /dev/null +++ b/jwt-scratch/src/js/node_modules/semver/README.md @@ -0,0 +1,412 @@ +semver(1) -- The semantic versioner for npm +=========================================== + +## Install + +```bash +npm install --save semver +```` + +## Usage + +As a node module: + +```js +const semver = require('semver') + +semver.valid('1.2.3') // '1.2.3' +semver.valid('a.b.c') // null +semver.clean(' =v1.2.3 ') // '1.2.3' +semver.satisfies('1.2.3', '1.x || >=2.5.0 || 5.0.0 - 7.2.3') // true +semver.gt('1.2.3', '9.8.7') // false +semver.lt('1.2.3', '9.8.7') // true +semver.minVersion('>=1.0.0') // '1.0.0' +semver.valid(semver.coerce('v2')) // '2.0.0' +semver.valid(semver.coerce('42.6.7.9.3-alpha')) // '42.6.7' +``` + +As a command-line utility: + +``` +$ semver -h + +A JavaScript implementation of the https://semver.org/ specification +Copyright Isaac Z. Schlueter + +Usage: semver [options] [ [...]] +Prints valid versions sorted by SemVer precedence + +Options: +-r --range + Print versions that match the specified range. + +-i --increment [] + Increment a version by the specified level. Level can + be one of: major, minor, patch, premajor, preminor, + prepatch, or prerelease. Default level is 'patch'. + Only one version may be specified. + +--preid + Identifier to be used to prefix premajor, preminor, + prepatch or prerelease version increments. + +-l --loose + Interpret versions and ranges loosely + +-p --include-prerelease + Always include prerelease versions in range matching + +-c --coerce + Coerce a string into SemVer if possible + (does not imply --loose) + +Program exits successfully if any valid version satisfies +all supplied ranges, and prints all satisfying versions. + +If no satisfying versions are found, then exits failure. + +Versions are printed in ascending order, so supplying +multiple versions to the utility will just sort them. +``` + +## Versions + +A "version" is described by the `v2.0.0` specification found at +. + +A leading `"="` or `"v"` character is stripped off and ignored. + +## Ranges + +A `version range` is a set of `comparators` which specify versions +that satisfy the range. + +A `comparator` is composed of an `operator` and a `version`. The set +of primitive `operators` is: + +* `<` Less than +* `<=` Less than or equal to +* `>` Greater than +* `>=` Greater than or equal to +* `=` Equal. If no operator is specified, then equality is assumed, + so this operator is optional, but MAY be included. + +For example, the comparator `>=1.2.7` would match the versions +`1.2.7`, `1.2.8`, `2.5.3`, and `1.3.9`, but not the versions `1.2.6` +or `1.1.0`. + +Comparators can be joined by whitespace to form a `comparator set`, +which is satisfied by the **intersection** of all of the comparators +it includes. + +A range is composed of one or more comparator sets, joined by `||`. A +version matches a range if and only if every comparator in at least +one of the `||`-separated comparator sets is satisfied by the version. + +For example, the range `>=1.2.7 <1.3.0` would match the versions +`1.2.7`, `1.2.8`, and `1.2.99`, but not the versions `1.2.6`, `1.3.0`, +or `1.1.0`. + +The range `1.2.7 || >=1.2.9 <2.0.0` would match the versions `1.2.7`, +`1.2.9`, and `1.4.6`, but not the versions `1.2.8` or `2.0.0`. + +### Prerelease Tags + +If a version has a prerelease tag (for example, `1.2.3-alpha.3`) then +it will only be allowed to satisfy comparator sets if at least one +comparator with the same `[major, minor, patch]` tuple also has a +prerelease tag. + +For example, the range `>1.2.3-alpha.3` would be allowed to match the +version `1.2.3-alpha.7`, but it would *not* be satisfied by +`3.4.5-alpha.9`, even though `3.4.5-alpha.9` is technically "greater +than" `1.2.3-alpha.3` according to the SemVer sort rules. The version +range only accepts prerelease tags on the `1.2.3` version. The +version `3.4.5` *would* satisfy the range, because it does not have a +prerelease flag, and `3.4.5` is greater than `1.2.3-alpha.7`. + +The purpose for this behavior is twofold. First, prerelease versions +frequently are updated very quickly, and contain many breaking changes +that are (by the author's design) not yet fit for public consumption. +Therefore, by default, they are excluded from range matching +semantics. + +Second, a user who has opted into using a prerelease version has +clearly indicated the intent to use *that specific* set of +alpha/beta/rc versions. By including a prerelease tag in the range, +the user is indicating that they are aware of the risk. However, it +is still not appropriate to assume that they have opted into taking a +similar risk on the *next* set of prerelease versions. + +Note that this behavior can be suppressed (treating all prerelease +versions as if they were normal versions, for the purpose of range +matching) by setting the `includePrerelease` flag on the options +object to any +[functions](https://github.com/npm/node-semver#functions) that do +range matching. + +#### Prerelease Identifiers + +The method `.inc` takes an additional `identifier` string argument that +will append the value of the string as a prerelease identifier: + +```javascript +semver.inc('1.2.3', 'prerelease', 'beta') +// '1.2.4-beta.0' +``` + +command-line example: + +```bash +$ semver 1.2.3 -i prerelease --preid beta +1.2.4-beta.0 +``` + +Which then can be used to increment further: + +```bash +$ semver 1.2.4-beta.0 -i prerelease +1.2.4-beta.1 +``` + +### Advanced Range Syntax + +Advanced range syntax desugars to primitive comparators in +deterministic ways. + +Advanced ranges may be combined in the same way as primitive +comparators using white space or `||`. + +#### Hyphen Ranges `X.Y.Z - A.B.C` + +Specifies an inclusive set. + +* `1.2.3 - 2.3.4` := `>=1.2.3 <=2.3.4` + +If a partial version is provided as the first version in the inclusive +range, then the missing pieces are replaced with zeroes. + +* `1.2 - 2.3.4` := `>=1.2.0 <=2.3.4` + +If a partial version is provided as the second version in the +inclusive range, then all versions that start with the supplied parts +of the tuple are accepted, but nothing that would be greater than the +provided tuple parts. + +* `1.2.3 - 2.3` := `>=1.2.3 <2.4.0` +* `1.2.3 - 2` := `>=1.2.3 <3.0.0` + +#### X-Ranges `1.2.x` `1.X` `1.2.*` `*` + +Any of `X`, `x`, or `*` may be used to "stand in" for one of the +numeric values in the `[major, minor, patch]` tuple. + +* `*` := `>=0.0.0` (Any version satisfies) +* `1.x` := `>=1.0.0 <2.0.0` (Matching major version) +* `1.2.x` := `>=1.2.0 <1.3.0` (Matching major and minor versions) + +A partial version range is treated as an X-Range, so the special +character is in fact optional. + +* `""` (empty string) := `*` := `>=0.0.0` +* `1` := `1.x.x` := `>=1.0.0 <2.0.0` +* `1.2` := `1.2.x` := `>=1.2.0 <1.3.0` + +#### Tilde Ranges `~1.2.3` `~1.2` `~1` + +Allows patch-level changes if a minor version is specified on the +comparator. Allows minor-level changes if not. + +* `~1.2.3` := `>=1.2.3 <1.(2+1).0` := `>=1.2.3 <1.3.0` +* `~1.2` := `>=1.2.0 <1.(2+1).0` := `>=1.2.0 <1.3.0` (Same as `1.2.x`) +* `~1` := `>=1.0.0 <(1+1).0.0` := `>=1.0.0 <2.0.0` (Same as `1.x`) +* `~0.2.3` := `>=0.2.3 <0.(2+1).0` := `>=0.2.3 <0.3.0` +* `~0.2` := `>=0.2.0 <0.(2+1).0` := `>=0.2.0 <0.3.0` (Same as `0.2.x`) +* `~0` := `>=0.0.0 <(0+1).0.0` := `>=0.0.0 <1.0.0` (Same as `0.x`) +* `~1.2.3-beta.2` := `>=1.2.3-beta.2 <1.3.0` Note that prereleases in + the `1.2.3` version will be allowed, if they are greater than or + equal to `beta.2`. So, `1.2.3-beta.4` would be allowed, but + `1.2.4-beta.2` would not, because it is a prerelease of a + different `[major, minor, patch]` tuple. + +#### Caret Ranges `^1.2.3` `^0.2.5` `^0.0.4` + +Allows changes that do not modify the left-most non-zero digit in the +`[major, minor, patch]` tuple. In other words, this allows patch and +minor updates for versions `1.0.0` and above, patch updates for +versions `0.X >=0.1.0`, and *no* updates for versions `0.0.X`. + +Many authors treat a `0.x` version as if the `x` were the major +"breaking-change" indicator. + +Caret ranges are ideal when an author may make breaking changes +between `0.2.4` and `0.3.0` releases, which is a common practice. +However, it presumes that there will *not* be breaking changes between +`0.2.4` and `0.2.5`. It allows for changes that are presumed to be +additive (but non-breaking), according to commonly observed practices. + +* `^1.2.3` := `>=1.2.3 <2.0.0` +* `^0.2.3` := `>=0.2.3 <0.3.0` +* `^0.0.3` := `>=0.0.3 <0.0.4` +* `^1.2.3-beta.2` := `>=1.2.3-beta.2 <2.0.0` Note that prereleases in + the `1.2.3` version will be allowed, if they are greater than or + equal to `beta.2`. So, `1.2.3-beta.4` would be allowed, but + `1.2.4-beta.2` would not, because it is a prerelease of a + different `[major, minor, patch]` tuple. +* `^0.0.3-beta` := `>=0.0.3-beta <0.0.4` Note that prereleases in the + `0.0.3` version *only* will be allowed, if they are greater than or + equal to `beta`. So, `0.0.3-pr.2` would be allowed. + +When parsing caret ranges, a missing `patch` value desugars to the +number `0`, but will allow flexibility within that value, even if the +major and minor versions are both `0`. + +* `^1.2.x` := `>=1.2.0 <2.0.0` +* `^0.0.x` := `>=0.0.0 <0.1.0` +* `^0.0` := `>=0.0.0 <0.1.0` + +A missing `minor` and `patch` values will desugar to zero, but also +allow flexibility within those values, even if the major version is +zero. + +* `^1.x` := `>=1.0.0 <2.0.0` +* `^0.x` := `>=0.0.0 <1.0.0` + +### Range Grammar + +Putting all this together, here is a Backus-Naur grammar for ranges, +for the benefit of parser authors: + +```bnf +range-set ::= range ( logical-or range ) * +logical-or ::= ( ' ' ) * '||' ( ' ' ) * +range ::= hyphen | simple ( ' ' simple ) * | '' +hyphen ::= partial ' - ' partial +simple ::= primitive | partial | tilde | caret +primitive ::= ( '<' | '>' | '>=' | '<=' | '=' ) partial +partial ::= xr ( '.' xr ( '.' xr qualifier ? )? )? +xr ::= 'x' | 'X' | '*' | nr +nr ::= '0' | ['1'-'9'] ( ['0'-'9'] ) * +tilde ::= '~' partial +caret ::= '^' partial +qualifier ::= ( '-' pre )? ( '+' build )? +pre ::= parts +build ::= parts +parts ::= part ( '.' part ) * +part ::= nr | [-0-9A-Za-z]+ +``` + +## Functions + +All methods and classes take a final `options` object argument. All +options in this object are `false` by default. The options supported +are: + +- `loose` Be more forgiving about not-quite-valid semver strings. + (Any resulting output will always be 100% strict compliant, of + course.) For backwards compatibility reasons, if the `options` + argument is a boolean value instead of an object, it is interpreted + to be the `loose` param. +- `includePrerelease` Set to suppress the [default + behavior](https://github.com/npm/node-semver#prerelease-tags) of + excluding prerelease tagged versions from ranges unless they are + explicitly opted into. + +Strict-mode Comparators and Ranges will be strict about the SemVer +strings that they parse. + +* `valid(v)`: Return the parsed version, or null if it's not valid. +* `inc(v, release)`: Return the version incremented by the release + type (`major`, `premajor`, `minor`, `preminor`, `patch`, + `prepatch`, or `prerelease`), or null if it's not valid + * `premajor` in one call will bump the version up to the next major + version and down to a prerelease of that major version. + `preminor`, and `prepatch` work the same way. + * If called from a non-prerelease version, the `prerelease` will work the + same as `prepatch`. It increments the patch version, then makes a + prerelease. If the input version is already a prerelease it simply + increments it. +* `prerelease(v)`: Returns an array of prerelease components, or null + if none exist. Example: `prerelease('1.2.3-alpha.1') -> ['alpha', 1]` +* `major(v)`: Return the major version number. +* `minor(v)`: Return the minor version number. +* `patch(v)`: Return the patch version number. +* `intersects(r1, r2, loose)`: Return true if the two supplied ranges + or comparators intersect. +* `parse(v)`: Attempt to parse a string as a semantic version, returning either + a `SemVer` object or `null`. + +### Comparison + +* `gt(v1, v2)`: `v1 > v2` +* `gte(v1, v2)`: `v1 >= v2` +* `lt(v1, v2)`: `v1 < v2` +* `lte(v1, v2)`: `v1 <= v2` +* `eq(v1, v2)`: `v1 == v2` This is true if they're logically equivalent, + even if they're not the exact same string. You already know how to + compare strings. +* `neq(v1, v2)`: `v1 != v2` The opposite of `eq`. +* `cmp(v1, comparator, v2)`: Pass in a comparison string, and it'll call + the corresponding function above. `"==="` and `"!=="` do simple + string comparison, but are included for completeness. Throws if an + invalid comparison string is provided. +* `compare(v1, v2)`: Return `0` if `v1 == v2`, or `1` if `v1` is greater, or `-1` if + `v2` is greater. Sorts in ascending order if passed to `Array.sort()`. +* `rcompare(v1, v2)`: The reverse of compare. Sorts an array of versions + in descending order when passed to `Array.sort()`. +* `diff(v1, v2)`: Returns difference between two versions by the release type + (`major`, `premajor`, `minor`, `preminor`, `patch`, `prepatch`, or `prerelease`), + or null if the versions are the same. + +### Comparators + +* `intersects(comparator)`: Return true if the comparators intersect + +### Ranges + +* `validRange(range)`: Return the valid range or null if it's not valid +* `satisfies(version, range)`: Return true if the version satisfies the + range. +* `maxSatisfying(versions, range)`: Return the highest version in the list + that satisfies the range, or `null` if none of them do. +* `minSatisfying(versions, range)`: Return the lowest version in the list + that satisfies the range, or `null` if none of them do. +* `minVersion(range)`: Return the lowest version that can possibly match + the given range. +* `gtr(version, range)`: Return `true` if version is greater than all the + versions possible in the range. +* `ltr(version, range)`: Return `true` if version is less than all the + versions possible in the range. +* `outside(version, range, hilo)`: Return true if the version is outside + the bounds of the range in either the high or low direction. The + `hilo` argument must be either the string `'>'` or `'<'`. (This is + the function called by `gtr` and `ltr`.) +* `intersects(range)`: Return true if any of the ranges comparators intersect + +Note that, since ranges may be non-contiguous, a version might not be +greater than a range, less than a range, *or* satisfy a range! For +example, the range `1.2 <1.2.9 || >2.0.0` would have a hole from `1.2.9` +until `2.0.0`, so the version `1.2.10` would not be greater than the +range (because `2.0.1` satisfies, which is higher), nor less than the +range (since `1.2.8` satisfies, which is lower), and it also does not +satisfy the range. + +If you want to know if a version satisfies or does not satisfy a +range, use the `satisfies(version, range)` function. + +### Coercion + +* `coerce(version)`: Coerces a string to semver if possible + +This aims to provide a very forgiving translation of a non-semver string to +semver. It looks for the first digit in a string, and consumes all +remaining characters which satisfy at least a partial semver (e.g., `1`, +`1.2`, `1.2.3`) up to the max permitted length (256 characters). Longer +versions are simply truncated (`4.6.3.9.2-alpha2` becomes `4.6.3`). All +surrounding text is simply ignored (`v3.4 replaces v3.3.1` becomes +`3.4.0`). Only text which lacks digits will fail coercion (`version one` +is not valid). The maximum length for any semver component considered for +coercion is 16 characters; longer components will be ignored +(`10000000000000000.4.7.4` becomes `4.7.4`). The maximum value for any +semver component is `Number.MAX_SAFE_INTEGER || (2**53 - 1)`; higher value +components are invalid (`9999999999999999.4.7.4` is likely invalid). diff --git a/jwt-scratch/src/js/node_modules/semver/bin/semver b/jwt-scratch/src/js/node_modules/semver/bin/semver new file mode 100755 index 0000000..801e77f --- /dev/null +++ b/jwt-scratch/src/js/node_modules/semver/bin/semver @@ -0,0 +1,160 @@ +#!/usr/bin/env node +// Standalone semver comparison program. +// Exits successfully and prints matching version(s) if +// any supplied version is valid and passes all tests. + +var argv = process.argv.slice(2) + +var versions = [] + +var range = [] + +var inc = null + +var version = require('../package.json').version + +var loose = false + +var includePrerelease = false + +var coerce = false + +var identifier + +var semver = require('../semver') + +var reverse = false + +var options = {} + +main() + +function main () { + if (!argv.length) return help() + while (argv.length) { + var a = argv.shift() + var indexOfEqualSign = a.indexOf('=') + if (indexOfEqualSign !== -1) { + a = a.slice(0, indexOfEqualSign) + argv.unshift(a.slice(indexOfEqualSign + 1)) + } + switch (a) { + case '-rv': case '-rev': case '--rev': case '--reverse': + reverse = true + break + case '-l': case '--loose': + loose = true + break + case '-p': case '--include-prerelease': + includePrerelease = true + break + case '-v': case '--version': + versions.push(argv.shift()) + break + case '-i': case '--inc': case '--increment': + switch (argv[0]) { + case 'major': case 'minor': case 'patch': case 'prerelease': + case 'premajor': case 'preminor': case 'prepatch': + inc = argv.shift() + break + default: + inc = 'patch' + break + } + break + case '--preid': + identifier = argv.shift() + break + case '-r': case '--range': + range.push(argv.shift()) + break + case '-c': case '--coerce': + coerce = true + break + case '-h': case '--help': case '-?': + return help() + default: + versions.push(a) + break + } + } + + var options = { loose: loose, includePrerelease: includePrerelease } + + versions = versions.map(function (v) { + return coerce ? (semver.coerce(v) || { version: v }).version : v + }).filter(function (v) { + return semver.valid(v) + }) + if (!versions.length) return fail() + if (inc && (versions.length !== 1 || range.length)) { return failInc() } + + for (var i = 0, l = range.length; i < l; i++) { + versions = versions.filter(function (v) { + return semver.satisfies(v, range[i], options) + }) + if (!versions.length) return fail() + } + return success(versions) +} + +function failInc () { + console.error('--inc can only be used on a single version with no range') + fail() +} + +function fail () { process.exit(1) } + +function success () { + var compare = reverse ? 'rcompare' : 'compare' + versions.sort(function (a, b) { + return semver[compare](a, b, options) + }).map(function (v) { + return semver.clean(v, options) + }).map(function (v) { + return inc ? semver.inc(v, inc, options, identifier) : v + }).forEach(function (v, i, _) { console.log(v) }) +} + +function help () { + console.log(['SemVer ' + version, + '', + 'A JavaScript implementation of the https://semver.org/ specification', + 'Copyright Isaac Z. Schlueter', + '', + 'Usage: semver [options] [ [...]]', + 'Prints valid versions sorted by SemVer precedence', + '', + 'Options:', + '-r --range ', + ' Print versions that match the specified range.', + '', + '-i --increment []', + ' Increment a version by the specified level. Level can', + ' be one of: major, minor, patch, premajor, preminor,', + " prepatch, or prerelease. Default level is 'patch'.", + ' Only one version may be specified.', + '', + '--preid ', + ' Identifier to be used to prefix premajor, preminor,', + ' prepatch or prerelease version increments.', + '', + '-l --loose', + ' Interpret versions and ranges loosely', + '', + '-p --include-prerelease', + ' Always include prerelease versions in range matching', + '', + '-c --coerce', + ' Coerce a string into SemVer if possible', + ' (does not imply --loose)', + '', + 'Program exits successfully if any valid version satisfies', + 'all supplied ranges, and prints all satisfying versions.', + '', + 'If no satisfying versions are found, then exits failure.', + '', + 'Versions are printed in ascending order, so supplying', + 'multiple versions to the utility will just sort them.' + ].join('\n')) +} diff --git a/jwt-scratch/src/js/node_modules/semver/package.json b/jwt-scratch/src/js/node_modules/semver/package.json new file mode 100644 index 0000000..de8edbd --- /dev/null +++ b/jwt-scratch/src/js/node_modules/semver/package.json @@ -0,0 +1,60 @@ +{ + "_from": "semver@^5.6.0", + "_id": "semver@5.7.1", + "_inBundle": false, + "_integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==", + "_location": "/semver", + "_phantomChildren": {}, + "_requested": { + "type": "range", + "registry": true, + "raw": "semver@^5.6.0", + "name": "semver", + "escapedName": "semver", + "rawSpec": "^5.6.0", + "saveSpec": null, + "fetchSpec": "^5.6.0" + }, + "_requiredBy": [ + "/jsonwebtoken" + ], + "_resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", + "_shasum": "a954f931aeba508d307bbf069eff0c01c96116f7", + "_spec": "semver@^5.6.0", + "_where": "/home/rock64/git/qseow-scripts/jwt-scratch/src/js/node_modules/jsonwebtoken", + "bin": { + "semver": "bin/semver" + }, + "bugs": { + "url": "https://github.com/npm/node-semver/issues" + }, + "bundleDependencies": false, + "deprecated": false, + "description": "The semantic version parser used by npm.", + "devDependencies": { + "tap": "^13.0.0-rc.18" + }, + "files": [ + "bin", + "range.bnf", + "semver.js" + ], + "homepage": "https://github.com/npm/node-semver#readme", + "license": "ISC", + "main": "semver.js", + "name": "semver", + "repository": { + "type": "git", + "url": "git+https://github.com/npm/node-semver.git" + }, + "scripts": { + "postpublish": "git push origin --all; git push origin --tags", + "postversion": "npm publish", + "preversion": "npm test", + "test": "tap" + }, + "tap": { + "check-coverage": true + }, + "version": "5.7.1" +} diff --git a/jwt-scratch/src/js/node_modules/semver/range.bnf b/jwt-scratch/src/js/node_modules/semver/range.bnf new file mode 100644 index 0000000..d4c6ae0 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/semver/range.bnf @@ -0,0 +1,16 @@ +range-set ::= range ( logical-or range ) * +logical-or ::= ( ' ' ) * '||' ( ' ' ) * +range ::= hyphen | simple ( ' ' simple ) * | '' +hyphen ::= partial ' - ' partial +simple ::= primitive | partial | tilde | caret +primitive ::= ( '<' | '>' | '>=' | '<=' | '=' ) partial +partial ::= xr ( '.' xr ( '.' xr qualifier ? )? )? +xr ::= 'x' | 'X' | '*' | nr +nr ::= '0' | [1-9] ( [0-9] ) * +tilde ::= '~' partial +caret ::= '^' partial +qualifier ::= ( '-' pre )? ( '+' build )? +pre ::= parts +build ::= parts +parts ::= part ( '.' part ) * +part ::= nr | [-0-9A-Za-z]+ diff --git a/jwt-scratch/src/js/node_modules/semver/semver.js b/jwt-scratch/src/js/node_modules/semver/semver.js new file mode 100644 index 0000000..d315d5d --- /dev/null +++ b/jwt-scratch/src/js/node_modules/semver/semver.js @@ -0,0 +1,1483 @@ +exports = module.exports = SemVer + +var debug +/* istanbul ignore next */ +if (typeof process === 'object' && + process.env && + process.env.NODE_DEBUG && + /\bsemver\b/i.test(process.env.NODE_DEBUG)) { + debug = function () { + var args = Array.prototype.slice.call(arguments, 0) + args.unshift('SEMVER') + console.log.apply(console, args) + } +} else { + debug = function () {} +} + +// Note: this is the semver.org version of the spec that it implements +// Not necessarily the package version of this code. +exports.SEMVER_SPEC_VERSION = '2.0.0' + +var MAX_LENGTH = 256 +var MAX_SAFE_INTEGER = Number.MAX_SAFE_INTEGER || + /* istanbul ignore next */ 9007199254740991 + +// Max safe segment length for coercion. +var MAX_SAFE_COMPONENT_LENGTH = 16 + +// The actual regexps go on exports.re +var re = exports.re = [] +var src = exports.src = [] +var R = 0 + +// The following Regular Expressions can be used for tokenizing, +// validating, and parsing SemVer version strings. + +// ## Numeric Identifier +// A single `0`, or a non-zero digit followed by zero or more digits. + +var NUMERICIDENTIFIER = R++ +src[NUMERICIDENTIFIER] = '0|[1-9]\\d*' +var NUMERICIDENTIFIERLOOSE = R++ +src[NUMERICIDENTIFIERLOOSE] = '[0-9]+' + +// ## Non-numeric Identifier +// Zero or more digits, followed by a letter or hyphen, and then zero or +// more letters, digits, or hyphens. + +var NONNUMERICIDENTIFIER = R++ +src[NONNUMERICIDENTIFIER] = '\\d*[a-zA-Z-][a-zA-Z0-9-]*' + +// ## Main Version +// Three dot-separated numeric identifiers. + +var MAINVERSION = R++ +src[MAINVERSION] = '(' + src[NUMERICIDENTIFIER] + ')\\.' + + '(' + src[NUMERICIDENTIFIER] + ')\\.' + + '(' + src[NUMERICIDENTIFIER] + ')' + +var MAINVERSIONLOOSE = R++ +src[MAINVERSIONLOOSE] = '(' + src[NUMERICIDENTIFIERLOOSE] + ')\\.' + + '(' + src[NUMERICIDENTIFIERLOOSE] + ')\\.' + + '(' + src[NUMERICIDENTIFIERLOOSE] + ')' + +// ## Pre-release Version Identifier +// A numeric identifier, or a non-numeric identifier. + +var PRERELEASEIDENTIFIER = R++ +src[PRERELEASEIDENTIFIER] = '(?:' + src[NUMERICIDENTIFIER] + + '|' + src[NONNUMERICIDENTIFIER] + ')' + +var PRERELEASEIDENTIFIERLOOSE = R++ +src[PRERELEASEIDENTIFIERLOOSE] = '(?:' + src[NUMERICIDENTIFIERLOOSE] + + '|' + src[NONNUMERICIDENTIFIER] + ')' + +// ## Pre-release Version +// Hyphen, followed by one or more dot-separated pre-release version +// identifiers. + +var PRERELEASE = R++ +src[PRERELEASE] = '(?:-(' + src[PRERELEASEIDENTIFIER] + + '(?:\\.' + src[PRERELEASEIDENTIFIER] + ')*))' + +var PRERELEASELOOSE = R++ +src[PRERELEASELOOSE] = '(?:-?(' + src[PRERELEASEIDENTIFIERLOOSE] + + '(?:\\.' + src[PRERELEASEIDENTIFIERLOOSE] + ')*))' + +// ## Build Metadata Identifier +// Any combination of digits, letters, or hyphens. + +var BUILDIDENTIFIER = R++ +src[BUILDIDENTIFIER] = '[0-9A-Za-z-]+' + +// ## Build Metadata +// Plus sign, followed by one or more period-separated build metadata +// identifiers. + +var BUILD = R++ +src[BUILD] = '(?:\\+(' + src[BUILDIDENTIFIER] + + '(?:\\.' + src[BUILDIDENTIFIER] + ')*))' + +// ## Full Version String +// A main version, followed optionally by a pre-release version and +// build metadata. + +// Note that the only major, minor, patch, and pre-release sections of +// the version string are capturing groups. The build metadata is not a +// capturing group, because it should not ever be used in version +// comparison. + +var FULL = R++ +var FULLPLAIN = 'v?' + src[MAINVERSION] + + src[PRERELEASE] + '?' + + src[BUILD] + '?' + +src[FULL] = '^' + FULLPLAIN + '$' + +// like full, but allows v1.2.3 and =1.2.3, which people do sometimes. +// also, 1.0.0alpha1 (prerelease without the hyphen) which is pretty +// common in the npm registry. +var LOOSEPLAIN = '[v=\\s]*' + src[MAINVERSIONLOOSE] + + src[PRERELEASELOOSE] + '?' + + src[BUILD] + '?' + +var LOOSE = R++ +src[LOOSE] = '^' + LOOSEPLAIN + '$' + +var GTLT = R++ +src[GTLT] = '((?:<|>)?=?)' + +// Something like "2.*" or "1.2.x". +// Note that "x.x" is a valid xRange identifer, meaning "any version" +// Only the first item is strictly required. +var XRANGEIDENTIFIERLOOSE = R++ +src[XRANGEIDENTIFIERLOOSE] = src[NUMERICIDENTIFIERLOOSE] + '|x|X|\\*' +var XRANGEIDENTIFIER = R++ +src[XRANGEIDENTIFIER] = src[NUMERICIDENTIFIER] + '|x|X|\\*' + +var XRANGEPLAIN = R++ +src[XRANGEPLAIN] = '[v=\\s]*(' + src[XRANGEIDENTIFIER] + ')' + + '(?:\\.(' + src[XRANGEIDENTIFIER] + ')' + + '(?:\\.(' + src[XRANGEIDENTIFIER] + ')' + + '(?:' + src[PRERELEASE] + ')?' + + src[BUILD] + '?' + + ')?)?' + +var XRANGEPLAINLOOSE = R++ +src[XRANGEPLAINLOOSE] = '[v=\\s]*(' + src[XRANGEIDENTIFIERLOOSE] + ')' + + '(?:\\.(' + src[XRANGEIDENTIFIERLOOSE] + ')' + + '(?:\\.(' + src[XRANGEIDENTIFIERLOOSE] + ')' + + '(?:' + src[PRERELEASELOOSE] + ')?' + + src[BUILD] + '?' + + ')?)?' + +var XRANGE = R++ +src[XRANGE] = '^' + src[GTLT] + '\\s*' + src[XRANGEPLAIN] + '$' +var XRANGELOOSE = R++ +src[XRANGELOOSE] = '^' + src[GTLT] + '\\s*' + src[XRANGEPLAINLOOSE] + '$' + +// Coercion. +// Extract anything that could conceivably be a part of a valid semver +var COERCE = R++ +src[COERCE] = '(?:^|[^\\d])' + + '(\\d{1,' + MAX_SAFE_COMPONENT_LENGTH + '})' + + '(?:\\.(\\d{1,' + MAX_SAFE_COMPONENT_LENGTH + '}))?' + + '(?:\\.(\\d{1,' + MAX_SAFE_COMPONENT_LENGTH + '}))?' + + '(?:$|[^\\d])' + +// Tilde ranges. +// Meaning is "reasonably at or greater than" +var LONETILDE = R++ +src[LONETILDE] = '(?:~>?)' + +var TILDETRIM = R++ +src[TILDETRIM] = '(\\s*)' + src[LONETILDE] + '\\s+' +re[TILDETRIM] = new RegExp(src[TILDETRIM], 'g') +var tildeTrimReplace = '$1~' + +var TILDE = R++ +src[TILDE] = '^' + src[LONETILDE] + src[XRANGEPLAIN] + '$' +var TILDELOOSE = R++ +src[TILDELOOSE] = '^' + src[LONETILDE] + src[XRANGEPLAINLOOSE] + '$' + +// Caret ranges. +// Meaning is "at least and backwards compatible with" +var LONECARET = R++ +src[LONECARET] = '(?:\\^)' + +var CARETTRIM = R++ +src[CARETTRIM] = '(\\s*)' + src[LONECARET] + '\\s+' +re[CARETTRIM] = new RegExp(src[CARETTRIM], 'g') +var caretTrimReplace = '$1^' + +var CARET = R++ +src[CARET] = '^' + src[LONECARET] + src[XRANGEPLAIN] + '$' +var CARETLOOSE = R++ +src[CARETLOOSE] = '^' + src[LONECARET] + src[XRANGEPLAINLOOSE] + '$' + +// A simple gt/lt/eq thing, or just "" to indicate "any version" +var COMPARATORLOOSE = R++ +src[COMPARATORLOOSE] = '^' + src[GTLT] + '\\s*(' + LOOSEPLAIN + ')$|^$' +var COMPARATOR = R++ +src[COMPARATOR] = '^' + src[GTLT] + '\\s*(' + FULLPLAIN + ')$|^$' + +// An expression to strip any whitespace between the gtlt and the thing +// it modifies, so that `> 1.2.3` ==> `>1.2.3` +var COMPARATORTRIM = R++ +src[COMPARATORTRIM] = '(\\s*)' + src[GTLT] + + '\\s*(' + LOOSEPLAIN + '|' + src[XRANGEPLAIN] + ')' + +// this one has to use the /g flag +re[COMPARATORTRIM] = new RegExp(src[COMPARATORTRIM], 'g') +var comparatorTrimReplace = '$1$2$3' + +// Something like `1.2.3 - 1.2.4` +// Note that these all use the loose form, because they'll be +// checked against either the strict or loose comparator form +// later. +var HYPHENRANGE = R++ +src[HYPHENRANGE] = '^\\s*(' + src[XRANGEPLAIN] + ')' + + '\\s+-\\s+' + + '(' + src[XRANGEPLAIN] + ')' + + '\\s*$' + +var HYPHENRANGELOOSE = R++ +src[HYPHENRANGELOOSE] = '^\\s*(' + src[XRANGEPLAINLOOSE] + ')' + + '\\s+-\\s+' + + '(' + src[XRANGEPLAINLOOSE] + ')' + + '\\s*$' + +// Star ranges basically just allow anything at all. +var STAR = R++ +src[STAR] = '(<|>)?=?\\s*\\*' + +// Compile to actual regexp objects. +// All are flag-free, unless they were created above with a flag. +for (var i = 0; i < R; i++) { + debug(i, src[i]) + if (!re[i]) { + re[i] = new RegExp(src[i]) + } +} + +exports.parse = parse +function parse (version, options) { + if (!options || typeof options !== 'object') { + options = { + loose: !!options, + includePrerelease: false + } + } + + if (version instanceof SemVer) { + return version + } + + if (typeof version !== 'string') { + return null + } + + if (version.length > MAX_LENGTH) { + return null + } + + var r = options.loose ? re[LOOSE] : re[FULL] + if (!r.test(version)) { + return null + } + + try { + return new SemVer(version, options) + } catch (er) { + return null + } +} + +exports.valid = valid +function valid (version, options) { + var v = parse(version, options) + return v ? v.version : null +} + +exports.clean = clean +function clean (version, options) { + var s = parse(version.trim().replace(/^[=v]+/, ''), options) + return s ? s.version : null +} + +exports.SemVer = SemVer + +function SemVer (version, options) { + if (!options || typeof options !== 'object') { + options = { + loose: !!options, + includePrerelease: false + } + } + if (version instanceof SemVer) { + if (version.loose === options.loose) { + return version + } else { + version = version.version + } + } else if (typeof version !== 'string') { + throw new TypeError('Invalid Version: ' + version) + } + + if (version.length > MAX_LENGTH) { + throw new TypeError('version is longer than ' + MAX_LENGTH + ' characters') + } + + if (!(this instanceof SemVer)) { + return new SemVer(version, options) + } + + debug('SemVer', version, options) + this.options = options + this.loose = !!options.loose + + var m = version.trim().match(options.loose ? re[LOOSE] : re[FULL]) + + if (!m) { + throw new TypeError('Invalid Version: ' + version) + } + + this.raw = version + + // these are actually numbers + this.major = +m[1] + this.minor = +m[2] + this.patch = +m[3] + + if (this.major > MAX_SAFE_INTEGER || this.major < 0) { + throw new TypeError('Invalid major version') + } + + if (this.minor > MAX_SAFE_INTEGER || this.minor < 0) { + throw new TypeError('Invalid minor version') + } + + if (this.patch > MAX_SAFE_INTEGER || this.patch < 0) { + throw new TypeError('Invalid patch version') + } + + // numberify any prerelease numeric ids + if (!m[4]) { + this.prerelease = [] + } else { + this.prerelease = m[4].split('.').map(function (id) { + if (/^[0-9]+$/.test(id)) { + var num = +id + if (num >= 0 && num < MAX_SAFE_INTEGER) { + return num + } + } + return id + }) + } + + this.build = m[5] ? m[5].split('.') : [] + this.format() +} + +SemVer.prototype.format = function () { + this.version = this.major + '.' + this.minor + '.' + this.patch + if (this.prerelease.length) { + this.version += '-' + this.prerelease.join('.') + } + return this.version +} + +SemVer.prototype.toString = function () { + return this.version +} + +SemVer.prototype.compare = function (other) { + debug('SemVer.compare', this.version, this.options, other) + if (!(other instanceof SemVer)) { + other = new SemVer(other, this.options) + } + + return this.compareMain(other) || this.comparePre(other) +} + +SemVer.prototype.compareMain = function (other) { + if (!(other instanceof SemVer)) { + other = new SemVer(other, this.options) + } + + return compareIdentifiers(this.major, other.major) || + compareIdentifiers(this.minor, other.minor) || + compareIdentifiers(this.patch, other.patch) +} + +SemVer.prototype.comparePre = function (other) { + if (!(other instanceof SemVer)) { + other = new SemVer(other, this.options) + } + + // NOT having a prerelease is > having one + if (this.prerelease.length && !other.prerelease.length) { + return -1 + } else if (!this.prerelease.length && other.prerelease.length) { + return 1 + } else if (!this.prerelease.length && !other.prerelease.length) { + return 0 + } + + var i = 0 + do { + var a = this.prerelease[i] + var b = other.prerelease[i] + debug('prerelease compare', i, a, b) + if (a === undefined && b === undefined) { + return 0 + } else if (b === undefined) { + return 1 + } else if (a === undefined) { + return -1 + } else if (a === b) { + continue + } else { + return compareIdentifiers(a, b) + } + } while (++i) +} + +// preminor will bump the version up to the next minor release, and immediately +// down to pre-release. premajor and prepatch work the same way. +SemVer.prototype.inc = function (release, identifier) { + switch (release) { + case 'premajor': + this.prerelease.length = 0 + this.patch = 0 + this.minor = 0 + this.major++ + this.inc('pre', identifier) + break + case 'preminor': + this.prerelease.length = 0 + this.patch = 0 + this.minor++ + this.inc('pre', identifier) + break + case 'prepatch': + // If this is already a prerelease, it will bump to the next version + // drop any prereleases that might already exist, since they are not + // relevant at this point. + this.prerelease.length = 0 + this.inc('patch', identifier) + this.inc('pre', identifier) + break + // If the input is a non-prerelease version, this acts the same as + // prepatch. + case 'prerelease': + if (this.prerelease.length === 0) { + this.inc('patch', identifier) + } + this.inc('pre', identifier) + break + + case 'major': + // If this is a pre-major version, bump up to the same major version. + // Otherwise increment major. + // 1.0.0-5 bumps to 1.0.0 + // 1.1.0 bumps to 2.0.0 + if (this.minor !== 0 || + this.patch !== 0 || + this.prerelease.length === 0) { + this.major++ + } + this.minor = 0 + this.patch = 0 + this.prerelease = [] + break + case 'minor': + // If this is a pre-minor version, bump up to the same minor version. + // Otherwise increment minor. + // 1.2.0-5 bumps to 1.2.0 + // 1.2.1 bumps to 1.3.0 + if (this.patch !== 0 || this.prerelease.length === 0) { + this.minor++ + } + this.patch = 0 + this.prerelease = [] + break + case 'patch': + // If this is not a pre-release version, it will increment the patch. + // If it is a pre-release it will bump up to the same patch version. + // 1.2.0-5 patches to 1.2.0 + // 1.2.0 patches to 1.2.1 + if (this.prerelease.length === 0) { + this.patch++ + } + this.prerelease = [] + break + // This probably shouldn't be used publicly. + // 1.0.0 "pre" would become 1.0.0-0 which is the wrong direction. + case 'pre': + if (this.prerelease.length === 0) { + this.prerelease = [0] + } else { + var i = this.prerelease.length + while (--i >= 0) { + if (typeof this.prerelease[i] === 'number') { + this.prerelease[i]++ + i = -2 + } + } + if (i === -1) { + // didn't increment anything + this.prerelease.push(0) + } + } + if (identifier) { + // 1.2.0-beta.1 bumps to 1.2.0-beta.2, + // 1.2.0-beta.fooblz or 1.2.0-beta bumps to 1.2.0-beta.0 + if (this.prerelease[0] === identifier) { + if (isNaN(this.prerelease[1])) { + this.prerelease = [identifier, 0] + } + } else { + this.prerelease = [identifier, 0] + } + } + break + + default: + throw new Error('invalid increment argument: ' + release) + } + this.format() + this.raw = this.version + return this +} + +exports.inc = inc +function inc (version, release, loose, identifier) { + if (typeof (loose) === 'string') { + identifier = loose + loose = undefined + } + + try { + return new SemVer(version, loose).inc(release, identifier).version + } catch (er) { + return null + } +} + +exports.diff = diff +function diff (version1, version2) { + if (eq(version1, version2)) { + return null + } else { + var v1 = parse(version1) + var v2 = parse(version2) + var prefix = '' + if (v1.prerelease.length || v2.prerelease.length) { + prefix = 'pre' + var defaultResult = 'prerelease' + } + for (var key in v1) { + if (key === 'major' || key === 'minor' || key === 'patch') { + if (v1[key] !== v2[key]) { + return prefix + key + } + } + } + return defaultResult // may be undefined + } +} + +exports.compareIdentifiers = compareIdentifiers + +var numeric = /^[0-9]+$/ +function compareIdentifiers (a, b) { + var anum = numeric.test(a) + var bnum = numeric.test(b) + + if (anum && bnum) { + a = +a + b = +b + } + + return a === b ? 0 + : (anum && !bnum) ? -1 + : (bnum && !anum) ? 1 + : a < b ? -1 + : 1 +} + +exports.rcompareIdentifiers = rcompareIdentifiers +function rcompareIdentifiers (a, b) { + return compareIdentifiers(b, a) +} + +exports.major = major +function major (a, loose) { + return new SemVer(a, loose).major +} + +exports.minor = minor +function minor (a, loose) { + return new SemVer(a, loose).minor +} + +exports.patch = patch +function patch (a, loose) { + return new SemVer(a, loose).patch +} + +exports.compare = compare +function compare (a, b, loose) { + return new SemVer(a, loose).compare(new SemVer(b, loose)) +} + +exports.compareLoose = compareLoose +function compareLoose (a, b) { + return compare(a, b, true) +} + +exports.rcompare = rcompare +function rcompare (a, b, loose) { + return compare(b, a, loose) +} + +exports.sort = sort +function sort (list, loose) { + return list.sort(function (a, b) { + return exports.compare(a, b, loose) + }) +} + +exports.rsort = rsort +function rsort (list, loose) { + return list.sort(function (a, b) { + return exports.rcompare(a, b, loose) + }) +} + +exports.gt = gt +function gt (a, b, loose) { + return compare(a, b, loose) > 0 +} + +exports.lt = lt +function lt (a, b, loose) { + return compare(a, b, loose) < 0 +} + +exports.eq = eq +function eq (a, b, loose) { + return compare(a, b, loose) === 0 +} + +exports.neq = neq +function neq (a, b, loose) { + return compare(a, b, loose) !== 0 +} + +exports.gte = gte +function gte (a, b, loose) { + return compare(a, b, loose) >= 0 +} + +exports.lte = lte +function lte (a, b, loose) { + return compare(a, b, loose) <= 0 +} + +exports.cmp = cmp +function cmp (a, op, b, loose) { + switch (op) { + case '===': + if (typeof a === 'object') + a = a.version + if (typeof b === 'object') + b = b.version + return a === b + + case '!==': + if (typeof a === 'object') + a = a.version + if (typeof b === 'object') + b = b.version + return a !== b + + case '': + case '=': + case '==': + return eq(a, b, loose) + + case '!=': + return neq(a, b, loose) + + case '>': + return gt(a, b, loose) + + case '>=': + return gte(a, b, loose) + + case '<': + return lt(a, b, loose) + + case '<=': + return lte(a, b, loose) + + default: + throw new TypeError('Invalid operator: ' + op) + } +} + +exports.Comparator = Comparator +function Comparator (comp, options) { + if (!options || typeof options !== 'object') { + options = { + loose: !!options, + includePrerelease: false + } + } + + if (comp instanceof Comparator) { + if (comp.loose === !!options.loose) { + return comp + } else { + comp = comp.value + } + } + + if (!(this instanceof Comparator)) { + return new Comparator(comp, options) + } + + debug('comparator', comp, options) + this.options = options + this.loose = !!options.loose + this.parse(comp) + + if (this.semver === ANY) { + this.value = '' + } else { + this.value = this.operator + this.semver.version + } + + debug('comp', this) +} + +var ANY = {} +Comparator.prototype.parse = function (comp) { + var r = this.options.loose ? re[COMPARATORLOOSE] : re[COMPARATOR] + var m = comp.match(r) + + if (!m) { + throw new TypeError('Invalid comparator: ' + comp) + } + + this.operator = m[1] + if (this.operator === '=') { + this.operator = '' + } + + // if it literally is just '>' or '' then allow anything. + if (!m[2]) { + this.semver = ANY + } else { + this.semver = new SemVer(m[2], this.options.loose) + } +} + +Comparator.prototype.toString = function () { + return this.value +} + +Comparator.prototype.test = function (version) { + debug('Comparator.test', version, this.options.loose) + + if (this.semver === ANY) { + return true + } + + if (typeof version === 'string') { + version = new SemVer(version, this.options) + } + + return cmp(version, this.operator, this.semver, this.options) +} + +Comparator.prototype.intersects = function (comp, options) { + if (!(comp instanceof Comparator)) { + throw new TypeError('a Comparator is required') + } + + if (!options || typeof options !== 'object') { + options = { + loose: !!options, + includePrerelease: false + } + } + + var rangeTmp + + if (this.operator === '') { + rangeTmp = new Range(comp.value, options) + return satisfies(this.value, rangeTmp, options) + } else if (comp.operator === '') { + rangeTmp = new Range(this.value, options) + return satisfies(comp.semver, rangeTmp, options) + } + + var sameDirectionIncreasing = + (this.operator === '>=' || this.operator === '>') && + (comp.operator === '>=' || comp.operator === '>') + var sameDirectionDecreasing = + (this.operator === '<=' || this.operator === '<') && + (comp.operator === '<=' || comp.operator === '<') + var sameSemVer = this.semver.version === comp.semver.version + var differentDirectionsInclusive = + (this.operator === '>=' || this.operator === '<=') && + (comp.operator === '>=' || comp.operator === '<=') + var oppositeDirectionsLessThan = + cmp(this.semver, '<', comp.semver, options) && + ((this.operator === '>=' || this.operator === '>') && + (comp.operator === '<=' || comp.operator === '<')) + var oppositeDirectionsGreaterThan = + cmp(this.semver, '>', comp.semver, options) && + ((this.operator === '<=' || this.operator === '<') && + (comp.operator === '>=' || comp.operator === '>')) + + return sameDirectionIncreasing || sameDirectionDecreasing || + (sameSemVer && differentDirectionsInclusive) || + oppositeDirectionsLessThan || oppositeDirectionsGreaterThan +} + +exports.Range = Range +function Range (range, options) { + if (!options || typeof options !== 'object') { + options = { + loose: !!options, + includePrerelease: false + } + } + + if (range instanceof Range) { + if (range.loose === !!options.loose && + range.includePrerelease === !!options.includePrerelease) { + return range + } else { + return new Range(range.raw, options) + } + } + + if (range instanceof Comparator) { + return new Range(range.value, options) + } + + if (!(this instanceof Range)) { + return new Range(range, options) + } + + this.options = options + this.loose = !!options.loose + this.includePrerelease = !!options.includePrerelease + + // First, split based on boolean or || + this.raw = range + this.set = range.split(/\s*\|\|\s*/).map(function (range) { + return this.parseRange(range.trim()) + }, this).filter(function (c) { + // throw out any that are not relevant for whatever reason + return c.length + }) + + if (!this.set.length) { + throw new TypeError('Invalid SemVer Range: ' + range) + } + + this.format() +} + +Range.prototype.format = function () { + this.range = this.set.map(function (comps) { + return comps.join(' ').trim() + }).join('||').trim() + return this.range +} + +Range.prototype.toString = function () { + return this.range +} + +Range.prototype.parseRange = function (range) { + var loose = this.options.loose + range = range.trim() + // `1.2.3 - 1.2.4` => `>=1.2.3 <=1.2.4` + var hr = loose ? re[HYPHENRANGELOOSE] : re[HYPHENRANGE] + range = range.replace(hr, hyphenReplace) + debug('hyphen replace', range) + // `> 1.2.3 < 1.2.5` => `>1.2.3 <1.2.5` + range = range.replace(re[COMPARATORTRIM], comparatorTrimReplace) + debug('comparator trim', range, re[COMPARATORTRIM]) + + // `~ 1.2.3` => `~1.2.3` + range = range.replace(re[TILDETRIM], tildeTrimReplace) + + // `^ 1.2.3` => `^1.2.3` + range = range.replace(re[CARETTRIM], caretTrimReplace) + + // normalize spaces + range = range.split(/\s+/).join(' ') + + // At this point, the range is completely trimmed and + // ready to be split into comparators. + + var compRe = loose ? re[COMPARATORLOOSE] : re[COMPARATOR] + var set = range.split(' ').map(function (comp) { + return parseComparator(comp, this.options) + }, this).join(' ').split(/\s+/) + if (this.options.loose) { + // in loose mode, throw out any that are not valid comparators + set = set.filter(function (comp) { + return !!comp.match(compRe) + }) + } + set = set.map(function (comp) { + return new Comparator(comp, this.options) + }, this) + + return set +} + +Range.prototype.intersects = function (range, options) { + if (!(range instanceof Range)) { + throw new TypeError('a Range is required') + } + + return this.set.some(function (thisComparators) { + return thisComparators.every(function (thisComparator) { + return range.set.some(function (rangeComparators) { + return rangeComparators.every(function (rangeComparator) { + return thisComparator.intersects(rangeComparator, options) + }) + }) + }) + }) +} + +// Mostly just for testing and legacy API reasons +exports.toComparators = toComparators +function toComparators (range, options) { + return new Range(range, options).set.map(function (comp) { + return comp.map(function (c) { + return c.value + }).join(' ').trim().split(' ') + }) +} + +// comprised of xranges, tildes, stars, and gtlt's at this point. +// already replaced the hyphen ranges +// turn into a set of JUST comparators. +function parseComparator (comp, options) { + debug('comp', comp, options) + comp = replaceCarets(comp, options) + debug('caret', comp) + comp = replaceTildes(comp, options) + debug('tildes', comp) + comp = replaceXRanges(comp, options) + debug('xrange', comp) + comp = replaceStars(comp, options) + debug('stars', comp) + return comp +} + +function isX (id) { + return !id || id.toLowerCase() === 'x' || id === '*' +} + +// ~, ~> --> * (any, kinda silly) +// ~2, ~2.x, ~2.x.x, ~>2, ~>2.x ~>2.x.x --> >=2.0.0 <3.0.0 +// ~2.0, ~2.0.x, ~>2.0, ~>2.0.x --> >=2.0.0 <2.1.0 +// ~1.2, ~1.2.x, ~>1.2, ~>1.2.x --> >=1.2.0 <1.3.0 +// ~1.2.3, ~>1.2.3 --> >=1.2.3 <1.3.0 +// ~1.2.0, ~>1.2.0 --> >=1.2.0 <1.3.0 +function replaceTildes (comp, options) { + return comp.trim().split(/\s+/).map(function (comp) { + return replaceTilde(comp, options) + }).join(' ') +} + +function replaceTilde (comp, options) { + var r = options.loose ? re[TILDELOOSE] : re[TILDE] + return comp.replace(r, function (_, M, m, p, pr) { + debug('tilde', comp, _, M, m, p, pr) + var ret + + if (isX(M)) { + ret = '' + } else if (isX(m)) { + ret = '>=' + M + '.0.0 <' + (+M + 1) + '.0.0' + } else if (isX(p)) { + // ~1.2 == >=1.2.0 <1.3.0 + ret = '>=' + M + '.' + m + '.0 <' + M + '.' + (+m + 1) + '.0' + } else if (pr) { + debug('replaceTilde pr', pr) + ret = '>=' + M + '.' + m + '.' + p + '-' + pr + + ' <' + M + '.' + (+m + 1) + '.0' + } else { + // ~1.2.3 == >=1.2.3 <1.3.0 + ret = '>=' + M + '.' + m + '.' + p + + ' <' + M + '.' + (+m + 1) + '.0' + } + + debug('tilde return', ret) + return ret + }) +} + +// ^ --> * (any, kinda silly) +// ^2, ^2.x, ^2.x.x --> >=2.0.0 <3.0.0 +// ^2.0, ^2.0.x --> >=2.0.0 <3.0.0 +// ^1.2, ^1.2.x --> >=1.2.0 <2.0.0 +// ^1.2.3 --> >=1.2.3 <2.0.0 +// ^1.2.0 --> >=1.2.0 <2.0.0 +function replaceCarets (comp, options) { + return comp.trim().split(/\s+/).map(function (comp) { + return replaceCaret(comp, options) + }).join(' ') +} + +function replaceCaret (comp, options) { + debug('caret', comp, options) + var r = options.loose ? re[CARETLOOSE] : re[CARET] + return comp.replace(r, function (_, M, m, p, pr) { + debug('caret', comp, _, M, m, p, pr) + var ret + + if (isX(M)) { + ret = '' + } else if (isX(m)) { + ret = '>=' + M + '.0.0 <' + (+M + 1) + '.0.0' + } else if (isX(p)) { + if (M === '0') { + ret = '>=' + M + '.' + m + '.0 <' + M + '.' + (+m + 1) + '.0' + } else { + ret = '>=' + M + '.' + m + '.0 <' + (+M + 1) + '.0.0' + } + } else if (pr) { + debug('replaceCaret pr', pr) + if (M === '0') { + if (m === '0') { + ret = '>=' + M + '.' + m + '.' + p + '-' + pr + + ' <' + M + '.' + m + '.' + (+p + 1) + } else { + ret = '>=' + M + '.' + m + '.' + p + '-' + pr + + ' <' + M + '.' + (+m + 1) + '.0' + } + } else { + ret = '>=' + M + '.' + m + '.' + p + '-' + pr + + ' <' + (+M + 1) + '.0.0' + } + } else { + debug('no pr') + if (M === '0') { + if (m === '0') { + ret = '>=' + M + '.' + m + '.' + p + + ' <' + M + '.' + m + '.' + (+p + 1) + } else { + ret = '>=' + M + '.' + m + '.' + p + + ' <' + M + '.' + (+m + 1) + '.0' + } + } else { + ret = '>=' + M + '.' + m + '.' + p + + ' <' + (+M + 1) + '.0.0' + } + } + + debug('caret return', ret) + return ret + }) +} + +function replaceXRanges (comp, options) { + debug('replaceXRanges', comp, options) + return comp.split(/\s+/).map(function (comp) { + return replaceXRange(comp, options) + }).join(' ') +} + +function replaceXRange (comp, options) { + comp = comp.trim() + var r = options.loose ? re[XRANGELOOSE] : re[XRANGE] + return comp.replace(r, function (ret, gtlt, M, m, p, pr) { + debug('xRange', comp, ret, gtlt, M, m, p, pr) + var xM = isX(M) + var xm = xM || isX(m) + var xp = xm || isX(p) + var anyX = xp + + if (gtlt === '=' && anyX) { + gtlt = '' + } + + if (xM) { + if (gtlt === '>' || gtlt === '<') { + // nothing is allowed + ret = '<0.0.0' + } else { + // nothing is forbidden + ret = '*' + } + } else if (gtlt && anyX) { + // we know patch is an x, because we have any x at all. + // replace X with 0 + if (xm) { + m = 0 + } + p = 0 + + if (gtlt === '>') { + // >1 => >=2.0.0 + // >1.2 => >=1.3.0 + // >1.2.3 => >= 1.2.4 + gtlt = '>=' + if (xm) { + M = +M + 1 + m = 0 + p = 0 + } else { + m = +m + 1 + p = 0 + } + } else if (gtlt === '<=') { + // <=0.7.x is actually <0.8.0, since any 0.7.x should + // pass. Similarly, <=7.x is actually <8.0.0, etc. + gtlt = '<' + if (xm) { + M = +M + 1 + } else { + m = +m + 1 + } + } + + ret = gtlt + M + '.' + m + '.' + p + } else if (xm) { + ret = '>=' + M + '.0.0 <' + (+M + 1) + '.0.0' + } else if (xp) { + ret = '>=' + M + '.' + m + '.0 <' + M + '.' + (+m + 1) + '.0' + } + + debug('xRange return', ret) + + return ret + }) +} + +// Because * is AND-ed with everything else in the comparator, +// and '' means "any version", just remove the *s entirely. +function replaceStars (comp, options) { + debug('replaceStars', comp, options) + // Looseness is ignored here. star is always as loose as it gets! + return comp.trim().replace(re[STAR], '') +} + +// This function is passed to string.replace(re[HYPHENRANGE]) +// M, m, patch, prerelease, build +// 1.2 - 3.4.5 => >=1.2.0 <=3.4.5 +// 1.2.3 - 3.4 => >=1.2.0 <3.5.0 Any 3.4.x will do +// 1.2 - 3.4 => >=1.2.0 <3.5.0 +function hyphenReplace ($0, + from, fM, fm, fp, fpr, fb, + to, tM, tm, tp, tpr, tb) { + if (isX(fM)) { + from = '' + } else if (isX(fm)) { + from = '>=' + fM + '.0.0' + } else if (isX(fp)) { + from = '>=' + fM + '.' + fm + '.0' + } else { + from = '>=' + from + } + + if (isX(tM)) { + to = '' + } else if (isX(tm)) { + to = '<' + (+tM + 1) + '.0.0' + } else if (isX(tp)) { + to = '<' + tM + '.' + (+tm + 1) + '.0' + } else if (tpr) { + to = '<=' + tM + '.' + tm + '.' + tp + '-' + tpr + } else { + to = '<=' + to + } + + return (from + ' ' + to).trim() +} + +// if ANY of the sets match ALL of its comparators, then pass +Range.prototype.test = function (version) { + if (!version) { + return false + } + + if (typeof version === 'string') { + version = new SemVer(version, this.options) + } + + for (var i = 0; i < this.set.length; i++) { + if (testSet(this.set[i], version, this.options)) { + return true + } + } + return false +} + +function testSet (set, version, options) { + for (var i = 0; i < set.length; i++) { + if (!set[i].test(version)) { + return false + } + } + + if (version.prerelease.length && !options.includePrerelease) { + // Find the set of versions that are allowed to have prereleases + // For example, ^1.2.3-pr.1 desugars to >=1.2.3-pr.1 <2.0.0 + // That should allow `1.2.3-pr.2` to pass. + // However, `1.2.4-alpha.notready` should NOT be allowed, + // even though it's within the range set by the comparators. + for (i = 0; i < set.length; i++) { + debug(set[i].semver) + if (set[i].semver === ANY) { + continue + } + + if (set[i].semver.prerelease.length > 0) { + var allowed = set[i].semver + if (allowed.major === version.major && + allowed.minor === version.minor && + allowed.patch === version.patch) { + return true + } + } + } + + // Version has a -pre, but it's not one of the ones we like. + return false + } + + return true +} + +exports.satisfies = satisfies +function satisfies (version, range, options) { + try { + range = new Range(range, options) + } catch (er) { + return false + } + return range.test(version) +} + +exports.maxSatisfying = maxSatisfying +function maxSatisfying (versions, range, options) { + var max = null + var maxSV = null + try { + var rangeObj = new Range(range, options) + } catch (er) { + return null + } + versions.forEach(function (v) { + if (rangeObj.test(v)) { + // satisfies(v, range, options) + if (!max || maxSV.compare(v) === -1) { + // compare(max, v, true) + max = v + maxSV = new SemVer(max, options) + } + } + }) + return max +} + +exports.minSatisfying = minSatisfying +function minSatisfying (versions, range, options) { + var min = null + var minSV = null + try { + var rangeObj = new Range(range, options) + } catch (er) { + return null + } + versions.forEach(function (v) { + if (rangeObj.test(v)) { + // satisfies(v, range, options) + if (!min || minSV.compare(v) === 1) { + // compare(min, v, true) + min = v + minSV = new SemVer(min, options) + } + } + }) + return min +} + +exports.minVersion = minVersion +function minVersion (range, loose) { + range = new Range(range, loose) + + var minver = new SemVer('0.0.0') + if (range.test(minver)) { + return minver + } + + minver = new SemVer('0.0.0-0') + if (range.test(minver)) { + return minver + } + + minver = null + for (var i = 0; i < range.set.length; ++i) { + var comparators = range.set[i] + + comparators.forEach(function (comparator) { + // Clone to avoid manipulating the comparator's semver object. + var compver = new SemVer(comparator.semver.version) + switch (comparator.operator) { + case '>': + if (compver.prerelease.length === 0) { + compver.patch++ + } else { + compver.prerelease.push(0) + } + compver.raw = compver.format() + /* fallthrough */ + case '': + case '>=': + if (!minver || gt(minver, compver)) { + minver = compver + } + break + case '<': + case '<=': + /* Ignore maximum versions */ + break + /* istanbul ignore next */ + default: + throw new Error('Unexpected operation: ' + comparator.operator) + } + }) + } + + if (minver && range.test(minver)) { + return minver + } + + return null +} + +exports.validRange = validRange +function validRange (range, options) { + try { + // Return '*' instead of '' so that truthiness works. + // This will throw if it's invalid anyway + return new Range(range, options).range || '*' + } catch (er) { + return null + } +} + +// Determine if version is less than all the versions possible in the range +exports.ltr = ltr +function ltr (version, range, options) { + return outside(version, range, '<', options) +} + +// Determine if version is greater than all the versions possible in the range. +exports.gtr = gtr +function gtr (version, range, options) { + return outside(version, range, '>', options) +} + +exports.outside = outside +function outside (version, range, hilo, options) { + version = new SemVer(version, options) + range = new Range(range, options) + + var gtfn, ltefn, ltfn, comp, ecomp + switch (hilo) { + case '>': + gtfn = gt + ltefn = lte + ltfn = lt + comp = '>' + ecomp = '>=' + break + case '<': + gtfn = lt + ltefn = gte + ltfn = gt + comp = '<' + ecomp = '<=' + break + default: + throw new TypeError('Must provide a hilo val of "<" or ">"') + } + + // If it satisifes the range it is not outside + if (satisfies(version, range, options)) { + return false + } + + // From now on, variable terms are as if we're in "gtr" mode. + // but note that everything is flipped for the "ltr" function. + + for (var i = 0; i < range.set.length; ++i) { + var comparators = range.set[i] + + var high = null + var low = null + + comparators.forEach(function (comparator) { + if (comparator.semver === ANY) { + comparator = new Comparator('>=0.0.0') + } + high = high || comparator + low = low || comparator + if (gtfn(comparator.semver, high.semver, options)) { + high = comparator + } else if (ltfn(comparator.semver, low.semver, options)) { + low = comparator + } + }) + + // If the edge version comparator has a operator then our version + // isn't outside it + if (high.operator === comp || high.operator === ecomp) { + return false + } + + // If the lowest version comparator has an operator and our version + // is less than it then it isn't higher than the range + if ((!low.operator || low.operator === comp) && + ltefn(version, low.semver)) { + return false + } else if (low.operator === ecomp && ltfn(version, low.semver)) { + return false + } + } + return true +} + +exports.prerelease = prerelease +function prerelease (version, options) { + var parsed = parse(version, options) + return (parsed && parsed.prerelease.length) ? parsed.prerelease : null +} + +exports.intersects = intersects +function intersects (r1, r2, options) { + r1 = new Range(r1, options) + r2 = new Range(r2, options) + return r1.intersects(r2) +} + +exports.coerce = coerce +function coerce (version) { + if (version instanceof SemVer) { + return version + } + + if (typeof version !== 'string') { + return null + } + + var match = version.match(re[COERCE]) + + if (match == null) { + return null + } + + return parse(match[1] + + '.' + (match[2] || '0') + + '.' + (match[3] || '0')) +} diff --git a/jwt-scratch/src/js/node_modules/ws/LICENSE b/jwt-scratch/src/js/node_modules/ws/LICENSE new file mode 100644 index 0000000..a145cd1 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/ws/LICENSE @@ -0,0 +1,21 @@ +The MIT License (MIT) + +Copyright (c) 2011 Einar Otto Stangvik + +Permission is hereby granted, free of charge, to any person obtaining a copy +of this software and associated documentation files (the "Software"), to deal +in the Software without restriction, including without limitation the rights +to use, copy, modify, merge, publish, distribute, sublicense, and/or sell +copies of the Software, and to permit persons to whom the Software is +furnished to do so, subject to the following conditions: + +The above copyright notice and this permission notice shall be included in all +copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR +IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, +FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE +AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER +LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, +OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE +SOFTWARE. diff --git a/jwt-scratch/src/js/node_modules/ws/README.md b/jwt-scratch/src/js/node_modules/ws/README.md new file mode 100644 index 0000000..9c6e528 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/ws/README.md @@ -0,0 +1,496 @@ +# ws: a Node.js WebSocket library + +[![Version npm](https://img.shields.io/npm/v/ws.svg?logo=npm)](https://www.npmjs.com/package/ws) +[![Build](https://img.shields.io/github/workflow/status/websockets/ws/CI/master?label=build&logo=github)](https://github.com/websockets/ws/actions?query=workflow%3ACI+branch%3Amaster) +[![Windows x86 Build](https://img.shields.io/appveyor/ci/lpinca/ws/master.svg?logo=appveyor)](https://ci.appveyor.com/project/lpinca/ws) +[![Coverage Status](https://img.shields.io/coveralls/websockets/ws/master.svg)](https://coveralls.io/github/websockets/ws) + +ws is a simple to use, blazing fast, and thoroughly tested WebSocket client and +server implementation. + +Passes the quite extensive Autobahn test suite: [server][server-report], +[client][client-report]. + +**Note**: This module does not work in the browser. The client in the docs is a +reference to a back end with the role of a client in the WebSocket +communication. Browser clients must use the native +[`WebSocket`](https://developer.mozilla.org/en-US/docs/Web/API/WebSocket) +object. To make the same code work seamlessly on Node.js and the browser, you +can use one of the many wrappers available on npm, like +[isomorphic-ws](https://github.com/heineiuo/isomorphic-ws). + +## Table of Contents + +- [Protocol support](#protocol-support) +- [Installing](#installing) + - [Opt-in for performance and spec compliance](#opt-in-for-performance-and-spec-compliance) +- [API docs](#api-docs) +- [WebSocket compression](#websocket-compression) +- [Usage examples](#usage-examples) + - [Sending and receiving text data](#sending-and-receiving-text-data) + - [Sending binary data](#sending-binary-data) + - [Simple server](#simple-server) + - [External HTTP/S server](#external-https-server) + - [Multiple servers sharing a single HTTP/S server](#multiple-servers-sharing-a-single-https-server) + - [Client authentication](#client-authentication) + - [Server broadcast](#server-broadcast) + - [echo.websocket.org demo](#echowebsocketorg-demo) + - [Use the Node.js streams API](#use-the-nodejs-streams-api) + - [Other examples](#other-examples) +- [FAQ](#faq) + - [How to get the IP address of the client?](#how-to-get-the-ip-address-of-the-client) + - [How to detect and close broken connections?](#how-to-detect-and-close-broken-connections) + - [How to connect via a proxy?](#how-to-connect-via-a-proxy) +- [Changelog](#changelog) +- [License](#license) + +## Protocol support + +- **HyBi drafts 07-12** (Use the option `protocolVersion: 8`) +- **HyBi drafts 13-17** (Current default, alternatively option + `protocolVersion: 13`) + +## Installing + +``` +npm install ws +``` + +### Opt-in for performance + +There are 2 optional modules that can be installed along side with the ws +module. These modules are binary addons which improve certain operations. +Prebuilt binaries are available for the most popular platforms so you don't +necessarily need to have a C++ compiler installed on your machine. + +- `npm install --save-optional bufferutil`: Allows to efficiently perform + operations such as masking and unmasking the data payload of the WebSocket + frames. +- `npm install --save-optional utf-8-validate`: Allows to efficiently check if a + message contains valid UTF-8. + +## API docs + +See [`/doc/ws.md`](./doc/ws.md) for Node.js-like documentation of ws classes and +utility functions. + +## WebSocket compression + +ws supports the [permessage-deflate extension][permessage-deflate] which enables +the client and server to negotiate a compression algorithm and its parameters, +and then selectively apply it to the data payloads of each WebSocket message. + +The extension is disabled by default on the server and enabled by default on the +client. It adds a significant overhead in terms of performance and memory +consumption so we suggest to enable it only if it is really needed. + +Note that Node.js has a variety of issues with high-performance compression, +where increased concurrency, especially on Linux, can lead to [catastrophic +memory fragmentation][node-zlib-bug] and slow performance. If you intend to use +permessage-deflate in production, it is worthwhile to set up a test +representative of your workload and ensure Node.js/zlib will handle it with +acceptable performance and memory usage. + +Tuning of permessage-deflate can be done via the options defined below. You can +also use `zlibDeflateOptions` and `zlibInflateOptions`, which is passed directly +into the creation of [raw deflate/inflate streams][node-zlib-deflaterawdocs]. + +See [the docs][ws-server-options] for more options. + +```js +const WebSocket = require('ws'); + +const wss = new WebSocket.Server({ + port: 8080, + perMessageDeflate: { + zlibDeflateOptions: { + // See zlib defaults. + chunkSize: 1024, + memLevel: 7, + level: 3 + }, + zlibInflateOptions: { + chunkSize: 10 * 1024 + }, + // Other options settable: + clientNoContextTakeover: true, // Defaults to negotiated value. + serverNoContextTakeover: true, // Defaults to negotiated value. + serverMaxWindowBits: 10, // Defaults to negotiated value. + // Below options specified as default values. + concurrencyLimit: 10, // Limits zlib concurrency for perf. + threshold: 1024 // Size (in bytes) below which messages + // should not be compressed. + } +}); +``` + +The client will only use the extension if it is supported and enabled on the +server. To always disable the extension on the client set the +`perMessageDeflate` option to `false`. + +```js +const WebSocket = require('ws'); + +const ws = new WebSocket('ws://www.host.com/path', { + perMessageDeflate: false +}); +``` + +## Usage examples + +### Sending and receiving text data + +```js +const WebSocket = require('ws'); + +const ws = new WebSocket('ws://www.host.com/path'); + +ws.on('open', function open() { + ws.send('something'); +}); + +ws.on('message', function incoming(data) { + console.log(data); +}); +``` + +### Sending binary data + +```js +const WebSocket = require('ws'); + +const ws = new WebSocket('ws://www.host.com/path'); + +ws.on('open', function open() { + const array = new Float32Array(5); + + for (var i = 0; i < array.length; ++i) { + array[i] = i / 2; + } + + ws.send(array); +}); +``` + +### Simple server + +```js +const WebSocket = require('ws'); + +const wss = new WebSocket.Server({ port: 8080 }); + +wss.on('connection', function connection(ws) { + ws.on('message', function incoming(message) { + console.log('received: %s', message); + }); + + ws.send('something'); +}); +``` + +### External HTTP/S server + +```js +const fs = require('fs'); +const https = require('https'); +const WebSocket = require('ws'); + +const server = https.createServer({ + cert: fs.readFileSync('/path/to/cert.pem'), + key: fs.readFileSync('/path/to/key.pem') +}); +const wss = new WebSocket.Server({ server }); + +wss.on('connection', function connection(ws) { + ws.on('message', function incoming(message) { + console.log('received: %s', message); + }); + + ws.send('something'); +}); + +server.listen(8080); +``` + +### Multiple servers sharing a single HTTP/S server + +```js +const http = require('http'); +const WebSocket = require('ws'); +const url = require('url'); + +const server = http.createServer(); +const wss1 = new WebSocket.Server({ noServer: true }); +const wss2 = new WebSocket.Server({ noServer: true }); + +wss1.on('connection', function connection(ws) { + // ... +}); + +wss2.on('connection', function connection(ws) { + // ... +}); + +server.on('upgrade', function upgrade(request, socket, head) { + const pathname = url.parse(request.url).pathname; + + if (pathname === '/foo') { + wss1.handleUpgrade(request, socket, head, function done(ws) { + wss1.emit('connection', ws, request); + }); + } else if (pathname === '/bar') { + wss2.handleUpgrade(request, socket, head, function done(ws) { + wss2.emit('connection', ws, request); + }); + } else { + socket.destroy(); + } +}); + +server.listen(8080); +``` + +### Client authentication + +```js +const http = require('http'); +const WebSocket = require('ws'); + +const server = http.createServer(); +const wss = new WebSocket.Server({ noServer: true }); + +wss.on('connection', function connection(ws, request, client) { + ws.on('message', function message(msg) { + console.log(`Received message ${msg} from user ${client}`); + }); +}); + +server.on('upgrade', function upgrade(request, socket, head) { + // This function is not defined on purpose. Implement it with your own logic. + authenticate(request, (err, client) => { + if (err || !client) { + socket.write('HTTP/1.1 401 Unauthorized\r\n\r\n'); + socket.destroy(); + return; + } + + wss.handleUpgrade(request, socket, head, function done(ws) { + wss.emit('connection', ws, request, client); + }); + }); +}); + +server.listen(8080); +``` + +Also see the provided [example][session-parse-example] using `express-session`. + +### Server broadcast + +A client WebSocket broadcasting to all connected WebSocket clients, including +itself. + +```js +const WebSocket = require('ws'); + +const wss = new WebSocket.Server({ port: 8080 }); + +wss.on('connection', function connection(ws) { + ws.on('message', function incoming(data) { + wss.clients.forEach(function each(client) { + if (client.readyState === WebSocket.OPEN) { + client.send(data); + } + }); + }); +}); +``` + +A client WebSocket broadcasting to every other connected WebSocket clients, +excluding itself. + +```js +const WebSocket = require('ws'); + +const wss = new WebSocket.Server({ port: 8080 }); + +wss.on('connection', function connection(ws) { + ws.on('message', function incoming(data) { + wss.clients.forEach(function each(client) { + if (client !== ws && client.readyState === WebSocket.OPEN) { + client.send(data); + } + }); + }); +}); +``` + +### echo.websocket.org demo + +```js +const WebSocket = require('ws'); + +const ws = new WebSocket('wss://echo.websocket.org/', { + origin: 'https://websocket.org' +}); + +ws.on('open', function open() { + console.log('connected'); + ws.send(Date.now()); +}); + +ws.on('close', function close() { + console.log('disconnected'); +}); + +ws.on('message', function incoming(data) { + console.log(`Roundtrip time: ${Date.now() - data} ms`); + + setTimeout(function timeout() { + ws.send(Date.now()); + }, 500); +}); +``` + +### Use the Node.js streams API + +```js +const WebSocket = require('ws'); + +const ws = new WebSocket('wss://echo.websocket.org/', { + origin: 'https://websocket.org' +}); + +const duplex = WebSocket.createWebSocketStream(ws, { encoding: 'utf8' }); + +duplex.pipe(process.stdout); +process.stdin.pipe(duplex); +``` + +### Other examples + +For a full example with a browser client communicating with a ws server, see the +examples folder. + +Otherwise, see the test cases. + +## FAQ + +### How to get the IP address of the client? + +The remote IP address can be obtained from the raw socket. + +```js +const WebSocket = require('ws'); + +const wss = new WebSocket.Server({ port: 8080 }); + +wss.on('connection', function connection(ws, req) { + const ip = req.socket.remoteAddress; +}); +``` + +When the server runs behind a proxy like NGINX, the de-facto standard is to use +the `X-Forwarded-For` header. + +```js +wss.on('connection', function connection(ws, req) { + const ip = req.headers['x-forwarded-for'].split(/\s*,\s*/)[0]; +}); +``` + +### How to detect and close broken connections? + +Sometimes the link between the server and the client can be interrupted in a way +that keeps both the server and the client unaware of the broken state of the +connection (e.g. when pulling the cord). + +In these cases ping messages can be used as a means to verify that the remote +endpoint is still responsive. + +```js +const WebSocket = require('ws'); + +function noop() {} + +function heartbeat() { + this.isAlive = true; +} + +const wss = new WebSocket.Server({ port: 8080 }); + +wss.on('connection', function connection(ws) { + ws.isAlive = true; + ws.on('pong', heartbeat); +}); + +const interval = setInterval(function ping() { + wss.clients.forEach(function each(ws) { + if (ws.isAlive === false) return ws.terminate(); + + ws.isAlive = false; + ws.ping(noop); + }); +}, 30000); + +wss.on('close', function close() { + clearInterval(interval); +}); +``` + +Pong messages are automatically sent in response to ping messages as required by +the spec. + +Just like the server example above your clients might as well lose connection +without knowing it. You might want to add a ping listener on your clients to +prevent that. A simple implementation would be: + +```js +const WebSocket = require('ws'); + +function heartbeat() { + clearTimeout(this.pingTimeout); + + // Use `WebSocket#terminate()`, which immediately destroys the connection, + // instead of `WebSocket#close()`, which waits for the close timer. + // Delay should be equal to the interval at which your server + // sends out pings plus a conservative assumption of the latency. + this.pingTimeout = setTimeout(() => { + this.terminate(); + }, 30000 + 1000); +} + +const client = new WebSocket('wss://echo.websocket.org/'); + +client.on('open', heartbeat); +client.on('ping', heartbeat); +client.on('close', function clear() { + clearTimeout(this.pingTimeout); +}); +``` + +### How to connect via a proxy? + +Use a custom `http.Agent` implementation like [https-proxy-agent][] or +[socks-proxy-agent][]. + +## Changelog + +We're using the GitHub [releases][changelog] for changelog entries. + +## License + +[MIT](LICENSE) + +[changelog]: https://github.com/websockets/ws/releases +[client-report]: http://websockets.github.io/ws/autobahn/clients/ +[https-proxy-agent]: https://github.com/TooTallNate/node-https-proxy-agent +[node-zlib-bug]: https://github.com/nodejs/node/issues/8871 +[node-zlib-deflaterawdocs]: + https://nodejs.org/api/zlib.html#zlib_zlib_createdeflateraw_options +[permessage-deflate]: https://tools.ietf.org/html/rfc7692 +[server-report]: http://websockets.github.io/ws/autobahn/servers/ +[session-parse-example]: ./examples/express-session-parse +[socks-proxy-agent]: https://github.com/TooTallNate/node-socks-proxy-agent +[ws-server-options]: + https://github.com/websockets/ws/blob/master/doc/ws.md#new-websocketserveroptions-callback diff --git a/jwt-scratch/src/js/node_modules/ws/browser.js b/jwt-scratch/src/js/node_modules/ws/browser.js new file mode 100644 index 0000000..ca4f628 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/ws/browser.js @@ -0,0 +1,8 @@ +'use strict'; + +module.exports = function () { + throw new Error( + 'ws does not work in the browser. Browser clients must use the native ' + + 'WebSocket object' + ); +}; diff --git a/jwt-scratch/src/js/node_modules/ws/index.js b/jwt-scratch/src/js/node_modules/ws/index.js new file mode 100644 index 0000000..722c786 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/ws/index.js @@ -0,0 +1,10 @@ +'use strict'; + +const WebSocket = require('./lib/websocket'); + +WebSocket.createWebSocketStream = require('./lib/stream'); +WebSocket.Server = require('./lib/websocket-server'); +WebSocket.Receiver = require('./lib/receiver'); +WebSocket.Sender = require('./lib/sender'); + +module.exports = WebSocket; diff --git a/jwt-scratch/src/js/node_modules/ws/lib/buffer-util.js b/jwt-scratch/src/js/node_modules/ws/lib/buffer-util.js new file mode 100644 index 0000000..6fd84c3 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/ws/lib/buffer-util.js @@ -0,0 +1,129 @@ +'use strict'; + +const { EMPTY_BUFFER } = require('./constants'); + +/** + * Merges an array of buffers into a new buffer. + * + * @param {Buffer[]} list The array of buffers to concat + * @param {Number} totalLength The total length of buffers in the list + * @return {Buffer} The resulting buffer + * @public + */ +function concat(list, totalLength) { + if (list.length === 0) return EMPTY_BUFFER; + if (list.length === 1) return list[0]; + + const target = Buffer.allocUnsafe(totalLength); + let offset = 0; + + for (let i = 0; i < list.length; i++) { + const buf = list[i]; + target.set(buf, offset); + offset += buf.length; + } + + if (offset < totalLength) return target.slice(0, offset); + + return target; +} + +/** + * Masks a buffer using the given mask. + * + * @param {Buffer} source The buffer to mask + * @param {Buffer} mask The mask to use + * @param {Buffer} output The buffer where to store the result + * @param {Number} offset The offset at which to start writing + * @param {Number} length The number of bytes to mask. + * @public + */ +function _mask(source, mask, output, offset, length) { + for (let i = 0; i < length; i++) { + output[offset + i] = source[i] ^ mask[i & 3]; + } +} + +/** + * Unmasks a buffer using the given mask. + * + * @param {Buffer} buffer The buffer to unmask + * @param {Buffer} mask The mask to use + * @public + */ +function _unmask(buffer, mask) { + // Required until https://github.com/nodejs/node/issues/9006 is resolved. + const length = buffer.length; + for (let i = 0; i < length; i++) { + buffer[i] ^= mask[i & 3]; + } +} + +/** + * Converts a buffer to an `ArrayBuffer`. + * + * @param {Buffer} buf The buffer to convert + * @return {ArrayBuffer} Converted buffer + * @public + */ +function toArrayBuffer(buf) { + if (buf.byteLength === buf.buffer.byteLength) { + return buf.buffer; + } + + return buf.buffer.slice(buf.byteOffset, buf.byteOffset + buf.byteLength); +} + +/** + * Converts `data` to a `Buffer`. + * + * @param {*} data The data to convert + * @return {Buffer} The buffer + * @throws {TypeError} + * @public + */ +function toBuffer(data) { + toBuffer.readOnly = true; + + if (Buffer.isBuffer(data)) return data; + + let buf; + + if (data instanceof ArrayBuffer) { + buf = Buffer.from(data); + } else if (ArrayBuffer.isView(data)) { + buf = Buffer.from(data.buffer, data.byteOffset, data.byteLength); + } else { + buf = Buffer.from(data); + toBuffer.readOnly = false; + } + + return buf; +} + +try { + const bufferUtil = require('bufferutil'); + const bu = bufferUtil.BufferUtil || bufferUtil; + + module.exports = { + concat, + mask(source, mask, output, offset, length) { + if (length < 48) _mask(source, mask, output, offset, length); + else bu.mask(source, mask, output, offset, length); + }, + toArrayBuffer, + toBuffer, + unmask(buffer, mask) { + if (buffer.length < 32) _unmask(buffer, mask); + else bu.unmask(buffer, mask); + } + }; +} catch (e) /* istanbul ignore next */ { + module.exports = { + concat, + mask: _mask, + toArrayBuffer, + toBuffer, + unmask: _unmask + }; +} diff --git a/jwt-scratch/src/js/node_modules/ws/lib/constants.js b/jwt-scratch/src/js/node_modules/ws/lib/constants.js new file mode 100644 index 0000000..4082981 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/ws/lib/constants.js @@ -0,0 +1,10 @@ +'use strict'; + +module.exports = { + BINARY_TYPES: ['nodebuffer', 'arraybuffer', 'fragments'], + GUID: '258EAFA5-E914-47DA-95CA-C5AB0DC85B11', + kStatusCode: Symbol('status-code'), + kWebSocket: Symbol('websocket'), + EMPTY_BUFFER: Buffer.alloc(0), + NOOP: () => {} +}; diff --git a/jwt-scratch/src/js/node_modules/ws/lib/event-target.js b/jwt-scratch/src/js/node_modules/ws/lib/event-target.js new file mode 100644 index 0000000..a6fbe72 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/ws/lib/event-target.js @@ -0,0 +1,184 @@ +'use strict'; + +/** + * Class representing an event. + * + * @private + */ +class Event { + /** + * Create a new `Event`. + * + * @param {String} type The name of the event + * @param {Object} target A reference to the target to which the event was + * dispatched + */ + constructor(type, target) { + this.target = target; + this.type = type; + } +} + +/** + * Class representing a message event. + * + * @extends Event + * @private + */ +class MessageEvent extends Event { + /** + * Create a new `MessageEvent`. + * + * @param {(String|Buffer|ArrayBuffer|Buffer[])} data The received data + * @param {WebSocket} target A reference to the target to which the event was + * dispatched + */ + constructor(data, target) { + super('message', target); + + this.data = data; + } +} + +/** + * Class representing a close event. + * + * @extends Event + * @private + */ +class CloseEvent extends Event { + /** + * Create a new `CloseEvent`. + * + * @param {Number} code The status code explaining why the connection is being + * closed + * @param {String} reason A human-readable string explaining why the + * connection is closing + * @param {WebSocket} target A reference to the target to which the event was + * dispatched + */ + constructor(code, reason, target) { + super('close', target); + + this.wasClean = target._closeFrameReceived && target._closeFrameSent; + this.reason = reason; + this.code = code; + } +} + +/** + * Class representing an open event. + * + * @extends Event + * @private + */ +class OpenEvent extends Event { + /** + * Create a new `OpenEvent`. + * + * @param {WebSocket} target A reference to the target to which the event was + * dispatched + */ + constructor(target) { + super('open', target); + } +} + +/** + * Class representing an error event. + * + * @extends Event + * @private + */ +class ErrorEvent extends Event { + /** + * Create a new `ErrorEvent`. + * + * @param {Object} error The error that generated this event + * @param {WebSocket} target A reference to the target to which the event was + * dispatched + */ + constructor(error, target) { + super('error', target); + + this.message = error.message; + this.error = error; + } +} + +/** + * This provides methods for emulating the `EventTarget` interface. It's not + * meant to be used directly. + * + * @mixin + */ +const EventTarget = { + /** + * Register an event listener. + * + * @param {String} type A string representing the event type to listen for + * @param {Function} listener The listener to add + * @param {Object} [options] An options object specifies characteristics about + * the event listener + * @param {Boolean} [options.once=false] A `Boolean`` indicating that the + * listener should be invoked at most once after being added. If `true`, + * the listener would be automatically removed when invoked. + * @public + */ + addEventListener(type, listener, options) { + if (typeof listener !== 'function') return; + + function onMessage(data) { + listener.call(this, new MessageEvent(data, this)); + } + + function onClose(code, message) { + listener.call(this, new CloseEvent(code, message, this)); + } + + function onError(error) { + listener.call(this, new ErrorEvent(error, this)); + } + + function onOpen() { + listener.call(this, new OpenEvent(this)); + } + + const method = options && options.once ? 'once' : 'on'; + + if (type === 'message') { + onMessage._listener = listener; + this[method](type, onMessage); + } else if (type === 'close') { + onClose._listener = listener; + this[method](type, onClose); + } else if (type === 'error') { + onError._listener = listener; + this[method](type, onError); + } else if (type === 'open') { + onOpen._listener = listener; + this[method](type, onOpen); + } else { + this[method](type, listener); + } + }, + + /** + * Remove an event listener. + * + * @param {String} type A string representing the event type to remove + * @param {Function} listener The listener to remove + * @public + */ + removeEventListener(type, listener) { + const listeners = this.listeners(type); + + for (let i = 0; i < listeners.length; i++) { + if (listeners[i] === listener || listeners[i]._listener === listener) { + this.removeListener(type, listeners[i]); + } + } + } +}; + +module.exports = EventTarget; diff --git a/jwt-scratch/src/js/node_modules/ws/lib/extension.js b/jwt-scratch/src/js/node_modules/ws/lib/extension.js new file mode 100644 index 0000000..87a4213 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/ws/lib/extension.js @@ -0,0 +1,223 @@ +'use strict'; + +// +// Allowed token characters: +// +// '!', '#', '$', '%', '&', ''', '*', '+', '-', +// '.', 0-9, A-Z, '^', '_', '`', a-z, '|', '~' +// +// tokenChars[32] === 0 // ' ' +// tokenChars[33] === 1 // '!' +// tokenChars[34] === 0 // '"' +// ... +// +// prettier-ignore +const tokenChars = [ + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, // 0 - 15 + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, // 16 - 31 + 0, 1, 0, 1, 1, 1, 1, 1, 0, 0, 1, 1, 0, 1, 1, 0, // 32 - 47 + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, // 48 - 63 + 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, // 64 - 79 + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 1, 1, // 80 - 95 + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, // 96 - 111 + 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 0, 1, 0 // 112 - 127 +]; + +/** + * Adds an offer to the map of extension offers or a parameter to the map of + * parameters. + * + * @param {Object} dest The map of extension offers or parameters + * @param {String} name The extension or parameter name + * @param {(Object|Boolean|String)} elem The extension parameters or the + * parameter value + * @private + */ +function push(dest, name, elem) { + if (dest[name] === undefined) dest[name] = [elem]; + else dest[name].push(elem); +} + +/** + * Parses the `Sec-WebSocket-Extensions` header into an object. + * + * @param {String} header The field value of the header + * @return {Object} The parsed object + * @public + */ +function parse(header) { + const offers = Object.create(null); + + if (header === undefined || header === '') return offers; + + let params = Object.create(null); + let mustUnescape = false; + let isEscaping = false; + let inQuotes = false; + let extensionName; + let paramName; + let start = -1; + let end = -1; + let i = 0; + + for (; i < header.length; i++) { + const code = header.charCodeAt(i); + + if (extensionName === undefined) { + if (end === -1 && tokenChars[code] === 1) { + if (start === -1) start = i; + } else if (code === 0x20 /* ' ' */ || code === 0x09 /* '\t' */) { + if (end === -1 && start !== -1) end = i; + } else if (code === 0x3b /* ';' */ || code === 0x2c /* ',' */) { + if (start === -1) { + throw new SyntaxError(`Unexpected character at index ${i}`); + } + + if (end === -1) end = i; + const name = header.slice(start, end); + if (code === 0x2c) { + push(offers, name, params); + params = Object.create(null); + } else { + extensionName = name; + } + + start = end = -1; + } else { + throw new SyntaxError(`Unexpected character at index ${i}`); + } + } else if (paramName === undefined) { + if (end === -1 && tokenChars[code] === 1) { + if (start === -1) start = i; + } else if (code === 0x20 || code === 0x09) { + if (end === -1 && start !== -1) end = i; + } else if (code === 0x3b || code === 0x2c) { + if (start === -1) { + throw new SyntaxError(`Unexpected character at index ${i}`); + } + + if (end === -1) end = i; + push(params, header.slice(start, end), true); + if (code === 0x2c) { + push(offers, extensionName, params); + params = Object.create(null); + extensionName = undefined; + } + + start = end = -1; + } else if (code === 0x3d /* '=' */ && start !== -1 && end === -1) { + paramName = header.slice(start, i); + start = end = -1; + } else { + throw new SyntaxError(`Unexpected character at index ${i}`); + } + } else { + // + // The value of a quoted-string after unescaping must conform to the + // token ABNF, so only token characters are valid. + // Ref: https://tools.ietf.org/html/rfc6455#section-9.1 + // + if (isEscaping) { + if (tokenChars[code] !== 1) { + throw new SyntaxError(`Unexpected character at index ${i}`); + } + if (start === -1) start = i; + else if (!mustUnescape) mustUnescape = true; + isEscaping = false; + } else if (inQuotes) { + if (tokenChars[code] === 1) { + if (start === -1) start = i; + } else if (code === 0x22 /* '"' */ && start !== -1) { + inQuotes = false; + end = i; + } else if (code === 0x5c /* '\' */) { + isEscaping = true; + } else { + throw new SyntaxError(`Unexpected character at index ${i}`); + } + } else if (code === 0x22 && header.charCodeAt(i - 1) === 0x3d) { + inQuotes = true; + } else if (end === -1 && tokenChars[code] === 1) { + if (start === -1) start = i; + } else if (start !== -1 && (code === 0x20 || code === 0x09)) { + if (end === -1) end = i; + } else if (code === 0x3b || code === 0x2c) { + if (start === -1) { + throw new SyntaxError(`Unexpected character at index ${i}`); + } + + if (end === -1) end = i; + let value = header.slice(start, end); + if (mustUnescape) { + value = value.replace(/\\/g, ''); + mustUnescape = false; + } + push(params, paramName, value); + if (code === 0x2c) { + push(offers, extensionName, params); + params = Object.create(null); + extensionName = undefined; + } + + paramName = undefined; + start = end = -1; + } else { + throw new SyntaxError(`Unexpected character at index ${i}`); + } + } + } + + if (start === -1 || inQuotes) { + throw new SyntaxError('Unexpected end of input'); + } + + if (end === -1) end = i; + const token = header.slice(start, end); + if (extensionName === undefined) { + push(offers, token, params); + } else { + if (paramName === undefined) { + push(params, token, true); + } else if (mustUnescape) { + push(params, paramName, token.replace(/\\/g, '')); + } else { + push(params, paramName, token); + } + push(offers, extensionName, params); + } + + return offers; +} + +/** + * Builds the `Sec-WebSocket-Extensions` header field value. + * + * @param {Object} extensions The map of extensions and parameters to format + * @return {String} A string representing the given object + * @public + */ +function format(extensions) { + return Object.keys(extensions) + .map((extension) => { + let configurations = extensions[extension]; + if (!Array.isArray(configurations)) configurations = [configurations]; + return configurations + .map((params) => { + return [extension] + .concat( + Object.keys(params).map((k) => { + let values = params[k]; + if (!Array.isArray(values)) values = [values]; + return values + .map((v) => (v === true ? k : `${k}=${v}`)) + .join('; '); + }) + ) + .join('; '); + }) + .join(', '); + }) + .join(', '); +} + +module.exports = { format, parse }; diff --git a/jwt-scratch/src/js/node_modules/ws/lib/limiter.js b/jwt-scratch/src/js/node_modules/ws/lib/limiter.js new file mode 100644 index 0000000..3fd3578 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/ws/lib/limiter.js @@ -0,0 +1,55 @@ +'use strict'; + +const kDone = Symbol('kDone'); +const kRun = Symbol('kRun'); + +/** + * A very simple job queue with adjustable concurrency. Adapted from + * https://github.com/STRML/async-limiter + */ +class Limiter { + /** + * Creates a new `Limiter`. + * + * @param {Number} [concurrency=Infinity] The maximum number of jobs allowed + * to run concurrently + */ + constructor(concurrency) { + this[kDone] = () => { + this.pending--; + this[kRun](); + }; + this.concurrency = concurrency || Infinity; + this.jobs = []; + this.pending = 0; + } + + /** + * Adds a job to the queue. + * + * @param {Function} job The job to run + * @public + */ + add(job) { + this.jobs.push(job); + this[kRun](); + } + + /** + * Removes a job from the queue and runs it if possible. + * + * @private + */ + [kRun]() { + if (this.pending === this.concurrency) return; + + if (this.jobs.length) { + const job = this.jobs.shift(); + + this.pending++; + job(this[kDone]); + } + } +} + +module.exports = Limiter; diff --git a/jwt-scratch/src/js/node_modules/ws/lib/permessage-deflate.js b/jwt-scratch/src/js/node_modules/ws/lib/permessage-deflate.js new file mode 100644 index 0000000..a8974b9 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/ws/lib/permessage-deflate.js @@ -0,0 +1,517 @@ +'use strict'; + +const zlib = require('zlib'); + +const bufferUtil = require('./buffer-util'); +const Limiter = require('./limiter'); +const { kStatusCode, NOOP } = require('./constants'); + +const TRAILER = Buffer.from([0x00, 0x00, 0xff, 0xff]); +const kPerMessageDeflate = Symbol('permessage-deflate'); +const kTotalLength = Symbol('total-length'); +const kCallback = Symbol('callback'); +const kBuffers = Symbol('buffers'); +const kError = Symbol('error'); + +// +// We limit zlib concurrency, which prevents severe memory fragmentation +// as documented in https://github.com/nodejs/node/issues/8871#issuecomment-250915913 +// and https://github.com/websockets/ws/issues/1202 +// +// Intentionally global; it's the global thread pool that's an issue. +// +let zlibLimiter; + +/** + * permessage-deflate implementation. + */ +class PerMessageDeflate { + /** + * Creates a PerMessageDeflate instance. + * + * @param {Object} [options] Configuration options + * @param {Boolean} [options.serverNoContextTakeover=false] Request/accept + * disabling of server context takeover + * @param {Boolean} [options.clientNoContextTakeover=false] Advertise/ + * acknowledge disabling of client context takeover + * @param {(Boolean|Number)} [options.serverMaxWindowBits] Request/confirm the + * use of a custom server window size + * @param {(Boolean|Number)} [options.clientMaxWindowBits] Advertise support + * for, or request, a custom client window size + * @param {Object} [options.zlibDeflateOptions] Options to pass to zlib on + * deflate + * @param {Object} [options.zlibInflateOptions] Options to pass to zlib on + * inflate + * @param {Number} [options.threshold=1024] Size (in bytes) below which + * messages should not be compressed + * @param {Number} [options.concurrencyLimit=10] The number of concurrent + * calls to zlib + * @param {Boolean} [isServer=false] Create the instance in either server or + * client mode + * @param {Number} [maxPayload=0] The maximum allowed message length + */ + constructor(options, isServer, maxPayload) { + this._maxPayload = maxPayload | 0; + this._options = options || {}; + this._threshold = + this._options.threshold !== undefined ? this._options.threshold : 1024; + this._isServer = !!isServer; + this._deflate = null; + this._inflate = null; + + this.params = null; + + if (!zlibLimiter) { + const concurrency = + this._options.concurrencyLimit !== undefined + ? this._options.concurrencyLimit + : 10; + zlibLimiter = new Limiter(concurrency); + } + } + + /** + * @type {String} + */ + static get extensionName() { + return 'permessage-deflate'; + } + + /** + * Create an extension negotiation offer. + * + * @return {Object} Extension parameters + * @public + */ + offer() { + const params = {}; + + if (this._options.serverNoContextTakeover) { + params.server_no_context_takeover = true; + } + if (this._options.clientNoContextTakeover) { + params.client_no_context_takeover = true; + } + if (this._options.serverMaxWindowBits) { + params.server_max_window_bits = this._options.serverMaxWindowBits; + } + if (this._options.clientMaxWindowBits) { + params.client_max_window_bits = this._options.clientMaxWindowBits; + } else if (this._options.clientMaxWindowBits == null) { + params.client_max_window_bits = true; + } + + return params; + } + + /** + * Accept an extension negotiation offer/response. + * + * @param {Array} configurations The extension negotiation offers/reponse + * @return {Object} Accepted configuration + * @public + */ + accept(configurations) { + configurations = this.normalizeParams(configurations); + + this.params = this._isServer + ? this.acceptAsServer(configurations) + : this.acceptAsClient(configurations); + + return this.params; + } + + /** + * Releases all resources used by the extension. + * + * @public + */ + cleanup() { + if (this._inflate) { + this._inflate.close(); + this._inflate = null; + } + + if (this._deflate) { + const callback = this._deflate[kCallback]; + + this._deflate.close(); + this._deflate = null; + + if (callback) { + callback( + new Error( + 'The deflate stream was closed while data was being processed' + ) + ); + } + } + } + + /** + * Accept an extension negotiation offer. + * + * @param {Array} offers The extension negotiation offers + * @return {Object} Accepted configuration + * @private + */ + acceptAsServer(offers) { + const opts = this._options; + const accepted = offers.find((params) => { + if ( + (opts.serverNoContextTakeover === false && + params.server_no_context_takeover) || + (params.server_max_window_bits && + (opts.serverMaxWindowBits === false || + (typeof opts.serverMaxWindowBits === 'number' && + opts.serverMaxWindowBits > params.server_max_window_bits))) || + (typeof opts.clientMaxWindowBits === 'number' && + !params.client_max_window_bits) + ) { + return false; + } + + return true; + }); + + if (!accepted) { + throw new Error('None of the extension offers can be accepted'); + } + + if (opts.serverNoContextTakeover) { + accepted.server_no_context_takeover = true; + } + if (opts.clientNoContextTakeover) { + accepted.client_no_context_takeover = true; + } + if (typeof opts.serverMaxWindowBits === 'number') { + accepted.server_max_window_bits = opts.serverMaxWindowBits; + } + if (typeof opts.clientMaxWindowBits === 'number') { + accepted.client_max_window_bits = opts.clientMaxWindowBits; + } else if ( + accepted.client_max_window_bits === true || + opts.clientMaxWindowBits === false + ) { + delete accepted.client_max_window_bits; + } + + return accepted; + } + + /** + * Accept the extension negotiation response. + * + * @param {Array} response The extension negotiation response + * @return {Object} Accepted configuration + * @private + */ + acceptAsClient(response) { + const params = response[0]; + + if ( + this._options.clientNoContextTakeover === false && + params.client_no_context_takeover + ) { + throw new Error('Unexpected parameter "client_no_context_takeover"'); + } + + if (!params.client_max_window_bits) { + if (typeof this._options.clientMaxWindowBits === 'number') { + params.client_max_window_bits = this._options.clientMaxWindowBits; + } + } else if ( + this._options.clientMaxWindowBits === false || + (typeof this._options.clientMaxWindowBits === 'number' && + params.client_max_window_bits > this._options.clientMaxWindowBits) + ) { + throw new Error( + 'Unexpected or invalid parameter "client_max_window_bits"' + ); + } + + return params; + } + + /** + * Normalize parameters. + * + * @param {Array} configurations The extension negotiation offers/reponse + * @return {Array} The offers/response with normalized parameters + * @private + */ + normalizeParams(configurations) { + configurations.forEach((params) => { + Object.keys(params).forEach((key) => { + let value = params[key]; + + if (value.length > 1) { + throw new Error(`Parameter "${key}" must have only a single value`); + } + + value = value[0]; + + if (key === 'client_max_window_bits') { + if (value !== true) { + const num = +value; + if (!Number.isInteger(num) || num < 8 || num > 15) { + throw new TypeError( + `Invalid value for parameter "${key}": ${value}` + ); + } + value = num; + } else if (!this._isServer) { + throw new TypeError( + `Invalid value for parameter "${key}": ${value}` + ); + } + } else if (key === 'server_max_window_bits') { + const num = +value; + if (!Number.isInteger(num) || num < 8 || num > 15) { + throw new TypeError( + `Invalid value for parameter "${key}": ${value}` + ); + } + value = num; + } else if ( + key === 'client_no_context_takeover' || + key === 'server_no_context_takeover' + ) { + if (value !== true) { + throw new TypeError( + `Invalid value for parameter "${key}": ${value}` + ); + } + } else { + throw new Error(`Unknown parameter "${key}"`); + } + + params[key] = value; + }); + }); + + return configurations; + } + + /** + * Decompress data. Concurrency limited. + * + * @param {Buffer} data Compressed data + * @param {Boolean} fin Specifies whether or not this is the last fragment + * @param {Function} callback Callback + * @public + */ + decompress(data, fin, callback) { + zlibLimiter.add((done) => { + this._decompress(data, fin, (err, result) => { + done(); + callback(err, result); + }); + }); + } + + /** + * Compress data. Concurrency limited. + * + * @param {Buffer} data Data to compress + * @param {Boolean} fin Specifies whether or not this is the last fragment + * @param {Function} callback Callback + * @public + */ + compress(data, fin, callback) { + zlibLimiter.add((done) => { + this._compress(data, fin, (err, result) => { + done(); + callback(err, result); + }); + }); + } + + /** + * Decompress data. + * + * @param {Buffer} data Compressed data + * @param {Boolean} fin Specifies whether or not this is the last fragment + * @param {Function} callback Callback + * @private + */ + _decompress(data, fin, callback) { + const endpoint = this._isServer ? 'client' : 'server'; + + if (!this._inflate) { + const key = `${endpoint}_max_window_bits`; + const windowBits = + typeof this.params[key] !== 'number' + ? zlib.Z_DEFAULT_WINDOWBITS + : this.params[key]; + + this._inflate = zlib.createInflateRaw({ + ...this._options.zlibInflateOptions, + windowBits + }); + this._inflate[kPerMessageDeflate] = this; + this._inflate[kTotalLength] = 0; + this._inflate[kBuffers] = []; + this._inflate.on('error', inflateOnError); + this._inflate.on('data', inflateOnData); + } + + this._inflate[kCallback] = callback; + + this._inflate.write(data); + if (fin) this._inflate.write(TRAILER); + + this._inflate.flush(() => { + const err = this._inflate[kError]; + + if (err) { + this._inflate.close(); + this._inflate = null; + callback(err); + return; + } + + const data = bufferUtil.concat( + this._inflate[kBuffers], + this._inflate[kTotalLength] + ); + + if (this._inflate._readableState.endEmitted) { + this._inflate.close(); + this._inflate = null; + } else { + this._inflate[kTotalLength] = 0; + this._inflate[kBuffers] = []; + + if (fin && this.params[`${endpoint}_no_context_takeover`]) { + this._inflate.reset(); + } + } + + callback(null, data); + }); + } + + /** + * Compress data. + * + * @param {Buffer} data Data to compress + * @param {Boolean} fin Specifies whether or not this is the last fragment + * @param {Function} callback Callback + * @private + */ + _compress(data, fin, callback) { + const endpoint = this._isServer ? 'server' : 'client'; + + if (!this._deflate) { + const key = `${endpoint}_max_window_bits`; + const windowBits = + typeof this.params[key] !== 'number' + ? zlib.Z_DEFAULT_WINDOWBITS + : this.params[key]; + + this._deflate = zlib.createDeflateRaw({ + ...this._options.zlibDeflateOptions, + windowBits + }); + + this._deflate[kTotalLength] = 0; + this._deflate[kBuffers] = []; + + // + // An `'error'` event is emitted, only on Node.js < 10.0.0, if the + // `zlib.DeflateRaw` instance is closed while data is being processed. + // This can happen if `PerMessageDeflate#cleanup()` is called at the wrong + // time due to an abnormal WebSocket closure. + // + this._deflate.on('error', NOOP); + this._deflate.on('data', deflateOnData); + } + + this._deflate[kCallback] = callback; + + this._deflate.write(data); + this._deflate.flush(zlib.Z_SYNC_FLUSH, () => { + if (!this._deflate) { + // + // The deflate stream was closed while data was being processed. + // + return; + } + + let data = bufferUtil.concat( + this._deflate[kBuffers], + this._deflate[kTotalLength] + ); + + if (fin) data = data.slice(0, data.length - 4); + + // + // Ensure that the callback will not be called again in + // `PerMessageDeflate#cleanup()`. + // + this._deflate[kCallback] = null; + + this._deflate[kTotalLength] = 0; + this._deflate[kBuffers] = []; + + if (fin && this.params[`${endpoint}_no_context_takeover`]) { + this._deflate.reset(); + } + + callback(null, data); + }); + } +} + +module.exports = PerMessageDeflate; + +/** + * The listener of the `zlib.DeflateRaw` stream `'data'` event. + * + * @param {Buffer} chunk A chunk of data + * @private + */ +function deflateOnData(chunk) { + this[kBuffers].push(chunk); + this[kTotalLength] += chunk.length; +} + +/** + * The listener of the `zlib.InflateRaw` stream `'data'` event. + * + * @param {Buffer} chunk A chunk of data + * @private + */ +function inflateOnData(chunk) { + this[kTotalLength] += chunk.length; + + if ( + this[kPerMessageDeflate]._maxPayload < 1 || + this[kTotalLength] <= this[kPerMessageDeflate]._maxPayload + ) { + this[kBuffers].push(chunk); + return; + } + + this[kError] = new RangeError('Max payload size exceeded'); + this[kError][kStatusCode] = 1009; + this.removeListener('data', inflateOnData); + this.reset(); +} + +/** + * The listener of the `zlib.InflateRaw` stream `'error'` event. + * + * @param {Error} err The emitted error + * @private + */ +function inflateOnError(err) { + // + // There is no need to call `Zlib#close()` as the handle is automatically + // closed when an error is emitted. + // + this[kPerMessageDeflate]._inflate = null; + err[kStatusCode] = 1007; + this[kCallback](err); +} diff --git a/jwt-scratch/src/js/node_modules/ws/lib/receiver.js b/jwt-scratch/src/js/node_modules/ws/lib/receiver.js new file mode 100644 index 0000000..65a5ab4 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/ws/lib/receiver.js @@ -0,0 +1,507 @@ +'use strict'; + +const { Writable } = require('stream'); + +const PerMessageDeflate = require('./permessage-deflate'); +const { + BINARY_TYPES, + EMPTY_BUFFER, + kStatusCode, + kWebSocket +} = require('./constants'); +const { concat, toArrayBuffer, unmask } = require('./buffer-util'); +const { isValidStatusCode, isValidUTF8 } = require('./validation'); + +const GET_INFO = 0; +const GET_PAYLOAD_LENGTH_16 = 1; +const GET_PAYLOAD_LENGTH_64 = 2; +const GET_MASK = 3; +const GET_DATA = 4; +const INFLATING = 5; + +/** + * HyBi Receiver implementation. + * + * @extends stream.Writable + */ +class Receiver extends Writable { + /** + * Creates a Receiver instance. + * + * @param {String} [binaryType=nodebuffer] The type for binary data + * @param {Object} [extensions] An object containing the negotiated extensions + * @param {Boolean} [isServer=false] Specifies whether to operate in client or + * server mode + * @param {Number} [maxPayload=0] The maximum allowed message length + */ + constructor(binaryType, extensions, isServer, maxPayload) { + super(); + + this._binaryType = binaryType || BINARY_TYPES[0]; + this[kWebSocket] = undefined; + this._extensions = extensions || {}; + this._isServer = !!isServer; + this._maxPayload = maxPayload | 0; + + this._bufferedBytes = 0; + this._buffers = []; + + this._compressed = false; + this._payloadLength = 0; + this._mask = undefined; + this._fragmented = 0; + this._masked = false; + this._fin = false; + this._opcode = 0; + + this._totalPayloadLength = 0; + this._messageLength = 0; + this._fragments = []; + + this._state = GET_INFO; + this._loop = false; + } + + /** + * Implements `Writable.prototype._write()`. + * + * @param {Buffer} chunk The chunk of data to write + * @param {String} encoding The character encoding of `chunk` + * @param {Function} cb Callback + * @private + */ + _write(chunk, encoding, cb) { + if (this._opcode === 0x08 && this._state == GET_INFO) return cb(); + + this._bufferedBytes += chunk.length; + this._buffers.push(chunk); + this.startLoop(cb); + } + + /** + * Consumes `n` bytes from the buffered data. + * + * @param {Number} n The number of bytes to consume + * @return {Buffer} The consumed bytes + * @private + */ + consume(n) { + this._bufferedBytes -= n; + + if (n === this._buffers[0].length) return this._buffers.shift(); + + if (n < this._buffers[0].length) { + const buf = this._buffers[0]; + this._buffers[0] = buf.slice(n); + return buf.slice(0, n); + } + + const dst = Buffer.allocUnsafe(n); + + do { + const buf = this._buffers[0]; + const offset = dst.length - n; + + if (n >= buf.length) { + dst.set(this._buffers.shift(), offset); + } else { + dst.set(new Uint8Array(buf.buffer, buf.byteOffset, n), offset); + this._buffers[0] = buf.slice(n); + } + + n -= buf.length; + } while (n > 0); + + return dst; + } + + /** + * Starts the parsing loop. + * + * @param {Function} cb Callback + * @private + */ + startLoop(cb) { + let err; + this._loop = true; + + do { + switch (this._state) { + case GET_INFO: + err = this.getInfo(); + break; + case GET_PAYLOAD_LENGTH_16: + err = this.getPayloadLength16(); + break; + case GET_PAYLOAD_LENGTH_64: + err = this.getPayloadLength64(); + break; + case GET_MASK: + this.getMask(); + break; + case GET_DATA: + err = this.getData(cb); + break; + default: + // `INFLATING` + this._loop = false; + return; + } + } while (this._loop); + + cb(err); + } + + /** + * Reads the first two bytes of a frame. + * + * @return {(RangeError|undefined)} A possible error + * @private + */ + getInfo() { + if (this._bufferedBytes < 2) { + this._loop = false; + return; + } + + const buf = this.consume(2); + + if ((buf[0] & 0x30) !== 0x00) { + this._loop = false; + return error(RangeError, 'RSV2 and RSV3 must be clear', true, 1002); + } + + const compressed = (buf[0] & 0x40) === 0x40; + + if (compressed && !this._extensions[PerMessageDeflate.extensionName]) { + this._loop = false; + return error(RangeError, 'RSV1 must be clear', true, 1002); + } + + this._fin = (buf[0] & 0x80) === 0x80; + this._opcode = buf[0] & 0x0f; + this._payloadLength = buf[1] & 0x7f; + + if (this._opcode === 0x00) { + if (compressed) { + this._loop = false; + return error(RangeError, 'RSV1 must be clear', true, 1002); + } + + if (!this._fragmented) { + this._loop = false; + return error(RangeError, 'invalid opcode 0', true, 1002); + } + + this._opcode = this._fragmented; + } else if (this._opcode === 0x01 || this._opcode === 0x02) { + if (this._fragmented) { + this._loop = false; + return error(RangeError, `invalid opcode ${this._opcode}`, true, 1002); + } + + this._compressed = compressed; + } else if (this._opcode > 0x07 && this._opcode < 0x0b) { + if (!this._fin) { + this._loop = false; + return error(RangeError, 'FIN must be set', true, 1002); + } + + if (compressed) { + this._loop = false; + return error(RangeError, 'RSV1 must be clear', true, 1002); + } + + if (this._payloadLength > 0x7d) { + this._loop = false; + return error( + RangeError, + `invalid payload length ${this._payloadLength}`, + true, + 1002 + ); + } + } else { + this._loop = false; + return error(RangeError, `invalid opcode ${this._opcode}`, true, 1002); + } + + if (!this._fin && !this._fragmented) this._fragmented = this._opcode; + this._masked = (buf[1] & 0x80) === 0x80; + + if (this._isServer) { + if (!this._masked) { + this._loop = false; + return error(RangeError, 'MASK must be set', true, 1002); + } + } else if (this._masked) { + this._loop = false; + return error(RangeError, 'MASK must be clear', true, 1002); + } + + if (this._payloadLength === 126) this._state = GET_PAYLOAD_LENGTH_16; + else if (this._payloadLength === 127) this._state = GET_PAYLOAD_LENGTH_64; + else return this.haveLength(); + } + + /** + * Gets extended payload length (7+16). + * + * @return {(RangeError|undefined)} A possible error + * @private + */ + getPayloadLength16() { + if (this._bufferedBytes < 2) { + this._loop = false; + return; + } + + this._payloadLength = this.consume(2).readUInt16BE(0); + return this.haveLength(); + } + + /** + * Gets extended payload length (7+64). + * + * @return {(RangeError|undefined)} A possible error + * @private + */ + getPayloadLength64() { + if (this._bufferedBytes < 8) { + this._loop = false; + return; + } + + const buf = this.consume(8); + const num = buf.readUInt32BE(0); + + // + // The maximum safe integer in JavaScript is 2^53 - 1. An error is returned + // if payload length is greater than this number. + // + if (num > Math.pow(2, 53 - 32) - 1) { + this._loop = false; + return error( + RangeError, + 'Unsupported WebSocket frame: payload length > 2^53 - 1', + false, + 1009 + ); + } + + this._payloadLength = num * Math.pow(2, 32) + buf.readUInt32BE(4); + return this.haveLength(); + } + + /** + * Payload length has been read. + * + * @return {(RangeError|undefined)} A possible error + * @private + */ + haveLength() { + if (this._payloadLength && this._opcode < 0x08) { + this._totalPayloadLength += this._payloadLength; + if (this._totalPayloadLength > this._maxPayload && this._maxPayload > 0) { + this._loop = false; + return error(RangeError, 'Max payload size exceeded', false, 1009); + } + } + + if (this._masked) this._state = GET_MASK; + else this._state = GET_DATA; + } + + /** + * Reads mask bytes. + * + * @private + */ + getMask() { + if (this._bufferedBytes < 4) { + this._loop = false; + return; + } + + this._mask = this.consume(4); + this._state = GET_DATA; + } + + /** + * Reads data bytes. + * + * @param {Function} cb Callback + * @return {(Error|RangeError|undefined)} A possible error + * @private + */ + getData(cb) { + let data = EMPTY_BUFFER; + + if (this._payloadLength) { + if (this._bufferedBytes < this._payloadLength) { + this._loop = false; + return; + } + + data = this.consume(this._payloadLength); + if (this._masked) unmask(data, this._mask); + } + + if (this._opcode > 0x07) return this.controlMessage(data); + + if (this._compressed) { + this._state = INFLATING; + this.decompress(data, cb); + return; + } + + if (data.length) { + // + // This message is not compressed so its lenght is the sum of the payload + // length of all fragments. + // + this._messageLength = this._totalPayloadLength; + this._fragments.push(data); + } + + return this.dataMessage(); + } + + /** + * Decompresses data. + * + * @param {Buffer} data Compressed data + * @param {Function} cb Callback + * @private + */ + decompress(data, cb) { + const perMessageDeflate = this._extensions[PerMessageDeflate.extensionName]; + + perMessageDeflate.decompress(data, this._fin, (err, buf) => { + if (err) return cb(err); + + if (buf.length) { + this._messageLength += buf.length; + if (this._messageLength > this._maxPayload && this._maxPayload > 0) { + return cb( + error(RangeError, 'Max payload size exceeded', false, 1009) + ); + } + + this._fragments.push(buf); + } + + const er = this.dataMessage(); + if (er) return cb(er); + + this.startLoop(cb); + }); + } + + /** + * Handles a data message. + * + * @return {(Error|undefined)} A possible error + * @private + */ + dataMessage() { + if (this._fin) { + const messageLength = this._messageLength; + const fragments = this._fragments; + + this._totalPayloadLength = 0; + this._messageLength = 0; + this._fragmented = 0; + this._fragments = []; + + if (this._opcode === 2) { + let data; + + if (this._binaryType === 'nodebuffer') { + data = concat(fragments, messageLength); + } else if (this._binaryType === 'arraybuffer') { + data = toArrayBuffer(concat(fragments, messageLength)); + } else { + data = fragments; + } + + this.emit('message', data); + } else { + const buf = concat(fragments, messageLength); + + if (!isValidUTF8(buf)) { + this._loop = false; + return error(Error, 'invalid UTF-8 sequence', true, 1007); + } + + this.emit('message', buf.toString()); + } + } + + this._state = GET_INFO; + } + + /** + * Handles a control message. + * + * @param {Buffer} data Data to handle + * @return {(Error|RangeError|undefined)} A possible error + * @private + */ + controlMessage(data) { + if (this._opcode === 0x08) { + this._loop = false; + + if (data.length === 0) { + this.emit('conclude', 1005, ''); + this.end(); + } else if (data.length === 1) { + return error(RangeError, 'invalid payload length 1', true, 1002); + } else { + const code = data.readUInt16BE(0); + + if (!isValidStatusCode(code)) { + return error(RangeError, `invalid status code ${code}`, true, 1002); + } + + const buf = data.slice(2); + + if (!isValidUTF8(buf)) { + return error(Error, 'invalid UTF-8 sequence', true, 1007); + } + + this.emit('conclude', code, buf.toString()); + this.end(); + } + } else if (this._opcode === 0x09) { + this.emit('ping', data); + } else { + this.emit('pong', data); + } + + this._state = GET_INFO; + } +} + +module.exports = Receiver; + +/** + * Builds an error object. + * + * @param {(Error|RangeError)} ErrorCtor The error constructor + * @param {String} message The error message + * @param {Boolean} prefix Specifies whether or not to add a default prefix to + * `message` + * @param {Number} statusCode The status code + * @return {(Error|RangeError)} The error + * @private + */ +function error(ErrorCtor, message, prefix, statusCode) { + const err = new ErrorCtor( + prefix ? `Invalid WebSocket frame: ${message}` : message + ); + + Error.captureStackTrace(err, error); + err[kStatusCode] = statusCode; + return err; +} diff --git a/jwt-scratch/src/js/node_modules/ws/lib/sender.js b/jwt-scratch/src/js/node_modules/ws/lib/sender.js new file mode 100644 index 0000000..ad71e19 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/ws/lib/sender.js @@ -0,0 +1,405 @@ +'use strict'; + +const { randomFillSync } = require('crypto'); + +const PerMessageDeflate = require('./permessage-deflate'); +const { EMPTY_BUFFER } = require('./constants'); +const { isValidStatusCode } = require('./validation'); +const { mask: applyMask, toBuffer } = require('./buffer-util'); + +const mask = Buffer.alloc(4); + +/** + * HyBi Sender implementation. + */ +class Sender { + /** + * Creates a Sender instance. + * + * @param {net.Socket} socket The connection socket + * @param {Object} [extensions] An object containing the negotiated extensions + */ + constructor(socket, extensions) { + this._extensions = extensions || {}; + this._socket = socket; + + this._firstFragment = true; + this._compress = false; + + this._bufferedBytes = 0; + this._deflating = false; + this._queue = []; + } + + /** + * Frames a piece of data according to the HyBi WebSocket protocol. + * + * @param {Buffer} data The data to frame + * @param {Object} options Options object + * @param {Number} options.opcode The opcode + * @param {Boolean} [options.readOnly=false] Specifies whether `data` can be + * modified + * @param {Boolean} [options.fin=false] Specifies whether or not to set the + * FIN bit + * @param {Boolean} [options.mask=false] Specifies whether or not to mask + * `data` + * @param {Boolean} [options.rsv1=false] Specifies whether or not to set the + * RSV1 bit + * @return {Buffer[]} The framed data as a list of `Buffer` instances + * @public + */ + static frame(data, options) { + const merge = options.mask && options.readOnly; + let offset = options.mask ? 6 : 2; + let payloadLength = data.length; + + if (data.length >= 65536) { + offset += 8; + payloadLength = 127; + } else if (data.length > 125) { + offset += 2; + payloadLength = 126; + } + + const target = Buffer.allocUnsafe(merge ? data.length + offset : offset); + + target[0] = options.fin ? options.opcode | 0x80 : options.opcode; + if (options.rsv1) target[0] |= 0x40; + + target[1] = payloadLength; + + if (payloadLength === 126) { + target.writeUInt16BE(data.length, 2); + } else if (payloadLength === 127) { + target.writeUInt32BE(0, 2); + target.writeUInt32BE(data.length, 6); + } + + if (!options.mask) return [target, data]; + + randomFillSync(mask, 0, 4); + + target[1] |= 0x80; + target[offset - 4] = mask[0]; + target[offset - 3] = mask[1]; + target[offset - 2] = mask[2]; + target[offset - 1] = mask[3]; + + if (merge) { + applyMask(data, mask, target, offset, data.length); + return [target]; + } + + applyMask(data, mask, data, 0, data.length); + return [target, data]; + } + + /** + * Sends a close message to the other peer. + * + * @param {Number} [code] The status code component of the body + * @param {String} [data] The message component of the body + * @param {Boolean} [mask=false] Specifies whether or not to mask the message + * @param {Function} [cb] Callback + * @public + */ + close(code, data, mask, cb) { + let buf; + + if (code === undefined) { + buf = EMPTY_BUFFER; + } else if (typeof code !== 'number' || !isValidStatusCode(code)) { + throw new TypeError('First argument must be a valid error code number'); + } else if (data === undefined || data === '') { + buf = Buffer.allocUnsafe(2); + buf.writeUInt16BE(code, 0); + } else { + const length = Buffer.byteLength(data); + + if (length > 123) { + throw new RangeError('The message must not be greater than 123 bytes'); + } + + buf = Buffer.allocUnsafe(2 + length); + buf.writeUInt16BE(code, 0); + buf.write(data, 2); + } + + if (this._deflating) { + this.enqueue([this.doClose, buf, mask, cb]); + } else { + this.doClose(buf, mask, cb); + } + } + + /** + * Frames and sends a close message. + * + * @param {Buffer} data The message to send + * @param {Boolean} [mask=false] Specifies whether or not to mask `data` + * @param {Function} [cb] Callback + * @private + */ + doClose(data, mask, cb) { + this.sendFrame( + Sender.frame(data, { + fin: true, + rsv1: false, + opcode: 0x08, + mask, + readOnly: false + }), + cb + ); + } + + /** + * Sends a ping message to the other peer. + * + * @param {*} data The message to send + * @param {Boolean} [mask=false] Specifies whether or not to mask `data` + * @param {Function} [cb] Callback + * @public + */ + ping(data, mask, cb) { + const buf = toBuffer(data); + + if (buf.length > 125) { + throw new RangeError('The data size must not be greater than 125 bytes'); + } + + if (this._deflating) { + this.enqueue([this.doPing, buf, mask, toBuffer.readOnly, cb]); + } else { + this.doPing(buf, mask, toBuffer.readOnly, cb); + } + } + + /** + * Frames and sends a ping message. + * + * @param {Buffer} data The message to send + * @param {Boolean} [mask=false] Specifies whether or not to mask `data` + * @param {Boolean} [readOnly=false] Specifies whether `data` can be modified + * @param {Function} [cb] Callback + * @private + */ + doPing(data, mask, readOnly, cb) { + this.sendFrame( + Sender.frame(data, { + fin: true, + rsv1: false, + opcode: 0x09, + mask, + readOnly + }), + cb + ); + } + + /** + * Sends a pong message to the other peer. + * + * @param {*} data The message to send + * @param {Boolean} [mask=false] Specifies whether or not to mask `data` + * @param {Function} [cb] Callback + * @public + */ + pong(data, mask, cb) { + const buf = toBuffer(data); + + if (buf.length > 125) { + throw new RangeError('The data size must not be greater than 125 bytes'); + } + + if (this._deflating) { + this.enqueue([this.doPong, buf, mask, toBuffer.readOnly, cb]); + } else { + this.doPong(buf, mask, toBuffer.readOnly, cb); + } + } + + /** + * Frames and sends a pong message. + * + * @param {Buffer} data The message to send + * @param {Boolean} [mask=false] Specifies whether or not to mask `data` + * @param {Boolean} [readOnly=false] Specifies whether `data` can be modified + * @param {Function} [cb] Callback + * @private + */ + doPong(data, mask, readOnly, cb) { + this.sendFrame( + Sender.frame(data, { + fin: true, + rsv1: false, + opcode: 0x0a, + mask, + readOnly + }), + cb + ); + } + + /** + * Sends a data message to the other peer. + * + * @param {*} data The message to send + * @param {Object} options Options object + * @param {Boolean} [options.compress=false] Specifies whether or not to + * compress `data` + * @param {Boolean} [options.binary=false] Specifies whether `data` is binary + * or text + * @param {Boolean} [options.fin=false] Specifies whether the fragment is the + * last one + * @param {Boolean} [options.mask=false] Specifies whether or not to mask + * `data` + * @param {Function} [cb] Callback + * @public + */ + send(data, options, cb) { + const buf = toBuffer(data); + const perMessageDeflate = this._extensions[PerMessageDeflate.extensionName]; + let opcode = options.binary ? 2 : 1; + let rsv1 = options.compress; + + if (this._firstFragment) { + this._firstFragment = false; + if (rsv1 && perMessageDeflate) { + rsv1 = buf.length >= perMessageDeflate._threshold; + } + this._compress = rsv1; + } else { + rsv1 = false; + opcode = 0; + } + + if (options.fin) this._firstFragment = true; + + if (perMessageDeflate) { + const opts = { + fin: options.fin, + rsv1, + opcode, + mask: options.mask, + readOnly: toBuffer.readOnly + }; + + if (this._deflating) { + this.enqueue([this.dispatch, buf, this._compress, opts, cb]); + } else { + this.dispatch(buf, this._compress, opts, cb); + } + } else { + this.sendFrame( + Sender.frame(buf, { + fin: options.fin, + rsv1: false, + opcode, + mask: options.mask, + readOnly: toBuffer.readOnly + }), + cb + ); + } + } + + /** + * Dispatches a data message. + * + * @param {Buffer} data The message to send + * @param {Boolean} [compress=false] Specifies whether or not to compress + * `data` + * @param {Object} options Options object + * @param {Number} options.opcode The opcode + * @param {Boolean} [options.readOnly=false] Specifies whether `data` can be + * modified + * @param {Boolean} [options.fin=false] Specifies whether or not to set the + * FIN bit + * @param {Boolean} [options.mask=false] Specifies whether or not to mask + * `data` + * @param {Boolean} [options.rsv1=false] Specifies whether or not to set the + * RSV1 bit + * @param {Function} [cb] Callback + * @private + */ + dispatch(data, compress, options, cb) { + if (!compress) { + this.sendFrame(Sender.frame(data, options), cb); + return; + } + + const perMessageDeflate = this._extensions[PerMessageDeflate.extensionName]; + + this._bufferedBytes += data.length; + this._deflating = true; + perMessageDeflate.compress(data, options.fin, (_, buf) => { + if (this._socket.destroyed) { + const err = new Error( + 'The socket was closed while data was being compressed' + ); + + if (typeof cb === 'function') cb(err); + + for (let i = 0; i < this._queue.length; i++) { + const callback = this._queue[i][4]; + + if (typeof callback === 'function') callback(err); + } + + return; + } + + this._bufferedBytes -= data.length; + this._deflating = false; + options.readOnly = false; + this.sendFrame(Sender.frame(buf, options), cb); + this.dequeue(); + }); + } + + /** + * Executes queued send operations. + * + * @private + */ + dequeue() { + while (!this._deflating && this._queue.length) { + const params = this._queue.shift(); + + this._bufferedBytes -= params[1].length; + Reflect.apply(params[0], this, params.slice(1)); + } + } + + /** + * Enqueues a send operation. + * + * @param {Array} params Send operation parameters. + * @private + */ + enqueue(params) { + this._bufferedBytes += params[1].length; + this._queue.push(params); + } + + /** + * Sends a frame. + * + * @param {Buffer[]} list The frame to send + * @param {Function} [cb] Callback + * @private + */ + sendFrame(list, cb) { + if (list.length === 2) { + this._socket.cork(); + this._socket.write(list[0]); + this._socket.write(list[1], cb); + this._socket.uncork(); + } else { + this._socket.write(list[0], cb); + } + } +} + +module.exports = Sender; diff --git a/jwt-scratch/src/js/node_modules/ws/lib/stream.js b/jwt-scratch/src/js/node_modules/ws/lib/stream.js new file mode 100644 index 0000000..604cf36 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/ws/lib/stream.js @@ -0,0 +1,165 @@ +'use strict'; + +const { Duplex } = require('stream'); + +/** + * Emits the `'close'` event on a stream. + * + * @param {stream.Duplex} The stream. + * @private + */ +function emitClose(stream) { + stream.emit('close'); +} + +/** + * The listener of the `'end'` event. + * + * @private + */ +function duplexOnEnd() { + if (!this.destroyed && this._writableState.finished) { + this.destroy(); + } +} + +/** + * The listener of the `'error'` event. + * + * @param {Error} err The error + * @private + */ +function duplexOnError(err) { + this.removeListener('error', duplexOnError); + this.destroy(); + if (this.listenerCount('error') === 0) { + // Do not suppress the throwing behavior. + this.emit('error', err); + } +} + +/** + * Wraps a `WebSocket` in a duplex stream. + * + * @param {WebSocket} ws The `WebSocket` to wrap + * @param {Object} [options] The options for the `Duplex` constructor + * @return {stream.Duplex} The duplex stream + * @public + */ +function createWebSocketStream(ws, options) { + let resumeOnReceiverDrain = true; + + function receiverOnDrain() { + if (resumeOnReceiverDrain) ws._socket.resume(); + } + + if (ws.readyState === ws.CONNECTING) { + ws.once('open', function open() { + ws._receiver.removeAllListeners('drain'); + ws._receiver.on('drain', receiverOnDrain); + }); + } else { + ws._receiver.removeAllListeners('drain'); + ws._receiver.on('drain', receiverOnDrain); + } + + const duplex = new Duplex({ + ...options, + autoDestroy: false, + emitClose: false, + objectMode: false, + writableObjectMode: false + }); + + ws.on('message', function message(msg) { + if (!duplex.push(msg)) { + resumeOnReceiverDrain = false; + ws._socket.pause(); + } + }); + + ws.once('error', function error(err) { + if (duplex.destroyed) return; + + duplex.destroy(err); + }); + + ws.once('close', function close() { + if (duplex.destroyed) return; + + duplex.push(null); + }); + + duplex._destroy = function (err, callback) { + if (ws.readyState === ws.CLOSED) { + callback(err); + process.nextTick(emitClose, duplex); + return; + } + + let called = false; + + ws.once('error', function error(err) { + called = true; + callback(err); + }); + + ws.once('close', function close() { + if (!called) callback(err); + process.nextTick(emitClose, duplex); + }); + ws.terminate(); + }; + + duplex._final = function (callback) { + if (ws.readyState === ws.CONNECTING) { + ws.once('open', function open() { + duplex._final(callback); + }); + return; + } + + // If the value of the `_socket` property is `null` it means that `ws` is a + // client websocket and the handshake failed. In fact, when this happens, a + // socket is never assigned to the websocket. Wait for the `'error'` event + // that will be emitted by the websocket. + if (ws._socket === null) return; + + if (ws._socket._writableState.finished) { + callback(); + if (duplex._readableState.endEmitted) duplex.destroy(); + } else { + ws._socket.once('finish', function finish() { + // `duplex` is not destroyed here because the `'end'` event will be + // emitted on `duplex` after this `'finish'` event. The EOF signaling + // `null` chunk is, in fact, pushed when the websocket emits `'close'`. + callback(); + }); + ws.close(); + } + }; + + duplex._read = function () { + if (ws.readyState === ws.OPEN && !resumeOnReceiverDrain) { + resumeOnReceiverDrain = true; + if (!ws._receiver._writableState.needDrain) ws._socket.resume(); + } + }; + + duplex._write = function (chunk, encoding, callback) { + if (ws.readyState === ws.CONNECTING) { + ws.once('open', function open() { + duplex._write(chunk, encoding, callback); + }); + return; + } + + ws.send(chunk, callback); + }; + + duplex.on('end', duplexOnEnd); + duplex.on('error', duplexOnError); + return duplex; +} + +module.exports = createWebSocketStream; diff --git a/jwt-scratch/src/js/node_modules/ws/lib/validation.js b/jwt-scratch/src/js/node_modules/ws/lib/validation.js new file mode 100644 index 0000000..d8693fd --- /dev/null +++ b/jwt-scratch/src/js/node_modules/ws/lib/validation.js @@ -0,0 +1,104 @@ +'use strict'; + +/** + * Checks if a status code is allowed in a close frame. + * + * @param {Number} code The status code + * @return {Boolean} `true` if the status code is valid, else `false` + * @public + */ +function isValidStatusCode(code) { + return ( + (code >= 1000 && + code <= 1014 && + code !== 1004 && + code !== 1005 && + code !== 1006) || + (code >= 3000 && code <= 4999) + ); +} + +/** + * Checks if a given buffer contains only correct UTF-8. + * Ported from https://www.cl.cam.ac.uk/%7Emgk25/ucs/utf8_check.c by + * Markus Kuhn. + * + * @param {Buffer} buf The buffer to check + * @return {Boolean} `true` if `buf` contains only correct UTF-8, else `false` + * @public + */ +function _isValidUTF8(buf) { + const len = buf.length; + let i = 0; + + while (i < len) { + if (buf[i] < 0x80) { + // 0xxxxxxx + i++; + } else if ((buf[i] & 0xe0) === 0xc0) { + // 110xxxxx 10xxxxxx + if ( + i + 1 === len || + (buf[i + 1] & 0xc0) !== 0x80 || + (buf[i] & 0xfe) === 0xc0 // Overlong + ) { + return false; + } else { + i += 2; + } + } else if ((buf[i] & 0xf0) === 0xe0) { + // 1110xxxx 10xxxxxx 10xxxxxx + if ( + i + 2 >= len || + (buf[i + 1] & 0xc0) !== 0x80 || + (buf[i + 2] & 0xc0) !== 0x80 || + (buf[i] === 0xe0 && (buf[i + 1] & 0xe0) === 0x80) || // Overlong + (buf[i] === 0xed && (buf[i + 1] & 0xe0) === 0xa0) // Surrogate (U+D800 - U+DFFF) + ) { + return false; + } else { + i += 3; + } + } else if ((buf[i] & 0xf8) === 0xf0) { + // 11110xxx 10xxxxxx 10xxxxxx 10xxxxxx + if ( + i + 3 >= len || + (buf[i + 1] & 0xc0) !== 0x80 || + (buf[i + 2] & 0xc0) !== 0x80 || + (buf[i + 3] & 0xc0) !== 0x80 || + (buf[i] === 0xf0 && (buf[i + 1] & 0xf0) === 0x80) || // Overlong + (buf[i] === 0xf4 && buf[i + 1] > 0x8f) || + buf[i] > 0xf4 // > U+10FFFF + ) { + return false; + } else { + i += 4; + } + } else { + return false; + } + } + + return true; +} + +try { + let isValidUTF8 = require('utf-8-validate'); + + /* istanbul ignore if */ + if (typeof isValidUTF8 === 'object') { + isValidUTF8 = isValidUTF8.Validation.isValidUTF8; // utf-8-validate@<3.0.0 + } + + module.exports = { + isValidStatusCode, + isValidUTF8(buf) { + return buf.length < 150 ? _isValidUTF8(buf) : isValidUTF8(buf); + } + }; +} catch (e) /* istanbul ignore next */ { + module.exports = { + isValidStatusCode, + isValidUTF8: _isValidUTF8 + }; +} diff --git a/jwt-scratch/src/js/node_modules/ws/lib/websocket-server.js b/jwt-scratch/src/js/node_modules/ws/lib/websocket-server.js new file mode 100644 index 0000000..b99ad05 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/ws/lib/websocket-server.js @@ -0,0 +1,406 @@ +'use strict'; + +const EventEmitter = require('events'); +const { createHash } = require('crypto'); +const { createServer, STATUS_CODES } = require('http'); + +const PerMessageDeflate = require('./permessage-deflate'); +const WebSocket = require('./websocket'); +const { format, parse } = require('./extension'); +const { GUID, kWebSocket } = require('./constants'); + +const keyRegex = /^[+/0-9A-Za-z]{22}==$/; + +/** + * Class representing a WebSocket server. + * + * @extends EventEmitter + */ +class WebSocketServer extends EventEmitter { + /** + * Create a `WebSocketServer` instance. + * + * @param {Object} options Configuration options + * @param {Number} [options.backlog=511] The maximum length of the queue of + * pending connections + * @param {Boolean} [options.clientTracking=true] Specifies whether or not to + * track clients + * @param {Function} [options.handleProtocols] A hook to handle protocols + * @param {String} [options.host] The hostname where to bind the server + * @param {Number} [options.maxPayload=104857600] The maximum allowed message + * size + * @param {Boolean} [options.noServer=false] Enable no server mode + * @param {String} [options.path] Accept only connections matching this path + * @param {(Boolean|Object)} [options.perMessageDeflate=false] Enable/disable + * permessage-deflate + * @param {Number} [options.port] The port where to bind the server + * @param {http.Server} [options.server] A pre-created HTTP/S server to use + * @param {Function} [options.verifyClient] A hook to reject connections + * @param {Function} [callback] A listener for the `listening` event + */ + constructor(options, callback) { + super(); + + options = { + maxPayload: 100 * 1024 * 1024, + perMessageDeflate: false, + handleProtocols: null, + clientTracking: true, + verifyClient: null, + noServer: false, + backlog: null, // use default (511 as implemented in net.js) + server: null, + host: null, + path: null, + port: null, + ...options + }; + + if (options.port == null && !options.server && !options.noServer) { + throw new TypeError( + 'One of the "port", "server", or "noServer" options must be specified' + ); + } + + if (options.port != null) { + this._server = createServer((req, res) => { + const body = STATUS_CODES[426]; + + res.writeHead(426, { + 'Content-Length': body.length, + 'Content-Type': 'text/plain' + }); + res.end(body); + }); + this._server.listen( + options.port, + options.host, + options.backlog, + callback + ); + } else if (options.server) { + this._server = options.server; + } + + if (this._server) { + const emitConnection = this.emit.bind(this, 'connection'); + + this._removeListeners = addListeners(this._server, { + listening: this.emit.bind(this, 'listening'), + error: this.emit.bind(this, 'error'), + upgrade: (req, socket, head) => { + this.handleUpgrade(req, socket, head, emitConnection); + } + }); + } + + if (options.perMessageDeflate === true) options.perMessageDeflate = {}; + if (options.clientTracking) this.clients = new Set(); + this.options = options; + } + + /** + * Returns the bound address, the address family name, and port of the server + * as reported by the operating system if listening on an IP socket. + * If the server is listening on a pipe or UNIX domain socket, the name is + * returned as a string. + * + * @return {(Object|String|null)} The address of the server + * @public + */ + address() { + if (this.options.noServer) { + throw new Error('The server is operating in "noServer" mode'); + } + + if (!this._server) return null; + return this._server.address(); + } + + /** + * Close the server. + * + * @param {Function} [cb] Callback + * @public + */ + close(cb) { + if (cb) this.once('close', cb); + + // + // Terminate all associated clients. + // + if (this.clients) { + for (const client of this.clients) client.terminate(); + } + + const server = this._server; + + if (server) { + this._removeListeners(); + this._removeListeners = this._server = null; + + // + // Close the http server if it was internally created. + // + if (this.options.port != null) { + server.close(() => this.emit('close')); + return; + } + } + + process.nextTick(emitClose, this); + } + + /** + * See if a given request should be handled by this server instance. + * + * @param {http.IncomingMessage} req Request object to inspect + * @return {Boolean} `true` if the request is valid, else `false` + * @public + */ + shouldHandle(req) { + if (this.options.path) { + const index = req.url.indexOf('?'); + const pathname = index !== -1 ? req.url.slice(0, index) : req.url; + + if (pathname !== this.options.path) return false; + } + + return true; + } + + /** + * Handle a HTTP Upgrade request. + * + * @param {http.IncomingMessage} req The request object + * @param {net.Socket} socket The network socket between the server and client + * @param {Buffer} head The first packet of the upgraded stream + * @param {Function} cb Callback + * @public + */ + handleUpgrade(req, socket, head, cb) { + socket.on('error', socketOnError); + + const key = + req.headers['sec-websocket-key'] !== undefined + ? req.headers['sec-websocket-key'].trim() + : false; + const version = +req.headers['sec-websocket-version']; + const extensions = {}; + + if ( + req.method !== 'GET' || + req.headers.upgrade.toLowerCase() !== 'websocket' || + !key || + !keyRegex.test(key) || + (version !== 8 && version !== 13) || + !this.shouldHandle(req) + ) { + return abortHandshake(socket, 400); + } + + if (this.options.perMessageDeflate) { + const perMessageDeflate = new PerMessageDeflate( + this.options.perMessageDeflate, + true, + this.options.maxPayload + ); + + try { + const offers = parse(req.headers['sec-websocket-extensions']); + + if (offers[PerMessageDeflate.extensionName]) { + perMessageDeflate.accept(offers[PerMessageDeflate.extensionName]); + extensions[PerMessageDeflate.extensionName] = perMessageDeflate; + } + } catch (err) { + return abortHandshake(socket, 400); + } + } + + // + // Optionally call external client verification handler. + // + if (this.options.verifyClient) { + const info = { + origin: + req.headers[`${version === 8 ? 'sec-websocket-origin' : 'origin'}`], + secure: !!(req.socket.authorized || req.socket.encrypted), + req + }; + + if (this.options.verifyClient.length === 2) { + this.options.verifyClient(info, (verified, code, message, headers) => { + if (!verified) { + return abortHandshake(socket, code || 401, message, headers); + } + + this.completeUpgrade(key, extensions, req, socket, head, cb); + }); + return; + } + + if (!this.options.verifyClient(info)) return abortHandshake(socket, 401); + } + + this.completeUpgrade(key, extensions, req, socket, head, cb); + } + + /** + * Upgrade the connection to WebSocket. + * + * @param {String} key The value of the `Sec-WebSocket-Key` header + * @param {Object} extensions The accepted extensions + * @param {http.IncomingMessage} req The request object + * @param {net.Socket} socket The network socket between the server and client + * @param {Buffer} head The first packet of the upgraded stream + * @param {Function} cb Callback + * @throws {Error} If called more than once with the same socket + * @private + */ + completeUpgrade(key, extensions, req, socket, head, cb) { + // + // Destroy the socket if the client has already sent a FIN packet. + // + if (!socket.readable || !socket.writable) return socket.destroy(); + + if (socket[kWebSocket]) { + throw new Error( + 'server.handleUpgrade() was called more than once with the same ' + + 'socket, possibly due to a misconfiguration' + ); + } + + const digest = createHash('sha1') + .update(key + GUID) + .digest('base64'); + + const headers = [ + 'HTTP/1.1 101 Switching Protocols', + 'Upgrade: websocket', + 'Connection: Upgrade', + `Sec-WebSocket-Accept: ${digest}` + ]; + + const ws = new WebSocket(null); + let protocol = req.headers['sec-websocket-protocol']; + + if (protocol) { + protocol = protocol.trim().split(/ *, */); + + // + // Optionally call external protocol selection handler. + // + if (this.options.handleProtocols) { + protocol = this.options.handleProtocols(protocol, req); + } else { + protocol = protocol[0]; + } + + if (protocol) { + headers.push(`Sec-WebSocket-Protocol: ${protocol}`); + ws._protocol = protocol; + } + } + + if (extensions[PerMessageDeflate.extensionName]) { + const params = extensions[PerMessageDeflate.extensionName].params; + const value = format({ + [PerMessageDeflate.extensionName]: [params] + }); + headers.push(`Sec-WebSocket-Extensions: ${value}`); + ws._extensions = extensions; + } + + // + // Allow external modification/inspection of handshake headers. + // + this.emit('headers', headers, req); + + socket.write(headers.concat('\r\n').join('\r\n')); + socket.removeListener('error', socketOnError); + + ws.setSocket(socket, head, this.options.maxPayload); + + if (this.clients) { + this.clients.add(ws); + ws.on('close', () => this.clients.delete(ws)); + } + + cb(ws, req); + } +} + +module.exports = WebSocketServer; + +/** + * Add event listeners on an `EventEmitter` using a map of + * pairs. + * + * @param {EventEmitter} server The event emitter + * @param {Object.} map The listeners to add + * @return {Function} A function that will remove the added listeners when + * called + * @private + */ +function addListeners(server, map) { + for (const event of Object.keys(map)) server.on(event, map[event]); + + return function removeListeners() { + for (const event of Object.keys(map)) { + server.removeListener(event, map[event]); + } + }; +} + +/** + * Emit a `'close'` event on an `EventEmitter`. + * + * @param {EventEmitter} server The event emitter + * @private + */ +function emitClose(server) { + server.emit('close'); +} + +/** + * Handle premature socket errors. + * + * @private + */ +function socketOnError() { + this.destroy(); +} + +/** + * Close the connection when preconditions are not fulfilled. + * + * @param {net.Socket} socket The socket of the upgrade request + * @param {Number} code The HTTP response status code + * @param {String} [message] The HTTP response body + * @param {Object} [headers] Additional HTTP response headers + * @private + */ +function abortHandshake(socket, code, message, headers) { + if (socket.writable) { + message = message || STATUS_CODES[code]; + headers = { + Connection: 'close', + 'Content-Type': 'text/html', + 'Content-Length': Buffer.byteLength(message), + ...headers + }; + + socket.write( + `HTTP/1.1 ${code} ${STATUS_CODES[code]}\r\n` + + Object.keys(headers) + .map((h) => `${h}: ${headers[h]}`) + .join('\r\n') + + '\r\n\r\n' + + message + ); + } + + socket.removeListener('error', socketOnError); + socket.destroy(); +} diff --git a/jwt-scratch/src/js/node_modules/ws/lib/websocket.js b/jwt-scratch/src/js/node_modules/ws/lib/websocket.js new file mode 100644 index 0000000..5392381 --- /dev/null +++ b/jwt-scratch/src/js/node_modules/ws/lib/websocket.js @@ -0,0 +1,943 @@ +'use strict'; + +const EventEmitter = require('events'); +const https = require('https'); +const http = require('http'); +const net = require('net'); +const tls = require('tls'); +const { randomBytes, createHash } = require('crypto'); +const { URL } = require('url'); + +const PerMessageDeflate = require('./permessage-deflate'); +const Receiver = require('./receiver'); +const Sender = require('./sender'); +const { + BINARY_TYPES, + EMPTY_BUFFER, + GUID, + kStatusCode, + kWebSocket, + NOOP +} = require('./constants'); +const { addEventListener, removeEventListener } = require('./event-target'); +const { format, parse } = require('./extension'); +const { toBuffer } = require('./buffer-util'); + +const readyStates = ['CONNECTING', 'OPEN', 'CLOSING', 'CLOSED']; +const protocolVersions = [8, 13]; +const closeTimeout = 30 * 1000; + +/** + * Class representing a WebSocket. + * + * @extends EventEmitter + */ +class WebSocket extends EventEmitter { + /** + * Create a new `WebSocket`. + * + * @param {(String|url.URL)} address The URL to which to connect + * @param {(String|String[])} [protocols] The subprotocols + * @param {Object} [options] Connection options + */ + constructor(address, protocols, options) { + super(); + + this._binaryType = BINARY_TYPES[0]; + this._closeCode = 1006; + this._closeFrameReceived = false; + this._closeFrameSent = false; + this._closeMessage = ''; + this._closeTimer = null; + this._extensions = {}; + this._protocol = ''; + this._readyState = WebSocket.CONNECTING; + this._receiver = null; + this._sender = null; + this._socket = null; + + if (address !== null) { + this._bufferedAmount = 0; + this._isServer = false; + this._redirects = 0; + + if (Array.isArray(protocols)) { + protocols = protocols.join(', '); + } else if (typeof protocols === 'object' && protocols !== null) { + options = protocols; + protocols = undefined; + } + + initAsClient(this, address, protocols, options); + } else { + this._isServer = true; + } + } + + /** + * This deviates from the WHATWG interface since ws doesn't support the + * required default "blob" type (instead we define a custom "nodebuffer" + * type). + * + * @type {String} + */ + get binaryType() { + return this._binaryType; + } + + set binaryType(type) { + if (!BINARY_TYPES.includes(type)) return; + + this._binaryType = type; + + // + // Allow to change `binaryType` on the fly. + // + if (this._receiver) this._receiver._binaryType = type; + } + + /** + * @type {Number} + */ + get bufferedAmount() { + if (!this._socket) return this._bufferedAmount; + + return this._socket._writableState.length + this._sender._bufferedBytes; + } + + /** + * @type {String} + */ + get extensions() { + return Object.keys(this._extensions).join(); + } + + /** + * @type {String} + */ + get protocol() { + return this._protocol; + } + + /** + * @type {Number} + */ + get readyState() { + return this._readyState; + } + + /** + * @type {String} + */ + get url() { + return this._url; + } + + /** + * Set up the socket and the internal resources. + * + * @param {net.Socket} socket The network socket between the server and client + * @param {Buffer} head The first packet of the upgraded stream + * @param {Number} [maxPayload=0] The maximum allowed message size + * @private + */ + setSocket(socket, head, maxPayload) { + const receiver = new Receiver( + this.binaryType, + this._extensions, + this._isServer, + maxPayload + ); + + this._sender = new Sender(socket, this._extensions); + this._receiver = receiver; + this._socket = socket; + + receiver[kWebSocket] = this; + socket[kWebSocket] = this; + + receiver.on('conclude', receiverOnConclude); + receiver.on('drain', receiverOnDrain); + receiver.on('error', receiverOnError); + receiver.on('message', receiverOnMessage); + receiver.on('ping', receiverOnPing); + receiver.on('pong', receiverOnPong); + + socket.setTimeout(0); + socket.setNoDelay(); + + if (head.length > 0) socket.unshift(head); + + socket.on('close', socketOnClose); + socket.on('data', socketOnData); + socket.on('end', socketOnEnd); + socket.on('error', socketOnError); + + this._readyState = WebSocket.OPEN; + this.emit('open'); + } + + /** + * Emit the `'close'` event. + * + * @private + */ + emitClose() { + if (!this._socket) { + this._readyState = WebSocket.CLOSED; + this.emit('close', this._closeCode, this._closeMessage); + return; + } + + if (this._extensions[PerMessageDeflate.extensionName]) { + this._extensions[PerMessageDeflate.extensionName].cleanup(); + } + + this._receiver.removeAllListeners(); + this._readyState = WebSocket.CLOSED; + this.emit('close', this._closeCode, this._closeMessage); + } + + /** + * Start a closing handshake. + * + * +----------+ +-----------+ +----------+ + * - - -|ws.close()|-->|close frame|-->|ws.close()|- - - + * | +----------+ +-----------+ +----------+ | + * +----------+ +-----------+ | + * CLOSING |ws.close()|<--|close frame|<--+-----+ CLOSING + * +----------+ +-----------+ | + * | | | +---+ | + * +------------------------+-->|fin| - - - - + * | +---+ | +---+ + * - - - - -|fin|<---------------------+ + * +---+ + * + * @param {Number} [code] Status code explaining why the connection is closing + * @param {String} [data] A string explaining why the connection is closing + * @public + */ + close(code, data) { + if (this.readyState === WebSocket.CLOSED) return; + if (this.readyState === WebSocket.CONNECTING) { + const msg = 'WebSocket was closed before the connection was established'; + return abortHandshake(this, this._req, msg); + } + + if (this.readyState === WebSocket.CLOSING) { + if (this._closeFrameSent && this._closeFrameReceived) this._socket.end(); + return; + } + + this._readyState = WebSocket.CLOSING; + this._sender.close(code, data, !this._isServer, (err) => { + // + // This error is handled by the `'error'` listener on the socket. We only + // want to know if the close frame has been sent here. + // + if (err) return; + + this._closeFrameSent = true; + if (this._closeFrameReceived) this._socket.end(); + }); + + // + // Specify a timeout for the closing handshake to complete. + // + this._closeTimer = setTimeout( + this._socket.destroy.bind(this._socket), + closeTimeout + ); + } + + /** + * Send a ping. + * + * @param {*} [data] The data to send + * @param {Boolean} [mask] Indicates whether or not to mask `data` + * @param {Function} [cb] Callback which is executed when the ping is sent + * @public + */ + ping(data, mask, cb) { + if (this.readyState === WebSocket.CONNECTING) { + throw new Error('WebSocket is not open: readyState 0 (CONNECTING)'); + } + + if (typeof data === 'function') { + cb = data; + data = mask = undefined; + } else if (typeof mask === 'function') { + cb = mask; + mask = undefined; + } + + if (typeof data === 'number') data = data.toString(); + + if (this.readyState !== WebSocket.OPEN) { + sendAfterClose(this, data, cb); + return; + } + + if (mask === undefined) mask = !this._isServer; + this._sender.ping(data || EMPTY_BUFFER, mask, cb); + } + + /** + * Send a pong. + * + * @param {*} [data] The data to send + * @param {Boolean} [mask] Indicates whether or not to mask `data` + * @param {Function} [cb] Callback which is executed when the pong is sent + * @public + */ + pong(data, mask, cb) { + if (this.readyState === WebSocket.CONNECTING) { + throw new Error('WebSocket is not open: readyState 0 (CONNECTING)'); + } + + if (typeof data === 'function') { + cb = data; + data = mask = undefined; + } else if (typeof mask === 'function') { + cb = mask; + mask = undefined; + } + + if (typeof data === 'number') data = data.toString(); + + if (this.readyState !== WebSocket.OPEN) { + sendAfterClose(this, data, cb); + return; + } + + if (mask === undefined) mask = !this._isServer; + this._sender.pong(data || EMPTY_BUFFER, mask, cb); + } + + /** + * Send a data message. + * + * @param {*} data The message to send + * @param {Object} [options] Options object + * @param {Boolean} [options.compress] Specifies whether or not to compress + * `data` + * @param {Boolean} [options.binary] Specifies whether `data` is binary or + * text + * @param {Boolean} [options.fin=true] Specifies whether the fragment is the + * last one + * @param {Boolean} [options.mask] Specifies whether or not to mask `data` + * @param {Function} [cb] Callback which is executed when data is written out + * @public + */ + send(data, options, cb) { + if (this.readyState === WebSocket.CONNECTING) { + throw new Error('WebSocket is not open: readyState 0 (CONNECTING)'); + } + + if (typeof options === 'function') { + cb = options; + options = {}; + } + + if (typeof data === 'number') data = data.toString(); + + if (this.readyState !== WebSocket.OPEN) { + sendAfterClose(this, data, cb); + return; + } + + const opts = { + binary: typeof data !== 'string', + mask: !this._isServer, + compress: true, + fin: true, + ...options + }; + + if (!this._extensions[PerMessageDeflate.extensionName]) { + opts.compress = false; + } + + this._sender.send(data || EMPTY_BUFFER, opts, cb); + } + + /** + * Forcibly close the connection. + * + * @public + */ + terminate() { + if (this.readyState === WebSocket.CLOSED) return; + if (this.readyState === WebSocket.CONNECTING) { + const msg = 'WebSocket was closed before the connection was established'; + return abortHandshake(this, this._req, msg); + } + + if (this._socket) { + this._readyState = WebSocket.CLOSING; + this._socket.destroy(); + } + } +} + +readyStates.forEach((readyState, i) => { + const descriptor = { enumerable: true, value: i }; + + Object.defineProperty(WebSocket.prototype, readyState, descriptor); + Object.defineProperty(WebSocket, readyState, descriptor); +}); + +[ + 'binaryType', + 'bufferedAmount', + 'extensions', + 'protocol', + 'readyState', + 'url' +].forEach((property) => { + Object.defineProperty(WebSocket.prototype, property, { enumerable: true }); +}); + +// +// Add the `onopen`, `onerror`, `onclose`, and `onmessage` attributes. +// See https://html.spec.whatwg.org/multipage/comms.html#the-websocket-interface +// +['open', 'error', 'close', 'message'].forEach((method) => { + Object.defineProperty(WebSocket.prototype, `on${method}`, { + configurable: true, + enumerable: true, + /** + * Return the listener of the event. + * + * @return {(Function|undefined)} The event listener or `undefined` + * @public + */ + get() { + const listeners = this.listeners(method); + for (let i = 0; i < listeners.length; i++) { + if (listeners[i]._listener) return listeners[i]._listener; + } + + return undefined; + }, + /** + * Add a listener for the event. + * + * @param {Function} listener The listener to add + * @public + */ + set(listener) { + const listeners = this.listeners(method); + for (let i = 0; i < listeners.length; i++) { + // + // Remove only the listeners added via `addEventListener`. + // + if (listeners[i]._listener) this.removeListener(method, listeners[i]); + } + this.addEventListener(method, listener); + } + }); +}); + +WebSocket.prototype.addEventListener = addEventListener; +WebSocket.prototype.removeEventListener = removeEventListener; + +module.exports = WebSocket; + +/** + * Initialize a WebSocket client. + * + * @param {WebSocket} websocket The client to initialize + * @param {(String|url.URL)} address The URL to which to connect + * @param {String} [protocols] The subprotocols + * @param {Object} [options] Connection options + * @param {(Boolean|Object)} [options.perMessageDeflate=true] Enable/disable + * permessage-deflate + * @param {Number} [options.handshakeTimeout] Timeout in milliseconds for the + * handshake request + * @param {Number} [options.protocolVersion=13] Value of the + * `Sec-WebSocket-Version` header + * @param {String} [options.origin] Value of the `Origin` or + * `Sec-WebSocket-Origin` header + * @param {Number} [options.maxPayload=104857600] The maximum allowed message + * size + * @param {Boolean} [options.followRedirects=false] Whether or not to follow + * redirects + * @param {Number} [options.maxRedirects=10] The maximum number of redirects + * allowed + * @private + */ +function initAsClient(websocket, address, protocols, options) { + const opts = { + protocolVersion: protocolVersions[1], + maxPayload: 100 * 1024 * 1024, + perMessageDeflate: true, + followRedirects: false, + maxRedirects: 10, + ...options, + createConnection: undefined, + socketPath: undefined, + hostname: undefined, + protocol: undefined, + timeout: undefined, + method: undefined, + host: undefined, + path: undefined, + port: undefined + }; + + if (!protocolVersions.includes(opts.protocolVersion)) { + throw new RangeError( + `Unsupported protocol version: ${opts.protocolVersion} ` + + `(supported versions: ${protocolVersions.join(', ')})` + ); + } + + let parsedUrl; + + if (address instanceof URL) { + parsedUrl = address; + websocket._url = address.href; + } else { + parsedUrl = new URL(address); + websocket._url = address; + } + + const isUnixSocket = parsedUrl.protocol === 'ws+unix:'; + + if (!parsedUrl.host && (!isUnixSocket || !parsedUrl.pathname)) { + throw new Error(`Invalid URL: ${websocket.url}`); + } + + const isSecure = + parsedUrl.protocol === 'wss:' || parsedUrl.protocol === 'https:'; + const defaultPort = isSecure ? 443 : 80; + const key = randomBytes(16).toString('base64'); + const get = isSecure ? https.get : http.get; + let perMessageDeflate; + + opts.createConnection = isSecure ? tlsConnect : netConnect; + opts.defaultPort = opts.defaultPort || defaultPort; + opts.port = parsedUrl.port || defaultPort; + opts.host = parsedUrl.hostname.startsWith('[') + ? parsedUrl.hostname.slice(1, -1) + : parsedUrl.hostname; + opts.headers = { + 'Sec-WebSocket-Version': opts.protocolVersion, + 'Sec-WebSocket-Key': key, + Connection: 'Upgrade', + Upgrade: 'websocket', + ...opts.headers + }; + opts.path = parsedUrl.pathname + parsedUrl.search; + opts.timeout = opts.handshakeTimeout; + + if (opts.perMessageDeflate) { + perMessageDeflate = new PerMessageDeflate( + opts.perMessageDeflate !== true ? opts.perMessageDeflate : {}, + false, + opts.maxPayload + ); + opts.headers['Sec-WebSocket-Extensions'] = format({ + [PerMessageDeflate.extensionName]: perMessageDeflate.offer() + }); + } + if (protocols) { + opts.headers['Sec-WebSocket-Protocol'] = protocols; + } + if (opts.origin) { + if (opts.protocolVersion < 13) { + opts.headers['Sec-WebSocket-Origin'] = opts.origin; + } else { + opts.headers.Origin = opts.origin; + } + } + if (parsedUrl.username || parsedUrl.password) { + opts.auth = `${parsedUrl.username}:${parsedUrl.password}`; + } + + if (isUnixSocket) { + const parts = opts.path.split(':'); + + opts.socketPath = parts[0]; + opts.path = parts[1]; + } + + let req = (websocket._req = get(opts)); + + if (opts.timeout) { + req.on('timeout', () => { + abortHandshake(websocket, req, 'Opening handshake has timed out'); + }); + } + + req.on('error', (err) => { + if (req === null || req.aborted) return; + + req = websocket._req = null; + websocket._readyState = WebSocket.CLOSING; + websocket.emit('error', err); + websocket.emitClose(); + }); + + req.on('response', (res) => { + const location = res.headers.location; + const statusCode = res.statusCode; + + if ( + location && + opts.followRedirects && + statusCode >= 300 && + statusCode < 400 + ) { + if (++websocket._redirects > opts.maxRedirects) { + abortHandshake(websocket, req, 'Maximum redirects exceeded'); + return; + } + + req.abort(); + + const addr = new URL(location, address); + + initAsClient(websocket, addr, protocols, options); + } else if (!websocket.emit('unexpected-response', req, res)) { + abortHandshake( + websocket, + req, + `Unexpected server response: ${res.statusCode}` + ); + } + }); + + req.on('upgrade', (res, socket, head) => { + websocket.emit('upgrade', res); + + // + // The user may have closed the connection from a listener of the `upgrade` + // event. + // + if (websocket.readyState !== WebSocket.CONNECTING) return; + + req = websocket._req = null; + + const digest = createHash('sha1') + .update(key + GUID) + .digest('base64'); + + if (res.headers['sec-websocket-accept'] !== digest) { + abortHandshake(websocket, socket, 'Invalid Sec-WebSocket-Accept header'); + return; + } + + const serverProt = res.headers['sec-websocket-protocol']; + const protList = (protocols || '').split(/, */); + let protError; + + if (!protocols && serverProt) { + protError = 'Server sent a subprotocol but none was requested'; + } else if (protocols && !serverProt) { + protError = 'Server sent no subprotocol'; + } else if (serverProt && !protList.includes(serverProt)) { + protError = 'Server sent an invalid subprotocol'; + } + + if (protError) { + abortHandshake(websocket, socket, protError); + return; + } + + if (serverProt) websocket._protocol = serverProt; + + if (perMessageDeflate) { + try { + const extensions = parse(res.headers['sec-websocket-extensions']); + + if (extensions[PerMessageDeflate.extensionName]) { + perMessageDeflate.accept(extensions[PerMessageDeflate.extensionName]); + websocket._extensions[ + PerMessageDeflate.extensionName + ] = perMessageDeflate; + } + } catch (err) { + abortHandshake( + websocket, + socket, + 'Invalid Sec-WebSocket-Extensions header' + ); + return; + } + } + + websocket.setSocket(socket, head, opts.maxPayload); + }); +} + +/** + * Create a `net.Socket` and initiate a connection. + * + * @param {Object} options Connection options + * @return {net.Socket} The newly created socket used to start the connection + * @private + */ +function netConnect(options) { + options.path = options.socketPath; + return net.connect(options); +} + +/** + * Create a `tls.TLSSocket` and initiate a connection. + * + * @param {Object} options Connection options + * @return {tls.TLSSocket} The newly created socket used to start the connection + * @private + */ +function tlsConnect(options) { + options.path = undefined; + + if (!options.servername && options.servername !== '') { + options.servername = net.isIP(options.host) ? '' : options.host; + } + + return tls.connect(options); +} + +/** + * Abort the handshake and emit an error. + * + * @param {WebSocket} websocket The WebSocket instance + * @param {(http.ClientRequest|net.Socket)} stream The request to abort or the + * socket to destroy + * @param {String} message The error message + * @private + */ +function abortHandshake(websocket, stream, message) { + websocket._readyState = WebSocket.CLOSING; + + const err = new Error(message); + Error.captureStackTrace(err, abortHandshake); + + if (stream.setHeader) { + stream.abort(); + + if (stream.socket && !stream.socket.destroyed) { + // + // On Node.js >= 14.3.0 `request.abort()` does not destroy the socket if + // called after the request completed. See + // https://github.com/websockets/ws/issues/1869. + // + stream.socket.destroy(); + } + + stream.once('abort', websocket.emitClose.bind(websocket)); + websocket.emit('error', err); + } else { + stream.destroy(err); + stream.once('error', websocket.emit.bind(websocket, 'error')); + stream.once('close', websocket.emitClose.bind(websocket)); + } +} + +/** + * Handle cases where the `ping()`, `pong()`, or `send()` methods are called + * when the `readyState` attribute is `CLOSING` or `CLOSED`. + * + * @param {WebSocket} websocket The WebSocket instance + * @param {*} [data] The data to send + * @param {Function} [cb] Callback + * @private + */ +function sendAfterClose(websocket, data, cb) { + if (data) { + const length = toBuffer(data).length; + + // + // The `_bufferedAmount` property is used only when the peer is a client and + // the opening handshake fails. Under these circumstances, in fact, the + // `setSocket()` method is not called, so the `_socket` and `_sender` + // properties are set to `null`. + // + if (websocket._socket) websocket._sender._bufferedBytes += length; + else websocket._bufferedAmount += length; + } + + if (cb) { + const err = new Error( + `WebSocket is not open: readyState ${websocket.readyState} ` + + `(${readyStates[websocket.readyState]})` + ); + cb(err); + } +} + +/** + * The listener of the `Receiver` `'conclude'` event. + * + * @param {Number} code The status code + * @param {String} reason The reason for closing + * @private + */ +function receiverOnConclude(code, reason) { + const websocket = this[kWebSocket]; + + websocket._socket.removeListener('data', socketOnData); + websocket._socket.resume(); + + websocket._closeFrameReceived = true; + websocket._closeMessage = reason; + websocket._closeCode = code; + + if (code === 1005) websocket.close(); + else websocket.close(code, reason); +} + +/** + * The listener of the `Receiver` `'drain'` event. + * + * @private + */ +function receiverOnDrain() { + this[kWebSocket]._socket.resume(); +} + +/** + * The listener of the `Receiver` `'error'` event. + * + * @param {(RangeError|Error)} err The emitted error + * @private + */ +function receiverOnError(err) { + const websocket = this[kWebSocket]; + + websocket._socket.removeListener('data', socketOnData); + + websocket._readyState = WebSocket.CLOSING; + websocket._closeCode = err[kStatusCode]; + websocket.emit('error', err); + websocket._socket.destroy(); +} + +/** + * The listener of the `Receiver` `'finish'` event. + * + * @private + */ +function receiverOnFinish() { + this[kWebSocket].emitClose(); +} + +/** + * The listener of the `Receiver` `'message'` event. + * + * @param {(String|Buffer|ArrayBuffer|Buffer[])} data The message + * @private + */ +function receiverOnMessage(data) { + this[kWebSocket].emit('message', data); +} + +/** + * The listener of the `Receiver` `'ping'` event. + * + * @param {Buffer} data The data included in the ping frame + * @private + */ +function receiverOnPing(data) { + const websocket = this[kWebSocket]; + + websocket.pong(data, !websocket._isServer, NOOP); + websocket.emit('ping', data); +} + +/** + * The listener of the `Receiver` `'pong'` event. + * + * @param {Buffer} data The data included in the pong frame + * @private + */ +function receiverOnPong(data) { + this[kWebSocket].emit('pong', data); +} + +/** + * The listener of the `net.Socket` `'close'` event. + * + * @private + */ +function socketOnClose() { + const websocket = this[kWebSocket]; + + this.removeListener('close', socketOnClose); + this.removeListener('end', socketOnEnd); + + websocket._readyState = WebSocket.CLOSING; + + // + // The close frame might not have been received or the `'end'` event emitted, + // for example, if the socket was destroyed due to an error. Ensure that the + // `receiver` stream is closed after writing any remaining buffered data to + // it. If the readable side of the socket is in flowing mode then there is no + // buffered data as everything has been already written and `readable.read()` + // will return `null`. If instead, the socket is paused, any possible buffered + // data will be read as a single chunk and emitted synchronously in a single + // `'data'` event. + // + websocket._socket.read(); + websocket._receiver.end(); + + this.removeListener('data', socketOnData); + this[kWebSocket] = undefined; + + clearTimeout(websocket._closeTimer); + + if ( + websocket._receiver._writableState.finished || + websocket._receiver._writableState.errorEmitted + ) { + websocket.emitClose(); + } else { + websocket._receiver.on('error', receiverOnFinish); + websocket._receiver.on('finish', receiverOnFinish); + } +} + +/** + * The listener of the `net.Socket` `'data'` event. + * + * @param {Buffer} chunk A chunk of data + * @private + */ +function socketOnData(chunk) { + if (!this[kWebSocket]._receiver.write(chunk)) { + this.pause(); + } +} + +/** + * The listener of the `net.Socket` `'end'` event. + * + * @private + */ +function socketOnEnd() { + const websocket = this[kWebSocket]; + + websocket._readyState = WebSocket.CLOSING; + websocket._receiver.end(); + this.end(); +} + +/** + * The listener of the `net.Socket` `'error'` event. + * + * @private + */ +function socketOnError() { + const websocket = this[kWebSocket]; + + this.removeListener('error', socketOnError); + this.on('error', NOOP); + + if (websocket) { + websocket._readyState = WebSocket.CLOSING; + this.destroy(); + } +} diff --git a/jwt-scratch/src/js/node_modules/ws/package.json b/jwt-scratch/src/js/node_modules/ws/package.json new file mode 100644 index 0000000..ca909ba --- /dev/null +++ b/jwt-scratch/src/js/node_modules/ws/package.json @@ -0,0 +1,91 @@ +{ + "_from": "ws", + "_id": "ws@7.4.5", + "_inBundle": false, + "_integrity": "sha512-xzyu3hFvomRfXKH8vOFMU3OguG6oOvhXMo3xsGy3xWExqaM2dxBbVxuD99O7m3ZUFMvvscsZDqxfgMaRr/Nr1g==", + "_location": "/ws", + "_phantomChildren": {}, + "_requested": { + "type": "tag", + "registry": true, + "raw": "ws", + "name": "ws", + "escapedName": "ws", + "rawSpec": "", + "saveSpec": null, + "fetchSpec": "latest" + }, + "_requiredBy": [ + "#USER", + "/" + ], + "_resolved": "https://registry.npmjs.org/ws/-/ws-7.4.5.tgz", + "_shasum": "a484dd851e9beb6fdb420027e3885e8ce48986c1", + "_spec": "ws", + "_where": "/home/rock64/git/qseow-scripts/jwt-scratch/src/js", + "author": { + "name": "Einar Otto Stangvik", + "email": "einaros@gmail.com", + "url": "http://2x.io" + }, + "browser": "browser.js", + "bugs": { + "url": "https://github.com/websockets/ws/issues" + }, + "bundleDependencies": false, + "deprecated": false, + "description": "Simple to use, blazing fast and thoroughly tested websocket client and server for Node.js", + "devDependencies": { + "benchmark": "^2.1.4", + "bufferutil": "^4.0.1", + "eslint": "^7.2.0", + "eslint-config-prettier": "^8.1.0", + "eslint-plugin-prettier": "^3.0.1", + "mocha": "^7.0.0", + "nyc": "^15.0.0", + "prettier": "^2.0.5", + "utf-8-validate": "^5.0.2" + }, + "engines": { + "node": ">=8.3.0" + }, + "files": [ + "browser.js", + "index.js", + "lib/*.js" + ], + "homepage": "https://github.com/websockets/ws", + "keywords": [ + "HyBi", + "Push", + "RFC-6455", + "WebSocket", + "WebSockets", + "real-time" + ], + "license": "MIT", + "main": "index.js", + "name": "ws", + "peerDependencies": { + "bufferutil": "^4.0.1", + "utf-8-validate": "^5.0.2" + }, + "peerDependenciesMeta": { + "bufferutil": { + "optional": true + }, + "utf-8-validate": { + "optional": true + } + }, + "repository": { + "type": "git", + "url": "git+https://github.com/websockets/ws.git" + }, + "scripts": { + "integration": "mocha --throw-deprecation test/*.integration.js", + "lint": "eslint --ignore-path .gitignore . && prettier --check --ignore-path .gitignore \"**/*.{json,md,yaml,yml}\"", + "test": "nyc --reporter=lcov --reporter=text mocha --throw-deprecation test/*.test.js" + }, + "version": "7.4.5" +} diff --git a/jwt-scratch/src/js/package-lock.json b/jwt-scratch/src/js/package-lock.json new file mode 100644 index 0000000..7cd3ab6 --- /dev/null +++ b/jwt-scratch/src/js/package-lock.json @@ -0,0 +1,115 @@ +{ + "requires": true, + "lockfileVersion": 1, + "dependencies": { + "buffer-equal-constant-time": { + "version": "1.0.1", + "resolved": "https://registry.npmjs.org/buffer-equal-constant-time/-/buffer-equal-constant-time-1.0.1.tgz", + "integrity": "sha1-+OcRMvf/5uAaXJaXpMbz5I1cyBk=" + }, + "ecdsa-sig-formatter": { + "version": "1.0.11", + "resolved": "https://registry.npmjs.org/ecdsa-sig-formatter/-/ecdsa-sig-formatter-1.0.11.tgz", + "integrity": "sha512-nagl3RYrbNv6kQkeJIpt6NJZy8twLB/2vtz6yN9Z4vRKHN4/QZJIEbqohALSgwKdnksuY3k5Addp5lg8sVoVcQ==", + "requires": { + "safe-buffer": "^5.0.1" + } + }, + "enigma.js": { + "version": "2.7.2", + "resolved": "https://registry.npmjs.org/enigma.js/-/enigma.js-2.7.2.tgz", + "integrity": "sha512-MATvu3+DqV3NGkdKM5uYJT8VLBkQeWgvNqiHsOXO/ChcMezwrKpr4gcn+gx/sqnACX9yaoFi02ECbs8rCZ+aIQ==" + }, + "jsonwebtoken": { + "version": "8.5.1", + "resolved": "https://registry.npmjs.org/jsonwebtoken/-/jsonwebtoken-8.5.1.tgz", + "integrity": "sha512-XjwVfRS6jTMsqYs0EsuJ4LGxXV14zQybNd4L2r0UvbVnSF9Af8x7p5MzbJ90Ioz/9TI41/hTCvznF/loiSzn8w==", + "requires": { + "jws": "^3.2.2", + "lodash.includes": "^4.3.0", + "lodash.isboolean": "^3.0.3", + "lodash.isinteger": "^4.0.4", + "lodash.isnumber": "^3.0.3", + "lodash.isplainobject": "^4.0.6", + "lodash.isstring": "^4.0.1", + "lodash.once": "^4.0.0", + "ms": "^2.1.1", + "semver": "^5.6.0" + } + }, + "jwa": { + "version": "1.4.1", + "resolved": "https://registry.npmjs.org/jwa/-/jwa-1.4.1.tgz", + "integrity": "sha512-qiLX/xhEEFKUAJ6FiBMbes3w9ATzyk5W7Hvzpa/SLYdxNtng+gcurvrI7TbACjIXlsJyr05/S1oUhZrc63evQA==", + "requires": { + "buffer-equal-constant-time": "1.0.1", + "ecdsa-sig-formatter": "1.0.11", + "safe-buffer": "^5.0.1" + } + }, + "jws": { + "version": "3.2.2", + "resolved": "https://registry.npmjs.org/jws/-/jws-3.2.2.tgz", + "integrity": "sha512-YHlZCB6lMTllWDtSPHz/ZXTsi8S00usEV6v1tjq8tOUZzw7DpSDWVXjXDre6ed1w/pd495ODpHZYSdkRTsa0HA==", + "requires": { + "jwa": "^1.4.1", + "safe-buffer": "^5.0.1" + } + }, + "lodash.includes": { + "version": "4.3.0", + "resolved": "https://registry.npmjs.org/lodash.includes/-/lodash.includes-4.3.0.tgz", + "integrity": "sha1-YLuYqHy5I8aMoeUTJUgzFISfVT8=" + }, + "lodash.isboolean": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/lodash.isboolean/-/lodash.isboolean-3.0.3.tgz", + "integrity": "sha1-bC4XHbKiV82WgC/UOwGyDV9YcPY=" + }, + "lodash.isinteger": { + "version": "4.0.4", + "resolved": "https://registry.npmjs.org/lodash.isinteger/-/lodash.isinteger-4.0.4.tgz", + "integrity": "sha1-YZwK89A/iwTDH1iChAt3sRzWg0M=" + }, + "lodash.isnumber": { + "version": "3.0.3", + "resolved": "https://registry.npmjs.org/lodash.isnumber/-/lodash.isnumber-3.0.3.tgz", + "integrity": "sha1-POdoEMWSjQM1IwGsKHMX8RwLH/w=" + }, + "lodash.isplainobject": { + "version": "4.0.6", + "resolved": "https://registry.npmjs.org/lodash.isplainobject/-/lodash.isplainobject-4.0.6.tgz", + "integrity": "sha1-fFJqUtibRcRcxpC4gWO+BJf1UMs=" + }, + "lodash.isstring": { + "version": "4.0.1", + "resolved": "https://registry.npmjs.org/lodash.isstring/-/lodash.isstring-4.0.1.tgz", + "integrity": "sha1-1SfftUVuynzJu5XV2ur4i6VKVFE=" + }, + "lodash.once": { + "version": "4.1.1", + "resolved": "https://registry.npmjs.org/lodash.once/-/lodash.once-4.1.1.tgz", + "integrity": "sha1-DdOXEhPHxW34gJd9UEyI+0cal6w=" + }, + "ms": { + "version": "2.1.3", + "resolved": "https://registry.npmjs.org/ms/-/ms-2.1.3.tgz", + "integrity": "sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA==" + }, + "safe-buffer": { + "version": "5.2.1", + "resolved": "https://registry.npmjs.org/safe-buffer/-/safe-buffer-5.2.1.tgz", + "integrity": "sha512-rp3So07KcdmmKbGvgaNxQSJr7bGVSVk5S9Eq1F+ppbRo70+YeaDxkw5Dd8NPN+GD6bjnYm2VuPuCXmpuYvmCXQ==" + }, + "semver": { + "version": "5.7.1", + "resolved": "https://registry.npmjs.org/semver/-/semver-5.7.1.tgz", + "integrity": "sha512-sauaDf/PZdVgrLTNYHRtpXa1iRiKcaebiKQ1BJdpQlWH2lCvexQdX55snPFyK7QzpudqbCI0qXFfOasHdyNDGQ==" + }, + "ws": { + "version": "7.4.5", + "resolved": "https://registry.npmjs.org/ws/-/ws-7.4.5.tgz", + "integrity": "sha512-xzyu3hFvomRfXKH8vOFMU3OguG6oOvhXMo3xsGy3xWExqaM2dxBbVxuD99O7m3ZUFMvvscsZDqxfgMaRr/Nr1g==" + } + } +} diff --git a/jwt-scratch/src/js/package.json b/jwt-scratch/src/js/package.json new file mode 100644 index 0000000..11e3a94 --- /dev/null +++ b/jwt-scratch/src/js/package.json @@ -0,0 +1,8 @@ +{ + "dependencies": { + "enigma.js": "^2.7.2", + "jsonwebtoken": "^8.5.1", + "uWebSockets.js": "uNetworking/uWebSockets.js", + "ws": "^7.4.5" + } +} diff --git a/jwt-scratch/src/js/uTest.js b/jwt-scratch/src/js/uTest.js new file mode 100644 index 0000000..905f134 --- /dev/null +++ b/jwt-scratch/src/js/uTest.js @@ -0,0 +1,38 @@ +/* A quite detailed WebSockets example */ + +const uWS = require('./node_modules/uWebSockets.js/src/uws.js'); +//const uWS = require('uWebSockets.js'); +const port = 9001; + +const app = uWS./*SSL*/App({ + key_file_name: 'misc/key.pem', + cert_file_name: 'misc/cert.pem', + passphrase: '1234' +}).ws('/*', { + /* Options */ + compression: uWS.SHARED_COMPRESSOR, + maxPayloadLength: 16 * 1024 * 1024, + idleTimeout: 10, + /* Handlers */ + open: (ws) => { + console.log('A WebSocket connected!'); + }, + message: (ws, message, isBinary) => { + /* Ok is false if backpressure was built up, wait for drain */ + let ok = ws.send(message, isBinary); + }, + drain: (ws) => { + console.log('WebSocket backpressure: ' + ws.getBufferedAmount()); + }, + close: (ws, code, message) => { + console.log('WebSocket closed'); + } +}).any('/*', (res, req) => { + res.end('Nothing to see here!'); +}).listen(port, (token) => { + if (token) { + console.log('Listening to port ' + port); + } else { + console.log('Failed to listen to port ' + port); + } +}); diff --git a/jwt-scratch/src/js/yarn.lock b/jwt-scratch/src/js/yarn.lock new file mode 100644 index 0000000..37b92e9 --- /dev/null +++ b/jwt-scratch/src/js/yarn.lock @@ -0,0 +1,7 @@ +# THIS IS AN AUTOGENERATED FILE. DO NOT EDIT THIS FILE DIRECTLY. +# yarn lockfile v1 + + +uWebSockets.js@uNetworking/uWebSockets.js: + version "0.0.0" + resolved "https://codeload.github.com/uNetworking/uWebSockets.js/tar.gz/9af80e10cec000fe6cdbd4037b2154e2ffa08b2d" diff --git a/jwt-scratch/ticket.html b/jwt-scratch/ticket.html deleted file mode 100644 index bb4e0e3..0000000 --- a/jwt-scratch/ticket.html +++ /dev/null @@ -1,93 +0,0 @@ - - - - - Qlik Sense Mashup - - - - - - - - - - - - -
-
-
-
-
- - diff --git a/jwt-scratch/ticket.js b/jwt-scratch/ticket.js deleted file mode 100644 index 99253c3..0000000 --- a/jwt-scratch/ticket.js +++ /dev/null @@ -1,29 +0,0 @@ -var config = { - host: "qseow.jprdonnelly.com", - prefix: "/jwt/", - port: 443, - isSecure: true, -}; -require.config({ - baseUrl: - (config.isSecure ? "https://" : "http://") + - config.host + - (config.port ? ":" + config.port : "") + - config.prefix + - "resources", -}); - -require(["js/qlik"], function (qlik) { - qlik.on("error", function (error) { - $("#popupText").append(error.message + "
"); - $("#popup").fadeIn(1000); - }); - $("#closePopup").click(function () { - $("#popup").hide(); - }); - - var app = qlik.openApp("106614d5-09ed-4cc3-95bd-e0d4e6b7381d", config); - - //get objects -- inserted here -- - app.getObject("QV01", "aUsNBCp"); -}); diff --git a/qseow-dev.code-workspace b/qseow-dev.code-workspace deleted file mode 100644 index 2b991f7..0000000 --- a/qseow-dev.code-workspace +++ /dev/null @@ -1,11 +0,0 @@ -{ - "folders": [ - { - "path": "." - }, - { - "path": "../sense-conductor" - } - ], - "settings": {} -} \ No newline at end of file