import { MessagePort } from 'node:worker_threads'; import { DbServer } from '../index.js'; export declare abstract class DbWorker { #private; constructor(address: BigInt, db: DbServer, onExit: (code: number) => void, workerName: string); protected db: DbServer; protected channel: MessagePort; private worker; protected resolvers: ((x: any) => any)[]; readyPromise: Promise; terminate(): Promise; abstract handleMsg(buf: any): void; protected callback: (resolve: (x: any) => any) => void; /** * Send msg to the worker thread and return a promise to the response. */ protected call(msg: any): Promise; updateCtx(address: BigInt): Promise; }