@zenfs/core 0.0.3 → 0.0.4
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/ApiError.d.ts +1 -1
- package/dist/backends/AsyncMirror.d.ts +5 -5
- package/dist/backends/AsyncMirror.js +5 -5
- package/dist/backends/AsyncStore.d.ts +5 -5
- package/dist/backends/AsyncStore.js +7 -7
- package/dist/backends/FolderAdapter.d.ts +2 -2
- package/dist/backends/FolderAdapter.js +4 -4
- package/dist/backends/InMemory.d.ts +3 -3
- package/dist/backends/InMemory.js +2 -2
- package/dist/backends/Locked.d.ts +6 -6
- package/dist/backends/Locked.js +1 -1
- package/dist/backends/OverlayFS.d.ts +6 -6
- package/dist/backends/OverlayFS.js +7 -7
- package/dist/backends/SyncStore.d.ts +5 -5
- package/dist/backends/SyncStore.js +7 -7
- package/dist/backends/backend.d.ts +1 -1
- package/dist/backends/backend.js +1 -1
- package/dist/backends/index.d.ts +5 -5
- package/dist/backends/index.js +4 -4
- package/dist/browser.min.js.map +1 -1
- package/dist/emulation/callbacks.d.ts +4 -4
- package/dist/emulation/callbacks.js +4 -4
- package/dist/emulation/fs.d.ts +3 -3
- package/dist/emulation/fs.js +2 -2
- package/dist/emulation/index.d.ts +5 -5
- package/dist/emulation/index.js +5 -5
- package/dist/emulation/promises.d.ts +5 -5
- package/dist/emulation/promises.js +4 -4
- package/dist/emulation/shared.d.ts +5 -5
- package/dist/emulation/shared.js +3 -3
- package/dist/emulation/sync.d.ts +4 -4
- package/dist/emulation/sync.js +3 -3
- package/dist/file.d.ts +3 -3
- package/dist/file.js +3 -3
- package/dist/filesystem.d.ts +5 -5
- package/dist/filesystem.js +2 -2
- package/dist/index.d.ts +14 -14
- package/dist/index.js +17 -17
- package/dist/inode.d.ts +2 -2
- package/dist/inode.js +1 -1
- package/dist/stats.d.ts +3 -3
- package/dist/stats.js +2 -2
- package/dist/utils.d.ts +4 -4
- package/dist/utils.js +1 -1
- package/package.json +1 -1
package/dist/ApiError.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { type FileSystem, SynchronousFileSystem, FileSystemMetadata } from '../filesystem';
|
|
2
|
-
import { File, FileFlag, PreloadFile } from '../file';
|
|
3
|
-
import { Stats } from '../stats';
|
|
4
|
-
import { Cred } from '../cred';
|
|
5
|
-
import { type BackendOptions } from './backend';
|
|
1
|
+
import { type FileSystem, SynchronousFileSystem, FileSystemMetadata } from '../filesystem.js';
|
|
2
|
+
import { File, FileFlag, PreloadFile } from '../file.js';
|
|
3
|
+
import { Stats } from '../stats.js';
|
|
4
|
+
import { Cred } from '../cred.js';
|
|
5
|
+
import { type BackendOptions } from './backend.js';
|
|
6
6
|
export declare namespace AsyncMirror {
|
|
7
7
|
/**
|
|
8
8
|
* Configuration options for the AsyncMirror file system.
|
|
@@ -8,12 +8,12 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
8
8
|
});
|
|
9
9
|
};
|
|
10
10
|
var _a;
|
|
11
|
-
import { SynchronousFileSystem } from '../filesystem';
|
|
12
|
-
import { ApiError, ErrorCode } from '../ApiError';
|
|
13
|
-
import { FileFlag, PreloadFile } from '../file';
|
|
11
|
+
import { SynchronousFileSystem } from '../filesystem.js';
|
|
12
|
+
import { ApiError, ErrorCode } from '../ApiError.js';
|
|
13
|
+
import { FileFlag, PreloadFile } from '../file.js';
|
|
14
14
|
import * as path from 'path';
|
|
15
|
-
import { Cred } from '../cred';
|
|
16
|
-
import { CreateBackend } from './backend';
|
|
15
|
+
import { Cred } from '../cred.js';
|
|
16
|
+
import { CreateBackend } from './backend.js';
|
|
17
17
|
/**
|
|
18
18
|
* We define our own file to interpose on syncSync() for mirroring purposes.
|
|
19
19
|
*/
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
/// <reference types="node" />
|
|
2
|
-
import { Cred } from '../cred';
|
|
3
|
-
import { PreloadFile, File, FileFlag } from '../file';
|
|
4
|
-
import { BaseFileSystem } from '../filesystem';
|
|
5
|
-
import { Stats } from '../stats';
|
|
1
|
+
/// <reference types="node" resolution-mode="require"/>
|
|
2
|
+
import { Cred } from '../cred.js';
|
|
3
|
+
import { PreloadFile, File, FileFlag } from '../file.js';
|
|
4
|
+
import { BaseFileSystem } from '../filesystem.js';
|
|
5
|
+
import { Stats } from '../stats.js';
|
|
6
6
|
/**
|
|
7
7
|
* Represents an *asynchronous* key-value store.
|
|
8
8
|
*/
|
|
@@ -8,13 +8,13 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
8
8
|
});
|
|
9
9
|
};
|
|
10
10
|
import * as path from 'path';
|
|
11
|
-
import { ApiError, ErrorCode } from '../ApiError';
|
|
12
|
-
import { W_OK, R_OK } from '../emulation/constants';
|
|
13
|
-
import { PreloadFile, FileFlag } from '../file';
|
|
14
|
-
import { BaseFileSystem } from '../filesystem';
|
|
15
|
-
import Inode from '../inode';
|
|
16
|
-
import { FileType } from '../stats';
|
|
17
|
-
import { ROOT_NODE_ID, randomUUID, getEmptyDirNode } from '../utils';
|
|
11
|
+
import { ApiError, ErrorCode } from '../ApiError.js';
|
|
12
|
+
import { W_OK, R_OK } from '../emulation/constants.js';
|
|
13
|
+
import { PreloadFile, FileFlag } from '../file.js';
|
|
14
|
+
import { BaseFileSystem } from '../filesystem.js';
|
|
15
|
+
import Inode from '../inode.js';
|
|
16
|
+
import { FileType } from '../stats.js';
|
|
17
|
+
import { ROOT_NODE_ID, randomUUID, getEmptyDirNode } from '../utils.js';
|
|
18
18
|
class LRUNode {
|
|
19
19
|
constructor(key, value) {
|
|
20
20
|
this.key = key;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { BaseFileSystem, type FileSystem } from '../filesystem';
|
|
2
|
-
import { type BackendOptions } from './backend';
|
|
1
|
+
import { BaseFileSystem, type FileSystem } from '../filesystem.js';
|
|
2
|
+
import { type BackendOptions } from './backend.js';
|
|
3
3
|
export declare namespace FolderAdapter {
|
|
4
4
|
/**
|
|
5
5
|
* Configuration options for a FolderAdapter file system.
|
|
@@ -8,11 +8,11 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
8
8
|
});
|
|
9
9
|
};
|
|
10
10
|
var _a;
|
|
11
|
-
import { BaseFileSystem } from '../filesystem';
|
|
11
|
+
import { BaseFileSystem } from '../filesystem.js';
|
|
12
12
|
import * as path from 'path';
|
|
13
|
-
import { ApiError } from '../ApiError';
|
|
14
|
-
import { Cred } from '../cred';
|
|
15
|
-
import { CreateBackend } from './backend';
|
|
13
|
+
import { ApiError } from '../ApiError.js';
|
|
14
|
+
import { Cred } from '../cred.js';
|
|
15
|
+
import { CreateBackend } from './backend.js';
|
|
16
16
|
/**
|
|
17
17
|
* The FolderAdapter file system wraps a file system, and scopes all interactions to a subfolder of that file system.
|
|
18
18
|
*
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
/// <reference types="node" />
|
|
2
|
-
import { SyncKeyValueStore, SimpleSyncStore, SyncKeyValueRWTransaction, SyncKeyValueFileSystem } from './SyncStore';
|
|
3
|
-
import { type BackendOptions } from './backend';
|
|
1
|
+
/// <reference types="node" resolution-mode="require"/>
|
|
2
|
+
import { SyncKeyValueStore, SimpleSyncStore, SyncKeyValueRWTransaction, SyncKeyValueFileSystem } from './SyncStore.js';
|
|
3
|
+
import { type BackendOptions } from './backend.js';
|
|
4
4
|
/**
|
|
5
5
|
* A simple in-memory key-value store backed by a JavaScript object.
|
|
6
6
|
*/
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
var _a;
|
|
2
|
-
import { SimpleSyncRWTransaction, SyncKeyValueFileSystem } from './SyncStore';
|
|
3
|
-
import { CreateBackend } from './backend';
|
|
2
|
+
import { SimpleSyncRWTransaction, SyncKeyValueFileSystem } from './SyncStore.js';
|
|
3
|
+
import { CreateBackend } from './backend.js';
|
|
4
4
|
/**
|
|
5
5
|
* A simple in-memory key-value store backed by a JavaScript object.
|
|
6
6
|
*/
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
/// <reference types="node" />
|
|
2
|
-
import { FileContents, FileSystem, FileSystemMetadata } from '../filesystem';
|
|
3
|
-
import { FileFlag } from '../file';
|
|
4
|
-
import { Stats } from '../stats';
|
|
5
|
-
import { File } from '../file';
|
|
6
|
-
import { Cred } from '../cred';
|
|
1
|
+
/// <reference types="node" resolution-mode="require"/>
|
|
2
|
+
import { FileContents, FileSystem, FileSystemMetadata } from '../filesystem.js';
|
|
3
|
+
import { FileFlag } from '../file.js';
|
|
4
|
+
import { Stats } from '../stats.js';
|
|
5
|
+
import { File } from '../file.js';
|
|
6
|
+
import { Cred } from '../cred.js';
|
|
7
7
|
/**
|
|
8
8
|
* This class serializes access to an underlying async filesystem.
|
|
9
9
|
* For example, on an OverlayFS instance with an async lower
|
package/dist/backends/Locked.js
CHANGED
|
@@ -7,7 +7,7 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
7
7
|
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
8
8
|
});
|
|
9
9
|
};
|
|
10
|
-
import Mutex from '../mutex';
|
|
10
|
+
import Mutex from '../mutex.js';
|
|
11
11
|
/**
|
|
12
12
|
* This class serializes access to an underlying async filesystem.
|
|
13
13
|
* For example, on an OverlayFS instance with an async lower
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { type FileSystem, BaseFileSystem, FileSystemMetadata } from '../filesystem';
|
|
2
|
-
import { File, FileFlag, PreloadFile } from '../file';
|
|
3
|
-
import { Stats } from '../stats';
|
|
4
|
-
import LockedFS from './Locked';
|
|
5
|
-
import { Cred } from '../cred';
|
|
6
|
-
import { type BackendOptions } from './backend';
|
|
1
|
+
import { type FileSystem, BaseFileSystem, FileSystemMetadata } from '../filesystem.js';
|
|
2
|
+
import { File, FileFlag, PreloadFile } from '../file.js';
|
|
3
|
+
import { Stats } from '../stats.js';
|
|
4
|
+
import LockedFS from './Locked.js';
|
|
5
|
+
import { Cred } from '../cred.js';
|
|
6
|
+
import { type BackendOptions } from './backend.js';
|
|
7
7
|
export declare namespace OverlayFS {
|
|
8
8
|
/**
|
|
9
9
|
* Configuration options for OverlayFS instances.
|
|
@@ -8,14 +8,14 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, ge
|
|
|
8
8
|
});
|
|
9
9
|
};
|
|
10
10
|
var _a;
|
|
11
|
-
import { BaseFileSystem } from '../filesystem';
|
|
12
|
-
import { ApiError, ErrorCode } from '../ApiError';
|
|
13
|
-
import { FileFlag, ActionType, PreloadFile } from '../file';
|
|
14
|
-
import { Stats } from '../stats';
|
|
15
|
-
import LockedFS from './Locked';
|
|
11
|
+
import { BaseFileSystem } from '../filesystem.js';
|
|
12
|
+
import { ApiError, ErrorCode } from '../ApiError.js';
|
|
13
|
+
import { FileFlag, ActionType, PreloadFile } from '../file.js';
|
|
14
|
+
import { Stats } from '../stats.js';
|
|
15
|
+
import LockedFS from './Locked.js';
|
|
16
16
|
import * as path from 'path';
|
|
17
|
-
import { Cred } from '../cred';
|
|
18
|
-
import { CreateBackend } from './backend';
|
|
17
|
+
import { Cred } from '../cred.js';
|
|
18
|
+
import { CreateBackend } from './backend.js';
|
|
19
19
|
/**
|
|
20
20
|
* @internal
|
|
21
21
|
*/
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
/// <reference types="node" />
|
|
2
|
-
import { Cred } from '../cred';
|
|
3
|
-
import { File, FileFlag, PreloadFile } from '../file';
|
|
4
|
-
import { SynchronousFileSystem } from '../filesystem';
|
|
5
|
-
import { Stats } from '../stats';
|
|
1
|
+
/// <reference types="node" resolution-mode="require"/>
|
|
2
|
+
import { Cred } from '../cred.js';
|
|
3
|
+
import { File, FileFlag, PreloadFile } from '../file.js';
|
|
4
|
+
import { SynchronousFileSystem } from '../filesystem.js';
|
|
5
|
+
import { Stats } from '../stats.js';
|
|
6
6
|
/**
|
|
7
7
|
* Represents a *synchronous* key-value store.
|
|
8
8
|
*/
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import * as path from 'path';
|
|
2
|
-
import { ApiError, ErrorCode } from '../ApiError';
|
|
3
|
-
import { W_OK, R_OK } from '../emulation/constants';
|
|
4
|
-
import { FileFlag, PreloadFile } from '../file';
|
|
5
|
-
import { SynchronousFileSystem } from '../filesystem';
|
|
6
|
-
import Inode from '../inode';
|
|
7
|
-
import { FileType } from '../stats';
|
|
8
|
-
import { randomUUID, getEmptyDirNode, ROOT_NODE_ID } from '../utils';
|
|
2
|
+
import { ApiError, ErrorCode } from '../ApiError.js';
|
|
3
|
+
import { W_OK, R_OK } from '../emulation/constants.js';
|
|
4
|
+
import { FileFlag, PreloadFile } from '../file.js';
|
|
5
|
+
import { SynchronousFileSystem } from '../filesystem.js';
|
|
6
|
+
import Inode from '../inode.js';
|
|
7
|
+
import { FileType } from '../stats.js';
|
|
8
|
+
import { randomUUID, getEmptyDirNode, ROOT_NODE_ID } from '../utils.js';
|
|
9
9
|
/**
|
|
10
10
|
* A simple RW transaction for simple synchronous key-value stores.
|
|
11
11
|
*/
|
package/dist/backends/backend.js
CHANGED
package/dist/backends/index.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { AsyncMirror } from './AsyncMirror';
|
|
2
|
-
import { FolderAdapter } from './FolderAdapter';
|
|
3
|
-
import { InMemoryFileSystem as InMemory } from './InMemory';
|
|
4
|
-
import { OverlayFS } from './OverlayFS';
|
|
5
|
-
import { BackendConstructor } from './backend';
|
|
1
|
+
import { AsyncMirror } from './AsyncMirror.js';
|
|
2
|
+
import { FolderAdapter } from './FolderAdapter.js';
|
|
3
|
+
import { InMemoryFileSystem as InMemory } from './InMemory.js';
|
|
4
|
+
import { OverlayFS } from './OverlayFS.js';
|
|
5
|
+
import { BackendConstructor } from './backend.js';
|
|
6
6
|
export declare const backends: {
|
|
7
7
|
[backend: string]: BackendConstructor;
|
|
8
8
|
};
|
package/dist/backends/index.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { AsyncMirror } from './AsyncMirror';
|
|
2
|
-
import { FolderAdapter } from './FolderAdapter';
|
|
3
|
-
import { InMemoryFileSystem as InMemory } from './InMemory';
|
|
4
|
-
import { OverlayFS } from './OverlayFS';
|
|
1
|
+
import { AsyncMirror } from './AsyncMirror.js';
|
|
2
|
+
import { FolderAdapter } from './FolderAdapter.js';
|
|
3
|
+
import { InMemoryFileSystem as InMemory } from './InMemory.js';
|
|
4
|
+
import { OverlayFS } from './OverlayFS.js';
|
|
5
5
|
export const backends = {};
|
|
6
6
|
export default backends;
|
|
7
7
|
export { AsyncMirror, FolderAdapter, InMemory, OverlayFS };
|