cafe-utility
Advanced tools
Comparing version 26.15.1 to 27.0.0
@@ -549,5 +549,14 @@ type Indexable = number | string; | ||
} | ||
declare function merkleStart(capacity: number): Chunk[]; | ||
declare function merkleAppend(levels: Chunk[], data: Uint8Array, onChunk: (chunk: Chunk) => Promise<void>, level?: number, spanIncrement?: bigint): Promise<Chunk[]>; | ||
declare function merkleFinalize(levels: Chunk[], onChunk: (chunk: Chunk) => Promise<void>, level?: number): Promise<Chunk>; | ||
export declare class MerkleTree { | ||
static readonly NOOP: (_: Chunk) => Promise<void>; | ||
count: number; | ||
private capacity; | ||
private chunks; | ||
private onChunk; | ||
constructor(onChunk: (chunk: Chunk) => Promise<void>, capacity?: number); | ||
static root(data: Uint8Array, capacity?: number): Promise<Chunk>; | ||
append(data: Uint8Array, level?: number, spanIncrement?: bigint): Promise<void>; | ||
private elevate; | ||
finalize(level?: number): Promise<Chunk>; | ||
} | ||
type Playbook<T> = { | ||
@@ -618,5 +627,2 @@ ttl: number; | ||
concatBytes: typeof concatBytes; | ||
merkleStart: typeof merkleStart; | ||
merkleAppend: typeof merkleAppend; | ||
merkleFinalize: typeof merkleFinalize; | ||
numberToUint8: typeof numberToUint8; | ||
@@ -623,0 +629,0 @@ uint8ToNumber: typeof uint8ToNumber; |
{ | ||
"name": "cafe-utility", | ||
"version": "26.15.1", | ||
"version": "27.0.0", | ||
"description": "", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
148762
4333