import Base from "./base.js"; import Logger from "../logger.js"; import LocalBackgroundJobsAdapter from "../background-jobs/local-adapter.js"; export type MigrationsRequireContextIDFunctionType = (id: string) => { default: typeof import("../database/migration/index.js").default; }; export type MigrationsRequireContextType = MigrationsRequireContextIDFunctionType & { keys: () => string[]; id: string; }; export type CommandsRequireContextIDFunctionType = (id: string) => { default: typeof import("../cli/base-command.js").default; }; export type CommandsRequireContextType = CommandsRequireContextIDFunctionType & { keys: () => string[]; id: string; }; export type TestFilesRequireContextIDFunctionType = (id: string) => ReturnType; export type TestFilesRequireContextType = TestFilesRequireContextIDFunctionType & { keys: () => string[]; id: string; }; export default class VelociousEnvironmentsHandlerBrowser extends Base { migrationsRequireContextCallback: (() => Promise) | undefined; testFilesRequireContextCallback: (() => Promise) | undefined; logger: Logger; _findCommandsResult: { name: string; file: string; }[] | undefined; /** * Creates the Browser/Expo local SQLite adapter and in-process dispatcher. * @param {{configuration: import("../configuration.js").default}} args - Adapter options. * @returns {LocalBackgroundJobsAdapter} - Local background-jobs adapter. */ createBackgroundJobsAdapter({ configuration }: { configuration: import("../configuration.js").default; }): LocalBackgroundJobsAdapter; /** * Find commands require context result. * @type {CommandsRequireContextType | undefined} */ findCommandsRequireContextResult: CommandsRequireContextType | undefined; /** * Migrations require context result. * @type {MigrationsRequireContextType | undefined} */ _migrationsRequireContextResult: MigrationsRequireContextType | undefined; /** * Test files require context result. * @type {TestFilesRequireContextType | undefined} */ _testFilesRequireContextResult: TestFilesRequireContextType | undefined; /** * Runs constructor. * @param {object} args - Options object. * @param {() => Promise} [args.migrationsRequireContextCallback] - Migrations require context callback. * @param {() => Promise} [args.testFilesRequireContextCallback] - Test files require context callback. */ constructor({ migrationsRequireContextCallback, testFilesRequireContextCallback, ...restArgs }?: { migrationsRequireContextCallback?: () => Promise; testFilesRequireContextCallback?: () => Promise; }); /** * Runs migrations require context. * @returns {Promise} - Resolves with the migrations require context. */ migrationsRequireContext(): Promise; /** * Runs test files require context. * @returns {Promise} - Resolves with the test files require context. */ testFilesRequireContext(): Promise; /** * Runs find commands. * @returns {Promise>} - Resolves with the commands. */ findCommands(): Promise>; /** * Runs find commands require context. * @returns {CommandsRequireContextType} - The commands require context. */ _findCommandsRequireContext(): CommandsRequireContextType; _actualFindCommands(): { name: string; file: string; }[]; /** * Runs require command. * @param {object} args - Options object. * @param {Array} args.commandParts - Command parts. * @returns {Promise} - Resolves with the require command. */ requireCommand({ commandParts }: { commandParts: Array; }): Promise; /** * Runs find migrations. * @returns {Promise>} - Resolves with the migrations. */ findMigrations(): Promise>; /** * Runs import test files. * @param {string[]} testFiles - Test files. * @returns {Promise} - Resolves when complete. */ importTestFiles(testFiles: string[]): Promise; /** * Require migration. * @param {string} filePath - File path. * @returns {Promise} - Resolves with the require migration. */ requireMigration: (filePath: string) => Promise; /** * Runs after migrations. * @param {object} args - Options object. * @param {Record} args.dbs - Dbs. * @returns {Promise} - Resolves when complete. */ afterMigrations({ dbs }: { dbs: Record; }): Promise; /** * Runs sqlite structure sql. * @param {object} args - Options object. * @param {Record} args.dbs - Dbs. * @returns {Promise} - Resolves with SQL string. */ _sqliteStructureSql({ dbs }: { dbs: Record; }): Promise; } //# sourceMappingURL=browser.d.ts.map