@loaders.gl/core 5.0.0-alpha.11 → 5.0.0-alpha.13
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +1 -1
- package/SCHEMA-README.md +9 -0
- package/SCHEMA-UTILS-README.md +11 -0
- package/dist/dist.dev.js +180 -146
- package/dist/dist.min.js +3 -3
- package/dist/index.cjs +107 -98
- package/dist/index.cjs.map +2 -2
- package/dist/index.d.ts +10 -10
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +8 -8
- package/dist/index.js.map +1 -1
- package/dist/iterators/make-iterator/make-iterator.js +1 -1
- package/dist/iterators/make-iterator/make-iterator.js.map +1 -1
- package/dist/iterators/make-iterator/make-stream-iterator.js +1 -1
- package/dist/iterators/make-iterator/make-stream-iterator.js.map +1 -1
- package/dist/iterators/make-iterator/make-string-iterator.js +1 -1
- package/dist/iterators/make-iterator/make-string-iterator.js.map +1 -1
- package/dist/lib/api/core-api.d.ts +1 -1
- package/dist/lib/api/core-api.d.ts.map +1 -1
- package/dist/lib/api/create-data-source.d.ts +1 -1
- package/dist/lib/api/create-data-source.d.ts.map +1 -1
- package/dist/lib/api/create-data-source.js +1 -1
- package/dist/lib/api/create-data-source.js.map +1 -1
- package/dist/lib/api/encode-table.d.ts +2 -2
- package/dist/lib/api/encode-table.d.ts.map +1 -1
- package/dist/lib/api/encode-table.js +1 -1
- package/dist/lib/api/encode-table.js.map +1 -1
- package/dist/lib/api/encode.d.ts +1 -1
- package/dist/lib/api/encode.d.ts.map +1 -1
- package/dist/lib/api/encode.js +2 -2
- package/dist/lib/api/encode.js.map +1 -1
- package/dist/lib/api/load-in-batches.d.ts +1 -1
- package/dist/lib/api/load-in-batches.d.ts.map +1 -1
- package/dist/lib/api/load-in-batches.js +1 -1
- package/dist/lib/api/load-in-batches.js.map +1 -1
- package/dist/lib/api/load-loader.d.ts +1 -1
- package/dist/lib/api/load-loader.d.ts.map +1 -1
- package/dist/lib/api/load-loader.js +1 -1
- package/dist/lib/api/load-loader.js.map +1 -1
- package/dist/lib/api/load.d.ts +1 -1
- package/dist/lib/api/load.d.ts.map +1 -1
- package/dist/lib/api/load.js +1 -1
- package/dist/lib/api/load.js.map +1 -1
- package/dist/lib/api/parse-file.d.ts +1 -1
- package/dist/lib/api/parse-file.d.ts.map +1 -1
- package/dist/lib/api/parse-file.js +2 -2
- package/dist/lib/api/parse-file.js.map +1 -1
- package/dist/lib/api/parse-in-batches.d.ts +1 -1
- package/dist/lib/api/parse-in-batches.d.ts.map +1 -1
- package/dist/lib/api/parse-in-batches.js +40 -4
- package/dist/lib/api/parse-in-batches.js.map +1 -1
- package/dist/lib/api/parse-sync.d.ts +1 -1
- package/dist/lib/api/parse-sync.d.ts.map +1 -1
- package/dist/lib/api/parse-sync.js +1 -1
- package/dist/lib/api/parse-sync.js.map +1 -1
- package/dist/lib/api/parse.d.ts +1 -1
- package/dist/lib/api/parse.d.ts.map +1 -1
- package/dist/lib/api/parse.js +3 -3
- package/dist/lib/api/parse.js.map +1 -1
- package/dist/lib/api/preload.d.ts +1 -1
- package/dist/lib/api/preload.d.ts.map +1 -1
- package/dist/lib/api/preload.js.map +1 -1
- package/dist/lib/api/register-loaders.d.ts +1 -1
- package/dist/lib/api/register-loaders.d.ts.map +1 -1
- package/dist/lib/api/select-loader.d.ts +1 -1
- package/dist/lib/api/select-loader.d.ts.map +1 -1
- package/dist/lib/api/select-loader.js +1 -1
- package/dist/lib/api/select-loader.js.map +1 -1
- package/dist/lib/api/select-source.d.ts +1 -1
- package/dist/lib/api/select-source.d.ts.map +1 -1
- package/dist/lib/common.d.ts +1 -1
- package/dist/lib/common.d.ts.map +1 -1
- package/dist/lib/fetch/fetch-file.js +2 -2
- package/dist/lib/fetch/fetch-file.js.map +1 -1
- package/dist/lib/filesystems/browser-filesystem.d.ts +1 -1
- package/dist/lib/filesystems/browser-filesystem.d.ts.map +1 -1
- package/dist/lib/filesystems/browser-filesystem.js +1 -1
- package/dist/lib/filesystems/browser-filesystem.js.map +1 -1
- package/dist/lib/init.js +2 -2
- package/dist/lib/init.js.map +1 -1
- package/dist/lib/loader-utils/get-data.d.ts +1 -1
- package/dist/lib/loader-utils/get-data.d.ts.map +1 -1
- package/dist/lib/loader-utils/get-data.js +1 -1
- package/dist/lib/loader-utils/get-data.js.map +1 -1
- package/dist/lib/loader-utils/get-fetch-function.d.ts +1 -1
- package/dist/lib/loader-utils/get-fetch-function.d.ts.map +1 -1
- package/dist/lib/loader-utils/get-fetch-function.js +1 -1
- package/dist/lib/loader-utils/get-fetch-function.js.map +1 -1
- package/dist/lib/loader-utils/loader-context.d.ts +1 -1
- package/dist/lib/loader-utils/loader-context.d.ts.map +1 -1
- package/dist/lib/loader-utils/loader-context.js +1 -1
- package/dist/lib/loader-utils/loader-context.js.map +1 -1
- package/dist/lib/loader-utils/loggers.d.ts +1 -1
- package/dist/lib/loader-utils/loggers.d.ts.map +1 -1
- package/dist/lib/loader-utils/loggers.js +1 -1
- package/dist/lib/loader-utils/loggers.js.map +1 -1
- package/dist/lib/loader-utils/normalize-loader.d.ts +1 -1
- package/dist/lib/loader-utils/normalize-loader.d.ts.map +1 -1
- package/dist/lib/loader-utils/normalize-loader.js +1 -1
- package/dist/lib/loader-utils/normalize-loader.js.map +1 -1
- package/dist/lib/loader-utils/option-defaults.d.ts +1 -1
- package/dist/lib/loader-utils/option-defaults.d.ts.map +1 -1
- package/dist/lib/loader-utils/option-defaults.js +1 -1
- package/dist/lib/loader-utils/option-defaults.js.map +1 -1
- package/dist/lib/loader-utils/option-utils.d.ts +1 -1
- package/dist/lib/loader-utils/option-utils.d.ts.map +1 -1
- package/dist/lib/loader-utils/option-utils.js +1 -1
- package/dist/lib/loader-utils/option-utils.js.map +1 -1
- package/dist/lib/utils/resource-utils.js +1 -1
- package/dist/lib/utils/resource-utils.js.map +1 -1
- package/dist/lib/utils/response-utils.js +1 -1
- package/dist/lib/utils/response-utils.js.map +1 -1
- package/dist/loader-utils/format-types.d.ts +32 -0
- package/dist/loader-utils/format-types.d.ts.map +1 -0
- package/dist/loader-utils/format-types.js +5 -0
- package/dist/loader-utils/format-types.js.map +1 -0
- package/dist/loader-utils/index.cjs +12416 -0
- package/dist/loader-utils/index.cjs.map +6 -0
- package/dist/loader-utils/index.d.ts +122 -0
- package/dist/loader-utils/index.d.ts.map +1 -0
- package/dist/loader-utils/index.js +91 -0
- package/dist/loader-utils/index.js.map +1 -0
- package/dist/loader-utils/json-loader.d.ts +27 -0
- package/dist/loader-utils/json-loader.d.ts.map +1 -0
- package/dist/loader-utils/json-loader.js +32 -0
- package/dist/loader-utils/json-loader.js.map +1 -0
- package/dist/loader-utils/lib/binary-utils/array-buffer-utils.d.ts +32 -0
- package/dist/loader-utils/lib/binary-utils/array-buffer-utils.d.ts.map +1 -0
- package/dist/loader-utils/lib/binary-utils/array-buffer-utils.js +88 -0
- package/dist/loader-utils/lib/binary-utils/array-buffer-utils.js.map +1 -0
- package/dist/loader-utils/lib/binary-utils/binary-chunk-reader.d.ts +67 -0
- package/dist/loader-utils/lib/binary-utils/binary-chunk-reader.d.ts.map +1 -0
- package/dist/loader-utils/lib/binary-utils/binary-chunk-reader.js +245 -0
- package/dist/loader-utils/lib/binary-utils/binary-chunk-reader.js.map +1 -0
- package/dist/loader-utils/lib/binary-utils/dataview-copy-utils.d.ts +43 -0
- package/dist/loader-utils/lib/binary-utils/dataview-copy-utils.d.ts.map +1 -0
- package/dist/loader-utils/lib/binary-utils/dataview-copy-utils.js +92 -0
- package/dist/loader-utils/lib/binary-utils/dataview-copy-utils.js.map +1 -0
- package/dist/loader-utils/lib/binary-utils/encode-array-buffer-to-base64.d.ts +3 -0
- package/dist/loader-utils/lib/binary-utils/encode-array-buffer-to-base64.d.ts.map +1 -0
- package/dist/loader-utils/lib/binary-utils/encode-array-buffer-to-base64.js +15 -0
- package/dist/loader-utils/lib/binary-utils/encode-array-buffer-to-base64.js.map +1 -0
- package/dist/loader-utils/lib/binary-utils/get-first-characters.d.ts +17 -0
- package/dist/loader-utils/lib/binary-utils/get-first-characters.d.ts.map +1 -0
- package/dist/loader-utils/lib/binary-utils/get-first-characters.js +43 -0
- package/dist/loader-utils/lib/binary-utils/get-first-characters.js.map +1 -0
- package/dist/loader-utils/lib/binary-utils/hex-transcoder.d.ts +15 -0
- package/dist/loader-utils/lib/binary-utils/hex-transcoder.d.ts.map +1 -0
- package/dist/loader-utils/lib/binary-utils/hex-transcoder.js +51 -0
- package/dist/loader-utils/lib/binary-utils/hex-transcoder.js.map +1 -0
- package/dist/loader-utils/lib/binary-utils/memory-conversion-utils.d.ts +20 -0
- package/dist/loader-utils/lib/binary-utils/memory-conversion-utils.d.ts.map +1 -0
- package/dist/loader-utils/lib/binary-utils/memory-conversion-utils.js +82 -0
- package/dist/loader-utils/lib/binary-utils/memory-conversion-utils.js.map +1 -0
- package/dist/loader-utils/lib/binary-utils/memory-copy-utils.d.ts +25 -0
- package/dist/loader-utils/lib/binary-utils/memory-copy-utils.d.ts.map +1 -0
- package/dist/loader-utils/lib/binary-utils/memory-copy-utils.js +59 -0
- package/dist/loader-utils/lib/binary-utils/memory-copy-utils.js.map +1 -0
- package/dist/loader-utils/lib/crs/crs-reprojection.d.ts +31 -0
- package/dist/loader-utils/lib/crs/crs-reprojection.d.ts.map +1 -0
- package/dist/loader-utils/lib/crs/crs-reprojection.js +20 -0
- package/dist/loader-utils/lib/crs/crs-reprojection.js.map +1 -0
- package/dist/loader-utils/lib/env-utils/assert.d.ts +6 -0
- package/dist/loader-utils/lib/env-utils/assert.d.ts.map +1 -0
- package/dist/loader-utils/lib/env-utils/assert.js +13 -0
- package/dist/loader-utils/lib/env-utils/assert.js.map +1 -0
- package/dist/loader-utils/lib/env-utils/globals.d.ts +15 -0
- package/dist/loader-utils/lib/env-utils/globals.d.ts.map +1 -0
- package/dist/loader-utils/lib/env-utils/globals.js +28 -0
- package/dist/loader-utils/lib/env-utils/globals.js.map +1 -0
- package/dist/loader-utils/lib/file-provider/data-view-file.d.ts +40 -0
- package/dist/loader-utils/lib/file-provider/data-view-file.d.ts.map +1 -0
- package/dist/loader-utils/lib/file-provider/data-view-file.js +68 -0
- package/dist/loader-utils/lib/file-provider/data-view-file.js.map +1 -0
- package/dist/loader-utils/lib/file-provider/file-handle-file.d.ts +54 -0
- package/dist/loader-utils/lib/file-provider/file-handle-file.d.ts.map +1 -0
- package/dist/loader-utils/lib/file-provider/file-handle-file.js +102 -0
- package/dist/loader-utils/lib/file-provider/file-handle-file.js.map +1 -0
- package/dist/loader-utils/lib/file-provider/file-provider-interface.d.ts +45 -0
- package/dist/loader-utils/lib/file-provider/file-provider-interface.d.ts.map +1 -0
- package/dist/loader-utils/lib/file-provider/file-provider-interface.js +13 -0
- package/dist/loader-utils/lib/file-provider/file-provider-interface.js.map +1 -0
- package/dist/loader-utils/lib/file-provider/file-provider.d.ts +57 -0
- package/dist/loader-utils/lib/file-provider/file-provider.d.ts.map +1 -0
- package/dist/loader-utils/lib/file-provider/file-provider.js +114 -0
- package/dist/loader-utils/lib/file-provider/file-provider.js.map +1 -0
- package/dist/loader-utils/lib/files/array-buffer-file.d.ts +21 -0
- package/dist/loader-utils/lib/files/array-buffer-file.d.ts.map +1 -0
- package/dist/loader-utils/lib/files/array-buffer-file.js +36 -0
- package/dist/loader-utils/lib/files/array-buffer-file.js.map +1 -0
- package/dist/loader-utils/lib/files/blob-file.d.ts +19 -0
- package/dist/loader-utils/lib/files/blob-file.d.ts.map +1 -0
- package/dist/loader-utils/lib/files/blob-file.js +39 -0
- package/dist/loader-utils/lib/files/blob-file.js.map +1 -0
- package/dist/loader-utils/lib/files/file.d.ts +33 -0
- package/dist/loader-utils/lib/files/file.d.ts.map +1 -0
- package/dist/loader-utils/lib/files/file.js +5 -0
- package/dist/loader-utils/lib/files/file.js.map +1 -0
- package/dist/loader-utils/lib/files/http-file-transport.d.ts +37 -0
- package/dist/loader-utils/lib/files/http-file-transport.d.ts.map +1 -0
- package/dist/loader-utils/lib/files/http-file-transport.js +290 -0
- package/dist/loader-utils/lib/files/http-file-transport.js.map +1 -0
- package/dist/loader-utils/lib/files/http-file-types.d.ts +49 -0
- package/dist/loader-utils/lib/files/http-file-types.d.ts.map +1 -0
- package/dist/loader-utils/lib/files/http-file-types.js +5 -0
- package/dist/loader-utils/lib/files/http-file-types.js.map +1 -0
- package/dist/loader-utils/lib/files/http-file.d.ts +55 -0
- package/dist/loader-utils/lib/files/http-file.d.ts.map +1 -0
- package/dist/loader-utils/lib/files/http-file.js +213 -0
- package/dist/loader-utils/lib/files/http-file.js.map +1 -0
- package/dist/loader-utils/lib/files/node-file-facade.d.ts +22 -0
- package/dist/loader-utils/lib/files/node-file-facade.d.ts.map +1 -0
- package/dist/loader-utils/lib/files/node-file-facade.js +45 -0
- package/dist/loader-utils/lib/files/node-file-facade.js.map +1 -0
- package/dist/loader-utils/lib/files/sources.d.ts +1 -0
- package/dist/loader-utils/lib/files/sources.d.ts.map +1 -0
- package/dist/loader-utils/lib/files/sources.js +155 -0
- package/dist/loader-utils/lib/files/sources.js.map +1 -0
- package/dist/loader-utils/lib/filesystems/filesystem.d.ts +33 -0
- package/dist/loader-utils/lib/filesystems/filesystem.d.ts.map +1 -0
- package/dist/loader-utils/lib/filesystems/filesystem.js +5 -0
- package/dist/loader-utils/lib/filesystems/filesystem.js.map +1 -0
- package/dist/loader-utils/lib/filesystems/node-filesystem-facade.d.ts +23 -0
- package/dist/loader-utils/lib/filesystems/node-filesystem-facade.d.ts.map +1 -0
- package/dist/loader-utils/lib/filesystems/node-filesystem-facade.js +48 -0
- package/dist/loader-utils/lib/filesystems/node-filesystem-facade.js.map +1 -0
- package/dist/loader-utils/lib/iterators/async-iteration.d.ts +20 -0
- package/dist/loader-utils/lib/iterators/async-iteration.d.ts.map +1 -0
- package/dist/loader-utils/lib/iterators/async-iteration.js +102 -0
- package/dist/loader-utils/lib/iterators/async-iteration.js.map +1 -0
- package/dist/loader-utils/lib/iterators/text-iterators.d.ts +19 -0
- package/dist/loader-utils/lib/iterators/text-iterators.d.ts.map +1 -0
- package/dist/loader-utils/lib/iterators/text-iterators.js +60 -0
- package/dist/loader-utils/lib/iterators/text-iterators.js.map +1 -0
- package/dist/loader-utils/lib/javascript-utils/is-type.d.ts +59 -0
- package/dist/loader-utils/lib/javascript-utils/is-type.d.ts.map +1 -0
- package/dist/loader-utils/lib/javascript-utils/is-type.js +68 -0
- package/dist/loader-utils/lib/javascript-utils/is-type.js.map +1 -0
- package/dist/loader-utils/lib/laz/laz-arithmetic-encoder.d.ts +118 -0
- package/dist/loader-utils/lib/laz/laz-arithmetic-encoder.d.ts.map +1 -0
- package/dist/loader-utils/lib/laz/laz-arithmetic-encoder.js +427 -0
- package/dist/loader-utils/lib/laz/laz-arithmetic-encoder.js.map +1 -0
- package/dist/loader-utils/lib/laz/laz-chunk-decoder.d.ts +204 -0
- package/dist/loader-utils/lib/laz/laz-chunk-decoder.d.ts.map +1 -0
- package/dist/loader-utils/lib/laz/laz-chunk-decoder.js +4226 -0
- package/dist/loader-utils/lib/laz/laz-chunk-decoder.js.map +1 -0
- package/dist/loader-utils/lib/laz/laz-chunk-encoder.d.ts +40 -0
- package/dist/loader-utils/lib/laz/laz-chunk-encoder.d.ts.map +1 -0
- package/dist/loader-utils/lib/laz/laz-chunk-encoder.js +1518 -0
- package/dist/loader-utils/lib/laz/laz-chunk-encoder.js.map +1 -0
- package/dist/loader-utils/lib/log-utils/log.d.ts +4 -0
- package/dist/loader-utils/lib/log-utils/log.d.ts.map +1 -0
- package/dist/loader-utils/lib/log-utils/log.js +21 -0
- package/dist/loader-utils/lib/log-utils/log.js.map +1 -0
- package/dist/loader-utils/lib/module-utils/initialize-wasm-module.d.ts +10 -0
- package/dist/loader-utils/lib/module-utils/initialize-wasm-module.d.ts.map +1 -0
- package/dist/loader-utils/lib/module-utils/initialize-wasm-module.js +44 -0
- package/dist/loader-utils/lib/module-utils/initialize-wasm-module.js.map +1 -0
- package/dist/loader-utils/lib/module-utils/js-module-utils.d.ts +18 -0
- package/dist/loader-utils/lib/module-utils/js-module-utils.d.ts.map +1 -0
- package/dist/loader-utils/lib/module-utils/js-module-utils.js +40 -0
- package/dist/loader-utils/lib/module-utils/js-module-utils.js.map +1 -0
- package/dist/loader-utils/lib/node/buffer.browser.d.ts +11 -0
- package/dist/loader-utils/lib/node/buffer.browser.d.ts.map +1 -0
- package/dist/loader-utils/lib/node/buffer.browser.js +20 -0
- package/dist/loader-utils/lib/node/buffer.browser.js.map +1 -0
- package/dist/loader-utils/lib/node/buffer.d.ts +11 -0
- package/dist/loader-utils/lib/node/buffer.d.ts.map +1 -0
- package/dist/loader-utils/lib/node/buffer.js +35 -0
- package/dist/loader-utils/lib/node/buffer.js.map +1 -0
- package/dist/loader-utils/lib/node/fs.browser.d.ts +2 -0
- package/dist/loader-utils/lib/node/fs.browser.d.ts.map +1 -0
- package/dist/loader-utils/lib/node/fs.browser.js +5 -0
- package/dist/loader-utils/lib/node/fs.browser.js.map +1 -0
- package/dist/loader-utils/lib/node/promisify.d.ts +13 -0
- package/dist/loader-utils/lib/node/promisify.d.ts.map +1 -0
- package/dist/loader-utils/lib/node/promisify.js +19 -0
- package/dist/loader-utils/lib/node/promisify.js.map +1 -0
- package/dist/loader-utils/lib/node/stream.browser.d.ts +2 -0
- package/dist/loader-utils/lib/node/stream.browser.d.ts.map +1 -0
- package/dist/loader-utils/lib/node/stream.browser.js +5 -0
- package/dist/loader-utils/lib/node/stream.browser.js.map +1 -0
- package/dist/loader-utils/lib/node/stream.d.ts +6 -0
- package/dist/loader-utils/lib/node/stream.d.ts.map +1 -0
- package/dist/loader-utils/lib/node/stream.js +8 -0
- package/dist/loader-utils/lib/node/stream.js.map +1 -0
- package/dist/loader-utils/lib/option-utils/merge-options.d.ts +12 -0
- package/dist/loader-utils/lib/option-utils/merge-options.d.ts.map +1 -0
- package/dist/loader-utils/lib/option-utils/merge-options.js +34 -0
- package/dist/loader-utils/lib/option-utils/merge-options.js.map +1 -0
- package/dist/loader-utils/lib/parser-utils/parse-json.d.ts +5 -0
- package/dist/loader-utils/lib/parser-utils/parse-json.d.ts.map +1 -0
- package/dist/loader-utils/lib/parser-utils/parse-json.js +16 -0
- package/dist/loader-utils/lib/parser-utils/parse-json.js.map +1 -0
- package/dist/loader-utils/lib/path-utils/cached-uri-resolver.d.ts +35 -0
- package/dist/loader-utils/lib/path-utils/cached-uri-resolver.d.ts.map +1 -0
- package/dist/loader-utils/lib/path-utils/cached-uri-resolver.js +64 -0
- package/dist/loader-utils/lib/path-utils/cached-uri-resolver.js.map +1 -0
- package/dist/loader-utils/lib/path-utils/file-aliases.d.ts +17 -0
- package/dist/loader-utils/lib/path-utils/file-aliases.d.ts.map +1 -0
- package/dist/loader-utils/lib/path-utils/file-aliases.js +44 -0
- package/dist/loader-utils/lib/path-utils/file-aliases.js.map +1 -0
- package/dist/loader-utils/lib/path-utils/get-cwd.d.ts +3 -0
- package/dist/loader-utils/lib/path-utils/get-cwd.d.ts.map +1 -0
- package/dist/loader-utils/lib/path-utils/get-cwd.js +12 -0
- package/dist/loader-utils/lib/path-utils/get-cwd.js.map +1 -0
- package/dist/loader-utils/lib/path-utils/path.d.ts +24 -0
- package/dist/loader-utils/lib/path-utils/path.d.ts.map +1 -0
- package/dist/loader-utils/lib/path-utils/path.js +173 -0
- package/dist/loader-utils/lib/path-utils/path.js.map +1 -0
- package/dist/loader-utils/lib/request-utils/abort-utils.d.ts +5 -0
- package/dist/loader-utils/lib/request-utils/abort-utils.d.ts.map +1 -0
- package/dist/loader-utils/lib/request-utils/abort-utils.js +59 -0
- package/dist/loader-utils/lib/request-utils/abort-utils.js.map +1 -0
- package/dist/loader-utils/lib/request-utils/authentication.d.ts +56 -0
- package/dist/loader-utils/lib/request-utils/authentication.d.ts.map +1 -0
- package/dist/loader-utils/lib/request-utils/authentication.js +67 -0
- package/dist/loader-utils/lib/request-utils/authentication.js.map +1 -0
- package/dist/loader-utils/lib/request-utils/parse-content-type.d.ts +7 -0
- package/dist/loader-utils/lib/request-utils/parse-content-type.d.ts.map +1 -0
- package/dist/loader-utils/lib/request-utils/parse-content-type.js +20 -0
- package/dist/loader-utils/lib/request-utils/parse-content-type.js.map +1 -0
- package/dist/loader-utils/lib/request-utils/range-request-cache.d.ts +70 -0
- package/dist/loader-utils/lib/request-utils/range-request-cache.d.ts.map +1 -0
- package/dist/loader-utils/lib/request-utils/range-request-cache.js +203 -0
- package/dist/loader-utils/lib/request-utils/range-request-cache.js.map +1 -0
- package/dist/loader-utils/lib/request-utils/range-request-scheduler.d.ts +201 -0
- package/dist/loader-utils/lib/request-utils/range-request-scheduler.d.ts.map +1 -0
- package/dist/loader-utils/lib/request-utils/range-request-scheduler.js +636 -0
- package/dist/loader-utils/lib/request-utils/range-request-scheduler.js.map +1 -0
- package/dist/loader-utils/lib/request-utils/request-cache.d.ts +62 -0
- package/dist/loader-utils/lib/request-utils/request-cache.d.ts.map +1 -0
- package/dist/loader-utils/lib/request-utils/request-cache.js +236 -0
- package/dist/loader-utils/lib/request-utils/request-cache.js.map +1 -0
- package/dist/loader-utils/lib/request-utils/request-credentials.d.ts +137 -0
- package/dist/loader-utils/lib/request-utils/request-credentials.d.ts.map +1 -0
- package/dist/loader-utils/lib/request-utils/request-credentials.js +379 -0
- package/dist/loader-utils/lib/request-utils/request-credentials.js.map +1 -0
- package/dist/loader-utils/lib/request-utils/request-scheduler.d.ts +71 -0
- package/dist/loader-utils/lib/request-utils/request-scheduler.d.ts.map +1 -0
- package/dist/loader-utils/lib/request-utils/request-scheduler.js +174 -0
- package/dist/loader-utils/lib/request-utils/request-scheduler.js.map +1 -0
- package/dist/loader-utils/lib/scan-utils/columnar-predicate.d.ts +56 -0
- package/dist/loader-utils/lib/scan-utils/columnar-predicate.d.ts.map +1 -0
- package/dist/loader-utils/lib/scan-utils/columnar-predicate.js +261 -0
- package/dist/loader-utils/lib/scan-utils/columnar-predicate.js.map +1 -0
- package/dist/loader-utils/lib/scan-utils/experimental-scan-options.d.ts +42 -0
- package/dist/loader-utils/lib/scan-utils/experimental-scan-options.d.ts.map +1 -0
- package/dist/loader-utils/lib/scan-utils/experimental-scan-options.js +5 -0
- package/dist/loader-utils/lib/scan-utils/experimental-scan-options.js.map +1 -0
- package/dist/loader-utils/lib/scan-utils/point-cloud-query.d.ts +56 -0
- package/dist/loader-utils/lib/scan-utils/point-cloud-query.d.ts.map +1 -0
- package/dist/loader-utils/lib/scan-utils/point-cloud-query.js +86 -0
- package/dist/loader-utils/lib/scan-utils/point-cloud-query.js.map +1 -0
- package/dist/loader-utils/lib/scan-utils/raster-query.d.ts +36 -0
- package/dist/loader-utils/lib/scan-utils/raster-query.d.ts.map +1 -0
- package/dist/loader-utils/lib/scan-utils/raster-query.js +49 -0
- package/dist/loader-utils/lib/scan-utils/raster-query.js.map +1 -0
- package/dist/loader-utils/lib/scan-utils/relational-query.d.ts +75 -0
- package/dist/loader-utils/lib/scan-utils/relational-query.d.ts.map +1 -0
- package/dist/loader-utils/lib/scan-utils/relational-query.js +107 -0
- package/dist/loader-utils/lib/scan-utils/relational-query.js.map +1 -0
- package/dist/loader-utils/lib/scan-utils/scan-executor.d.ts +20 -0
- package/dist/loader-utils/lib/scan-utils/scan-executor.d.ts.map +1 -0
- package/dist/loader-utils/lib/scan-utils/scan-executor.js +183 -0
- package/dist/loader-utils/lib/scan-utils/scan-executor.js.map +1 -0
- package/dist/loader-utils/lib/scan-utils/scan-fragments.d.ts +23 -0
- package/dist/loader-utils/lib/scan-utils/scan-fragments.d.ts.map +1 -0
- package/dist/loader-utils/lib/scan-utils/scan-fragments.js +5 -0
- package/dist/loader-utils/lib/scan-utils/scan-fragments.js.map +1 -0
- package/dist/loader-utils/lib/scan-utils/scan-query-metadata.d.ts +272 -0
- package/dist/loader-utils/lib/scan-utils/scan-query-metadata.d.ts.map +1 -0
- package/dist/loader-utils/lib/scan-utils/scan-query-metadata.js +97 -0
- package/dist/loader-utils/lib/scan-utils/scan-query-metadata.js.map +1 -0
- package/dist/loader-utils/lib/scan-utils/table-query-explain.d.ts +39 -0
- package/dist/loader-utils/lib/scan-utils/table-query-explain.d.ts.map +1 -0
- package/dist/loader-utils/lib/scan-utils/table-query-explain.js +35 -0
- package/dist/loader-utils/lib/scan-utils/table-query-explain.js.map +1 -0
- package/dist/loader-utils/lib/scan-utils/table-query.d.ts +77 -0
- package/dist/loader-utils/lib/scan-utils/table-query.d.ts.map +1 -0
- package/dist/loader-utils/lib/scan-utils/table-query.js +56 -0
- package/dist/loader-utils/lib/scan-utils/table-query.js.map +1 -0
- package/dist/loader-utils/lib/scan-utils/table-scan-batch.d.ts +30 -0
- package/dist/loader-utils/lib/scan-utils/table-scan-batch.d.ts.map +1 -0
- package/dist/loader-utils/lib/scan-utils/table-scan-batch.js +161 -0
- package/dist/loader-utils/lib/scan-utils/table-scan-batch.js.map +1 -0
- package/dist/loader-utils/lib/sources/catalog-source.d.ts +36 -0
- package/dist/loader-utils/lib/sources/catalog-source.d.ts.map +1 -0
- package/dist/loader-utils/lib/sources/catalog-source.js +5 -0
- package/dist/loader-utils/lib/sources/catalog-source.js.map +1 -0
- package/dist/loader-utils/lib/sources/data-source-manager.d.ts +136 -0
- package/dist/loader-utils/lib/sources/data-source-manager.d.ts.map +1 -0
- package/dist/loader-utils/lib/sources/data-source-manager.js +376 -0
- package/dist/loader-utils/lib/sources/data-source-manager.js.map +1 -0
- package/dist/loader-utils/lib/sources/data-source.d.ts +79 -0
- package/dist/loader-utils/lib/sources/data-source.d.ts.map +1 -0
- package/dist/loader-utils/lib/sources/data-source.js +145 -0
- package/dist/loader-utils/lib/sources/data-source.js.map +1 -0
- package/dist/loader-utils/lib/sources/image-source.d.ts +55 -0
- package/dist/loader-utils/lib/sources/image-source.d.ts.map +1 -0
- package/dist/loader-utils/lib/sources/image-source.js +5 -0
- package/dist/loader-utils/lib/sources/image-source.js.map +1 -0
- package/dist/loader-utils/lib/sources/image-tile-source.d.ts +12 -0
- package/dist/loader-utils/lib/sources/image-tile-source.d.ts.map +1 -0
- package/dist/loader-utils/lib/sources/image-tile-source.js +5 -0
- package/dist/loader-utils/lib/sources/image-tile-source.js.map +1 -0
- package/dist/loader-utils/lib/sources/raster-coverage.d.ts +17 -0
- package/dist/loader-utils/lib/sources/raster-coverage.d.ts.map +1 -0
- package/dist/loader-utils/lib/sources/raster-coverage.js +62 -0
- package/dist/loader-utils/lib/sources/raster-coverage.js.map +1 -0
- package/dist/loader-utils/lib/sources/raster-region.d.ts +4 -0
- package/dist/loader-utils/lib/sources/raster-region.d.ts.map +1 -0
- package/dist/loader-utils/lib/sources/raster-region.js +22 -0
- package/dist/loader-utils/lib/sources/raster-region.js.map +1 -0
- package/dist/loader-utils/lib/sources/raster-sampling.d.ts +35 -0
- package/dist/loader-utils/lib/sources/raster-sampling.d.ts.map +1 -0
- package/dist/loader-utils/lib/sources/raster-sampling.js +152 -0
- package/dist/loader-utils/lib/sources/raster-sampling.js.map +1 -0
- package/dist/loader-utils/lib/sources/raster-source.d.ts +302 -0
- package/dist/loader-utils/lib/sources/raster-source.d.ts.map +1 -0
- package/dist/loader-utils/lib/sources/raster-source.js +20 -0
- package/dist/loader-utils/lib/sources/raster-source.js.map +1 -0
- package/dist/loader-utils/lib/sources/service-capabilities.d.ts +36 -0
- package/dist/loader-utils/lib/sources/service-capabilities.d.ts.map +1 -0
- package/dist/loader-utils/lib/sources/service-capabilities.js +5 -0
- package/dist/loader-utils/lib/sources/service-capabilities.js.map +1 -0
- package/dist/loader-utils/lib/sources/tile-grid.d.ts +46 -0
- package/dist/loader-utils/lib/sources/tile-grid.d.ts.map +1 -0
- package/dist/loader-utils/lib/sources/tile-grid.js +128 -0
- package/dist/loader-utils/lib/sources/tile-grid.js.map +1 -0
- package/dist/loader-utils/lib/sources/tile-source-adapter.d.ts +24 -0
- package/dist/loader-utils/lib/sources/tile-source-adapter.d.ts.map +1 -0
- package/dist/loader-utils/lib/sources/tile-source-adapter.js +109 -0
- package/dist/loader-utils/lib/sources/tile-source-adapter.js.map +1 -0
- package/dist/loader-utils/lib/sources/tile-source-utils.d.ts +6 -0
- package/dist/loader-utils/lib/sources/tile-source-utils.d.ts.map +1 -0
- package/dist/loader-utils/lib/sources/tile-source-utils.js +13 -0
- package/dist/loader-utils/lib/sources/tile-source-utils.js.map +1 -0
- package/dist/loader-utils/lib/sources/tile-source.d.ts +190 -0
- package/dist/loader-utils/lib/sources/tile-source.d.ts.map +1 -0
- package/dist/loader-utils/lib/sources/tile-source.js +5 -0
- package/dist/loader-utils/lib/sources/tile-source.js.map +1 -0
- package/dist/loader-utils/lib/sources/utils/image-type.d.ts +10 -0
- package/dist/loader-utils/lib/sources/utils/image-type.d.ts.map +1 -0
- package/dist/loader-utils/lib/sources/utils/image-type.js +5 -0
- package/dist/loader-utils/lib/sources/utils/image-type.js.map +1 -0
- package/dist/loader-utils/lib/sources/utils/utils.d.ts +13 -0
- package/dist/loader-utils/lib/sources/utils/utils.d.ts.map +1 -0
- package/dist/loader-utils/lib/sources/utils/utils.js +26 -0
- package/dist/loader-utils/lib/sources/utils/utils.js.map +1 -0
- package/dist/loader-utils/lib/sources/vector-source.d.ts +76 -0
- package/dist/loader-utils/lib/sources/vector-source.d.ts.map +1 -0
- package/dist/loader-utils/lib/sources/vector-source.js +5 -0
- package/dist/loader-utils/lib/sources/vector-source.js.map +1 -0
- package/dist/loader-utils/lib/sources/vector-tile-source.d.ts +15 -0
- package/dist/loader-utils/lib/sources/vector-tile-source.d.ts.map +1 -0
- package/dist/loader-utils/lib/sources/vector-tile-source.js +5 -0
- package/dist/loader-utils/lib/sources/vector-tile-source.js.map +1 -0
- package/dist/loader-utils/lib/sources/xyz-grid.d.ts +9 -0
- package/dist/loader-utils/lib/sources/xyz-grid.d.ts.map +1 -0
- package/dist/loader-utils/lib/sources/xyz-grid.js +63 -0
- package/dist/loader-utils/lib/sources/xyz-grid.js.map +1 -0
- package/dist/loader-utils/lib/worker-loader-utils/create-loader-worker.d.ts +22 -0
- package/dist/loader-utils/lib/worker-loader-utils/create-loader-worker.d.ts.map +1 -0
- package/dist/loader-utils/lib/worker-loader-utils/create-loader-worker.js +155 -0
- package/dist/loader-utils/lib/worker-loader-utils/create-loader-worker.js.map +1 -0
- package/dist/loader-utils/lib/worker-loader-utils/encode-with-worker.d.ts +8 -0
- package/dist/loader-utils/lib/worker-loader-utils/encode-with-worker.d.ts.map +1 -0
- package/dist/loader-utils/lib/worker-loader-utils/encode-with-worker.js +23 -0
- package/dist/loader-utils/lib/worker-loader-utils/encode-with-worker.js.map +1 -0
- package/dist/loader-utils/lib/worker-loader-utils/parse-with-worker.d.ts +41 -0
- package/dist/loader-utils/lib/worker-loader-utils/parse-with-worker.d.ts.map +1 -0
- package/dist/loader-utils/lib/worker-loader-utils/parse-with-worker.js +239 -0
- package/dist/loader-utils/lib/worker-loader-utils/parse-with-worker.js.map +1 -0
- package/dist/loader-utils/loader-types.d.ts +322 -0
- package/dist/loader-utils/loader-types.d.ts.map +1 -0
- package/dist/loader-utils/loader-types.js +33 -0
- package/dist/loader-utils/loader-types.js.map +1 -0
- package/dist/loader-utils/source-types.d.ts +42 -0
- package/dist/loader-utils/source-types.d.ts.map +1 -0
- package/dist/loader-utils/source-types.js +8 -0
- package/dist/loader-utils/source-types.js.map +1 -0
- package/dist/loader-utils/types.d.ts +24 -0
- package/dist/loader-utils/types.d.ts.map +1 -0
- package/dist/loader-utils/types.js +6 -0
- package/dist/loader-utils/types.js.map +1 -0
- package/dist/loader-utils/workers/json-worker.d.ts +2 -0
- package/dist/loader-utils/workers/json-worker.d.ts.map +1 -0
- package/dist/loader-utils/workers/json-worker.js +7 -0
- package/dist/loader-utils/workers/json-worker.js.map +1 -0
- package/dist/loader-utils/writer-types.d.ts +74 -0
- package/dist/loader-utils/writer-types.d.ts.map +1 -0
- package/dist/loader-utils/writer-types.js +5 -0
- package/dist/loader-utils/writer-types.js.map +1 -0
- package/dist/null-loader.d.ts +2 -2
- package/dist/null-loader.d.ts.map +1 -1
- package/dist/null-loader.js +1 -1
- package/dist/null-worker-node.js +7 -19
- package/dist/null-worker.js +7 -7
- package/dist/polyfills/buffer/btoa.node.d.ts +3 -0
- package/dist/polyfills/buffer/btoa.node.d.ts.map +1 -0
- package/dist/polyfills/buffer/btoa.node.js +13 -0
- package/dist/polyfills/buffer/btoa.node.js.map +1 -0
- package/dist/polyfills/buffer/to-array-buffer.node.d.ts +2 -0
- package/dist/polyfills/buffer/to-array-buffer.node.d.ts.map +1 -0
- package/dist/polyfills/buffer/to-array-buffer.node.js +12 -0
- package/dist/polyfills/buffer/to-array-buffer.node.js.map +1 -0
- package/dist/polyfills/crypto/node-hash.d.ts +29 -0
- package/dist/polyfills/crypto/node-hash.d.ts.map +1 -0
- package/dist/polyfills/crypto/node-hash.js +63 -0
- package/dist/polyfills/crypto/node-hash.js.map +1 -0
- package/dist/polyfills/fetch/decode-data-uri.d.ts +11 -0
- package/dist/polyfills/fetch/decode-data-uri.d.ts.map +1 -0
- package/dist/polyfills/fetch/decode-data-uri.js +63 -0
- package/dist/polyfills/fetch/decode-data-uri.js.map +1 -0
- package/dist/polyfills/fetch/fetch-polyfill.d.ts +11 -0
- package/dist/polyfills/fetch/fetch-polyfill.d.ts.map +1 -0
- package/dist/polyfills/fetch/fetch-polyfill.js +141 -0
- package/dist/polyfills/fetch/fetch-polyfill.js.map +1 -0
- package/dist/polyfills/fetch/headers-polyfill.d.ts +34 -0
- package/dist/polyfills/fetch/headers-polyfill.d.ts.map +1 -0
- package/dist/polyfills/fetch/headers-polyfill.js +105 -0
- package/dist/polyfills/fetch/headers-polyfill.js.map +1 -0
- package/dist/polyfills/fetch/response-polyfill.d.ts +22 -0
- package/dist/polyfills/fetch/response-polyfill.d.ts.map +1 -0
- package/dist/polyfills/fetch/response-polyfill.js +81 -0
- package/dist/polyfills/fetch/response-polyfill.js.map +1 -0
- package/dist/polyfills/fetch/utils/decode-data-uri.node.d.ts +11 -0
- package/dist/polyfills/fetch/utils/decode-data-uri.node.d.ts.map +1 -0
- package/dist/polyfills/fetch/utils/decode-data-uri.node.js +32 -0
- package/dist/polyfills/fetch/utils/decode-data-uri.node.js.map +1 -0
- package/dist/polyfills/file/blob-stream-controller.d.ts +29 -0
- package/dist/polyfills/file/blob-stream-controller.d.ts.map +1 -0
- package/dist/polyfills/file/blob-stream-controller.js +64 -0
- package/dist/polyfills/file/blob-stream-controller.js.map +1 -0
- package/dist/polyfills/file/blob-stream.d.ts +25 -0
- package/dist/polyfills/file/blob-stream.d.ts.map +1 -0
- package/dist/polyfills/file/blob-stream.js +38 -0
- package/dist/polyfills/file/blob-stream.js.map +1 -0
- package/dist/polyfills/file/blob.d.ts +58 -0
- package/dist/polyfills/file/blob.d.ts.map +1 -0
- package/dist/polyfills/file/blob.js +166 -0
- package/dist/polyfills/file/blob.js.map +1 -0
- package/dist/polyfills/file/file-reader.d.ts +24 -0
- package/dist/polyfills/file/file-reader.d.ts.map +1 -0
- package/dist/polyfills/file/file-reader.js +51 -0
- package/dist/polyfills/file/file-reader.js.map +1 -0
- package/dist/polyfills/file/file.d.ts +24 -0
- package/dist/polyfills/file/file.d.ts.map +1 -0
- package/dist/polyfills/file/file.js +41 -0
- package/dist/polyfills/file/file.js.map +1 -0
- package/dist/polyfills/file/install-blob-polyfills.d.ts +9 -0
- package/dist/polyfills/file/install-blob-polyfills.d.ts.map +1 -0
- package/dist/polyfills/file/install-blob-polyfills.js +14 -0
- package/dist/polyfills/file/install-blob-polyfills.js.map +1 -0
- package/dist/polyfills/file/install-file-polyfills.d.ts +3 -0
- package/dist/polyfills/file/install-file-polyfills.d.ts.map +1 -0
- package/dist/polyfills/file/install-file-polyfills.js +20 -0
- package/dist/polyfills/file/install-file-polyfills.js.map +1 -0
- package/dist/polyfills/file/readable-stream.d.ts +5 -0
- package/dist/polyfills/file/readable-stream.d.ts.map +1 -0
- package/dist/polyfills/file/readable-stream.js +8 -0
- package/dist/polyfills/file/readable-stream.js.map +1 -0
- package/dist/polyfills/filesystems/fetch-node.d.ts +8 -0
- package/dist/polyfills/filesystems/fetch-node.d.ts.map +1 -0
- package/dist/polyfills/filesystems/fetch-node.js +88 -0
- package/dist/polyfills/filesystems/fetch-node.js.map +1 -0
- package/dist/polyfills/filesystems/node-file.d.ts +15 -0
- package/dist/polyfills/filesystems/node-file.d.ts.map +1 -0
- package/dist/polyfills/filesystems/node-file.js +138 -0
- package/dist/polyfills/filesystems/node-file.js.map +1 -0
- package/dist/polyfills/filesystems/node-filesystem.d.ts +19 -0
- package/dist/polyfills/filesystems/node-filesystem.d.ts.map +1 -0
- package/dist/polyfills/filesystems/node-filesystem.js +44 -0
- package/dist/polyfills/filesystems/node-filesystem.js.map +1 -0
- package/dist/polyfills/filesystems/stream-utils.node.d.ts +18 -0
- package/dist/polyfills/filesystems/stream-utils.node.d.ts.map +1 -0
- package/dist/polyfills/filesystems/stream-utils.node.js +67 -0
- package/dist/polyfills/filesystems/stream-utils.node.js.map +1 -0
- package/dist/polyfills/images/encode-image-node.d.ts +20 -0
- package/dist/polyfills/images/encode-image-node.d.ts.map +1 -0
- package/dist/polyfills/images/encode-image-node.js +37 -0
- package/dist/polyfills/images/encode-image-node.js.map +1 -0
- package/dist/polyfills/images/image-codecs-node.d.ts +8 -0
- package/dist/polyfills/images/image-codecs-node.d.ts.map +1 -0
- package/dist/polyfills/images/image-codecs-node.js +27 -0
- package/dist/polyfills/images/image-codecs-node.js.map +1 -0
- package/dist/polyfills/images/node-image-bitmap.d.ts +38 -0
- package/dist/polyfills/images/node-image-bitmap.d.ts.map +1 -0
- package/dist/polyfills/images/node-image-bitmap.js +64 -0
- package/dist/polyfills/images/node-image-bitmap.js.map +1 -0
- package/dist/polyfills/images/node-image-formats.d.ts +3 -0
- package/dist/polyfills/images/node-image-formats.d.ts.map +1 -0
- package/dist/polyfills/images/node-image-formats.js +6 -0
- package/dist/polyfills/images/node-image-formats.js.map +1 -0
- package/dist/polyfills/images/parse-image-node.d.ts +11 -0
- package/dist/polyfills/images/parse-image-node.d.ts.map +1 -0
- package/dist/polyfills/images/parse-image-node.js +36 -0
- package/dist/polyfills/images/parse-image-node.js.map +1 -0
- package/dist/polyfills/index.browser.d.ts +8 -0
- package/dist/polyfills/index.browser.d.ts.map +1 -0
- package/dist/polyfills/index.browser.js +18 -0
- package/dist/polyfills/index.browser.js.map +1 -0
- package/dist/polyfills/index.cjs +2918 -0
- package/dist/polyfills/index.cjs.map +6 -0
- package/dist/polyfills/index.d.ts +7 -0
- package/dist/polyfills/index.d.ts.map +1 -0
- package/dist/polyfills/index.js +110 -0
- package/dist/polyfills/index.js.map +1 -0
- package/dist/polyfills/libs/encoding-indexes-asian.d.ts +10 -0
- package/dist/polyfills/libs/encoding-indexes-asian.d.ts.map +1 -0
- package/dist/polyfills/libs/encoding-indexes-asian.js +14 -0
- package/dist/polyfills/libs/encoding-indexes-asian.js.map +1 -0
- package/dist/polyfills/load-library/require-utils.node.d.ts +19 -0
- package/dist/polyfills/load-library/require-utils.node.d.ts.map +1 -0
- package/dist/polyfills/load-library/require-utils.node.js +88 -0
- package/dist/polyfills/load-library/require-utils.node.js.map +1 -0
- package/dist/polyfills/streams/make-node-stream.d.ts +10 -0
- package/dist/polyfills/streams/make-node-stream.d.ts.map +1 -0
- package/dist/polyfills/streams/make-node-stream.js +70 -0
- package/dist/polyfills/streams/make-node-stream.js.map +1 -0
- package/dist/polyfills/text-encoder/encoding-indexes.d.ts +31 -0
- package/dist/polyfills/text-encoder/encoding-indexes.d.ts.map +1 -0
- package/dist/polyfills/text-encoder/encoding-indexes.js +35 -0
- package/dist/polyfills/text-encoder/encoding-indexes.js.map +1 -0
- package/dist/polyfills/text-encoder/text-encoder.d.ts +15 -0
- package/dist/polyfills/text-encoder/text-encoder.d.ts.map +1 -0
- package/dist/polyfills/text-encoder/text-encoder.js +2778 -0
- package/dist/polyfills/text-encoder/text-encoder.js.map +1 -0
- package/dist/polyfills/utils/assert.d.ts +2 -0
- package/dist/polyfills/utils/assert.d.ts.map +1 -0
- package/dist/polyfills/utils/assert.js +9 -0
- package/dist/polyfills/utils/assert.js.map +1 -0
- package/dist/polyfills/utils/buffer-utils.d.ts +5 -0
- package/dist/polyfills/utils/buffer-utils.d.ts.map +1 -0
- package/dist/polyfills/utils/buffer-utils.js +34 -0
- package/dist/polyfills/utils/buffer-utils.js.map +1 -0
- package/dist/polyfills/utils/filesystem-types.d.ts +10 -0
- package/dist/polyfills/utils/filesystem-types.d.ts.map +1 -0
- package/dist/polyfills/utils/filesystem-types.js +5 -0
- package/dist/polyfills/utils/filesystem-types.js.map +1 -0
- package/dist/polyfills/utils/is-browser.d.ts +2 -0
- package/dist/polyfills/utils/is-browser.d.ts.map +1 -0
- package/dist/polyfills/utils/is-browser.js +8 -0
- package/dist/polyfills/utils/is-browser.js.map +1 -0
- package/dist/polyfills/utils/path-utils.d.ts +7 -0
- package/dist/polyfills/utils/path-utils.d.ts.map +1 -0
- package/dist/polyfills/utils/path-utils.js +28 -0
- package/dist/polyfills/utils/path-utils.js.map +1 -0
- package/dist/schema/categories/category-gis.d.ts +7 -0
- package/dist/schema/categories/category-gis.d.ts.map +1 -0
- package/dist/schema/categories/category-gis.js +5 -0
- package/dist/schema/categories/category-gis.js.map +1 -0
- package/dist/schema/categories/category-image.d.ts +18 -0
- package/dist/schema/categories/category-image.d.ts.map +1 -0
- package/dist/schema/categories/category-image.js +5 -0
- package/dist/schema/categories/category-image.js.map +1 -0
- package/dist/schema/categories/category-mesh.d.ts +99 -0
- package/dist/schema/categories/category-mesh.d.ts.map +1 -0
- package/dist/schema/categories/category-mesh.js +14 -0
- package/dist/schema/categories/category-mesh.js.map +1 -0
- package/dist/schema/categories/category-table.d.ts +106 -0
- package/dist/schema/categories/category-table.d.ts.map +1 -0
- package/dist/schema/categories/category-table.js +5 -0
- package/dist/schema/categories/category-table.js.map +1 -0
- package/dist/schema/categories/category-texture.d.ts +115 -0
- package/dist/schema/categories/category-texture.d.ts.map +1 -0
- package/dist/schema/categories/category-texture.js +5 -0
- package/dist/schema/categories/category-texture.js.map +1 -0
- package/dist/schema/deprecated/mesh-utils.d.ts +12 -0
- package/dist/schema/deprecated/mesh-utils.d.ts.map +1 -0
- package/dist/schema/deprecated/mesh-utils.js +37 -0
- package/dist/schema/deprecated/mesh-utils.js.map +1 -0
- package/dist/schema/float16.d.ts +19 -0
- package/dist/schema/float16.d.ts.map +1 -0
- package/dist/schema/float16.js +90 -0
- package/dist/schema/float16.js.map +1 -0
- package/dist/schema/geoarrow-metadata.schema.json +117 -0
- package/dist/schema/geometry/arrow-binary-features.d.ts +45 -0
- package/dist/schema/geometry/arrow-binary-features.d.ts.map +1 -0
- package/dist/schema/geometry/arrow-binary-features.js +5 -0
- package/dist/schema/geometry/arrow-binary-features.js.map +1 -0
- package/dist/schema/geometry/binary-features.d.ts +30 -0
- package/dist/schema/geometry/binary-features.d.ts.map +1 -0
- package/dist/schema/geometry/binary-features.js +5 -0
- package/dist/schema/geometry/binary-features.js.map +1 -0
- package/dist/schema/geometry/binary-geometries.d.ts +33 -0
- package/dist/schema/geometry/binary-geometries.d.ts.map +1 -0
- package/dist/schema/geometry/binary-geometries.js +5 -0
- package/dist/schema/geometry/binary-geometries.js.map +1 -0
- package/dist/schema/geometry/flat-geometries.d.ts +61 -0
- package/dist/schema/geometry/flat-geometries.d.ts.map +1 -0
- package/dist/schema/geometry/flat-geometries.js +5 -0
- package/dist/schema/geometry/flat-geometries.js.map +1 -0
- package/dist/schema/geometry/geoarrow.d.ts +69 -0
- package/dist/schema/geometry/geoarrow.d.ts.map +1 -0
- package/dist/schema/geometry/geoarrow.js +5 -0
- package/dist/schema/geometry/geoarrow.js.map +1 -0
- package/dist/schema/geoparquet.schema.json +222 -0
- package/dist/schema/geospatial-metadata-zod-schema.cjs +154 -0
- package/dist/schema/geospatial-metadata-zod-schema.cjs.map +6 -0
- package/dist/schema/geospatial-metadata-zod-schema.d.ts +44 -0
- package/dist/schema/geospatial-metadata-zod-schema.d.ts.map +1 -0
- package/dist/schema/geospatial-metadata-zod-schema.js +151 -0
- package/dist/schema/geospatial-metadata-zod-schema.js.map +1 -0
- package/dist/schema/index.cjs +259 -0
- package/dist/schema/index.cjs.map +6 -0
- package/dist/schema/index.d.ts +21 -0
- package/dist/schema/index.d.ts.map +1 -0
- package/dist/schema/index.js +9 -0
- package/dist/schema/index.js.map +1 -0
- package/dist/schema/metadata.d.ts +40 -0
- package/dist/schema/metadata.d.ts.map +1 -0
- package/dist/schema/metadata.js +86 -0
- package/dist/schema/metadata.js.map +1 -0
- package/dist/schema/types/batch.d.ts +37 -0
- package/dist/schema/types/batch.d.ts.map +1 -0
- package/dist/schema/types/batch.js +5 -0
- package/dist/schema/types/batch.js.map +1 -0
- package/dist/schema/types/schema.d.ts +70 -0
- package/dist/schema/types/schema.d.ts.map +1 -0
- package/dist/schema/types/schema.js +5 -0
- package/dist/schema/types/schema.js.map +1 -0
- package/dist/schema/types/types.d.ts +16 -0
- package/dist/schema/types/types.d.ts.map +1 -0
- package/dist/schema/types/types.js +6 -0
- package/dist/schema/types/types.js.map +1 -0
- package/dist/schema-utils/arrow-transport.cjs +665 -0
- package/dist/schema-utils/arrow-transport.cjs.map +6 -0
- package/dist/schema-utils/arrow-transport.d.ts +4 -0
- package/dist/schema-utils/arrow-transport.d.ts.map +1 -0
- package/dist/schema-utils/arrow-transport.js +7 -0
- package/dist/schema-utils/arrow-transport.js.map +1 -0
- package/dist/schema-utils/deprecated.d.ts +24 -0
- package/dist/schema-utils/deprecated.d.ts.map +1 -0
- package/dist/schema-utils/deprecated.js +27 -0
- package/dist/schema-utils/deprecated.js.map +1 -0
- package/dist/schema-utils/index.cjs +3423 -0
- package/dist/schema-utils/index.cjs.map +6 -0
- package/dist/schema-utils/index.d.ts +38 -0
- package/dist/schema-utils/index.d.ts.map +1 -0
- package/dist/schema-utils/index.js +77 -0
- package/dist/schema-utils/index.js.map +1 -0
- package/dist/schema-utils/lib/arrow/arrow-table-transport.d.ts +72 -0
- package/dist/schema-utils/lib/arrow/arrow-table-transport.d.ts.map +1 -0
- package/dist/schema-utils/lib/arrow/arrow-table-transport.js +162 -0
- package/dist/schema-utils/lib/arrow/arrow-table-transport.js.map +1 -0
- package/dist/schema-utils/lib/arrow/split-arrow-buffers.d.ts +33 -0
- package/dist/schema-utils/lib/arrow/split-arrow-buffers.d.ts.map +1 -0
- package/dist/schema-utils/lib/arrow/split-arrow-buffers.js +128 -0
- package/dist/schema-utils/lib/arrow/split-arrow-buffers.js.map +1 -0
- package/dist/schema-utils/lib/arrow-utils/arrow-fixed-size-list-utils.d.ts +11 -0
- package/dist/schema-utils/lib/arrow-utils/arrow-fixed-size-list-utils.d.ts.map +1 -0
- package/dist/schema-utils/lib/arrow-utils/arrow-fixed-size-list-utils.js +45 -0
- package/dist/schema-utils/lib/arrow-utils/arrow-fixed-size-list-utils.js.map +1 -0
- package/dist/schema-utils/lib/arrow-utils/arrow-list-of-fixed-size-list-utils.d.ts +11 -0
- package/dist/schema-utils/lib/arrow-utils/arrow-list-of-fixed-size-list-utils.d.ts.map +1 -0
- package/dist/schema-utils/lib/arrow-utils/arrow-list-of-fixed-size-list-utils.js +33 -0
- package/dist/schema-utils/lib/arrow-utils/arrow-list-of-fixed-size-list-utils.js.map +1 -0
- package/dist/schema-utils/lib/converters/convert.d.ts +10 -0
- package/dist/schema-utils/lib/converters/convert.d.ts.map +1 -0
- package/dist/schema-utils/lib/converters/convert.js +98 -0
- package/dist/schema-utils/lib/converters/convert.js.map +1 -0
- package/dist/schema-utils/lib/converters/converters.d.ts +3 -0
- package/dist/schema-utils/lib/converters/converters.d.ts.map +1 -0
- package/dist/schema-utils/lib/converters/converters.js +5 -0
- package/dist/schema-utils/lib/converters/converters.js.map +1 -0
- package/dist/schema-utils/lib/converters/types.d.ts +35 -0
- package/dist/schema-utils/lib/converters/types.d.ts.map +1 -0
- package/dist/schema-utils/lib/converters/types.js +5 -0
- package/dist/schema-utils/lib/converters/types.js.map +1 -0
- package/dist/schema-utils/lib/mesh/convert-mesh-to-table.d.ts +44 -0
- package/dist/schema-utils/lib/mesh/convert-mesh-to-table.d.ts.map +1 -0
- package/dist/schema-utils/lib/mesh/convert-mesh-to-table.js +187 -0
- package/dist/schema-utils/lib/mesh/convert-mesh-to-table.js.map +1 -0
- package/dist/schema-utils/lib/mesh/convert-table-to-mesh.d.ts +14 -0
- package/dist/schema-utils/lib/mesh/convert-table-to-mesh.d.ts.map +1 -0
- package/dist/schema-utils/lib/mesh/convert-table-to-mesh.js +217 -0
- package/dist/schema-utils/lib/mesh/convert-table-to-mesh.js.map +1 -0
- package/dist/schema-utils/lib/mesh/deduce-mesh-schema.d.ts +23 -0
- package/dist/schema-utils/lib/mesh/deduce-mesh-schema.d.ts.map +1 -0
- package/dist/schema-utils/lib/mesh/deduce-mesh-schema.js +72 -0
- package/dist/schema-utils/lib/mesh/deduce-mesh-schema.js.map +1 -0
- package/dist/schema-utils/lib/mesh/mesh-utils.d.ts +23 -0
- package/dist/schema-utils/lib/mesh/mesh-utils.d.ts.map +1 -0
- package/dist/schema-utils/lib/mesh/mesh-utils.js +54 -0
- package/dist/schema-utils/lib/mesh/mesh-utils.js.map +1 -0
- package/dist/schema-utils/lib/mesh/point-cloud-tiler.d.ts +98 -0
- package/dist/schema-utils/lib/mesh/point-cloud-tiler.d.ts.map +1 -0
- package/dist/schema-utils/lib/mesh/point-cloud-tiler.js +407 -0
- package/dist/schema-utils/lib/mesh/point-cloud-tiler.js.map +1 -0
- package/dist/schema-utils/lib/schema/convert-arrow-schema.d.ts +39 -0
- package/dist/schema-utils/lib/schema/convert-arrow-schema.d.ts.map +1 -0
- package/dist/schema-utils/lib/schema/convert-arrow-schema.js +441 -0
- package/dist/schema-utils/lib/schema/convert-arrow-schema.js.map +1 -0
- package/dist/schema-utils/lib/schema/data-type.d.ts +16 -0
- package/dist/schema-utils/lib/schema/data-type.d.ts.map +1 -0
- package/dist/schema-utils/lib/schema/data-type.js +102 -0
- package/dist/schema-utils/lib/schema/data-type.js.map +1 -0
- package/dist/schema-utils/lib/schema/deduce-table-schema.d.ts +14 -0
- package/dist/schema-utils/lib/schema/deduce-table-schema.d.ts.map +1 -0
- package/dist/schema-utils/lib/schema/deduce-table-schema.js +101 -0
- package/dist/schema-utils/lib/schema/deduce-table-schema.js.map +1 -0
- package/dist/schema-utils/lib/table/arrow-api/arrow-like-field.d.ts +19 -0
- package/dist/schema-utils/lib/table/arrow-api/arrow-like-field.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/arrow-api/arrow-like-field.js +37 -0
- package/dist/schema-utils/lib/table/arrow-api/arrow-like-field.js.map +1 -0
- package/dist/schema-utils/lib/table/arrow-api/arrow-like-interface.d.ts +43 -0
- package/dist/schema-utils/lib/table/arrow-api/arrow-like-interface.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/arrow-api/arrow-like-interface.js +5 -0
- package/dist/schema-utils/lib/table/arrow-api/arrow-like-interface.js.map +1 -0
- package/dist/schema-utils/lib/table/arrow-api/arrow-like-schema.d.ts +12 -0
- package/dist/schema-utils/lib/table/arrow-api/arrow-like-schema.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/arrow-api/arrow-like-schema.js +82 -0
- package/dist/schema-utils/lib/table/arrow-api/arrow-like-schema.js.map +1 -0
- package/dist/schema-utils/lib/table/arrow-api/arrow-like-table.d.ts +28 -0
- package/dist/schema-utils/lib/table/arrow-api/arrow-like-table.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/arrow-api/arrow-like-table.js +64 -0
- package/dist/schema-utils/lib/table/arrow-api/arrow-like-table.js.map +1 -0
- package/dist/schema-utils/lib/table/arrow-api/arrow-like-type.d.ts +177 -0
- package/dist/schema-utils/lib/table/arrow-api/arrow-like-type.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/arrow-api/arrow-like-type.js +441 -0
- package/dist/schema-utils/lib/table/arrow-api/arrow-like-type.js.map +1 -0
- package/dist/schema-utils/lib/table/arrow-api/enum.d.ts +92 -0
- package/dist/schema-utils/lib/table/arrow-api/enum.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/arrow-api/enum.js +98 -0
- package/dist/schema-utils/lib/table/arrow-api/enum.js.map +1 -0
- package/dist/schema-utils/lib/table/arrow-api/get-type-info.d.ts +13 -0
- package/dist/schema-utils/lib/table/arrow-api/get-type-info.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/arrow-api/get-type-info.js +28 -0
- package/dist/schema-utils/lib/table/arrow-api/get-type-info.js.map +1 -0
- package/dist/schema-utils/lib/table/arrow-api/index.d.ts +6 -0
- package/dist/schema-utils/lib/table/arrow-api/index.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/arrow-api/index.js +8 -0
- package/dist/schema-utils/lib/table/arrow-api/index.js.map +1 -0
- package/dist/schema-utils/lib/table/batch-builder/arrow-table-batch-aggregator.d.ts +10 -0
- package/dist/schema-utils/lib/table/batch-builder/arrow-table-batch-aggregator.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/batch-builder/arrow-table-batch-aggregator.js +71 -0
- package/dist/schema-utils/lib/table/batch-builder/arrow-table-batch-aggregator.js.map +1 -0
- package/dist/schema-utils/lib/table/batch-builder/arrow-table-builder.d.ts +28 -0
- package/dist/schema-utils/lib/table/batch-builder/arrow-table-builder.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/batch-builder/arrow-table-builder.js +104 -0
- package/dist/schema-utils/lib/table/batch-builder/arrow-table-builder.js.map +1 -0
- package/dist/schema-utils/lib/table/batch-builder/base-table-batch-aggregator.d.ts +19 -0
- package/dist/schema-utils/lib/table/batch-builder/base-table-batch-aggregator.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/batch-builder/base-table-batch-aggregator.js +64 -0
- package/dist/schema-utils/lib/table/batch-builder/base-table-batch-aggregator.js.map +1 -0
- package/dist/schema-utils/lib/table/batch-builder/columnar-table-batch-aggregator.d.ts +20 -0
- package/dist/schema-utils/lib/table/batch-builder/columnar-table-batch-aggregator.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/batch-builder/columnar-table-batch-aggregator.js +84 -0
- package/dist/schema-utils/lib/table/batch-builder/columnar-table-batch-aggregator.js.map +1 -0
- package/dist/schema-utils/lib/table/batch-builder/row-table-batch-aggregator.d.ts +21 -0
- package/dist/schema-utils/lib/table/batch-builder/row-table-batch-aggregator.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/batch-builder/row-table-batch-aggregator.js +86 -0
- package/dist/schema-utils/lib/table/batch-builder/row-table-batch-aggregator.js.map +1 -0
- package/dist/schema-utils/lib/table/batch-builder/table-batch-aggregator.d.ts +24 -0
- package/dist/schema-utils/lib/table/batch-builder/table-batch-aggregator.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/batch-builder/table-batch-aggregator.js +5 -0
- package/dist/schema-utils/lib/table/batch-builder/table-batch-aggregator.js.map +1 -0
- package/dist/schema-utils/lib/table/batch-builder/table-batch-builder.d.ts +52 -0
- package/dist/schema-utils/lib/table/batch-builder/table-batch-builder.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/batch-builder/table-batch-builder.js +149 -0
- package/dist/schema-utils/lib/table/batch-builder/table-batch-builder.js.map +1 -0
- package/dist/schema-utils/lib/table/batches/convert-batches.d.ts +10 -0
- package/dist/schema-utils/lib/table/batches/convert-batches.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/batches/convert-batches.js +46 -0
- package/dist/schema-utils/lib/table/batches/convert-batches.js.map +1 -0
- package/dist/schema-utils/lib/table/batches/make-arrow-batch-iterator.d.ts +17 -0
- package/dist/schema-utils/lib/table/batches/make-arrow-batch-iterator.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/batches/make-arrow-batch-iterator.js +61 -0
- package/dist/schema-utils/lib/table/batches/make-arrow-batch-iterator.js.map +1 -0
- package/dist/schema-utils/lib/table/batches/make-table-batch-iterator.d.ts +15 -0
- package/dist/schema-utils/lib/table/batches/make-table-batch-iterator.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/batches/make-table-batch-iterator.js +22 -0
- package/dist/schema-utils/lib/table/batches/make-table-batch-iterator.js.map +1 -0
- package/dist/schema-utils/lib/table/batches/make-table-from-batches.d.ts +9 -0
- package/dist/schema-utils/lib/table/batches/make-table-from-batches.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/batches/make-table-from-batches.js +63 -0
- package/dist/schema-utils/lib/table/batches/make-table-from-batches.js.map +1 -0
- package/dist/schema-utils/lib/table/query-arrow-table.d.ts +23 -0
- package/dist/schema-utils/lib/table/query-arrow-table.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/query-arrow-table.js +73 -0
- package/dist/schema-utils/lib/table/query-arrow-table.js.map +1 -0
- package/dist/schema-utils/lib/table/tables/convert-arrow-table.d.ts +24 -0
- package/dist/schema-utils/lib/table/tables/convert-arrow-table.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/tables/convert-arrow-table.js +151 -0
- package/dist/schema-utils/lib/table/tables/convert-arrow-table.js.map +1 -0
- package/dist/schema-utils/lib/table/tables/convert-table.d.ts +43 -0
- package/dist/schema-utils/lib/table/tables/convert-table.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/tables/convert-table.js +122 -0
- package/dist/schema-utils/lib/table/tables/convert-table.js.map +1 -0
- package/dist/schema-utils/lib/table/tables/make-table.d.ts +67 -0
- package/dist/schema-utils/lib/table/tables/make-table.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/tables/make-table.js +102 -0
- package/dist/schema-utils/lib/table/tables/make-table.js.map +1 -0
- package/dist/schema-utils/lib/table/tables/row-utils.d.ts +15 -0
- package/dist/schema-utils/lib/table/tables/row-utils.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/tables/row-utils.js +50 -0
- package/dist/schema-utils/lib/table/tables/row-utils.js.map +1 -0
- package/dist/schema-utils/lib/table/tables/table-accessors.d.ts +68 -0
- package/dist/schema-utils/lib/table/tables/table-accessors.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/tables/table-accessors.js +352 -0
- package/dist/schema-utils/lib/table/tables/table-accessors.js.map +1 -0
- package/dist/schema-utils/lib/table/tables/table-column.d.ts +7 -0
- package/dist/schema-utils/lib/table/tables/table-column.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/tables/table-column.js +40 -0
- package/dist/schema-utils/lib/table/tables/table-column.js.map +1 -0
- package/dist/schema-utils/lib/table/tables/table-converter/convert-tables.d.ts +9 -0
- package/dist/schema-utils/lib/table/tables/table-converter/convert-tables.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/tables/table-converter/convert-tables.js +19 -0
- package/dist/schema-utils/lib/table/tables/table-converter/convert-tables.js.map +1 -0
- package/dist/schema-utils/lib/table/tables/table-converter/table-converter.d.ts +16 -0
- package/dist/schema-utils/lib/table/tables/table-converter/table-converter.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/tables/table-converter/table-converter.js +45 -0
- package/dist/schema-utils/lib/table/tables/table-converter/table-converter.js.map +1 -0
- package/dist/schema-utils/lib/table/tables/table-types.d.ts +12 -0
- package/dist/schema-utils/lib/table/tables/table-types.d.ts.map +1 -0
- package/dist/schema-utils/lib/table/tables/table-types.js +24 -0
- package/dist/schema-utils/lib/table/tables/table-types.js.map +1 -0
- package/dist/schema-utils/lib/utils/assert.d.ts +2 -0
- package/dist/schema-utils/lib/utils/assert.d.ts.map +1 -0
- package/dist/schema-utils/lib/utils/assert.js +12 -0
- package/dist/schema-utils/lib/utils/assert.js.map +1 -0
- package/dist/schema-utils/lib/utils/async-queue.d.ts +18 -0
- package/dist/schema-utils/lib/utils/async-queue.d.ts.map +1 -0
- package/dist/schema-utils/lib/utils/async-queue.js +96 -0
- package/dist/schema-utils/lib/utils/async-queue.js.map +1 -0
- package/dist/schema-utils/types/types.d.ts +15 -0
- package/dist/schema-utils/types/types.d.ts.map +1 -0
- package/dist/schema-utils/types/types.js +5 -0
- package/dist/schema-utils/types/types.js.map +1 -0
- package/dist/worker-utils/index.cjs +1448 -0
- package/dist/worker-utils/index.cjs.map +6 -0
- package/dist/worker-utils/index.d.ts +22 -0
- package/dist/worker-utils/index.d.ts.map +1 -0
- package/dist/worker-utils/index.js +40 -0
- package/dist/worker-utils/index.js.map +1 -0
- package/dist/worker-utils/lib/async-queue/async-queue.d.ts +32 -0
- package/dist/worker-utils/lib/async-queue/async-queue.d.ts.map +1 -0
- package/dist/worker-utils/lib/async-queue/async-queue.js +91 -0
- package/dist/worker-utils/lib/async-queue/async-queue.js.map +1 -0
- package/dist/worker-utils/lib/env-utils/assert.d.ts +3 -0
- package/dist/worker-utils/lib/env-utils/assert.d.ts.map +1 -0
- package/dist/worker-utils/lib/env-utils/assert.js +13 -0
- package/dist/worker-utils/lib/env-utils/assert.js.map +1 -0
- package/dist/worker-utils/lib/env-utils/globals.d.ts +22 -0
- package/dist/worker-utils/lib/env-utils/globals.d.ts.map +1 -0
- package/dist/worker-utils/lib/env-utils/globals.js +30 -0
- package/dist/worker-utils/lib/env-utils/globals.js.map +1 -0
- package/dist/worker-utils/lib/env-utils/version.d.ts +2 -0
- package/dist/worker-utils/lib/env-utils/version.d.ts.map +1 -0
- package/dist/worker-utils/lib/env-utils/version.js +20 -0
- package/dist/worker-utils/lib/env-utils/version.js.map +1 -0
- package/dist/worker-utils/lib/library-utils/library-utils.d.ts +42 -0
- package/dist/worker-utils/lib/library-utils/library-utils.d.ts.map +1 -0
- package/dist/worker-utils/lib/library-utils/library-utils.js +248 -0
- package/dist/worker-utils/lib/library-utils/library-utils.js.map +1 -0
- package/dist/worker-utils/lib/node/worker_threads-browser.d.ts +14 -0
- package/dist/worker-utils/lib/node/worker_threads-browser.d.ts.map +1 -0
- package/dist/worker-utils/lib/node/worker_threads-browser.js +22 -0
- package/dist/worker-utils/lib/node/worker_threads-browser.js.map +1 -0
- package/dist/worker-utils/lib/node/worker_threads.d.ts +15 -0
- package/dist/worker-utils/lib/node/worker_threads.d.ts.map +1 -0
- package/dist/worker-utils/lib/node/worker_threads.js +16 -0
- package/dist/worker-utils/lib/node/worker_threads.js.map +1 -0
- package/dist/worker-utils/lib/npm-tag.d.ts +8 -0
- package/dist/worker-utils/lib/npm-tag.d.ts.map +1 -0
- package/dist/worker-utils/lib/npm-tag.js +11 -0
- package/dist/worker-utils/lib/npm-tag.js.map +1 -0
- package/dist/worker-utils/lib/process-utils/child-process-proxy.browser.d.ts +8 -0
- package/dist/worker-utils/lib/process-utils/child-process-proxy.browser.d.ts.map +1 -0
- package/dist/worker-utils/lib/process-utils/child-process-proxy.browser.js +18 -0
- package/dist/worker-utils/lib/process-utils/child-process-proxy.browser.js.map +1 -0
- package/dist/worker-utils/lib/process-utils/child-process-proxy.d.ts +45 -0
- package/dist/worker-utils/lib/process-utils/child-process-proxy.d.ts.map +1 -0
- package/dist/worker-utils/lib/process-utils/child-process-proxy.js +123 -0
- package/dist/worker-utils/lib/process-utils/child-process-proxy.js.map +1 -0
- package/dist/worker-utils/lib/process-utils/process-utils.d.ts +2 -0
- package/dist/worker-utils/lib/process-utils/process-utils.d.ts.map +1 -0
- package/dist/worker-utils/lib/process-utils/process-utils.js +32 -0
- package/dist/worker-utils/lib/process-utils/process-utils.js.map +1 -0
- package/dist/worker-utils/lib/worker-api/create-worker.d.ts +9 -0
- package/dist/worker-utils/lib/worker-api/create-worker.d.ts.map +1 -0
- package/dist/worker-utils/lib/worker-api/create-worker.js +123 -0
- package/dist/worker-utils/lib/worker-api/create-worker.js.map +1 -0
- package/dist/worker-utils/lib/worker-api/get-worker-url.d.ts +27 -0
- package/dist/worker-utils/lib/worker-api/get-worker-url.d.ts.map +1 -0
- package/dist/worker-utils/lib/worker-api/get-worker-url.js +103 -0
- package/dist/worker-utils/lib/worker-api/get-worker-url.js.map +1 -0
- package/dist/worker-utils/lib/worker-api/process-on-worker.d.ts +44 -0
- package/dist/worker-utils/lib/worker-api/process-on-worker.d.ts.map +1 -0
- package/dist/worker-utils/lib/worker-api/process-on-worker.js +312 -0
- package/dist/worker-utils/lib/worker-api/process-on-worker.js.map +1 -0
- package/dist/worker-utils/lib/worker-api/validate-worker-version.d.ts +9 -0
- package/dist/worker-utils/lib/worker-api/validate-worker-version.d.ts.map +1 -0
- package/dist/worker-utils/lib/worker-api/validate-worker-version.js +35 -0
- package/dist/worker-utils/lib/worker-api/validate-worker-version.js.map +1 -0
- package/dist/worker-utils/lib/worker-farm/worker-body.d.ts +20 -0
- package/dist/worker-utils/lib/worker-farm/worker-body.d.ts.map +1 -0
- package/dist/worker-utils/lib/worker-farm/worker-body.js +131 -0
- package/dist/worker-utils/lib/worker-farm/worker-body.js.map +1 -0
- package/dist/worker-utils/lib/worker-farm/worker-farm.d.ts +58 -0
- package/dist/worker-utils/lib/worker-farm/worker-farm.d.ts.map +1 -0
- package/dist/worker-utils/lib/worker-farm/worker-farm.js +116 -0
- package/dist/worker-utils/lib/worker-farm/worker-farm.js.map +1 -0
- package/dist/worker-utils/lib/worker-farm/worker-job.d.ts +34 -0
- package/dist/worker-utils/lib/worker-farm/worker-job.d.ts.map +1 -0
- package/dist/worker-utils/lib/worker-farm/worker-job.js +73 -0
- package/dist/worker-utils/lib/worker-farm/worker-job.js.map +1 -0
- package/dist/worker-utils/lib/worker-farm/worker-pool.d.ts +94 -0
- package/dist/worker-utils/lib/worker-farm/worker-pool.d.ts.map +1 -0
- package/dist/worker-utils/lib/worker-farm/worker-pool.js +193 -0
- package/dist/worker-utils/lib/worker-farm/worker-pool.js.map +1 -0
- package/dist/worker-utils/lib/worker-farm/worker-thread.d.ts +67 -0
- package/dist/worker-utils/lib/worker-farm/worker-thread.d.ts.map +1 -0
- package/dist/worker-utils/lib/worker-farm/worker-thread.js +175 -0
- package/dist/worker-utils/lib/worker-farm/worker-thread.js.map +1 -0
- package/dist/worker-utils/lib/worker-utils/get-loadable-worker-url.d.ts +14 -0
- package/dist/worker-utils/lib/worker-utils/get-loadable-worker-url.d.ts.map +1 -0
- package/dist/worker-utils/lib/worker-utils/get-loadable-worker-url.js +72 -0
- package/dist/worker-utils/lib/worker-utils/get-loadable-worker-url.js.map +1 -0
- package/dist/worker-utils/lib/worker-utils/get-transfer-list.d.ts +15 -0
- package/dist/worker-utils/lib/worker-utils/get-transfer-list.d.ts.map +1 -0
- package/dist/worker-utils/lib/worker-utils/get-transfer-list.js +86 -0
- package/dist/worker-utils/lib/worker-utils/get-transfer-list.js.map +1 -0
- package/dist/worker-utils/lib/worker-utils/remove-nontransferable-options.d.ts +6 -0
- package/dist/worker-utils/lib/worker-utils/remove-nontransferable-options.d.ts.map +1 -0
- package/dist/worker-utils/lib/worker-utils/remove-nontransferable-options.js +27 -0
- package/dist/worker-utils/lib/worker-utils/remove-nontransferable-options.js.map +1 -0
- package/dist/worker-utils/null-worker-node.js +349 -0
- package/dist/worker-utils/null-worker-node.js.map +7 -0
- package/dist/worker-utils/null-worker.js +327 -0
- package/dist/worker-utils/null-worker.js.map +7 -0
- package/dist/worker-utils/types.d.ts +79 -0
- package/dist/worker-utils/types.d.ts.map +1 -0
- package/dist/worker-utils/types.js +5 -0
- package/dist/worker-utils/types.js.map +1 -0
- package/dist/worker-utils/workers/null-worker.d.ts +2 -0
- package/dist/worker-utils/workers/null-worker.d.ts.map +1 -0
- package/dist/worker-utils/workers/null-worker.js +17 -0
- package/dist/worker-utils/workers/null-worker.js.map +1 -0
- package/dist/workers/null-worker-node.js +1 -1
- package/dist/workers/null-worker-node.js.map +1 -1
- package/dist/workers/null-worker.js +1 -1
- package/dist/workers/null-worker.js.map +1 -1
- package/package.json +101 -11
- package/src/index.ts +10 -10
- package/src/iterators/make-iterator/make-iterator.ts +1 -1
- package/src/iterators/make-iterator/make-stream-iterator.ts +1 -1
- package/src/iterators/make-iterator/make-string-iterator.ts +1 -1
- package/src/lib/api/core-api.ts +1 -1
- package/src/lib/api/create-data-source.ts +2 -2
- package/src/lib/api/encode-table.ts +2 -2
- package/src/lib/api/encode.ts +3 -3
- package/src/lib/api/load-in-batches.ts +2 -2
- package/src/lib/api/load-loader.ts +2 -2
- package/src/lib/api/load.ts +2 -2
- package/src/lib/api/parse-file.ts +3 -3
- package/src/lib/api/parse-in-batches.ts +44 -6
- package/src/lib/api/parse-sync.ts +2 -2
- package/src/lib/api/parse.ts +4 -4
- package/src/lib/api/preload.ts +6 -1
- package/src/lib/api/register-loaders.ts +1 -1
- package/src/lib/api/select-loader.ts +3 -3
- package/src/lib/api/select-source.ts +1 -1
- package/src/lib/common.ts +1 -1
- package/src/lib/fetch/fetch-file.ts +2 -2
- package/src/lib/filesystems/browser-filesystem.ts +2 -2
- package/src/lib/init.ts +1 -1
- package/src/lib/loader-utils/get-data.ts +2 -2
- package/src/lib/loader-utils/get-fetch-function.ts +2 -2
- package/src/lib/loader-utils/loader-context.ts +2 -2
- package/src/lib/loader-utils/loggers.ts +1 -1
- package/src/lib/loader-utils/normalize-loader.ts +2 -2
- package/src/lib/loader-utils/option-defaults.ts +2 -2
- package/src/lib/loader-utils/option-utils.ts +1 -1
- package/src/lib/utils/resource-utils.ts +1 -1
- package/src/lib/utils/response-utils.ts +1 -1
- package/src/loader-utils/format-types.ts +49 -0
- package/src/loader-utils/index.ts +522 -0
- package/src/loader-utils/json-loader.ts +39 -0
- package/src/loader-utils/lib/binary-utils/array-buffer-utils.ts +114 -0
- package/src/loader-utils/lib/binary-utils/binary-chunk-reader.ts +297 -0
- package/src/loader-utils/lib/binary-utils/dataview-copy-utils.ts +121 -0
- package/src/loader-utils/lib/binary-utils/encode-array-buffer-to-base64.ts +17 -0
- package/src/loader-utils/lib/binary-utils/get-first-characters.ts +46 -0
- package/src/loader-utils/lib/binary-utils/hex-transcoder.ts +54 -0
- package/src/loader-utils/lib/binary-utils/memory-conversion-utils.ts +105 -0
- package/src/loader-utils/lib/binary-utils/memory-copy-utils.ts +69 -0
- package/src/loader-utils/lib/crs/crs-reprojection.ts +52 -0
- package/src/loader-utils/lib/env-utils/assert.ts +13 -0
- package/src/loader-utils/lib/env-utils/globals.ts +36 -0
- package/src/loader-utils/lib/file-provider/data-view-file.ts +83 -0
- package/src/loader-utils/lib/file-provider/file-handle-file.ts +114 -0
- package/src/loader-utils/lib/file-provider/file-provider-interface.ts +60 -0
- package/src/loader-utils/lib/file-provider/file-provider.ts +130 -0
- package/src/loader-utils/lib/files/array-buffer-file.ts +46 -0
- package/src/loader-utils/lib/files/blob-file.ts +45 -0
- package/src/loader-utils/lib/files/file.ts +39 -0
- package/src/loader-utils/lib/files/http-file-transport.ts +432 -0
- package/src/loader-utils/lib/files/http-file-types.ts +60 -0
- package/src/loader-utils/lib/files/http-file.ts +267 -0
- package/src/loader-utils/lib/files/node-file-facade.ts +57 -0
- package/src/loader-utils/lib/files/sources.ts +154 -0
- package/src/loader-utils/lib/filesystems/filesystem.ts +40 -0
- package/src/loader-utils/lib/filesystems/node-filesystem-facade.ts +65 -0
- package/src/loader-utils/lib/iterators/async-iteration.ts +136 -0
- package/src/loader-utils/lib/iterators/text-iterators.ts +76 -0
- package/src/loader-utils/lib/javascript-utils/is-type.ts +130 -0
- package/src/loader-utils/lib/laz/LASZIP-LICENSE +202 -0
- package/src/loader-utils/lib/laz/LASZIP-NOTICE +6 -0
- package/src/loader-utils/lib/laz/laz-arithmetic-encoder.ts +446 -0
- package/src/loader-utils/lib/laz/laz-chunk-decoder.ts +5251 -0
- package/src/loader-utils/lib/laz/laz-chunk-encoder.ts +1909 -0
- package/src/loader-utils/lib/log-utils/log.ts +28 -0
- package/src/loader-utils/lib/module-utils/initialize-wasm-module.ts +51 -0
- package/src/loader-utils/lib/module-utils/js-module-utils.ts +44 -0
- package/src/loader-utils/lib/node/buffer.browser.ts +22 -0
- package/src/loader-utils/lib/node/buffer.ts +40 -0
- package/src/loader-utils/lib/node/fs.browser.ts +5 -0
- package/src/loader-utils/lib/node/promisify.ts +72 -0
- package/src/loader-utils/lib/node/stream.browser.ts +5 -0
- package/src/loader-utils/lib/node/stream.ts +12 -0
- package/src/loader-utils/lib/option-utils/merge-options.ts +50 -0
- package/src/loader-utils/lib/parser-utils/parse-json.ts +16 -0
- package/src/loader-utils/lib/path-utils/cached-uri-resolver.ts +69 -0
- package/src/loader-utils/lib/path-utils/file-aliases.ts +49 -0
- package/src/loader-utils/lib/path-utils/get-cwd.ts +12 -0
- package/src/loader-utils/lib/path-utils/path.ts +173 -0
- package/src/loader-utils/lib/request-utils/abort-utils.ts +64 -0
- package/src/loader-utils/lib/request-utils/authentication.ts +134 -0
- package/src/loader-utils/lib/request-utils/parse-content-type.ts +22 -0
- package/src/loader-utils/lib/request-utils/range-request-cache.ts +279 -0
- package/src/loader-utils/lib/request-utils/range-request-scheduler.ts +899 -0
- package/src/loader-utils/lib/request-utils/request-cache.ts +296 -0
- package/src/loader-utils/lib/request-utils/request-credentials.ts +576 -0
- package/src/loader-utils/lib/request-utils/request-scheduler.ts +230 -0
- package/src/loader-utils/lib/scan-utils/columnar-predicate.ts +397 -0
- package/src/loader-utils/lib/scan-utils/experimental-scan-options.ts +46 -0
- package/src/loader-utils/lib/scan-utils/point-cloud-query.ts +176 -0
- package/src/loader-utils/lib/scan-utils/raster-query.ts +82 -0
- package/src/loader-utils/lib/scan-utils/relational-query.ts +188 -0
- package/src/loader-utils/lib/scan-utils/scan-executor.ts +208 -0
- package/src/loader-utils/lib/scan-utils/scan-fragments.ts +33 -0
- package/src/loader-utils/lib/scan-utils/scan-query-metadata.ts +439 -0
- package/src/loader-utils/lib/scan-utils/table-query-explain.ts +88 -0
- package/src/loader-utils/lib/scan-utils/table-query.ts +163 -0
- package/src/loader-utils/lib/scan-utils/table-scan-batch.ts +200 -0
- package/src/loader-utils/lib/sources/catalog-source.ts +42 -0
- package/src/loader-utils/lib/sources/data-source-manager.ts +569 -0
- package/src/loader-utils/lib/sources/data-source.ts +236 -0
- package/src/loader-utils/lib/sources/image-source.ts +66 -0
- package/src/loader-utils/lib/sources/image-tile-source.ts +22 -0
- package/src/loader-utils/lib/sources/raster-coverage.ts +92 -0
- package/src/loader-utils/lib/sources/raster-region.ts +35 -0
- package/src/loader-utils/lib/sources/raster-sampling.ts +213 -0
- package/src/loader-utils/lib/sources/raster-source.ts +344 -0
- package/src/loader-utils/lib/sources/service-capabilities.ts +50 -0
- package/src/loader-utils/lib/sources/tile-grid.ts +162 -0
- package/src/loader-utils/lib/sources/tile-source-adapter.ts +126 -0
- package/src/loader-utils/lib/sources/tile-source-utils.ts +19 -0
- package/src/loader-utils/lib/sources/tile-source.ts +198 -0
- package/src/loader-utils/lib/sources/utils/image-type.ts +14 -0
- package/src/loader-utils/lib/sources/utils/utils.ts +31 -0
- package/src/loader-utils/lib/sources/vector-source.ts +89 -0
- package/src/loader-utils/lib/sources/vector-tile-source.ts +29 -0
- package/src/loader-utils/lib/sources/xyz-grid.ts +82 -0
- package/src/loader-utils/lib/worker-loader-utils/create-loader-worker.ts +233 -0
- package/src/loader-utils/lib/worker-loader-utils/encode-with-worker.ts +28 -0
- package/src/loader-utils/lib/worker-loader-utils/parse-with-worker.ts +347 -0
- package/src/loader-utils/loader-types.ts +531 -0
- package/src/loader-utils/source-types.ts +76 -0
- package/src/loader-utils/types.ts +83 -0
- package/src/loader-utils/workers/json-worker.ts +8 -0
- package/src/loader-utils/writer-types.ts +107 -0
- package/src/null-loader.ts +2 -2
- package/src/polyfills/README.md +16 -0
- package/src/polyfills/buffer/btoa.node.ts +15 -0
- package/src/polyfills/buffer/to-array-buffer.node.ts +12 -0
- package/src/polyfills/crypto/node-hash.ts +78 -0
- package/src/polyfills/fetch/decode-data-uri.ts +71 -0
- package/src/polyfills/fetch/fetch-polyfill.ts +165 -0
- package/src/polyfills/fetch/headers-polyfill.ts +119 -0
- package/src/polyfills/fetch/response-polyfill.ts +101 -0
- package/src/polyfills/fetch/utils/decode-data-uri.node.ts +34 -0
- package/src/polyfills/file/blob-stream-controller.ts +69 -0
- package/src/polyfills/file/blob-stream.ts +40 -0
- package/src/polyfills/file/blob.ts +177 -0
- package/src/polyfills/file/file-reader.ts +59 -0
- package/src/polyfills/file/file.ts +45 -0
- package/src/polyfills/file/install-blob-polyfills.ts +17 -0
- package/src/polyfills/file/install-file-polyfills.ts +24 -0
- package/src/polyfills/file/readable-stream.ts +8 -0
- package/src/polyfills/filesystems/fetch-node.ts +98 -0
- package/src/polyfills/filesystems/node-file.ts +169 -0
- package/src/polyfills/filesystems/node-filesystem.ts +54 -0
- package/src/polyfills/filesystems/stream-utils.node.ts +81 -0
- package/src/polyfills/images/encode-image-node.ts +45 -0
- package/src/polyfills/images/encode-image.node.ts.disabled +41 -0
- package/src/polyfills/images/image-codecs-node.ts +40 -0
- package/src/polyfills/images/node-image-bitmap.ts +81 -0
- package/src/polyfills/images/node-image-formats.ts +6 -0
- package/src/polyfills/images/parse-image-node.ts +54 -0
- package/src/polyfills/images/parse-image.node.ts.disabled +55 -0
- package/src/polyfills/index.browser.ts +23 -0
- package/src/polyfills/index.ts +154 -0
- package/src/polyfills/libs/encoding-indexes-asian.js +15 -0
- package/src/polyfills/load-library/require-utils.node.ts +108 -0
- package/src/polyfills/streams/make-node-stream.ts +83 -0
- package/src/polyfills/text-encoder/encoding-indexes.ts +36 -0
- package/src/polyfills/text-encoder/text-encoder.ts +3085 -0
- package/src/polyfills/utils/assert.ts +9 -0
- package/src/polyfills/utils/buffer-utils.ts +40 -0
- package/src/polyfills/utils/filesystem-types.ts +13 -0
- package/src/polyfills/utils/is-browser.ts +8 -0
- package/src/polyfills/utils/path-utils.ts +31 -0
- package/src/polyfills/wip/fetch-browser/fetch-file.browser.d.ts +34 -0
- package/src/schema/categories/category-gis.ts +63 -0
- package/src/schema/categories/category-image.ts +23 -0
- package/src/schema/categories/category-mesh.ts +138 -0
- package/src/schema/categories/category-table.ts +125 -0
- package/src/schema/categories/category-texture.ts +259 -0
- package/src/schema/deprecated/mesh-utils.ts +46 -0
- package/src/schema/float16.ts +111 -0
- package/src/schema/geometry/arrow-binary-features.ts +54 -0
- package/src/schema/geometry/binary-features.ts +43 -0
- package/src/schema/geometry/binary-geometries.ts +45 -0
- package/src/schema/geometry/flat-geometries.ts +72 -0
- package/src/schema/geometry/geoarrow.ts +116 -0
- package/src/schema/geospatial-metadata-zod-schema.ts +163 -0
- package/src/schema/index.ts +169 -0
- package/src/schema/metadata.ts +115 -0
- package/src/schema/types/batch.ts +47 -0
- package/src/schema/types/schema.ts +86 -0
- package/src/schema/types/types.ts +52 -0
- package/src/schema-utils/arrow-transport.ts +7 -0
- package/src/schema-utils/deprecated.ts +53 -0
- package/src/schema-utils/index.ts +165 -0
- package/src/schema-utils/lib/arrow/arrow-table-transport.ts +260 -0
- package/src/schema-utils/lib/arrow/split-arrow-buffers.ts +235 -0
- package/src/schema-utils/lib/arrow-utils/arrow-fixed-size-list-utils.ts +78 -0
- package/src/schema-utils/lib/arrow-utils/arrow-list-of-fixed-size-list-utils.ts +48 -0
- package/src/schema-utils/lib/converters/convert.ts +142 -0
- package/src/schema-utils/lib/converters/converters.ts +6 -0
- package/src/schema-utils/lib/converters/types.ts +44 -0
- package/src/schema-utils/lib/mesh/convert-mesh-to-table.ts +311 -0
- package/src/schema-utils/lib/mesh/convert-table-to-mesh.ts +257 -0
- package/src/schema-utils/lib/mesh/deduce-mesh-schema.ts +85 -0
- package/src/schema-utils/lib/mesh/mesh-utils.ts +73 -0
- package/src/schema-utils/lib/mesh/point-cloud-tiler.ts +485 -0
- package/src/schema-utils/lib/schema/convert-arrow-schema.ts +552 -0
- package/src/schema-utils/lib/schema/data-type.ts +122 -0
- package/src/schema-utils/lib/schema/deduce-table-schema.ts +119 -0
- package/src/schema-utils/lib/table/arrow-api/arrow-like-field.ts +53 -0
- package/src/schema-utils/lib/table/arrow-api/arrow-like-interface.ts +84 -0
- package/src/schema-utils/lib/table/arrow-api/arrow-like-schema.ts +101 -0
- package/src/schema-utils/lib/table/arrow-api/arrow-like-table.ts +85 -0
- package/src/schema-utils/lib/table/arrow-api/arrow-like-type.ts +500 -0
- package/src/schema-utils/lib/table/arrow-api/enum.ts +99 -0
- package/src/schema-utils/lib/table/arrow-api/get-type-info.ts +38 -0
- package/src/schema-utils/lib/table/arrow-api/index.ts +50 -0
- package/src/schema-utils/lib/table/batch-builder/arrow-table-batch-aggregator-builders.ts.disabled +190 -0
- package/src/schema-utils/lib/table/batch-builder/arrow-table-batch-aggregator.ts +85 -0
- package/src/schema-utils/lib/table/batch-builder/arrow-table-builder.ts +123 -0
- package/src/schema-utils/lib/table/batch-builder/base-table-batch-aggregator.ts +82 -0
- package/src/schema-utils/lib/table/batch-builder/columnar-table-batch-aggregator.ts +104 -0
- package/src/schema-utils/lib/table/batch-builder/row-table-batch-aggregator.ts +108 -0
- package/src/schema-utils/lib/table/batch-builder/table-batch-aggregator.ts +28 -0
- package/src/schema-utils/lib/table/batch-builder/table-batch-builder.ts +185 -0
- package/src/schema-utils/lib/table/batches/convert-batches.ts +83 -0
- package/src/schema-utils/lib/table/batches/make-arrow-batch-iterator.ts +81 -0
- package/src/schema-utils/lib/table/batches/make-table-batch-iterator.ts +25 -0
- package/src/schema-utils/lib/table/batches/make-table-from-batches.ts +84 -0
- package/src/schema-utils/lib/table/query-arrow-table.ts +130 -0
- package/src/schema-utils/lib/table/tables/convert-arrow-table.ts +198 -0
- package/src/schema-utils/lib/table/tables/convert-table.ts +152 -0
- package/src/schema-utils/lib/table/tables/make-table.ts +127 -0
- package/src/schema-utils/lib/table/tables/row-utils.ts +59 -0
- package/src/schema-utils/lib/table/tables/table-accessors.ts +418 -0
- package/src/schema-utils/lib/table/tables/table-column.ts +49 -0
- package/src/schema-utils/lib/table/tables/table-converter/convert-tables.ts +35 -0
- package/src/schema-utils/lib/table/tables/table-converter/table-converter.ts +57 -0
- package/src/schema-utils/lib/table/tables/table-types.ts +37 -0
- package/src/schema-utils/lib/utils/assert.ts +12 -0
- package/src/schema-utils/lib/utils/async-queue.ts +109 -0
- package/src/schema-utils/types/types.ts +45 -0
- package/src/worker-utils/index.ts +80 -0
- package/src/worker-utils/lib/async-queue/async-queue.ts +100 -0
- package/src/worker-utils/lib/env-utils/assert.ts +14 -0
- package/src/worker-utils/lib/env-utils/globals.ts +40 -0
- package/src/worker-utils/lib/env-utils/version.ts +25 -0
- package/src/worker-utils/lib/library-utils/library-utils.ts +303 -0
- package/src/worker-utils/lib/node/worker_threads-browser.ts +34 -0
- package/src/worker-utils/lib/node/worker_threads.ts +58 -0
- package/src/worker-utils/lib/npm-tag.ts +11 -0
- package/src/worker-utils/lib/process-utils/child-process-proxy.browser.ts +23 -0
- package/src/worker-utils/lib/process-utils/child-process-proxy.ts +165 -0
- package/src/worker-utils/lib/process-utils/process-utils.ts +34 -0
- package/src/worker-utils/lib/worker-api/create-worker.ts +166 -0
- package/src/worker-utils/lib/worker-api/get-worker-url.ts +129 -0
- package/src/worker-utils/lib/worker-api/process-on-worker.ts +413 -0
- package/src/worker-utils/lib/worker-api/validate-worker-version.ts +44 -0
- package/src/worker-utils/lib/worker-farm/worker-body.ts +145 -0
- package/src/worker-utils/lib/worker-farm/worker-farm.ts +144 -0
- package/src/worker-utils/lib/worker-farm/worker-job.ts +83 -0
- package/src/worker-utils/lib/worker-farm/worker-pool.ts +263 -0
- package/src/worker-utils/lib/worker-farm/worker-thread.ts +206 -0
- package/src/worker-utils/lib/worker-utils/get-loadable-worker-url.ts +81 -0
- package/src/worker-utils/lib/worker-utils/get-transfer-list.ts +93 -0
- package/src/worker-utils/lib/worker-utils/remove-nontransferable-options.ts +27 -0
- package/src/worker-utils/types.ts +125 -0
- package/src/worker-utils/workers/null-worker.ts +20 -0
- package/src/workers/null-worker-node.ts +1 -1
- package/src/workers/null-worker.ts +1 -1
|
@@ -0,0 +1,899 @@
|
|
|
1
|
+
// loaders.gl
|
|
2
|
+
// SPDX-License-Identifier: MIT
|
|
3
|
+
// SPDX-FileCopyrightText: Copyright (c) vis.gl contributors
|
|
4
|
+
|
|
5
|
+
import {Stats} from 'probe.gl/stats';
|
|
6
|
+
|
|
7
|
+
/** Typed snapshot of the byte-range scheduler counters stored in a probe.gl `Stats` object. */
|
|
8
|
+
export type RangeStats = {
|
|
9
|
+
/** Number of caller-requested byte ranges. */
|
|
10
|
+
logicalRanges: number;
|
|
11
|
+
/** Number of queue flushes that produced at least one transport request. */
|
|
12
|
+
rangeBatches: number;
|
|
13
|
+
/** Number of merged byte ranges requested from the transport. */
|
|
14
|
+
transportRanges: number;
|
|
15
|
+
/** Number of merged byte ranges that completed successfully. */
|
|
16
|
+
completedTransportRanges: number;
|
|
17
|
+
/** Number of logical ranges eliminated by coalescing. */
|
|
18
|
+
coalescedRanges: number;
|
|
19
|
+
/** Number of bytes requested by callers before coalescing. */
|
|
20
|
+
requestedBytes: number;
|
|
21
|
+
/** Number of bytes requested from the transport after coalescing and expansion. */
|
|
22
|
+
transportBytes: number;
|
|
23
|
+
/** Number of bytes read from transport responses. */
|
|
24
|
+
responseBytes: number;
|
|
25
|
+
/** Aggregate time spent awaiting transport requests, in milliseconds. */
|
|
26
|
+
networkTimeMs: number;
|
|
27
|
+
/** Number of transport-requested bytes that were not part of logical caller requests. */
|
|
28
|
+
overfetchBytes: number;
|
|
29
|
+
/** Number of transport ranges that failed. */
|
|
30
|
+
failedTransportRanges: number;
|
|
31
|
+
/** Number of logical byte ranges aborted before completion. */
|
|
32
|
+
abortedLogicalRanges: number;
|
|
33
|
+
/** Number of transport responses that returned a full-object fallback. */
|
|
34
|
+
fullResponseFallbacks: number;
|
|
35
|
+
};
|
|
36
|
+
|
|
37
|
+
/** Options for the byte-range request scheduler. */
|
|
38
|
+
export type RangeRequestSchedulerProps = {
|
|
39
|
+
/** Fixed window from the first queued range; later arrivals and completions do not extend it. */
|
|
40
|
+
batchDelayMs?: number;
|
|
41
|
+
/** Maximum byte gap that can be over-fetched when merging two adjacent requests. */
|
|
42
|
+
maxGapBytes?: number;
|
|
43
|
+
/** Maximum byte gap that can be over-fetched when expanding one range to include the next request. */
|
|
44
|
+
rangeExpansionBytes?: number;
|
|
45
|
+
/** Maximum total byte length of one merged range request. */
|
|
46
|
+
maxMergedBytes?: number;
|
|
47
|
+
/** Maximum simultaneous transports; defaults to six. */
|
|
48
|
+
maxConcurrency?: number;
|
|
49
|
+
/** Maximum unsettled logical requests; defaults to 4096. */
|
|
50
|
+
maxQueueSize?: number;
|
|
51
|
+
/** Maximum individual logical range length; defaults to 64 MiB. */
|
|
52
|
+
maxRangeBytes?: number;
|
|
53
|
+
/** Lifetime budget for merged transport spans, including gaps and failed/canceled reads; default MAX_SAFE_INTEGER. */
|
|
54
|
+
maxTotalBytes?: number;
|
|
55
|
+
/** Optional probe.gl Stats object that receives range batching counters. */
|
|
56
|
+
stats?: Stats;
|
|
57
|
+
/** Optional event callback for range batching diagnostics. */
|
|
58
|
+
onEvent?: (event: RangeRequestEvent) => void;
|
|
59
|
+
};
|
|
60
|
+
|
|
61
|
+
/** One logical byte-range request handled by `RangeRequestScheduler.scheduleRequest()`. */
|
|
62
|
+
export type RangeRequest = {
|
|
63
|
+
/** Stable identifier for the remote byte-range-addressable resource. */
|
|
64
|
+
sourceId: string;
|
|
65
|
+
/** Start byte offset. */
|
|
66
|
+
offset: number;
|
|
67
|
+
/** Number of bytes to read. */
|
|
68
|
+
length: number;
|
|
69
|
+
/** Optional caller abort signal. */
|
|
70
|
+
signal?: AbortSignal;
|
|
71
|
+
/** Requests only coalesce when this key is identical. Defaults to the shared source identifier. */
|
|
72
|
+
isolationKey?: unknown;
|
|
73
|
+
/** Fetches bytes for this source. */
|
|
74
|
+
fetchRange: (
|
|
75
|
+
offset: number,
|
|
76
|
+
length: number,
|
|
77
|
+
signal?: AbortSignal
|
|
78
|
+
) => Promise<ArrayBuffer | RangeRequestTransportResult>;
|
|
79
|
+
};
|
|
80
|
+
|
|
81
|
+
/** HTTP byte-range request handled by `RangeRequestScheduler.fetch()`. */
|
|
82
|
+
export type RangeFetchRequest = {
|
|
83
|
+
/** URL of the remote byte-range-addressable resource. */
|
|
84
|
+
url: string;
|
|
85
|
+
/** Optional stable identifier for the remote resource; defaults to `url`. */
|
|
86
|
+
sourceId?: string;
|
|
87
|
+
/** Start byte offset. */
|
|
88
|
+
offset: number;
|
|
89
|
+
/** Number of bytes to read. */
|
|
90
|
+
length: number;
|
|
91
|
+
/** Optional caller abort signal. */
|
|
92
|
+
signal?: AbortSignal;
|
|
93
|
+
/** Requests only coalesce when this key is identical. Omit it to isolate this fetch call. */
|
|
94
|
+
isolationKey?: unknown;
|
|
95
|
+
/** Optional fetch implementation for tests or host environments. */
|
|
96
|
+
fetch?: (url: string, options?: RequestInit) => Promise<Response>;
|
|
97
|
+
/** Optional fetch options merged into the transport request. */
|
|
98
|
+
fetchOptions?: RequestInit;
|
|
99
|
+
};
|
|
100
|
+
|
|
101
|
+
/** Transport result plus diagnostics for one merged byte-range request. */
|
|
102
|
+
export type RangeRequestTransportResult = {
|
|
103
|
+
/** Bytes returned by the transport. */
|
|
104
|
+
arrayBuffer: ArrayBuffer;
|
|
105
|
+
/** HTTP status code or transport-specific equivalent. */
|
|
106
|
+
status?: number;
|
|
107
|
+
/** Total source length, when known. Used to validate a response clamped at end of file. */
|
|
108
|
+
sourceByteLength?: number;
|
|
109
|
+
/** Number of response bytes read from the transport before slicing. */
|
|
110
|
+
transportBytes?: number;
|
|
111
|
+
/** Time spent awaiting this transport request, in milliseconds. */
|
|
112
|
+
networkTimeMs?: number;
|
|
113
|
+
/** True when the transport returned the complete object and the requested range was sliced locally. */
|
|
114
|
+
fullResponse?: boolean;
|
|
115
|
+
};
|
|
116
|
+
|
|
117
|
+
/** Diagnostic event emitted by the byte-range request scheduler. */
|
|
118
|
+
export type RangeRequestEvent = {
|
|
119
|
+
/** Event type. */
|
|
120
|
+
type: 'queued' | 'batch' | 'request' | 'response' | 'error' | 'abort';
|
|
121
|
+
/** Stable identifier for the remote byte-range-addressable resource. */
|
|
122
|
+
sourceId?: string;
|
|
123
|
+
/** Start byte offset of a merged transport request. */
|
|
124
|
+
offset?: number;
|
|
125
|
+
/** Byte length of a merged transport request. */
|
|
126
|
+
length?: number;
|
|
127
|
+
/** Number of caller requests in a batch or merged request. */
|
|
128
|
+
logicalRequestCount?: number;
|
|
129
|
+
/** Number of merged transport requests created for a batch. */
|
|
130
|
+
transportRequestCount?: number;
|
|
131
|
+
/** Sum of caller-requested bytes. */
|
|
132
|
+
logicalBytes?: number;
|
|
133
|
+
/** Bytes requested from the transport after merging and expansion. */
|
|
134
|
+
transportBytes?: number;
|
|
135
|
+
/** Bytes returned by the transport before slicing. */
|
|
136
|
+
responseBytes?: number;
|
|
137
|
+
/** Time spent awaiting the transport request, in milliseconds. */
|
|
138
|
+
networkTimeMs?: number;
|
|
139
|
+
/** Bytes fetched only to bridge nearby requested ranges. */
|
|
140
|
+
overfetchBytes?: number;
|
|
141
|
+
/** HTTP status code or transport-specific equivalent. */
|
|
142
|
+
status?: number;
|
|
143
|
+
/** True when the transport returned the complete object and a requested range was sliced locally. */
|
|
144
|
+
fullResponse?: boolean;
|
|
145
|
+
/** Error thrown by one merged transport request. */
|
|
146
|
+
error?: unknown;
|
|
147
|
+
};
|
|
148
|
+
|
|
149
|
+
type PendingRequest = RangeRequest & {
|
|
150
|
+
resolve: (arrayBuffer: ArrayBuffer) => void;
|
|
151
|
+
reject: (error: unknown) => void;
|
|
152
|
+
settled: boolean;
|
|
153
|
+
abortListener?: () => void;
|
|
154
|
+
onAbort?: () => void;
|
|
155
|
+
};
|
|
156
|
+
|
|
157
|
+
type MergedRequest = {
|
|
158
|
+
sourceId: string;
|
|
159
|
+
isolationKey: unknown;
|
|
160
|
+
offset: number;
|
|
161
|
+
endOffset: number;
|
|
162
|
+
fetchRange: RangeRequest['fetchRange'];
|
|
163
|
+
requests: PendingRequest[];
|
|
164
|
+
};
|
|
165
|
+
|
|
166
|
+
/** probe.gl `Stats` counter names used for typed range scheduler snapshots. */
|
|
167
|
+
const RANGE_STATS_KEYS: Record<keyof RangeStats, string> = {
|
|
168
|
+
logicalRanges: 'Logical Range Requests',
|
|
169
|
+
rangeBatches: 'Range Request Batches',
|
|
170
|
+
transportRanges: 'Transport Ranges Created',
|
|
171
|
+
completedTransportRanges: 'Range Transport Requests Completed',
|
|
172
|
+
coalescedRanges: 'Coalesced Logical Ranges',
|
|
173
|
+
requestedBytes: 'Logical Range Request Bytes',
|
|
174
|
+
transportBytes: 'Range Transport Bytes Requested',
|
|
175
|
+
responseBytes: 'Range Response Bytes',
|
|
176
|
+
networkTimeMs: 'Range Network Time',
|
|
177
|
+
overfetchBytes: 'Range Overfetch Bytes',
|
|
178
|
+
failedTransportRanges: 'Range Transport Requests Failed',
|
|
179
|
+
abortedLogicalRanges: 'Aborted Logical Range Requests',
|
|
180
|
+
fullResponseFallbacks: 'Full Response Fallbacks'
|
|
181
|
+
};
|
|
182
|
+
|
|
183
|
+
const DEFAULT_PROPS: Required<RangeRequestSchedulerProps> = {
|
|
184
|
+
batchDelayMs: 50,
|
|
185
|
+
maxGapBytes: 65536,
|
|
186
|
+
rangeExpansionBytes: 65536,
|
|
187
|
+
maxMergedBytes: 8388608,
|
|
188
|
+
maxConcurrency: 6,
|
|
189
|
+
maxQueueSize: 4096,
|
|
190
|
+
maxRangeBytes: 64 * 1024 * 1024,
|
|
191
|
+
maxTotalBytes: Number.MAX_SAFE_INTEGER,
|
|
192
|
+
stats: createRangeStats('range-request-scheduler-default'),
|
|
193
|
+
onEvent: () => {}
|
|
194
|
+
};
|
|
195
|
+
|
|
196
|
+
/**
|
|
197
|
+
* Coalesces nearby byte range requests and carves the merged response back
|
|
198
|
+
* into the originally requested byte ranges.
|
|
199
|
+
*/
|
|
200
|
+
export class RangeRequestScheduler {
|
|
201
|
+
/** Runtime scheduler configuration with defaults filled in. */
|
|
202
|
+
readonly props: Required<Omit<RangeRequestSchedulerProps, 'stats' | 'onEvent'>>;
|
|
203
|
+
/** Runtime counters for range batching and transport behavior. */
|
|
204
|
+
readonly stats: Stats;
|
|
205
|
+
/** Optional event callback for range batching diagnostics. */
|
|
206
|
+
readonly onEvent?: (event: RangeRequestEvent) => void;
|
|
207
|
+
|
|
208
|
+
private pendingRequests: PendingRequest[] = [];
|
|
209
|
+
/** Merged transports waiting for a concurrency slot. */
|
|
210
|
+
private transportQueue: MergedRequest[] = [];
|
|
211
|
+
/** Number of active transports. */
|
|
212
|
+
private activeTransports = 0;
|
|
213
|
+
/** Bytes reserved by started transports; failures and cancellation do not refund this budget. */
|
|
214
|
+
private reservedTransportBytes = 0;
|
|
215
|
+
/** Number of unsettled logical requests. */
|
|
216
|
+
private queuedRequests = 0;
|
|
217
|
+
/** Unsettled requests retained until completion or disposal. */
|
|
218
|
+
private logicalRequests = new Set<PendingRequest>();
|
|
219
|
+
/** Controllers for transports owned by this scheduler. */
|
|
220
|
+
private transportControllers = new Set<AbortController>();
|
|
221
|
+
/** Disposal prevents further enqueueing. */
|
|
222
|
+
private finalized = false;
|
|
223
|
+
/** Pending batch window, independent of in-flight transport requests. */
|
|
224
|
+
private flushTimer: ReturnType<typeof setTimeout> | null = null;
|
|
225
|
+
|
|
226
|
+
/** Creates a scheduler for one group of byte-range-addressable resources. */
|
|
227
|
+
constructor(props: RangeRequestSchedulerProps = {}) {
|
|
228
|
+
const rangeExpansionBytes =
|
|
229
|
+
props.rangeExpansionBytes ?? props.maxGapBytes ?? DEFAULT_PROPS.rangeExpansionBytes;
|
|
230
|
+
this.props = {
|
|
231
|
+
batchDelayMs: props.batchDelayMs ?? DEFAULT_PROPS.batchDelayMs,
|
|
232
|
+
maxGapBytes: props.maxGapBytes ?? rangeExpansionBytes,
|
|
233
|
+
rangeExpansionBytes,
|
|
234
|
+
maxMergedBytes: props.maxMergedBytes ?? DEFAULT_PROPS.maxMergedBytes,
|
|
235
|
+
maxConcurrency: props.maxConcurrency ?? 6,
|
|
236
|
+
maxQueueSize: props.maxQueueSize ?? 4096,
|
|
237
|
+
maxRangeBytes: props.maxRangeBytes ?? 64 * 1024 * 1024,
|
|
238
|
+
maxTotalBytes: props.maxTotalBytes ?? DEFAULT_PROPS.maxTotalBytes
|
|
239
|
+
};
|
|
240
|
+
for (const value of [
|
|
241
|
+
this.props.maxConcurrency,
|
|
242
|
+
this.props.maxQueueSize,
|
|
243
|
+
this.props.maxRangeBytes,
|
|
244
|
+
this.props.maxTotalBytes
|
|
245
|
+
]) {
|
|
246
|
+
if (!Number.isSafeInteger(value) || value <= 0)
|
|
247
|
+
throw new Error('Range scheduler limits must be positive integers');
|
|
248
|
+
}
|
|
249
|
+
this.stats = props.stats || createRangeStats('range-request-scheduler');
|
|
250
|
+
this.onEvent = props.onEvent;
|
|
251
|
+
initializeStats(this.stats);
|
|
252
|
+
}
|
|
253
|
+
|
|
254
|
+
/**
|
|
255
|
+
* Enqueues one byte range request and resolves with the exact requested byte slice.
|
|
256
|
+
*/
|
|
257
|
+
scheduleRequest(request: RangeRequest): Promise<ArrayBuffer> {
|
|
258
|
+
if (this.finalized) return Promise.reject(new Error('Range scheduler is finalized'));
|
|
259
|
+
if (
|
|
260
|
+
!Number.isSafeInteger(request.offset) ||
|
|
261
|
+
request.offset < 0 ||
|
|
262
|
+
!Number.isSafeInteger(request.length) ||
|
|
263
|
+
request.length > this.props.maxRangeBytes ||
|
|
264
|
+
!Number.isSafeInteger(request.offset + request.length)
|
|
265
|
+
)
|
|
266
|
+
return Promise.reject(new Error('Invalid or oversized byte range'));
|
|
267
|
+
if (this.queuedRequests >= this.props.maxQueueSize)
|
|
268
|
+
return Promise.reject(new Error('Range scheduler queue limit exceeded'));
|
|
269
|
+
if (request.length < 0) {
|
|
270
|
+
return Promise.reject(new Error('Byte range length cannot be negative'));
|
|
271
|
+
}
|
|
272
|
+
|
|
273
|
+
if (request.signal?.aborted) {
|
|
274
|
+
return Promise.reject(request.signal.reason ?? createAbortError());
|
|
275
|
+
}
|
|
276
|
+
|
|
277
|
+
if (request.length === 0) {
|
|
278
|
+
return Promise.resolve(new ArrayBuffer(0));
|
|
279
|
+
}
|
|
280
|
+
|
|
281
|
+
this.queuedRequests++;
|
|
282
|
+
let pendingRequest: PendingRequest;
|
|
283
|
+
const promise = new Promise<ArrayBuffer>((resolve, reject) => {
|
|
284
|
+
pendingRequest = {...request, resolve, reject, settled: false};
|
|
285
|
+
this.logicalRequests.add(pendingRequest);
|
|
286
|
+
if (request.signal) {
|
|
287
|
+
pendingRequest.abortListener = () => {
|
|
288
|
+
this.abortRequest(pendingRequest);
|
|
289
|
+
pendingRequest.onAbort?.();
|
|
290
|
+
};
|
|
291
|
+
request.signal.addEventListener('abort', pendingRequest.abortListener, {once: true});
|
|
292
|
+
}
|
|
293
|
+
this.pendingRequests.push(pendingRequest);
|
|
294
|
+
});
|
|
295
|
+
|
|
296
|
+
this.trackEvent({
|
|
297
|
+
type: 'queued',
|
|
298
|
+
sourceId: request.sourceId,
|
|
299
|
+
offset: request.offset,
|
|
300
|
+
length: request.length,
|
|
301
|
+
logicalRequestCount: 1,
|
|
302
|
+
logicalBytes: request.length
|
|
303
|
+
});
|
|
304
|
+
|
|
305
|
+
this.scheduleFlush();
|
|
306
|
+
return promise.finally(() => {
|
|
307
|
+
if (pendingRequest.abortListener)
|
|
308
|
+
request.signal?.removeEventListener('abort', pendingRequest.abortListener);
|
|
309
|
+
this.queuedRequests--;
|
|
310
|
+
this.logicalRequests.delete(pendingRequest);
|
|
311
|
+
});
|
|
312
|
+
}
|
|
313
|
+
|
|
314
|
+
/**
|
|
315
|
+
* Enqueues one HTTP byte-range request and resolves with the exact requested byte slice.
|
|
316
|
+
*/
|
|
317
|
+
fetch(request: RangeFetchRequest): Promise<ArrayBuffer> {
|
|
318
|
+
const fetchFunction = request.fetch || globalThis.fetch;
|
|
319
|
+
return this.scheduleRequest({
|
|
320
|
+
sourceId: request.sourceId || request.url,
|
|
321
|
+
offset: request.offset,
|
|
322
|
+
length: request.length,
|
|
323
|
+
signal: request.signal,
|
|
324
|
+
// Different fetch calls may carry different credentials or transport implementations.
|
|
325
|
+
// Sharing is therefore opt-in through an explicit common isolation key.
|
|
326
|
+
isolationKey: request.isolationKey ?? {},
|
|
327
|
+
fetchRange: (offset, length, signal) =>
|
|
328
|
+
fetchHttpRange({
|
|
329
|
+
url: request.url,
|
|
330
|
+
offset,
|
|
331
|
+
length,
|
|
332
|
+
signal,
|
|
333
|
+
fetch: fetchFunction,
|
|
334
|
+
fetchOptions: request.fetchOptions
|
|
335
|
+
})
|
|
336
|
+
});
|
|
337
|
+
}
|
|
338
|
+
|
|
339
|
+
/** Immediately starts loading the currently queued requests. */
|
|
340
|
+
flush(): void {
|
|
341
|
+
if (this.flushTimer !== null) {
|
|
342
|
+
clearTimeout(this.flushTimer);
|
|
343
|
+
this.flushTimer = null;
|
|
344
|
+
}
|
|
345
|
+
|
|
346
|
+
const pendingRequests = this.pendingRequests;
|
|
347
|
+
this.pendingRequests = [];
|
|
348
|
+
|
|
349
|
+
const activeRequests = pendingRequests.filter(request => {
|
|
350
|
+
if (request.settled || request.signal?.aborted) {
|
|
351
|
+
this.abortRequest(request);
|
|
352
|
+
return false;
|
|
353
|
+
}
|
|
354
|
+
return true;
|
|
355
|
+
});
|
|
356
|
+
|
|
357
|
+
const mergedRequests = this.mergeRequests(activeRequests);
|
|
358
|
+
if (activeRequests.length > 0) {
|
|
359
|
+
this.trackBatch(activeRequests, mergedRequests);
|
|
360
|
+
}
|
|
361
|
+
this.transportQueue.push(...mergedRequests);
|
|
362
|
+
this.startQueuedTransports();
|
|
363
|
+
}
|
|
364
|
+
|
|
365
|
+
/** Cancels owned work and releases queued resources; borrowed users must not finalize shared schedulers. */
|
|
366
|
+
finalize(): void {
|
|
367
|
+
this.finalized = true;
|
|
368
|
+
if (this.flushTimer !== null) clearTimeout(this.flushTimer);
|
|
369
|
+
this.flushTimer = null;
|
|
370
|
+
for (const request of this.logicalRequests) {
|
|
371
|
+
this.abortRequest(request);
|
|
372
|
+
if (request.abortListener)
|
|
373
|
+
request.signal?.removeEventListener('abort', request.abortListener);
|
|
374
|
+
}
|
|
375
|
+
for (const controller of this.transportControllers) controller.abort();
|
|
376
|
+
this.transportQueue = [];
|
|
377
|
+
this.pendingRequests = [];
|
|
378
|
+
this.logicalRequests.clear();
|
|
379
|
+
}
|
|
380
|
+
|
|
381
|
+
/** Starts transports while respecting the configured concurrency bound. */
|
|
382
|
+
private startQueuedTransports(): void {
|
|
383
|
+
while (this.activeTransports < this.props.maxConcurrency && this.transportQueue.length) {
|
|
384
|
+
const request = this.transportQueue.shift()!;
|
|
385
|
+
this.activeTransports++;
|
|
386
|
+
void this.fetchMergedRequest(request).finally(() => {
|
|
387
|
+
this.activeTransports--;
|
|
388
|
+
this.startQueuedTransports();
|
|
389
|
+
});
|
|
390
|
+
}
|
|
391
|
+
}
|
|
392
|
+
|
|
393
|
+
/** Starts a fixed batch window only when no flush is already scheduled. */
|
|
394
|
+
private scheduleFlush(): void {
|
|
395
|
+
if (this.flushTimer !== null) {
|
|
396
|
+
return;
|
|
397
|
+
}
|
|
398
|
+
|
|
399
|
+
this.flushTimer = setTimeout(() => this.flush(), this.props.batchDelayMs);
|
|
400
|
+
}
|
|
401
|
+
|
|
402
|
+
/** Sorts active requests and combines requests for the same source when thresholds allow. */
|
|
403
|
+
private mergeRequests(requests: PendingRequest[]): MergedRequest[] {
|
|
404
|
+
requests.sort((left, right) => {
|
|
405
|
+
if (left.sourceId !== right.sourceId) {
|
|
406
|
+
return left.sourceId < right.sourceId ? -1 : 1;
|
|
407
|
+
}
|
|
408
|
+
return left.offset - right.offset;
|
|
409
|
+
});
|
|
410
|
+
|
|
411
|
+
const mergedRequests: MergedRequest[] = [];
|
|
412
|
+
|
|
413
|
+
for (const request of requests) {
|
|
414
|
+
const requestEndOffset = request.offset + request.length;
|
|
415
|
+
const lastMergedRequest = mergedRequests[mergedRequests.length - 1];
|
|
416
|
+
|
|
417
|
+
if (lastMergedRequest && canMergeRequests(lastMergedRequest, request, this.props)) {
|
|
418
|
+
lastMergedRequest.endOffset = Math.max(lastMergedRequest.endOffset, requestEndOffset);
|
|
419
|
+
lastMergedRequest.requests.push(request);
|
|
420
|
+
} else {
|
|
421
|
+
mergedRequests.push({
|
|
422
|
+
sourceId: request.sourceId,
|
|
423
|
+
isolationKey: request.isolationKey ?? request.sourceId,
|
|
424
|
+
offset: request.offset,
|
|
425
|
+
endOffset: requestEndOffset,
|
|
426
|
+
fetchRange: request.fetchRange,
|
|
427
|
+
requests: [request]
|
|
428
|
+
});
|
|
429
|
+
}
|
|
430
|
+
}
|
|
431
|
+
|
|
432
|
+
return mergedRequests;
|
|
433
|
+
}
|
|
434
|
+
|
|
435
|
+
/** Loads one merged range and resolves each child request with its sliced bytes. */
|
|
436
|
+
private async fetchMergedRequest(mergedRequest: MergedRequest): Promise<void> {
|
|
437
|
+
const {offset, endOffset, fetchRange, requests} = mergedRequest;
|
|
438
|
+
const abortController = new AbortController();
|
|
439
|
+
this.transportControllers.add(abortController);
|
|
440
|
+
const requestStartTime = getTimestamp();
|
|
441
|
+
const abortTransportIfUnused = () => {
|
|
442
|
+
if (requests.every(request => request.settled || request.signal?.aborted)) {
|
|
443
|
+
abortController.abort();
|
|
444
|
+
}
|
|
445
|
+
};
|
|
446
|
+
|
|
447
|
+
try {
|
|
448
|
+
for (const request of requests) {
|
|
449
|
+
request.onAbort = abortTransportIfUnused;
|
|
450
|
+
}
|
|
451
|
+
abortTransportIfUnused();
|
|
452
|
+
if (requests.every(request => request.settled)) {
|
|
453
|
+
return;
|
|
454
|
+
}
|
|
455
|
+
|
|
456
|
+
const logicalBytes = getLogicalRequestBytes(requests);
|
|
457
|
+
const length = endOffset - offset;
|
|
458
|
+
if (length > this.props.maxTotalBytes - this.reservedTransportBytes)
|
|
459
|
+
throw new RangeError('Range request total byte limit exceeded');
|
|
460
|
+
// Reserve synchronously before awaiting transport so concurrent reads share one budget.
|
|
461
|
+
this.reservedTransportBytes += length;
|
|
462
|
+
this.trackEvent({
|
|
463
|
+
type: 'request',
|
|
464
|
+
sourceId: mergedRequest.sourceId,
|
|
465
|
+
offset,
|
|
466
|
+
length,
|
|
467
|
+
logicalRequestCount: requests.length,
|
|
468
|
+
logicalBytes,
|
|
469
|
+
transportBytes: length,
|
|
470
|
+
overfetchBytes: Math.max(length - logicalBytes, 0)
|
|
471
|
+
});
|
|
472
|
+
|
|
473
|
+
const transportResult = normalizeTransportResult(
|
|
474
|
+
await fetchRange(offset, length, abortController.signal)
|
|
475
|
+
);
|
|
476
|
+
const {arrayBuffer} = transportResult;
|
|
477
|
+
const isClampedFullResponse =
|
|
478
|
+
transportResult.fullResponse && offset === 0 && arrayBuffer.byteLength < length;
|
|
479
|
+
const isClampedEndOfFile =
|
|
480
|
+
arrayBuffer.byteLength < length &&
|
|
481
|
+
Number.isSafeInteger(transportResult.sourceByteLength) &&
|
|
482
|
+
offset + arrayBuffer.byteLength === transportResult.sourceByteLength;
|
|
483
|
+
if (arrayBuffer.byteLength !== length && !isClampedFullResponse && !isClampedEndOfFile) {
|
|
484
|
+
throw new Error(
|
|
485
|
+
`Byte-range transport returned ${arrayBuffer.byteLength} bytes; expected ${length}`
|
|
486
|
+
);
|
|
487
|
+
}
|
|
488
|
+
const networkTimeMs = transportResult.networkTimeMs ?? getTimestamp() - requestStartTime;
|
|
489
|
+
|
|
490
|
+
this.trackEvent({
|
|
491
|
+
type: 'response',
|
|
492
|
+
sourceId: mergedRequest.sourceId,
|
|
493
|
+
offset,
|
|
494
|
+
length,
|
|
495
|
+
logicalRequestCount: requests.length,
|
|
496
|
+
logicalBytes,
|
|
497
|
+
transportBytes: length,
|
|
498
|
+
responseBytes: transportResult.transportBytes ?? arrayBuffer.byteLength,
|
|
499
|
+
networkTimeMs,
|
|
500
|
+
overfetchBytes: Math.max(length - logicalBytes, 0),
|
|
501
|
+
status: transportResult.status,
|
|
502
|
+
fullResponse: transportResult.fullResponse
|
|
503
|
+
});
|
|
504
|
+
|
|
505
|
+
for (const request of requests) {
|
|
506
|
+
if (request.settled) {
|
|
507
|
+
continue;
|
|
508
|
+
}
|
|
509
|
+
|
|
510
|
+
const start = request.offset - offset;
|
|
511
|
+
request.settled = true;
|
|
512
|
+
request.resolve(arrayBuffer.slice(start, start + request.length));
|
|
513
|
+
}
|
|
514
|
+
} catch (error) {
|
|
515
|
+
if (!abortController.signal.aborted) {
|
|
516
|
+
this.trackEvent({
|
|
517
|
+
type: 'error',
|
|
518
|
+
sourceId: mergedRequest.sourceId,
|
|
519
|
+
offset,
|
|
520
|
+
length: endOffset - offset,
|
|
521
|
+
logicalRequestCount: requests.length,
|
|
522
|
+
logicalBytes: getLogicalRequestBytes(requests),
|
|
523
|
+
networkTimeMs: getTimestamp() - requestStartTime,
|
|
524
|
+
error
|
|
525
|
+
});
|
|
526
|
+
}
|
|
527
|
+
|
|
528
|
+
for (const request of requests) {
|
|
529
|
+
if (request.settled) {
|
|
530
|
+
continue;
|
|
531
|
+
}
|
|
532
|
+
if (request.signal?.aborted) {
|
|
533
|
+
this.abortRequest(request);
|
|
534
|
+
} else {
|
|
535
|
+
request.settled = true;
|
|
536
|
+
request.reject(error);
|
|
537
|
+
}
|
|
538
|
+
}
|
|
539
|
+
} finally {
|
|
540
|
+
this.transportControllers.delete(abortController);
|
|
541
|
+
for (const request of requests) {
|
|
542
|
+
if (request.abortListener) {
|
|
543
|
+
request.signal?.removeEventListener('abort', request.abortListener);
|
|
544
|
+
}
|
|
545
|
+
request.onAbort = undefined;
|
|
546
|
+
}
|
|
547
|
+
}
|
|
548
|
+
}
|
|
549
|
+
|
|
550
|
+
/** Rejects and tracks one logical request exactly once when its caller aborts. */
|
|
551
|
+
private abortRequest(request: PendingRequest): void {
|
|
552
|
+
if (request.settled) {
|
|
553
|
+
return;
|
|
554
|
+
}
|
|
555
|
+
request.settled = true;
|
|
556
|
+
this.pendingRequests = this.pendingRequests.filter(pending => pending !== request);
|
|
557
|
+
for (const group of this.transportQueue) {
|
|
558
|
+
group.requests = group.requests.filter(pending => !pending.settled);
|
|
559
|
+
if (group.requests.length) {
|
|
560
|
+
group.offset = Math.min(...group.requests.map(pending => pending.offset));
|
|
561
|
+
group.endOffset = Math.max(
|
|
562
|
+
...group.requests.map(pending => pending.offset + pending.length)
|
|
563
|
+
);
|
|
564
|
+
}
|
|
565
|
+
}
|
|
566
|
+
this.transportQueue = this.transportQueue.filter(group => group.requests.length > 0);
|
|
567
|
+
request.reject(request.signal?.reason ?? createAbortError());
|
|
568
|
+
this.trackEvent({
|
|
569
|
+
type: 'abort',
|
|
570
|
+
sourceId: request.sourceId,
|
|
571
|
+
offset: request.offset,
|
|
572
|
+
length: request.length,
|
|
573
|
+
logicalRequestCount: 1,
|
|
574
|
+
logicalBytes: request.length
|
|
575
|
+
});
|
|
576
|
+
}
|
|
577
|
+
|
|
578
|
+
/** Emits one event to Stats and to the optional callback. */
|
|
579
|
+
private trackEvent(event: RangeRequestEvent): void {
|
|
580
|
+
trackStatsEvent(this.stats, event);
|
|
581
|
+
try {
|
|
582
|
+
this.onEvent?.(event);
|
|
583
|
+
} catch {
|
|
584
|
+
// Diagnostics must not change transport behavior or orphan queued requests.
|
|
585
|
+
}
|
|
586
|
+
}
|
|
587
|
+
|
|
588
|
+
/** Emits one batch event after logical requests have been merged. */
|
|
589
|
+
private trackBatch(activeRequests: PendingRequest[], mergedRequests: MergedRequest[]): void {
|
|
590
|
+
const logicalBytes = getLogicalRequestBytes(activeRequests);
|
|
591
|
+
const transportBytes = mergedRequests.reduce(
|
|
592
|
+
(sum, mergedRequest) => sum + mergedRequest.endOffset - mergedRequest.offset,
|
|
593
|
+
0
|
|
594
|
+
);
|
|
595
|
+
this.trackEvent({
|
|
596
|
+
type: 'batch',
|
|
597
|
+
logicalRequestCount: activeRequests.length,
|
|
598
|
+
transportRequestCount: mergedRequests.length,
|
|
599
|
+
logicalBytes,
|
|
600
|
+
transportBytes,
|
|
601
|
+
overfetchBytes: Math.max(transportBytes - logicalBytes, 0)
|
|
602
|
+
});
|
|
603
|
+
}
|
|
604
|
+
}
|
|
605
|
+
|
|
606
|
+
/**
|
|
607
|
+
* Tracks range batching events in a probe.gl Stats object.
|
|
608
|
+
*/
|
|
609
|
+
export function trackStatsEvent(stats: Stats, event: RangeRequestEvent): void {
|
|
610
|
+
if ((event.type === 'response' || event.type === 'error') && event.networkTimeMs !== undefined) {
|
|
611
|
+
stats.get(RANGE_STATS_KEYS.networkTimeMs, 'time').addTime(event.networkTimeMs);
|
|
612
|
+
}
|
|
613
|
+
|
|
614
|
+
switch (event.type) {
|
|
615
|
+
case 'queued':
|
|
616
|
+
stats.get(RANGE_STATS_KEYS.logicalRanges, 'count').incrementCount();
|
|
617
|
+
stats.get(RANGE_STATS_KEYS.requestedBytes, 'count').addCount(event.logicalBytes || 0);
|
|
618
|
+
break;
|
|
619
|
+
case 'batch':
|
|
620
|
+
stats.get(RANGE_STATS_KEYS.rangeBatches, 'count').incrementCount();
|
|
621
|
+
stats.get('Logical Ranges Batched', 'count').addCount(event.logicalRequestCount || 0);
|
|
622
|
+
stats
|
|
623
|
+
.get(RANGE_STATS_KEYS.transportRanges, 'count')
|
|
624
|
+
.addCount(event.transportRequestCount || 0);
|
|
625
|
+
stats
|
|
626
|
+
.get(RANGE_STATS_KEYS.coalescedRanges, 'count')
|
|
627
|
+
.addCount(
|
|
628
|
+
Math.max((event.logicalRequestCount || 0) - (event.transportRequestCount || 0), 0)
|
|
629
|
+
);
|
|
630
|
+
stats.get(RANGE_STATS_KEYS.transportBytes, 'count').addCount(event.transportBytes || 0);
|
|
631
|
+
stats.get(RANGE_STATS_KEYS.overfetchBytes, 'count').addCount(event.overfetchBytes || 0);
|
|
632
|
+
break;
|
|
633
|
+
case 'response':
|
|
634
|
+
stats.get(RANGE_STATS_KEYS.completedTransportRanges, 'count').incrementCount();
|
|
635
|
+
stats.get(RANGE_STATS_KEYS.responseBytes, 'count').addCount(event.responseBytes || 0);
|
|
636
|
+
if (event.fullResponse) {
|
|
637
|
+
stats.get(RANGE_STATS_KEYS.fullResponseFallbacks, 'count').incrementCount();
|
|
638
|
+
}
|
|
639
|
+
break;
|
|
640
|
+
case 'error':
|
|
641
|
+
stats.get(RANGE_STATS_KEYS.failedTransportRanges, 'count').incrementCount();
|
|
642
|
+
break;
|
|
643
|
+
case 'abort':
|
|
644
|
+
stats.get(RANGE_STATS_KEYS.abortedLogicalRanges, 'count').incrementCount();
|
|
645
|
+
break;
|
|
646
|
+
default:
|
|
647
|
+
}
|
|
648
|
+
}
|
|
649
|
+
|
|
650
|
+
/** Creates a probe.gl `Stats` object initialized with byte-range scheduler counters. */
|
|
651
|
+
export function createRangeStats(id = 'range-request-scheduler'): Stats {
|
|
652
|
+
const stats = new Stats({id});
|
|
653
|
+
initializeStats(stats);
|
|
654
|
+
return stats;
|
|
655
|
+
}
|
|
656
|
+
|
|
657
|
+
/** Reads byte-range scheduler counters from a probe.gl `Stats` object. */
|
|
658
|
+
export function getRangeStats(stats: Stats): RangeStats {
|
|
659
|
+
return {
|
|
660
|
+
logicalRanges: stats.get(RANGE_STATS_KEYS.logicalRanges).count,
|
|
661
|
+
rangeBatches: stats.get(RANGE_STATS_KEYS.rangeBatches).count,
|
|
662
|
+
transportRanges: stats.get(RANGE_STATS_KEYS.transportRanges).count,
|
|
663
|
+
completedTransportRanges: stats.get(RANGE_STATS_KEYS.completedTransportRanges).count,
|
|
664
|
+
coalescedRanges: stats.get(RANGE_STATS_KEYS.coalescedRanges).count,
|
|
665
|
+
requestedBytes: stats.get(RANGE_STATS_KEYS.requestedBytes).count,
|
|
666
|
+
transportBytes: stats.get(RANGE_STATS_KEYS.transportBytes).count,
|
|
667
|
+
responseBytes: stats.get(RANGE_STATS_KEYS.responseBytes).count,
|
|
668
|
+
networkTimeMs: stats.get(RANGE_STATS_KEYS.networkTimeMs).time,
|
|
669
|
+
overfetchBytes: stats.get(RANGE_STATS_KEYS.overfetchBytes).count,
|
|
670
|
+
failedTransportRanges: stats.get(RANGE_STATS_KEYS.failedTransportRanges).count,
|
|
671
|
+
abortedLogicalRanges: stats.get(RANGE_STATS_KEYS.abortedLogicalRanges).count,
|
|
672
|
+
fullResponseFallbacks: stats.get(RANGE_STATS_KEYS.fullResponseFallbacks).count
|
|
673
|
+
};
|
|
674
|
+
}
|
|
675
|
+
|
|
676
|
+
/** Issues one HTTP range request and parses range-related status/header behavior. */
|
|
677
|
+
export async function fetchHttpRange(
|
|
678
|
+
request: Required<Pick<RangeFetchRequest, 'url' | 'fetch'>> &
|
|
679
|
+
Pick<RangeFetchRequest, 'offset' | 'length' | 'signal' | 'fetchOptions'>
|
|
680
|
+
): Promise<RangeRequestTransportResult> {
|
|
681
|
+
const abortContext = createAbortableFetchContext(request.signal);
|
|
682
|
+
const requestStartTime = getTimestamp();
|
|
683
|
+
|
|
684
|
+
try {
|
|
685
|
+
let fullResponse = false;
|
|
686
|
+
let response = await request.fetch(
|
|
687
|
+
request.url,
|
|
688
|
+
createRangeFetchOptions(
|
|
689
|
+
request.fetchOptions,
|
|
690
|
+
request.offset,
|
|
691
|
+
request.length,
|
|
692
|
+
abortContext.signal
|
|
693
|
+
)
|
|
694
|
+
);
|
|
695
|
+
|
|
696
|
+
if (response.status === 416 && request.offset === 0) {
|
|
697
|
+
const actualLength = parseUnsatisfiedContentRange(response.headers.get('Content-Range'));
|
|
698
|
+
if (!actualLength) {
|
|
699
|
+
throw new Error('Missing content-length on 416 response');
|
|
700
|
+
}
|
|
701
|
+
response = await request.fetch(
|
|
702
|
+
request.url,
|
|
703
|
+
createRangeFetchOptions(request.fetchOptions, 0, actualLength, abortContext.signal)
|
|
704
|
+
);
|
|
705
|
+
fullResponse = true;
|
|
706
|
+
}
|
|
707
|
+
|
|
708
|
+
if (response.status === 200) {
|
|
709
|
+
abortContext.abort();
|
|
710
|
+
await cancelIgnoredRangeResponse(response);
|
|
711
|
+
throw new Error('Byte-range request failed: server returned 200 instead of 206');
|
|
712
|
+
}
|
|
713
|
+
|
|
714
|
+
if (response.status !== 206 && !response.ok) {
|
|
715
|
+
throw new Error(`Bad response code: ${response.status}`);
|
|
716
|
+
}
|
|
717
|
+
|
|
718
|
+
const arrayBuffer = await response.arrayBuffer();
|
|
719
|
+
const contentRangeHeader = response.headers.get('Content-Range');
|
|
720
|
+
const contentRange = parseSatisfiedContentRange(contentRangeHeader);
|
|
721
|
+
if (contentRangeHeader && !contentRange) {
|
|
722
|
+
throw new Error(`Invalid Content-Range header: ${contentRangeHeader}`);
|
|
723
|
+
}
|
|
724
|
+
if (contentRange) {
|
|
725
|
+
const responseLength = contentRange.endOffset - contentRange.offset + 1;
|
|
726
|
+
const requestedEndOffset = request.offset + request.length - 1;
|
|
727
|
+
if (
|
|
728
|
+
contentRange.offset !== request.offset ||
|
|
729
|
+
contentRange.endOffset > requestedEndOffset ||
|
|
730
|
+
responseLength !== arrayBuffer.byteLength ||
|
|
731
|
+
(contentRange.sourceByteLength !== undefined &&
|
|
732
|
+
contentRange.endOffset >= contentRange.sourceByteLength)
|
|
733
|
+
) {
|
|
734
|
+
throw new Error(`Content-Range does not match requested range: ${contentRangeHeader}`);
|
|
735
|
+
}
|
|
736
|
+
}
|
|
737
|
+
return {
|
|
738
|
+
arrayBuffer,
|
|
739
|
+
status: response.status,
|
|
740
|
+
sourceByteLength: contentRange?.sourceByteLength,
|
|
741
|
+
transportBytes: arrayBuffer.byteLength,
|
|
742
|
+
networkTimeMs: getTimestamp() - requestStartTime,
|
|
743
|
+
fullResponse
|
|
744
|
+
};
|
|
745
|
+
} finally {
|
|
746
|
+
abortContext.removeAbortListener();
|
|
747
|
+
}
|
|
748
|
+
}
|
|
749
|
+
|
|
750
|
+
/** Returns true when a new request can be folded into an existing merged request. */
|
|
751
|
+
function canMergeRequests(
|
|
752
|
+
mergedRequest: MergedRequest,
|
|
753
|
+
request: RangeRequest,
|
|
754
|
+
props: Required<Omit<RangeRequestSchedulerProps, 'stats' | 'onEvent'>>
|
|
755
|
+
): boolean {
|
|
756
|
+
if (mergedRequest.sourceId !== request.sourceId) {
|
|
757
|
+
return false;
|
|
758
|
+
}
|
|
759
|
+
if (mergedRequest.isolationKey !== (request.isolationKey ?? request.sourceId)) {
|
|
760
|
+
return false;
|
|
761
|
+
}
|
|
762
|
+
|
|
763
|
+
const requestEndOffset = request.offset + request.length;
|
|
764
|
+
const gapBytes = request.offset - mergedRequest.endOffset;
|
|
765
|
+
const mergedBytes = Math.max(mergedRequest.endOffset, requestEndOffset) - mergedRequest.offset;
|
|
766
|
+
|
|
767
|
+
return gapBytes <= props.rangeExpansionBytes && mergedBytes <= props.maxMergedBytes;
|
|
768
|
+
}
|
|
769
|
+
|
|
770
|
+
/** Initializes the Stats keys used by the range scheduler. */
|
|
771
|
+
function initializeStats(stats: Stats): void {
|
|
772
|
+
stats.get(RANGE_STATS_KEYS.logicalRanges, 'count');
|
|
773
|
+
stats.get(RANGE_STATS_KEYS.requestedBytes, 'count');
|
|
774
|
+
stats.get(RANGE_STATS_KEYS.rangeBatches, 'count');
|
|
775
|
+
stats.get('Logical Ranges Batched', 'count');
|
|
776
|
+
stats.get(RANGE_STATS_KEYS.transportRanges, 'count');
|
|
777
|
+
stats.get(RANGE_STATS_KEYS.coalescedRanges, 'count');
|
|
778
|
+
stats.get(RANGE_STATS_KEYS.transportBytes, 'count');
|
|
779
|
+
stats.get(RANGE_STATS_KEYS.completedTransportRanges, 'count');
|
|
780
|
+
stats.get(RANGE_STATS_KEYS.responseBytes, 'count');
|
|
781
|
+
stats.get(RANGE_STATS_KEYS.networkTimeMs, 'time');
|
|
782
|
+
stats.get(RANGE_STATS_KEYS.overfetchBytes, 'count');
|
|
783
|
+
stats.get(RANGE_STATS_KEYS.fullResponseFallbacks, 'count');
|
|
784
|
+
stats.get(RANGE_STATS_KEYS.failedTransportRanges, 'count');
|
|
785
|
+
stats.get(RANGE_STATS_KEYS.abortedLogicalRanges, 'count');
|
|
786
|
+
}
|
|
787
|
+
|
|
788
|
+
/** Returns the sum of the caller-requested byte lengths. */
|
|
789
|
+
function getLogicalRequestBytes(requests: {length: number}[]): number {
|
|
790
|
+
return requests.reduce((sum, request) => sum + request.length, 0);
|
|
791
|
+
}
|
|
792
|
+
|
|
793
|
+
/** Normalizes legacy ArrayBuffer fetch results and diagnostic transport results. */
|
|
794
|
+
function normalizeTransportResult(
|
|
795
|
+
result: ArrayBuffer | RangeRequestTransportResult
|
|
796
|
+
): RangeRequestTransportResult {
|
|
797
|
+
return result instanceof ArrayBuffer ? {arrayBuffer: result} : result;
|
|
798
|
+
}
|
|
799
|
+
|
|
800
|
+
/** Creates fetch options for one HTTP byte-range request while preserving caller headers. */
|
|
801
|
+
function createRangeFetchOptions(
|
|
802
|
+
fetchOptions: RequestInit | undefined,
|
|
803
|
+
offset: number,
|
|
804
|
+
length: number,
|
|
805
|
+
signal: AbortSignal
|
|
806
|
+
): RequestInit {
|
|
807
|
+
return {
|
|
808
|
+
...fetchOptions,
|
|
809
|
+
signal,
|
|
810
|
+
headers: {
|
|
811
|
+
...getHeadersObject(fetchOptions?.headers),
|
|
812
|
+
Range: `bytes=${offset}-${offset + length - 1}`
|
|
813
|
+
}
|
|
814
|
+
};
|
|
815
|
+
}
|
|
816
|
+
|
|
817
|
+
/** Copies supported HeadersInit values into a plain object so Range can be merged in. */
|
|
818
|
+
function getHeadersObject(headers?: HeadersInit): Record<string, string> {
|
|
819
|
+
if (!headers) {
|
|
820
|
+
return {};
|
|
821
|
+
}
|
|
822
|
+
if (headers instanceof Headers) {
|
|
823
|
+
return Object.fromEntries(headers.entries());
|
|
824
|
+
}
|
|
825
|
+
if (Array.isArray(headers)) {
|
|
826
|
+
return Object.fromEntries(headers);
|
|
827
|
+
}
|
|
828
|
+
return headers;
|
|
829
|
+
}
|
|
830
|
+
|
|
831
|
+
/** Parses a `Content-Range: bytes *\/<length>` header from an unsatisfied range response. */
|
|
832
|
+
function parseUnsatisfiedContentRange(contentRange: string | null): number | null {
|
|
833
|
+
const match = contentRange?.match(/^bytes \*\/(\d+)$/);
|
|
834
|
+
return match ? Number(match[1]) : null;
|
|
835
|
+
}
|
|
836
|
+
|
|
837
|
+
/** Parses a `Content-Range: bytes <start>-<end>/<length-or-*>` response header. */
|
|
838
|
+
function parseSatisfiedContentRange(contentRange: string | null): {
|
|
839
|
+
offset: number;
|
|
840
|
+
endOffset: number;
|
|
841
|
+
sourceByteLength?: number;
|
|
842
|
+
} | null {
|
|
843
|
+
const match = contentRange?.match(/^bytes (\d+)-(\d+)\/(\d+|\*)$/);
|
|
844
|
+
if (!match) {
|
|
845
|
+
return null;
|
|
846
|
+
}
|
|
847
|
+
const offset = Number(match[1]);
|
|
848
|
+
const endOffset = Number(match[2]);
|
|
849
|
+
const sourceByteLength = match[3] === '*' ? undefined : Number(match[3]);
|
|
850
|
+
if (
|
|
851
|
+
!Number.isSafeInteger(offset) ||
|
|
852
|
+
!Number.isSafeInteger(endOffset) ||
|
|
853
|
+
offset > endOffset ||
|
|
854
|
+
(sourceByteLength !== undefined && !Number.isSafeInteger(sourceByteLength))
|
|
855
|
+
) {
|
|
856
|
+
return null;
|
|
857
|
+
}
|
|
858
|
+
return {offset, endOffset, sourceByteLength};
|
|
859
|
+
}
|
|
860
|
+
|
|
861
|
+
/** Creates an inner abort controller that follows an optional parent signal and can cancel one fetch. */
|
|
862
|
+
function createAbortableFetchContext(parentSignal?: AbortSignal): {
|
|
863
|
+
signal: AbortSignal;
|
|
864
|
+
abort: () => void;
|
|
865
|
+
removeAbortListener: () => void;
|
|
866
|
+
} {
|
|
867
|
+
const abortController = new AbortController();
|
|
868
|
+
const abortListener = () => abortController.abort(parentSignal?.reason);
|
|
869
|
+
if (parentSignal?.aborted) {
|
|
870
|
+
abortController.abort(parentSignal?.reason);
|
|
871
|
+
} else {
|
|
872
|
+
parentSignal?.addEventListener('abort', abortListener, {once: true});
|
|
873
|
+
}
|
|
874
|
+
return {
|
|
875
|
+
signal: abortController.signal,
|
|
876
|
+
abort: () => abortController.abort(),
|
|
877
|
+
removeAbortListener: () => parentSignal?.removeEventListener('abort', abortListener)
|
|
878
|
+
};
|
|
879
|
+
}
|
|
880
|
+
|
|
881
|
+
/** Cancels a response body when a server ignores a `Range` header and starts sending the whole archive. */
|
|
882
|
+
async function cancelIgnoredRangeResponse(response: Response): Promise<void> {
|
|
883
|
+
await response.body?.cancel().catch(() => {});
|
|
884
|
+
}
|
|
885
|
+
|
|
886
|
+
/** Returns a high-resolution timestamp when available. */
|
|
887
|
+
function getTimestamp(): number {
|
|
888
|
+
return globalThis.performance?.now() ?? Date.now();
|
|
889
|
+
}
|
|
890
|
+
|
|
891
|
+
/** Creates a conventional abort error without requiring DOMException in every host. */
|
|
892
|
+
function createAbortError(): Error {
|
|
893
|
+
if (typeof DOMException !== 'undefined') {
|
|
894
|
+
return new DOMException('Request aborted', 'AbortError');
|
|
895
|
+
}
|
|
896
|
+
const error = new Error('Request aborted');
|
|
897
|
+
error.name = 'AbortError';
|
|
898
|
+
return error;
|
|
899
|
+
}
|