@adonisjs/lucid
Version:
SQL ORM built on top of Active Record pattern
26 lines (25 loc) • 941 B
TypeScript
import { type MysqlConfig, type QueryClientContract } from '../../../types/database.js';
import { BaseSchemaState } from '../base_schema_state.js';
/**
* MySQL schema dumps are delegated to `mysqldump`.
*/
export declare class MysqlSchemaState extends BaseSchemaState {
constructor(client: QueryClientContract, connectionConfig: MysqlConfig, schemaTableName: string, schemaVersionsTableName: string);
/**
* Dump the structural schema using `mysqldump` and normalize the output
* afterwards to keep the file deterministic.
*/
protected dumpSchema(path: string): Promise<void>;
/**
* Load the schema dump using the `mysql` CLI.
*/
load(path: string): Promise<void>;
/**
* Normalize the configured connection and ensure required fields exist.
*/
private getConnection;
/**
* Build the shared MySQL CLI connection arguments.
*/
private getConnectionArguments;
}