/// import { BaseConnectionPool, PoolOptions } from '@databases/shared'; import { SQLQuery } from '@databases/sql'; import Connection from './Connection'; import Transaction from './Transaction'; import { Readable } from 'stream'; import { ConnectionPool as IConnectionPool } from './types/Queryable'; import { parseComposite, parseArray } from './TypeOverrides'; import EventHandlers from './types/EventHandlers'; import PgDriver from './Driver'; import { PgOptions } from './ConnectionSource'; export default class ConnectionPool extends BaseConnectionPool implements IConnectionPool { readonly sql: import("@databases/sql").SQL; private readonly _types; constructor(options: PgOptions, { poolOptions, schema, handlers: { onError, ...handlers }, acquireLockTimeoutMilliseconds, }: { poolOptions?: Omit, 'openConnection' | 'closeConnection'>; schema?: string | string[]; handlers: EventHandlers & { onError: (err: Error) => void; }; acquireLockTimeoutMilliseconds: number; }); registerTypeParser(type: number | string, parser: (value: string) => T): Promise<(value: string) => T>; getTypeParser(type: number | string): Promise<(value: string) => any>; readonly parseComposite: typeof parseComposite; readonly parseArray: typeof parseArray; queryNodeStream(query: SQLQuery, options?: { highWaterMark?: number; }): Readable; }