@loaders.gl/loader-utils 4.0.0-alpha.22 → 4.0.0-alpha.23

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.
Files changed (64) hide show
  1. package/dist/es5/index.js +30 -2
  2. package/dist/es5/index.js.map +1 -1
  3. package/dist/es5/json-loader.js +1 -1
  4. package/dist/es5/lib/file-provider/data-view-file.js +146 -0
  5. package/dist/es5/lib/file-provider/data-view-file.js.map +1 -0
  6. package/dist/es5/lib/file-provider/file-handle-file.js +236 -0
  7. package/dist/es5/lib/file-provider/file-handle-file.js.map +1 -0
  8. package/dist/es5/lib/file-provider/file-handle.js +104 -0
  9. package/dist/es5/lib/file-provider/file-handle.js.map +1 -0
  10. package/dist/es5/lib/file-provider/file-provider.js +11 -0
  11. package/dist/es5/lib/file-provider/file-provider.js.map +1 -0
  12. package/dist/es5/lib/filesystems/filesystem.js +2 -0
  13. package/dist/es5/lib/filesystems/filesystem.js.map +1 -0
  14. package/dist/es5/lib/filesystems/node-filesystem.js +2 -2
  15. package/dist/es5/lib/filesystems/node-filesystem.js.map +1 -1
  16. package/dist/es5/types.js.map +1 -1
  17. package/dist/esm/index.js +5 -1
  18. package/dist/esm/index.js.map +1 -1
  19. package/dist/esm/json-loader.js +1 -1
  20. package/dist/esm/lib/file-provider/data-view-file.js +33 -0
  21. package/dist/esm/lib/file-provider/data-view-file.js.map +1 -0
  22. package/dist/esm/lib/file-provider/file-handle-file.js +59 -0
  23. package/dist/esm/lib/file-provider/file-handle-file.js.map +1 -0
  24. package/dist/esm/lib/file-provider/file-handle.js +37 -0
  25. package/dist/esm/lib/file-provider/file-handle.js.map +1 -0
  26. package/dist/esm/lib/file-provider/file-provider.js +4 -0
  27. package/dist/esm/lib/file-provider/file-provider.js.map +1 -0
  28. package/dist/esm/lib/filesystems/filesystem.js +2 -0
  29. package/dist/esm/lib/filesystems/filesystem.js.map +1 -0
  30. package/dist/esm/lib/filesystems/node-filesystem.js +1 -1
  31. package/dist/esm/lib/filesystems/node-filesystem.js.map +1 -1
  32. package/dist/esm/types.js.map +1 -1
  33. package/dist/index.d.ts +8 -2
  34. package/dist/index.d.ts.map +1 -1
  35. package/dist/index.js +11 -3
  36. package/dist/lib/file-provider/data-view-file.d.ts +37 -0
  37. package/dist/lib/file-provider/data-view-file.d.ts.map +1 -0
  38. package/dist/lib/file-provider/data-view-file.js +63 -0
  39. package/dist/lib/file-provider/file-handle-file.d.ts +53 -0
  40. package/dist/lib/file-provider/file-handle-file.d.ts.map +1 -0
  41. package/dist/lib/file-provider/file-handle-file.js +92 -0
  42. package/dist/lib/file-provider/file-handle.d.ts +40 -0
  43. package/dist/lib/file-provider/file-handle.d.ts.map +1 -0
  44. package/dist/lib/file-provider/file-handle.js +55 -0
  45. package/dist/lib/file-provider/file-provider.d.ts +45 -0
  46. package/dist/lib/file-provider/file-provider.d.ts.map +1 -0
  47. package/dist/lib/file-provider/file-provider.js +13 -0
  48. package/dist/lib/filesystems/filesystem.d.ts +81 -0
  49. package/dist/lib/filesystems/filesystem.d.ts.map +1 -0
  50. package/dist/lib/filesystems/filesystem.js +37 -0
  51. package/dist/lib/filesystems/node-filesystem.d.ts +2 -2
  52. package/dist/lib/filesystems/node-filesystem.d.ts.map +1 -1
  53. package/dist/lib/filesystems/node-filesystem.js +3 -2
  54. package/dist/types.d.ts +0 -44
  55. package/dist/types.d.ts.map +1 -1
  56. package/package.json +3 -3
  57. package/src/index.ts +10 -4
  58. package/src/lib/file-provider/data-view-file.ts +72 -0
  59. package/src/lib/file-provider/file-handle-file.ts +116 -0
  60. package/src/lib/file-provider/file-handle.ts +74 -0
  61. package/src/lib/file-provider/file-provider.ts +56 -0
  62. package/src/lib/filesystems/filesystem.ts +87 -0
  63. package/src/lib/filesystems/node-filesystem.ts +3 -3
  64. package/src/types.ts +0 -34
@@ -0,0 +1,63 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.DataViewFile = void 0;
4
+ /**
5
+ * Checks if bigint can be converted to number and convert it if possible
6
+ * @param bigint bigint to be converted
7
+ * @returns number
8
+ */
9
+ const toNumber = (bigint) => {
10
+ if (bigint > Number.MAX_SAFE_INTEGER) {
11
+ throw new Error('Offset is out of bounds');
12
+ }
13
+ return Number(bigint);
14
+ };
15
+ /** Provides file data using DataView */
16
+ class DataViewFile {
17
+ constructor(file) {
18
+ this.file = file;
19
+ }
20
+ // eslint-disable-next-line @typescript-eslint/no-empty-function
21
+ async destroy() { }
22
+ /**
23
+ * Gets an unsigned 8-bit integer at the specified byte offset from the start of the file.
24
+ * @param offset The offset, in bytes, from the start of the file where to read the data.
25
+ */
26
+ async getUint8(offset) {
27
+ return this.file.getUint8(toNumber(offset));
28
+ }
29
+ /**
30
+ * Gets an unsigned 16-bit intege at the specified byte offset from the start of the file.
31
+ * @param offset The offset, in bytes, from the start of the file where to read the data.
32
+ */
33
+ async getUint16(offset) {
34
+ return this.file.getUint16(toNumber(offset), true);
35
+ }
36
+ /**
37
+ * Gets an unsigned 32-bit integer at the specified byte offset from the start of the file.
38
+ * @param offset The offset, in bytes, from the start of the file where to read the data.
39
+ */
40
+ async getUint32(offset) {
41
+ return this.file.getUint32(toNumber(offset), true);
42
+ }
43
+ /**
44
+ * Gets an unsigned 64-bit integer at the specified byte offset from the start of the file.
45
+ * @param offset The offset, in bytes, from the start of the file where to read the data.
46
+ */
47
+ async getBigUint64(offset) {
48
+ return this.file.getBigUint64(toNumber(offset), true);
49
+ }
50
+ /**
51
+ * returns an ArrayBuffer whose contents are a copy of this file bytes from startOffset, inclusive, up to endOffset, exclusive.
52
+ * @param startOffset The offset, in bytes, from the start of the file where to start reading the data.
53
+ * @param endOffset The offset, in bytes, from the start of the file where to end reading the data.
54
+ */
55
+ async slice(startOffset, endOffset) {
56
+ return this.file.buffer.slice(toNumber(startOffset), toNumber(endOffset));
57
+ }
58
+ /** the length (in bytes) of the data. */
59
+ get length() {
60
+ return BigInt(this.file.byteLength);
61
+ }
62
+ }
63
+ exports.DataViewFile = DataViewFile;
@@ -0,0 +1,53 @@
1
+ import { FileProvider } from './file-provider';
2
+ /**
3
+ * Provides file data using node fs library
4
+ */
5
+ export declare class FileHandleFile implements FileProvider {
6
+ /**
7
+ * Returns a new copy of FileHandleFile
8
+ * @param path The path to the file in file system
9
+ */
10
+ static from(path: string): Promise<FileHandleFile>;
11
+ /**
12
+ * The FileHandle from which data is provided
13
+ */
14
+ private fileDescriptor;
15
+ /**
16
+ * The file length in bytes
17
+ */
18
+ private size;
19
+ private constructor();
20
+ /** Close file */
21
+ destroy(): Promise<void>;
22
+ /**
23
+ * Gets an unsigned 8-bit integer at the specified byte offset from the start of the file.
24
+ * @param offset The offset, in bytes, from the start of the file where to read the data.
25
+ */
26
+ getUint8(offset: bigint): Promise<number>;
27
+ /**
28
+ * Gets an unsigned 16-bit integer at the specified byte offset from the start of the file.
29
+ * @param offset The offset, in bytes, from the start of the file where to read the data.
30
+ */
31
+ getUint16(offset: bigint): Promise<number>;
32
+ /**
33
+ * Gets an unsigned 32-bit integer at the specified byte offset from the start of the file.
34
+ * @param offset The offset, in bytes, from the start of the file where to read the data.
35
+ */
36
+ getUint32(offset: bigint): Promise<number>;
37
+ /**
38
+ * Gets an unsigned 32-bit integer at the specified byte offset from the start of the file.
39
+ * @param offset The offset, in bytes, from the start of the file where to read the data.
40
+ */
41
+ getBigUint64(offset: bigint): Promise<bigint>;
42
+ /**
43
+ * returns an ArrayBuffer whose contents are a copy of this file bytes from startOffset, inclusive, up to endOffset, exclusive.
44
+ * @param startOffsset The offset, in byte, from the start of the file where to start reading the data.
45
+ * @param endOffset The offset, in bytes, from the start of the file where to end reading the data.
46
+ */
47
+ slice(startOffsset: bigint, endOffset: bigint): Promise<ArrayBuffer>;
48
+ /**
49
+ * the length (in bytes) of the data.
50
+ */
51
+ get length(): bigint;
52
+ }
53
+ //# sourceMappingURL=file-handle-file.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"file-handle-file.d.ts","sourceRoot":"","sources":["../../../src/lib/file-provider/file-handle-file.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,YAAY,EAAC,MAAM,iBAAiB,CAAC;AAI7C;;GAEG;AACH,qBAAa,cAAe,YAAW,YAAY;IACjD;;;OAGG;WACU,IAAI,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC,cAAc,CAAC;IAMxD;;OAEG;IACH,OAAO,CAAC,cAAc,CAAa;IAEnC;;OAEG;IACH,OAAO,CAAC,IAAI,CAAS;IAErB,OAAO;IAKP,iBAAiB;IACX,OAAO,IAAI,OAAO,CAAC,IAAI,CAAC;IAI9B;;;OAGG;IACG,QAAQ,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;IAU/C;;;OAGG;IACG,SAAS,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;IAUhD;;;OAGG;IACG,SAAS,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;IAUhD;;;OAGG;IACG,YAAY,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC;IAUnD;;;;OAIG;IACG,KAAK,CAAC,YAAY,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,WAAW,CAAC;IAU1E;;OAEG;IACH,IAAI,MAAM,IAAI,MAAM,CAEnB;CACF"}
@@ -0,0 +1,92 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.FileHandleFile = void 0;
4
+ const file_handle_1 = require("./file-handle");
5
+ const file_aliases_1 = require("../path-utils/file-aliases");
6
+ /**
7
+ * Provides file data using node fs library
8
+ */
9
+ class FileHandleFile {
10
+ /**
11
+ * Returns a new copy of FileHandleFile
12
+ * @param path The path to the file in file system
13
+ */
14
+ static async from(path) {
15
+ path = (0, file_aliases_1.resolvePath)(path);
16
+ const fileDescriptor = await file_handle_1.FileHandle.open(path);
17
+ return new FileHandleFile(fileDescriptor, fileDescriptor.stat.size);
18
+ }
19
+ constructor(fileDescriptor, size) {
20
+ this.fileDescriptor = fileDescriptor;
21
+ this.size = size;
22
+ }
23
+ /** Close file */
24
+ async destroy() {
25
+ await this.fileDescriptor.close();
26
+ }
27
+ /**
28
+ * Gets an unsigned 8-bit integer at the specified byte offset from the start of the file.
29
+ * @param offset The offset, in bytes, from the start of the file where to read the data.
30
+ */
31
+ async getUint8(offset) {
32
+ const val = new Uint8Array((await this.fileDescriptor.read(Buffer.alloc(1), 0, 1, offset)).buffer.buffer).at(0);
33
+ if (val === undefined) {
34
+ throw new Error('something went wrong');
35
+ }
36
+ return val;
37
+ }
38
+ /**
39
+ * Gets an unsigned 16-bit integer at the specified byte offset from the start of the file.
40
+ * @param offset The offset, in bytes, from the start of the file where to read the data.
41
+ */
42
+ async getUint16(offset) {
43
+ const val = new Uint16Array((await this.fileDescriptor.read(Buffer.alloc(2), 0, 2, offset)).buffer.buffer).at(0);
44
+ if (val === undefined) {
45
+ throw new Error('something went wrong');
46
+ }
47
+ return val;
48
+ }
49
+ /**
50
+ * Gets an unsigned 32-bit integer at the specified byte offset from the start of the file.
51
+ * @param offset The offset, in bytes, from the start of the file where to read the data.
52
+ */
53
+ async getUint32(offset) {
54
+ const val = new Uint32Array((await this.fileDescriptor.read(Buffer.alloc(4), 0, 4, offset)).buffer.buffer).at(0);
55
+ if (val === undefined) {
56
+ throw new Error('something went wrong');
57
+ }
58
+ return val;
59
+ }
60
+ /**
61
+ * Gets an unsigned 32-bit integer at the specified byte offset from the start of the file.
62
+ * @param offset The offset, in bytes, from the start of the file where to read the data.
63
+ */
64
+ async getBigUint64(offset) {
65
+ const val = new BigInt64Array((await this.fileDescriptor.read(Buffer.alloc(8), 0, 8, offset)).buffer.buffer).at(0);
66
+ if (val === undefined) {
67
+ throw new Error('something went wrong');
68
+ }
69
+ return val;
70
+ }
71
+ /**
72
+ * returns an ArrayBuffer whose contents are a copy of this file bytes from startOffset, inclusive, up to endOffset, exclusive.
73
+ * @param startOffsset The offset, in byte, from the start of the file where to start reading the data.
74
+ * @param endOffset The offset, in bytes, from the start of the file where to end reading the data.
75
+ */
76
+ async slice(startOffsset, endOffset) {
77
+ const bigLength = endOffset - startOffsset;
78
+ if (bigLength > Number.MAX_SAFE_INTEGER) {
79
+ throw new Error('too big slice');
80
+ }
81
+ const length = Number(bigLength);
82
+ return (await this.fileDescriptor.read(Buffer.alloc(length), 0, length, startOffsset)).buffer
83
+ .buffer;
84
+ }
85
+ /**
86
+ * the length (in bytes) of the data.
87
+ */
88
+ get length() {
89
+ return this.size;
90
+ }
91
+ }
92
+ exports.FileHandleFile = FileHandleFile;
@@ -0,0 +1,40 @@
1
+ /// <reference types="node" />
2
+ /// <reference types="node" />
3
+ import { BigIntStats } from 'fs';
4
+ /** file reading result */
5
+ export type FileReadResult = {
6
+ /** amount of the bytes read */
7
+ bytesRead: number;
8
+ /** the buffer filled with data from file*/
9
+ buffer: Buffer;
10
+ };
11
+ /** Object handling file info */
12
+ export declare class FileHandle {
13
+ private fileDescriptor;
14
+ private stats;
15
+ private constructor();
16
+ /**
17
+ * Opens a `FileHandle`.
18
+ *
19
+ * @param path path to the file
20
+ * @return Fulfills with a {FileHandle} object.
21
+ */
22
+ static open(path: string): Promise<FileHandle>;
23
+ /** Close file */
24
+ close(): Promise<void>;
25
+ /**
26
+ * Reads data from the file and stores that in the given buffer.
27
+ *
28
+ * If the file is not modified concurrently, the end-of-file is reached when the
29
+ * number of bytes read is zero.
30
+ * @param buffer A buffer that will be filled with the file data read.
31
+ * @param offset The location in the buffer at which to start filling.
32
+ * @param length The number of bytes to read.
33
+ * @param position The location where to begin reading data from the file. If `null`, data will be read from the current file position, and the position will be updated. If `position` is an
34
+ * integer, the current file position will remain unchanged.
35
+ * @return Fulfills upon success with a FileReadResult object
36
+ */
37
+ read: (buffer: Buffer, offset: number, length: number, position: number | bigint) => Promise<FileReadResult>;
38
+ get stat(): BigIntStats;
39
+ }
40
+ //# sourceMappingURL=file-handle.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"file-handle.d.ts","sourceRoot":"","sources":["../../../src/lib/file-provider/file-handle.ts"],"names":[],"mappings":";;AAAA,OAAO,EAA0B,WAAW,EAAC,MAAM,IAAI,CAAC;AAExD,0BAA0B;AAC1B,MAAM,MAAM,cAAc,GAAG;IAC3B,+BAA+B;IAC/B,SAAS,EAAE,MAAM,CAAC;IAClB,2CAA2C;IAC3C,MAAM,EAAE,MAAM,CAAC;CAChB,CAAC;AAEF,gCAAgC;AAChC,qBAAa,UAAU;IACrB,OAAO,CAAC,cAAc,CAAS;IAC/B,OAAO,CAAC,KAAK,CAAc;IAE3B,OAAO;IAIP;;;;;OAKG;WAEU,IAAI,CAAC,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC,UAAU,CAAC;IAYpD,iBAAiB;IACX,KAAK,IAAI,OAAO,CAAC,IAAI,CAAC;IAM5B;;;;;;;;;;;OAWG;IACH,IAAI,WACM,MAAM,UACN,MAAM,UACN,MAAM,YACJ,MAAM,GAAG,MAAM,KACxB,QAAQ,cAAc,CAAC,CAMxB;IAEF,IAAI,IAAI,IAAI,WAAW,CAEtB;CACF"}
@@ -0,0 +1,55 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.FileHandle = void 0;
4
+ const fs_1 = require("fs");
5
+ /** Object handling file info */
6
+ class FileHandle {
7
+ constructor(fileDescriptor, stats) {
8
+ /**
9
+ * Reads data from the file and stores that in the given buffer.
10
+ *
11
+ * If the file is not modified concurrently, the end-of-file is reached when the
12
+ * number of bytes read is zero.
13
+ * @param buffer A buffer that will be filled with the file data read.
14
+ * @param offset The location in the buffer at which to start filling.
15
+ * @param length The number of bytes to read.
16
+ * @param position The location where to begin reading data from the file. If `null`, data will be read from the current file position, and the position will be updated. If `position` is an
17
+ * integer, the current file position will remain unchanged.
18
+ * @return Fulfills upon success with a FileReadResult object
19
+ */
20
+ this.read = (buffer, offset, length, position) => {
21
+ return new Promise((s) => {
22
+ (0, fs_1.read)(this.fileDescriptor, buffer, offset, length, position, (_err, bytesRead, buffer) => s({ bytesRead, buffer }));
23
+ });
24
+ };
25
+ this.fileDescriptor = fileDescriptor;
26
+ this.stats = stats;
27
+ }
28
+ /**
29
+ * Opens a `FileHandle`.
30
+ *
31
+ * @param path path to the file
32
+ * @return Fulfills with a {FileHandle} object.
33
+ */
34
+ static async open(path) {
35
+ const [fd, stats] = await Promise.all([
36
+ new Promise((resolve, reject) => {
37
+ (0, fs_1.open)(path, undefined, undefined, (_err, fd) => (_err ? reject(_err) : resolve(fd)));
38
+ }),
39
+ new Promise((resolve, reject) => {
40
+ (0, fs_1.stat)(path, { bigint: true }, (_err, stats) => (_err ? reject(_err) : resolve(stats)));
41
+ })
42
+ ]);
43
+ return new FileHandle(fd, stats);
44
+ }
45
+ /** Close file */
46
+ async close() {
47
+ return new Promise((resolve) => {
48
+ (0, fs_1.close)(this.fileDescriptor, (_err) => resolve());
49
+ });
50
+ }
51
+ get stat() {
52
+ return this.stats;
53
+ }
54
+ }
55
+ exports.FileHandle = FileHandle;
@@ -0,0 +1,45 @@
1
+ /**
2
+ * Interface for providing file data
3
+ */
4
+ export interface FileProvider {
5
+ /**
6
+ * Cleanup class data
7
+ */
8
+ destroy(): Promise<void>;
9
+ /**
10
+ * Gets an unsigned 8-bit integer at the specified byte offset from the start of the file.
11
+ * @param offset The offset, in bytes, from the start of the file where to read the data.
12
+ */
13
+ getUint8(offset: bigint): Promise<number>;
14
+ /**
15
+ * Gets an unsigned 16-bit integer at the specified byte offset from the start of the file.
16
+ * @param offset The offset, in bytes, from the start of the file where to read the data.
17
+ */
18
+ getUint16(offset: bigint): Promise<number>;
19
+ /**
20
+ * Gets an unsigned 32-bit integer at the specified byte offset from the start of the file.
21
+ * @param offset The offset, in bytes, from the file of the view where to read the data.
22
+ */
23
+ getUint32(offset: bigint): Promise<number>;
24
+ /**
25
+ * Gets an unsigned 32-bit integer at the specified byte offset from the start of the file.
26
+ * @param offset The offset, in byte, from the file of the view where to read the data.
27
+ */
28
+ getBigUint64(offset: bigint): Promise<bigint>;
29
+ /**
30
+ * returns an ArrayBuffer whose contents are a copy of this file bytes from startOffset, inclusive, up to endOffset, exclusive.
31
+ * @param startOffset The offset, in bytes, from the start of the file where to start reading the data.
32
+ * @param endOffset The offset, in bytes, from the start of the file where to end reading the data.
33
+ */
34
+ slice(startOffset: bigint, endOffset: bigint): Promise<ArrayBuffer>;
35
+ /**
36
+ * the length (in bytes) of the data.
37
+ */
38
+ length: bigint;
39
+ }
40
+ /**
41
+ * Check is the object has FileProvider members
42
+ * @param fileProvider - tested object
43
+ */
44
+ export declare const isFileProvider: (fileProvider: unknown) => bigint;
45
+ //# sourceMappingURL=file-provider.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"file-provider.d.ts","sourceRoot":"","sources":["../../../src/lib/file-provider/file-provider.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,MAAM,WAAW,YAAY;IAC3B;;OAEG;IACH,OAAO,IAAI,OAAO,CAAC,IAAI,CAAC,CAAC;IACzB;;;OAGG;IACH,QAAQ,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC;IAE1C;;;OAGG;IACH,SAAS,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC;IAE3C;;;OAGG;IACH,SAAS,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC;IAE3C;;;OAGG;IACH,YAAY,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,MAAM,CAAC,CAAC;IAE9C;;;;OAIG;IACH,KAAK,CAAC,WAAW,EAAE,MAAM,EAAE,SAAS,EAAE,MAAM,GAAG,OAAO,CAAC,WAAW,CAAC,CAAC;IAEpE;;OAEG;IACH,MAAM,EAAE,MAAM,CAAC;CAChB;AAED;;;GAGG;AACH,eAAO,MAAM,cAAc,iBAAkB,OAAO,WAMnD,CAAC"}
@@ -0,0 +1,13 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.isFileProvider = void 0;
4
+ /**
5
+ * Check is the object has FileProvider members
6
+ * @param fileProvider - tested object
7
+ */
8
+ const isFileProvider = (fileProvider) => {
9
+ return (fileProvider?.getUint8 &&
10
+ fileProvider?.slice &&
11
+ fileProvider?.length);
12
+ };
13
+ exports.isFileProvider = isFileProvider;
@@ -0,0 +1,81 @@
1
+ /// <reference types="node" />
2
+ export type ReadOptions = {};
3
+ export type Stat = {
4
+ size: number;
5
+ isDirectory: () => boolean;
6
+ };
7
+ /**
8
+ * A FileSystem interface can encapsulate various file sources,
9
+ * a FileList, a ZipFile, a GoogleDrive etc.
10
+ */
11
+ export interface FileSystem {
12
+ /**
13
+ * Return a list of file names
14
+ * @param dirname directory name. file system root directory if omitted
15
+ */
16
+ readdir(dirname?: string, options?: {
17
+ recursive?: boolean;
18
+ }): Promise<string[]>;
19
+ /**
20
+ * Gets information from a local file from the filesystem
21
+ * @param filename file name to stat
22
+ * @param options currently unused
23
+ * @throws if filename is not in local filesystem
24
+ */
25
+ stat(filename: string, options?: object): Promise<{
26
+ size: number;
27
+ }>;
28
+ /**
29
+ * Fetches a local file from the filesystem (or a URL)
30
+ * @param filename
31
+ * @param options
32
+ */
33
+ fetch(filename: RequestInfo, options?: RequestInit): Promise<Response>;
34
+ }
35
+ /**
36
+ * A random access file system
37
+ */
38
+ export interface RandomAccessReadFileSystem extends FileSystem {
39
+ open(path: string, flags: unknown, mode?: unknown): Promise<any>;
40
+ close(fd: unknown): Promise<void>;
41
+ fstat(fd: unknown): Promise<Stat>;
42
+ read(fd: any, options?: ReadOptions): Promise<{
43
+ bytesRead: number;
44
+ buffer: Buffer;
45
+ }>;
46
+ }
47
+ /**
48
+ * A FileSystem interface can encapsulate a FileList, a ZipFile, a GoogleDrive etc.
49
+ *
50
+ export interface IFileSystem {
51
+ /**
52
+ * Return a list of file names
53
+ * @param dirname directory name. file system root directory if omitted
54
+ *
55
+ readdir(dirname?: string, options?: {recursive?: boolean}): Promise<string[]>;
56
+
57
+ /**
58
+ * Gets information from a local file from the filesystem
59
+ * @param filename file name to stat
60
+ * @param options currently unused
61
+ * @throws if filename is not in local filesystem
62
+ *
63
+ stat(filename: string, options?: object): Promise<{size: number}>;
64
+
65
+ /**
66
+ * Fetches a local file from the filesystem (or a URL)
67
+ * @param filename
68
+ * @param options
69
+ *
70
+ fetch(filename: string, options?: object): Promise<Response>;
71
+ }
72
+
73
+ type ReadOptions = {buffer?: ArrayBuffer; offset?: number; length?: number; position?: number};
74
+ export interface IRandomAccessReadFileSystem extends IFileSystem {
75
+ open(path: string, flags: string | number, mode?: any): Promise<any>;
76
+ close(fd: any): Promise<void>;
77
+ fstat(fd: any): Promise<object>;
78
+ read(fd: any, options?: ReadOptions): Promise<{bytesRead: number; buffer: Buffer}>;
79
+ }
80
+ */
81
+ //# sourceMappingURL=filesystem.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"filesystem.d.ts","sourceRoot":"","sources":["../../../src/lib/filesystems/filesystem.ts"],"names":[],"mappings":";AAEA,MAAM,MAAM,WAAW,GAAG,EAAE,CAAC;AAE7B,MAAM,MAAM,IAAI,GAAG;IACjB,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,OAAO,CAAC;CAC5B,CAAC;AAEF;;;GAGG;AACH,MAAM,WAAW,UAAU;IACzB;;;OAGG;IACH,OAAO,CAAC,OAAO,CAAC,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE;QAAC,SAAS,CAAC,EAAE,OAAO,CAAA;KAAC,GAAG,OAAO,CAAC,MAAM,EAAE,CAAC,CAAC;IAE9E;;;;;OAKG;IACH,IAAI,CAAC,QAAQ,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC;QAAC,IAAI,EAAE,MAAM,CAAA;KAAC,CAAC,CAAC;IAElE;;;;OAIG;IACH,KAAK,CAAC,QAAQ,EAAE,WAAW,EAAE,OAAO,CAAC,EAAE,WAAW,GAAG,OAAO,CAAC,QAAQ,CAAC,CAAC;CACxE;AAED;;GAEG;AACH,MAAM,WAAW,0BAA2B,SAAQ,UAAU;IAC5D,IAAI,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,OAAO,EAAE,IAAI,CAAC,EAAE,OAAO,GAAG,OAAO,CAAC,GAAG,CAAC,CAAC;IACjE,KAAK,CAAC,EAAE,EAAE,OAAO,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAClC,KAAK,CAAC,EAAE,EAAE,OAAO,GAAG,OAAO,CAAC,IAAI,CAAC,CAAC;IAClC,IAAI,CAAC,EAAE,EAAE,GAAG,EAAE,OAAO,CAAC,EAAE,WAAW,GAAG,OAAO,CAAC;QAAC,SAAS,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAA;KAAC,CAAC,CAAC;CAQpF;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAiCE"}
@@ -0,0 +1,37 @@
1
+ "use strict";
2
+ // loaders.gl, MIT license
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ /**
5
+ * A FileSystem interface can encapsulate a FileList, a ZipFile, a GoogleDrive etc.
6
+ *
7
+ export interface IFileSystem {
8
+ /**
9
+ * Return a list of file names
10
+ * @param dirname directory name. file system root directory if omitted
11
+ *
12
+ readdir(dirname?: string, options?: {recursive?: boolean}): Promise<string[]>;
13
+
14
+ /**
15
+ * Gets information from a local file from the filesystem
16
+ * @param filename file name to stat
17
+ * @param options currently unused
18
+ * @throws if filename is not in local filesystem
19
+ *
20
+ stat(filename: string, options?: object): Promise<{size: number}>;
21
+
22
+ /**
23
+ * Fetches a local file from the filesystem (or a URL)
24
+ * @param filename
25
+ * @param options
26
+ *
27
+ fetch(filename: string, options?: object): Promise<Response>;
28
+ }
29
+
30
+ type ReadOptions = {buffer?: ArrayBuffer; offset?: number; length?: number; position?: number};
31
+ export interface IRandomAccessReadFileSystem extends IFileSystem {
32
+ open(path: string, flags: string | number, mode?: any): Promise<any>;
33
+ close(fd: any): Promise<void>;
34
+ fstat(fd: any): Promise<object>;
35
+ read(fd: any, options?: ReadOptions): Promise<{bytesRead: number; buffer: Buffer}>;
36
+ }
37
+ */
@@ -1,7 +1,7 @@
1
1
  /// <reference types="node" />
2
2
  /// <reference types="node" />
3
3
  import * as fs from '../node/fs';
4
- import { IFileSystem, IRandomAccessReadFileSystem } from '../../types';
4
+ import { FileSystem, RandomAccessReadFileSystem } from './filesystem';
5
5
  type Stat = {
6
6
  size: number;
7
7
  isDirectory: () => boolean;
@@ -18,7 +18,7 @@ type ReadOptions = {
18
18
  * Compatible with BrowserFileSystem.
19
19
  * @param options
20
20
  */
21
- export default class NodeFileSystem implements IFileSystem, IRandomAccessReadFileSystem {
21
+ export declare class NodeFileSystem implements FileSystem, RandomAccessReadFileSystem {
22
22
  constructor(options: {
23
23
  [key: string]: any;
24
24
  });
@@ -1 +1 @@
1
- {"version":3,"file":"node-filesystem.d.ts","sourceRoot":"","sources":["../../../src/lib/filesystems/node-filesystem.ts"],"names":[],"mappings":";;AAAA,OAAO,KAAK,EAAE,MAAM,YAAY,CAAC;AACjC,OAAO,EAAC,WAAW,EAAE,2BAA2B,EAAC,MAAM,aAAa,CAAC;AAIrE,KAAK,IAAI,GAAG;IACV,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,OAAO,CAAC;IAC3B,IAAI,CAAC,EAAE,EAAE,CAAC,KAAK,CAAC;CACjB,CAAC;AAEF,KAAK,WAAW,GAAG;IACjB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB,CAAC;AAEF;;;;GAIG;AACH,MAAM,CAAC,OAAO,OAAO,cAAe,YAAW,WAA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W,GAAG;IACjB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB,QAAQ,CAAC,EAAE,MAAM,CAAC;CACnB,CAAC;AAEF;;;;GAIG;AACH,qBAAa,cAAe,YAAW,UAAU,EAAE,0BAA0B;gBAE/D,OAAO,EAAE;QAAC,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAA;KAAC;IAInC,OAAO,CAAC,OAAO,SAAM,EAAE,OAAO,CAAC,EAAE,EAAE,GAAG,OAAO,CAAC,GAAG,EAAE,CAAC;IAIpD,IAAI,CAAC,IAAI,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,EAAE,GAAG,OAAO,CAAC,IAAI,CAAC;IAK/C,KAAK,CAAC,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE;QAAC,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAA;KAAC;IAQjD,IAAI,CAAC,IAAI,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,GAAG,MAAM,EAAE,IAAI,CAAC,EAAE,GAAG,GAAG,OAAO,CAAC,MAAM,CAAC;IAIvE,KAAK,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;IAIhC,KAAK,CAAC,EAAE,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;IAKhC,IAAI,CACR,EAAE,EAAE,MAAM,EAEV,EAAC,MAAa,EAAE,MAAU,EAAE,MAA0B,EAAE,QAAe,EAAC,EAAE,WAAW,GACpF,OAAO,CAAC;QAAC,SAAS,EAAE,MAAM,CAAC;QAAC,MAAM,EAAE,MAAM,CAAA;KAAC,CAAC;CAehD"}
@@ -23,6 +23,7 @@ var __importStar = (this && this.__importStar) || function (mod) {
23
23
  return result;
24
24
  };
25
25
  Object.defineProperty(exports, "__esModule", { value: true });
26
+ exports.NodeFileSystem = void 0;
26
27
  const fs = __importStar(require("../node/fs"));
27
28
  /**
28
29
  * FileSystem pass-through for Node.js
@@ -30,7 +31,7 @@ const fs = __importStar(require("../node/fs"));
30
31
  * @param options
31
32
  */
32
33
  class NodeFileSystem {
33
- // implements IFileSystem
34
+ // implements FileSystem
34
35
  constructor(options) {
35
36
  this.fetch = options._fetch;
36
37
  }
@@ -70,4 +71,4 @@ class NodeFileSystem {
70
71
  return { bytesRead: totalBytesRead, buffer };
71
72
  }
72
73
  }
73
- exports.default = NodeFileSystem;
74
+ exports.NodeFileSystem = NodeFileSystem;
package/dist/types.d.ts CHANGED
@@ -1,4 +1,3 @@
1
- /// <reference types="node" />
2
1
  export type TypedIntArray = Int8Array | Uint8Array | Uint8ClampedArray | Int16Array | Uint16Array | Int32Array | Uint32Array | Int32Array | Uint32Array;
3
2
  export type TypedFloatArray = Uint16Array | Float32Array | Float64Array;
4
3
  export type TypedArray = TypedIntArray | TypedFloatArray;
@@ -16,47 +15,4 @@ export type SyncDataType = string | ArrayBuffer;
16
15
  export type DataType = string | ArrayBuffer | File | Blob | Response | ReadableStream | Iterable<ArrayBuffer> | AsyncIterable<ArrayBuffer>;
17
16
  /** Types that can be parsed in batches */
18
17
  export type BatchableDataType = DataType | Iterable<ArrayBuffer> | AsyncIterable<ArrayBuffer> | Promise<AsyncIterable<ArrayBuffer>>;
19
- /**
20
- * A FileSystem interface can encapsulate a FileList, a ZipFile, a GoogleDrive etc.
21
- */
22
- export interface IFileSystem {
23
- /**
24
- * Return a list of file names
25
- * @param dirname directory name. file system root directory if omitted
26
- */
27
- readdir(dirname?: string, options?: {
28
- recursive?: boolean;
29
- }): Promise<string[]>;
30
- /**
31
- * Gets information from a local file from the filesystem
32
- * @param filename file name to stat
33
- * @param options currently unused
34
- * @throws if filename is not in local filesystem
35
- */
36
- stat(filename: string, options?: object): Promise<{
37
- size: number;
38
- }>;
39
- /**
40
- * Fetches a local file from the filesystem (or a URL)
41
- * @param filename
42
- * @param options
43
- */
44
- fetch(filename: string, options?: object): Promise<Response>;
45
- }
46
- type ReadOptions = {
47
- buffer?: ArrayBuffer;
48
- offset?: number;
49
- length?: number;
50
- position?: number;
51
- };
52
- export interface IRandomAccessReadFileSystem extends IFileSystem {
53
- open(path: string, flags: string | number, mode?: any): Promise<any>;
54
- close(fd: any): Promise<void>;
55
- fstat(fd: any): Promise<object>;
56
- read(fd: any, options?: ReadOptions): Promise<{
57
- bytesRead: number;
58
- buffer: Buffer;
59
- }>;
60
- }
61
- export {};
62
18
  //# sourceMappingURL=types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":";AAEA,MAAM,MAAM,aAAa,GACrB,SAAS,GACT,UAAU,GACV,iBAAiB,GACjB,UAAU,GACV,WAAW,GACX,UAAU,GACV,WAAW,GACX,UAAU,GACV,WAAW,CAAC;AAEhB,MAAM,MAAM,eAAe,GAAG,WAAW,GAAG,YAAY,GAAG,YAAY,CAAC;AAExE,MAAM,MAAM,UAAU,GAAG,aAAa,GAAG,eAAe,CAAC;AAEzD,MAAM,MAAM,aAAa,GAAG,UAAU,GAAG,aAAa,GAAG,cAAc,CAAC;AAExE,MAAM,MAAM,qBAAqB,GAC7B,oBAAoB,GACpB,qBAAqB,GACrB,qBAAqB,GACrB,sBAAsB,GACtB,qBAAqB,GACrB,sBAAsB,GACtB,qBAAqB,GACrB,sBAAsB,GACtB,uBAAuB,GACvB,uBAAuB,CAAC;AAE5B,MAAM,MAAM,wBAAwB,GAChC,qBAAqB,GACrB,wBAAwB,GACxB,yBAAyB,CAAC;AAE9B,mDAAmD;AACnD,MAAM,MAAM,WAAW,GAAG,MAAM,EAAE,GAAG,UAAU,CAAC;AAEhD,MAAM,MAAM,YAAY,GAAG,MAAM,EAAE,GAAG,UAAU,CAAC;AAIjD,MAAM,MAAM,SAAS,GAAG,CAAC,GAAG,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,WAAW,KAAK,OAAO,CAAC,QAAQ,CAAC,CAAC;AA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G,MAAM,EAAE,GAAG,UAAU,CAAC;AAIjD,MAAM,MAAM,SAAS,GAAG,CAAC,GAAG,EAAE,MAAM,EAAE,OAAO,CAAC,EAAE,WAAW,KAAK,OAAO,CAAC,QAAQ,CAAC,CAAC;AAIlF,MAAM,MAAM,gBAAgB,GAAG,CAC7B,aAAa,EAAE,aAAa,CAAC,WAAW,CAAC,GAAG,QAAQ,CAAC,WAAW,CAAC,KAC9D,aAAa,CAAC,WAAW,CAAC,CAAC;AAEhC,6CAA6C;AAC7C,MAAM,MAAM,YAAY,GAAG,MAAM,GAAG,WAAW,CAAC;AAEhD,qCAAqC;AACrC,MAAM,MAAM,QAAQ,GAChB,MAAM,GACN,WAAW,GACX,IAAI,GACJ,IAAI,GACJ,QAAQ,GACR,cAAc,GACd,QAAQ,CAAC,WAAW,CAAC,GACrB,aAAa,CAAC,WAAW,CAAC,CAAC;AAE/B,0CAA0C;AAC1C,MAAM,MAAM,iBAAiB,GACzB,QAAQ,GACR,QAAQ,CAAC,WAAW,CAAC,GACrB,aAAa,CAAC,WAAW,CAAC,GAC1B,OAAO,CAAC,aAAa,CAAC,WAAW,CAAC,CAAC,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@loaders.gl/loader-utils",
3
- "version": "4.0.0-alpha.22",
3
+ "version": "4.0.0-alpha.23",
4
4
  "description": "Framework-independent loaders for 3D graphics formats",
5
5
  "license": "MIT",
6
6
  "publishConfig": {
@@ -38,8 +38,8 @@
38
38
  "scripts": {},
39
39
  "dependencies": {
40
40
  "@babel/runtime": "^7.3.1",
41
- "@loaders.gl/worker-utils": "4.0.0-alpha.22",
41
+ "@loaders.gl/worker-utils": "4.0.0-alpha.23",
42
42
  "@probe.gl/stats": "^4.0.2"
43
43
  },
44
- "gitHead": "0da838c506d1275383f2fd3d244d9c72b25397d2"
44
+ "gitHead": "e212f2a0c0e342f7cb65ce84fa2ff39f64b7d94b"
45
45
  }