xitdb 0.1.0 → 0.2.0

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 (63) hide show
  1. package/dist/core-buffered-file.d.ts +41 -0
  2. package/dist/core-file.d.ts +18 -0
  3. package/dist/core-memory.d.ts +36 -0
  4. package/dist/core.d.ts +23 -0
  5. package/dist/database.d.ts +244 -0
  6. package/dist/exceptions.d.ts +51 -0
  7. package/dist/hasher.d.ts +9 -0
  8. package/dist/index.d.ts +26 -0
  9. package/dist/index.js +429 -266
  10. package/dist/read-array-list.d.ts +13 -0
  11. package/dist/read-counted-hash-map.d.ts +7 -0
  12. package/dist/read-counted-hash-set.d.ts +7 -0
  13. package/dist/read-cursor.d.ts +57 -0
  14. package/dist/read-hash-map.d.ts +27 -0
  15. package/dist/read-hash-set.d.ts +18 -0
  16. package/dist/read-linked-array-list.d.ts +13 -0
  17. package/dist/slot-pointer.d.ts +7 -0
  18. package/dist/slot.d.ts +15 -0
  19. package/{src/slotted.ts → dist/slotted.d.ts} +1 -2
  20. package/dist/tag.d.ts +17 -0
  21. package/dist/write-array-list.d.ts +16 -0
  22. package/dist/write-counted-hash-map.d.ts +7 -0
  23. package/dist/write-counted-hash-set.d.ts +7 -0
  24. package/dist/write-cursor.d.ts +36 -0
  25. package/dist/write-hash-map.d.ts +25 -0
  26. package/dist/write-hash-set.d.ts +19 -0
  27. package/dist/write-linked-array-list.d.ts +19 -0
  28. package/dist/writeable-data.d.ts +20 -0
  29. package/package.json +12 -1
  30. package/.claude/settings.local.json +0 -9
  31. package/bun.lock +0 -24
  32. package/bunfig.toml +0 -1
  33. package/example/README.md +0 -46
  34. package/example/dump.ts +0 -201
  35. package/src/core-buffered-file.ts +0 -226
  36. package/src/core-file.ts +0 -137
  37. package/src/core-memory.ts +0 -179
  38. package/src/core.ts +0 -25
  39. package/src/database.ts +0 -2232
  40. package/src/exceptions.ts +0 -31
  41. package/src/hasher.ts +0 -52
  42. package/src/index.ts +0 -110
  43. package/src/read-array-list.ts +0 -45
  44. package/src/read-counted-hash-map.ts +0 -28
  45. package/src/read-counted-hash-set.ts +0 -28
  46. package/src/read-cursor.ts +0 -546
  47. package/src/read-hash-map.ts +0 -117
  48. package/src/read-hash-set.ts +0 -70
  49. package/src/read-linked-array-list.ts +0 -45
  50. package/src/slot-pointer.ts +0 -15
  51. package/src/slot.ts +0 -51
  52. package/src/tag.ts +0 -23
  53. package/src/write-array-list.ts +0 -65
  54. package/src/write-counted-hash-map.ts +0 -31
  55. package/src/write-counted-hash-set.ts +0 -31
  56. package/src/write-cursor.ts +0 -166
  57. package/src/write-hash-map.ts +0 -129
  58. package/src/write-hash-set.ts +0 -86
  59. package/src/write-linked-array-list.ts +0 -80
  60. package/src/writeable-data.ts +0 -67
  61. package/tests/database.test.ts +0 -2519
  62. package/tests/fixtures/test.db +0 -0
  63. package/tsconfig.json +0 -17
@@ -0,0 +1,13 @@
1
+ import { Slot } from './slot';
2
+ import type { Slotted } from './slotted';
3
+ import { ReadCursor, CursorIterator } from './read-cursor';
4
+ export declare class ReadArrayList implements Slotted {
5
+ cursor: ReadCursor;
6
+ constructor(cursor: ReadCursor);
7
+ slot(): Slot;
8
+ count(): Promise<number>;
9
+ iterator(): CursorIterator;
10
+ [Symbol.asyncIterator](): AsyncIterator<ReadCursor>;
11
+ getCursor(index: number): Promise<ReadCursor | null>;
12
+ getSlot(index: number): Promise<Slot | null>;
13
+ }
@@ -0,0 +1,7 @@
1
+ import { ReadHashMap } from './read-hash-map';
2
+ import { ReadCursor } from './read-cursor';
3
+ export declare class ReadCountedHashMap extends ReadHashMap {
4
+ protected constructor();
5
+ static create(cursor: ReadCursor): Promise<ReadCountedHashMap>;
6
+ count(): Promise<number>;
7
+ }
@@ -0,0 +1,7 @@
1
+ import { ReadHashSet } from './read-hash-set';
2
+ import { ReadCursor } from './read-cursor';
3
+ export declare class ReadCountedHashSet extends ReadHashSet {
4
+ protected constructor();
5
+ static create(cursor: ReadCursor): Promise<ReadCountedHashSet>;
6
+ count(): Promise<number>;
7
+ }
@@ -0,0 +1,57 @@
1
+ import { Slot } from './slot';
2
+ import { SlotPointer } from './slot-pointer';
3
+ import type { Slotted } from './slotted';
4
+ import { Database, type PathPart } from './database';
5
+ import { Bytes } from './writeable-data';
6
+ export declare class KeyValuePairCursor {
7
+ valueCursor: ReadCursor;
8
+ keyCursor: ReadCursor;
9
+ hash: Uint8Array;
10
+ constructor(valueCursor: ReadCursor, keyCursor: ReadCursor, hash: Uint8Array);
11
+ }
12
+ export declare class ReadCursor implements Slotted {
13
+ slotPtr: SlotPointer;
14
+ db: Database;
15
+ constructor(slotPtr: SlotPointer, db: Database);
16
+ slot(): Slot;
17
+ readPath(path: PathPart[]): Promise<ReadCursor | null>;
18
+ readPathSlot(path: PathPart[]): Promise<Slot | null>;
19
+ readUint(): number;
20
+ readInt(): number;
21
+ readFloat(): number;
22
+ readBytes(maxSizeMaybe?: number | null): Promise<Uint8Array>;
23
+ readBytesObject(maxSizeMaybe?: number | null): Promise<Bytes>;
24
+ readKeyValuePair(): Promise<KeyValuePairCursor>;
25
+ reader(): Promise<Reader>;
26
+ count(): Promise<number>;
27
+ [Symbol.asyncIterator](): AsyncIterator<ReadCursor>;
28
+ iterator(): CursorIterator;
29
+ }
30
+ export declare class Reader {
31
+ parent: ReadCursor;
32
+ size: number;
33
+ startPosition: number;
34
+ relativePosition: number;
35
+ constructor(parent: ReadCursor, size: number, startPosition: number, relativePosition: number);
36
+ read(buffer: Uint8Array): Promise<number>;
37
+ readFully(buffer: Uint8Array): Promise<void>;
38
+ readByte(): Promise<number>;
39
+ readShort(): Promise<number>;
40
+ readInt(): Promise<number>;
41
+ readLong(): Promise<number>;
42
+ seek(position: number): void;
43
+ }
44
+ export declare class CursorIterator {
45
+ cursor: ReadCursor;
46
+ size: number;
47
+ index: number;
48
+ private stack;
49
+ private nextCursorMaybe;
50
+ private initialized;
51
+ constructor(cursor: ReadCursor);
52
+ init(): Promise<void>;
53
+ private initStack;
54
+ hasNext(): Promise<boolean>;
55
+ next(): Promise<ReadCursor | null>;
56
+ private nextInternal;
57
+ }
@@ -0,0 +1,27 @@
1
+ import { Slot } from './slot';
2
+ import type { Slotted } from './slotted';
3
+ import { ReadCursor, CursorIterator, KeyValuePairCursor } from './read-cursor';
4
+ import { Bytes } from './writeable-data';
5
+ export declare class ReadHashMap implements Slotted {
6
+ cursor: ReadCursor;
7
+ protected constructor();
8
+ static create(cursor: ReadCursor): Promise<ReadHashMap>;
9
+ slot(): Slot;
10
+ iterator(): CursorIterator;
11
+ [Symbol.asyncIterator](): AsyncIterator<ReadCursor>;
12
+ getCursorByString(key: string): Promise<ReadCursor | null>;
13
+ getSlotByString(key: string): Promise<Slot | null>;
14
+ getKeyCursorByString(key: string): Promise<ReadCursor | null>;
15
+ getKeySlotByString(key: string): Promise<Slot | null>;
16
+ getKeyValuePairByString(key: string): Promise<KeyValuePairCursor | null>;
17
+ getCursorByBytes(key: Bytes): Promise<ReadCursor | null>;
18
+ getSlotByBytes(key: Bytes): Promise<Slot | null>;
19
+ getKeyCursorByBytes(key: Bytes): Promise<ReadCursor | null>;
20
+ getKeySlotByBytes(key: Bytes): Promise<Slot | null>;
21
+ getKeyValuePairByBytes(key: Bytes): Promise<KeyValuePairCursor | null>;
22
+ getCursor(hash: Uint8Array): Promise<ReadCursor | null>;
23
+ getSlot(hash: Uint8Array): Promise<Slot | null>;
24
+ getKeyCursor(hash: Uint8Array): Promise<ReadCursor | null>;
25
+ getKeySlot(hash: Uint8Array): Promise<Slot | null>;
26
+ getKeyValuePair(hash: Uint8Array): Promise<KeyValuePairCursor | null>;
27
+ }
@@ -0,0 +1,18 @@
1
+ import { Slot } from './slot';
2
+ import type { Slotted } from './slotted';
3
+ import { ReadCursor, CursorIterator } from './read-cursor';
4
+ import { Bytes } from './writeable-data';
5
+ export declare class ReadHashSet implements Slotted {
6
+ cursor: ReadCursor;
7
+ protected constructor();
8
+ static create(cursor: ReadCursor): Promise<ReadHashSet>;
9
+ slot(): Slot;
10
+ iterator(): CursorIterator;
11
+ [Symbol.asyncIterator](): AsyncIterator<ReadCursor>;
12
+ getCursorByString(key: string): Promise<ReadCursor | null>;
13
+ getSlotByString(key: string): Promise<Slot | null>;
14
+ getCursorByBytes(key: Bytes): Promise<ReadCursor | null>;
15
+ getSlotByBytes(key: Bytes): Promise<Slot | null>;
16
+ getCursor(hash: Uint8Array): Promise<ReadCursor | null>;
17
+ getSlot(hash: Uint8Array): Promise<Slot | null>;
18
+ }
@@ -0,0 +1,13 @@
1
+ import { Slot } from './slot';
2
+ import type { Slotted } from './slotted';
3
+ import { ReadCursor, CursorIterator } from './read-cursor';
4
+ export declare class ReadLinkedArrayList implements Slotted {
5
+ cursor: ReadCursor;
6
+ constructor(cursor: ReadCursor);
7
+ slot(): Slot;
8
+ count(): Promise<number>;
9
+ iterator(): CursorIterator;
10
+ [Symbol.asyncIterator](): AsyncIterator<ReadCursor>;
11
+ getCursor(index: number): Promise<ReadCursor | null>;
12
+ getSlot(index: number): Promise<Slot | null>;
13
+ }
@@ -0,0 +1,7 @@
1
+ import { Slot } from './slot';
2
+ export declare class SlotPointer {
3
+ readonly position: number | null;
4
+ readonly slot: Slot;
5
+ constructor(position: number | null, slot: Slot);
6
+ withSlot(slot: Slot): SlotPointer;
7
+ }
package/dist/slot.d.ts ADDED
@@ -0,0 +1,15 @@
1
+ import { Tag } from './tag';
2
+ import type { WriteableData } from './writeable-data';
3
+ export declare class Slot implements WriteableData {
4
+ static readonly LENGTH = 9;
5
+ readonly value: bigint;
6
+ readonly tag: Tag;
7
+ readonly full: boolean;
8
+ constructor(value?: number | bigint, tag?: Tag, full?: boolean);
9
+ withTag(tag: Tag): Slot;
10
+ withFull(full: boolean): Slot;
11
+ empty(): boolean;
12
+ toBytes(): Uint8Array;
13
+ static fromBytes(bytes: Uint8Array): Slot;
14
+ equals(other: Slot): boolean;
15
+ }
@@ -1,5 +1,4 @@
1
1
  import type { Slot } from './slot';
2
-
3
2
  export interface Slotted {
4
- slot(): Slot;
3
+ slot(): Slot;
5
4
  }
package/dist/tag.d.ts ADDED
@@ -0,0 +1,17 @@
1
+ export declare const enum Tag {
2
+ NONE = 0,
3
+ INDEX = 1,
4
+ ARRAY_LIST = 2,
5
+ LINKED_ARRAY_LIST = 3,
6
+ HASH_MAP = 4,
7
+ KV_PAIR = 5,
8
+ BYTES = 6,
9
+ SHORT_BYTES = 7,
10
+ UINT = 8,
11
+ INT = 9,
12
+ FLOAT = 10,
13
+ HASH_SET = 11,
14
+ COUNTED_HASH_MAP = 12,
15
+ COUNTED_HASH_SET = 13
16
+ }
17
+ export declare function tagValueOf(n: number): Tag;
@@ -0,0 +1,16 @@
1
+ import { ReadArrayList } from './read-array-list';
2
+ import { WriteCursor, WriteCursorIterator } from './write-cursor';
3
+ import { type ContextFunction } from './database';
4
+ import type { WriteableData } from './writeable-data';
5
+ export declare class WriteArrayList extends ReadArrayList {
6
+ constructor(cursor: WriteCursor);
7
+ static create(cursor: WriteCursor): Promise<WriteArrayList>;
8
+ iterator(): WriteCursorIterator;
9
+ [Symbol.asyncIterator](): AsyncIterator<WriteCursor>;
10
+ put(index: number, data: WriteableData): Promise<void>;
11
+ putCursor(index: number): Promise<WriteCursor>;
12
+ append(data: WriteableData): Promise<void>;
13
+ appendCursor(): Promise<WriteCursor>;
14
+ appendContext(data: WriteableData | null, fn: ContextFunction): Promise<void>;
15
+ slice(size: number): Promise<void>;
16
+ }
@@ -0,0 +1,7 @@
1
+ import { WriteHashMap } from './write-hash-map';
2
+ import { WriteCursor } from './write-cursor';
3
+ export declare class WriteCountedHashMap extends WriteHashMap {
4
+ protected constructor();
5
+ static create(cursor: WriteCursor): Promise<WriteCountedHashMap>;
6
+ count(): Promise<number>;
7
+ }
@@ -0,0 +1,7 @@
1
+ import { WriteHashSet } from './write-hash-set';
2
+ import { WriteCursor } from './write-cursor';
3
+ export declare class WriteCountedHashSet extends WriteHashSet {
4
+ protected constructor();
5
+ static create(cursor: WriteCursor): Promise<WriteCountedHashSet>;
6
+ count(): Promise<number>;
7
+ }
@@ -0,0 +1,36 @@
1
+ import { Slot } from './slot';
2
+ import { SlotPointer } from './slot-pointer';
3
+ import { Database, type PathPart } from './database';
4
+ import { ReadCursor, KeyValuePairCursor, CursorIterator } from './read-cursor';
5
+ import type { WriteableData } from './writeable-data';
6
+ export declare class WriteKeyValuePairCursor extends KeyValuePairCursor {
7
+ valueCursor: WriteCursor;
8
+ keyCursor: WriteCursor;
9
+ constructor(valueCursor: WriteCursor, keyCursor: WriteCursor, hash: Uint8Array);
10
+ }
11
+ export declare class WriteCursor extends ReadCursor {
12
+ constructor(slotPtr: SlotPointer, db: Database);
13
+ writePath(path: PathPart[]): Promise<WriteCursor>;
14
+ write(data: WriteableData | null): Promise<void>;
15
+ writeIfEmpty(data: WriteableData): Promise<void>;
16
+ readKeyValuePair(): Promise<WriteKeyValuePairCursor>;
17
+ writer(): Promise<Writer>;
18
+ [Symbol.asyncIterator](): AsyncIterator<WriteCursor>;
19
+ iterator(): WriteCursorIterator;
20
+ }
21
+ export declare class Writer {
22
+ parent: WriteCursor;
23
+ size: number;
24
+ slot: Slot;
25
+ startPosition: number;
26
+ relativePosition: number;
27
+ formatTag: Uint8Array | null;
28
+ constructor(parent: WriteCursor, size: number, slot: Slot, startPosition: number, relativePosition: number);
29
+ write(buffer: Uint8Array): Promise<void>;
30
+ finish(): Promise<void>;
31
+ seek(position: number): void;
32
+ }
33
+ export declare class WriteCursorIterator extends CursorIterator {
34
+ constructor(cursor: WriteCursor);
35
+ next(): Promise<WriteCursor | null>;
36
+ }
@@ -0,0 +1,25 @@
1
+ import { ReadHashMap } from './read-hash-map';
2
+ import { WriteCursor, WriteCursorIterator } from './write-cursor';
3
+ import type { WriteableData } from './writeable-data';
4
+ import { Bytes } from './writeable-data';
5
+ export declare class WriteHashMap extends ReadHashMap {
6
+ protected constructor();
7
+ static create(cursor: WriteCursor): Promise<WriteHashMap>;
8
+ iterator(): WriteCursorIterator;
9
+ [Symbol.asyncIterator](): AsyncIterator<WriteCursor>;
10
+ putByString(key: string, data: WriteableData): Promise<void>;
11
+ putCursorByString(key: string): Promise<WriteCursor>;
12
+ putKeyByString(key: string, data: WriteableData): Promise<void>;
13
+ putKeyCursorByString(key: string): Promise<WriteCursor>;
14
+ removeByString(key: string): Promise<boolean>;
15
+ putByBytes(key: Bytes, data: WriteableData): Promise<void>;
16
+ putCursorByBytes(key: Bytes): Promise<WriteCursor>;
17
+ putKeyByBytes(key: Bytes, data: WriteableData): Promise<void>;
18
+ putKeyCursorByBytes(key: Bytes): Promise<WriteCursor>;
19
+ removeByBytes(key: Bytes): Promise<boolean>;
20
+ put(hash: Uint8Array, data: WriteableData): Promise<void>;
21
+ putCursor(hash: Uint8Array): Promise<WriteCursor>;
22
+ putKey(hash: Uint8Array, data: WriteableData): Promise<void>;
23
+ putKeyCursor(hash: Uint8Array): Promise<WriteCursor>;
24
+ remove(hash: Uint8Array): Promise<boolean>;
25
+ }
@@ -0,0 +1,19 @@
1
+ import { ReadHashSet } from './read-hash-set';
2
+ import { WriteCursor, WriteCursorIterator } from './write-cursor';
3
+ import type { WriteableData } from './writeable-data';
4
+ import { Bytes } from './writeable-data';
5
+ export declare class WriteHashSet extends ReadHashSet {
6
+ protected constructor();
7
+ static create(cursor: WriteCursor): Promise<WriteHashSet>;
8
+ iterator(): WriteCursorIterator;
9
+ [Symbol.asyncIterator](): AsyncIterator<WriteCursor>;
10
+ putByString(key: string): Promise<void>;
11
+ putCursorByString(key: string): Promise<WriteCursor>;
12
+ removeByString(key: string): Promise<boolean>;
13
+ putByBytes(key: Bytes): Promise<void>;
14
+ putCursorByBytes(key: Bytes): Promise<WriteCursor>;
15
+ removeByBytes(key: Bytes): Promise<boolean>;
16
+ put(hash: Uint8Array, data: WriteableData): Promise<void>;
17
+ putCursor(hash: Uint8Array): Promise<WriteCursor>;
18
+ remove(hash: Uint8Array): Promise<boolean>;
19
+ }
@@ -0,0 +1,19 @@
1
+ import { Slot } from './slot';
2
+ import { ReadLinkedArrayList } from './read-linked-array-list';
3
+ import { WriteCursor, WriteCursorIterator } from './write-cursor';
4
+ import type { WriteableData } from './writeable-data';
5
+ export declare class WriteLinkedArrayList extends ReadLinkedArrayList {
6
+ constructor(cursor: WriteCursor);
7
+ static create(cursor: WriteCursor): Promise<WriteLinkedArrayList>;
8
+ iterator(): WriteCursorIterator;
9
+ [Symbol.asyncIterator](): AsyncIterator<WriteCursor>;
10
+ put(index: number, data: WriteableData): Promise<void>;
11
+ putCursor(index: number): Promise<WriteCursor>;
12
+ append(data: WriteableData): Promise<void>;
13
+ appendCursor(): Promise<WriteCursor>;
14
+ slice(offset: number, size: number): Promise<void>;
15
+ concat(list: Slot): Promise<void>;
16
+ insert(index: number, data: WriteableData): Promise<void>;
17
+ insertCursor(index: number): Promise<WriteCursor>;
18
+ remove(index: number): Promise<void>;
19
+ }
@@ -0,0 +1,20 @@
1
+ export interface WriteableData {
2
+ }
3
+ export declare class Uint implements WriteableData {
4
+ readonly value: number;
5
+ constructor(value: number);
6
+ }
7
+ export declare class Int implements WriteableData {
8
+ readonly value: number;
9
+ constructor(value: number);
10
+ }
11
+ export declare class Float implements WriteableData {
12
+ readonly value: number;
13
+ constructor(value: number);
14
+ }
15
+ export declare class Bytes implements WriteableData {
16
+ readonly value: Uint8Array;
17
+ readonly formatTag: Uint8Array | null;
18
+ constructor(value: Uint8Array | string, formatTag?: Uint8Array | string | null);
19
+ isShort(): boolean;
20
+ }
package/package.json CHANGED
@@ -1,12 +1,23 @@
1
1
  {
2
2
  "name": "xitdb",
3
- "version": "0.1.0",
3
+ "version": "0.2.0",
4
4
  "type": "module",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
7
+ "exports": {
8
+ ".": {
9
+ "types": "./dist/index.d.ts",
10
+ "import": "./dist/index.js",
11
+ "default": "./dist/index.js"
12
+ }
13
+ },
14
+ "files": [
15
+ "dist"
16
+ ],
7
17
  "scripts": {
8
18
  "build": "bun build ./src/index.ts --outdir ./dist --target bun",
9
19
  "build:types": "tsc --emitDeclarationOnly",
20
+ "prepublishOnly": "bun run build && bun run build:types",
10
21
  "test": "bun test",
11
22
  "typecheck": "tsc --noEmit"
12
23
  },
@@ -1,9 +0,0 @@
1
- {
2
- "permissions": {
3
- "allow": [
4
- "Bash(bun test:*)",
5
- "Bash(bun run tsc:*)",
6
- "Bash(bunx tsc:*)"
7
- ]
8
- }
9
- }
package/bun.lock DELETED
@@ -1,24 +0,0 @@
1
- {
2
- "lockfileVersion": 1,
3
- "configVersion": 1,
4
- "workspaces": {
5
- "": {
6
- "name": "xitdb",
7
- "devDependencies": {
8
- "@types/bun": "latest",
9
- "typescript": "^5.3.0",
10
- },
11
- },
12
- },
13
- "packages": {
14
- "@types/bun": ["@types/bun@1.3.6", "", { "dependencies": { "bun-types": "1.3.6" } }, "sha512-uWCv6FO/8LcpREhenN1d1b6fcspAB+cefwD7uti8C8VffIv0Um08TKMn98FynpTiU38+y2dUO55T11NgDt8VAA=="],
15
-
16
- "@types/node": ["@types/node@25.0.9", "", { "dependencies": { "undici-types": "~7.16.0" } }, "sha512-/rpCXHlCWeqClNBwUhDcusJxXYDjZTyE8v5oTO7WbL8eij2nKhUeU89/6xgjU7N4/Vh3He0BtyhJdQbDyhiXAw=="],
17
-
18
- "bun-types": ["bun-types@1.3.6", "", { "dependencies": { "@types/node": "*" } }, "sha512-OlFwHcnNV99r//9v5IIOgQ9Uk37gZqrNMCcqEaExdkVq3Avwqok1bJFmvGMCkCE0FqzdY8VMOZpfpR3lwI+CsQ=="],
19
-
20
- "typescript": ["typescript@5.9.3", "", { "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" } }, "sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw=="],
21
-
22
- "undici-types": ["undici-types@7.16.0", "", {}, "sha512-Zz+aZWSj8LE6zoxD+xrjh4VfkIG8Ya6LvYkZqtUQGJPZjYl53ypCaUwWqo7eI0x66KBGeRo+mlBEkMSeSZ38Nw=="],
23
- }
24
- }
package/bunfig.toml DELETED
@@ -1 +0,0 @@
1
- # Bun configuration for xitdb-ts
package/example/README.md DELETED
@@ -1,46 +0,0 @@
1
- This is an example program that reads a xitdb file and prints out its most recent value (the last item of the top-level ArrayList). From the root of this repo, run:
2
-
3
- ```
4
- bun run example/dump.ts tests/fixtures/test.db
5
- ```
6
-
7
- ...and it will print:
8
-
9
- ```
10
- ArrayList[2]:
11
- HashMap{7}:
12
- (none):
13
- LinkedArrayList[1]:
14
- [0]:
15
- "Wash the car"
16
- (none):
17
- HashSet{1}: ["a"]
18
- (none):
19
- ArrayList[2]:
20
- [0]:
21
- HashMap{2}:
22
- (none):
23
- 26 (uint)
24
- (none):
25
- "Alice"
26
- [1]:
27
- HashMap{2}:
28
- (none):
29
- 42 (uint)
30
- (none):
31
- "Bob"
32
- (none):
33
- "foo"
34
- "fruits":
35
- ArrayList[2]:
36
- [0]:
37
- "lemon"
38
- [1]:
39
- "pear"
40
- (none):
41
- CountedHashMap{1}:
42
- "a":
43
- 2 (uint)
44
- (none):
45
- CountedHashSet{1}: ["a"]
46
- ```