1 line
40 KiB
Plaintext
1 line
40 KiB
Plaintext
|
{"version":3,"file":"when-4bbc8319.js","sources":["../../../../Source/Core/defined.js","../../../../Source/Core/defaultValue.js","../../../../Source/ThirdParty/_commonjsHelpers-3aae1032.js","../../../../Source/ThirdParty/when.js"],"sourcesContent":["/**\n * @function\n *\n * @param {*} value The object.\n * @returns {Boolean} Returns true if the object is defined, returns false otherwise.\n *\n * @example\n * if (Cesium.defined(positions)) {\n * doSomething();\n * } else {\n * doSomethingElse();\n * }\n */\nfunction defined(value) {\n return value !== undefined && value !== null;\n}\nexport default defined;\n","/**\n * Returns the first parameter if not undefined, otherwise the second parameter.\n * Useful for setting a default value for a parameter.\n *\n * @function\n *\n * @param {*} a\n * @param {*} b\n * @returns {*} Returns the first parameter if not undefined, otherwise the second parameter.\n *\n * @example\n * param = Cesium.defaultValue(param, 'default');\n */\nfunction defaultValue(a, b) {\n if (a !== undefined && a !== null) {\n return a;\n }\n return b;\n}\n\n/**\n * A frozen empty object that can be used as the default value for options passed as\n * an object literal.\n * @type {Object}\n * @memberof defaultValue\n */\ndefaultValue.EMPTY_OBJECT = Object.freeze({});\n\nexport default defaultValue;\n","/* This file is automatically rebuilt by the Cesium build process. */\nvar commonjsGlobal = typeof globalThis !== 'undefined' ? globalThis : typeof window !== 'undefined' ? window : typeof global !== 'undefined' ? global : typeof self !== 'undefined' ? self : {};\n\nfunction createCommonjsModule(fn, basedir, module) {\n\treturn module = {\n\t\tpath: basedir,\n\t\texports: {},\n\t\trequire: function (path, base) {\n\t\t\treturn commonjsRequire(path, (base === undefined || base === null) ? module.path : base);\n\t\t}\n\t}, fn(module, module.exports), module.exports;\n}\n\nfunction commonjsRequire () {\n\tthrow new Error('Dynamic requires are not currently supported by @rollup/plugin-commonjs');\n}\n\nexport { commonjsGlobal as a, createCommonjsModule as c };\n","/* This file is automatically rebuilt by the Cesium build process. */\nimport { c as createCommonjsModule } from './_commonjsHelpers-3aae1032.js';\n\nvar when = createCommonjsModule(function (module, exports) {\n/** @license MIT License (c) copyright B Cavalier & J Hann */\n\n/**\n * A lightweight CommonJS Promises/A and when() implementation\n * when is part of the cujo.js family of libraries (http://cujojs.com/)\n *\n * Licensed under the MIT License at:\n * http://www.opensource.org/licenses/mit-license.php\n *\n * @version 1.7.1\n */\n\n(function(define) {define(function () {\n\tvar reduceArray, slice, undef;\n\n\t//\n\t// Public API\n\t//\n\n\twhen.defer = defer; // Create a deferred\n\twhen.resolve = resolve; // Create a resolved promise\n\twhen.reject = reject; // Create a rejected promise\n\n\twhen.join = join; // Join 2 or more promises\n\n\twhen.all = all; // Resolve a list of promises\n\twhen.map = map; // Array.map() for promises\n\twhen.reduce = reduce; // Array.reduce() for promises\n\n\twhen.any = any; // One-winner race\n\twhen.some = some; // Multi-winner race\n\n\twhen.chain = chain; // Make a promise trigger another resolver\n\n\twhen.isPromise = isPromise; // Determine if a thing is a promise\n\n\t/**\n\t * Register an observer for a promise or immediate value.\n\t *\n\t * @param {*} promiseOrValue\n\t * @param {function?} [onFulfilled] callback to be called when promiseOrValue is\n\t * successfully fulfilled. If promiseOrValue is an immediate value, callback\n\t * will be invoked immediately.\n\t * @param {function?} [onRejected] callback to be called when promiseOrValue is\n\t * rejected.\n\t * @param {function?} [onProgress] callback to be called when progress updates\n\t * are issued for promiseOrValue.\n\t * @returns {Promise} a new {@link Promise} that will complete with the return\n\t * value of callback or errba
|