import { EntityExplorerService } from './entity-explorer.service'; import { PostgresCollector } from '../collectors/postgres-collector'; import { MysqlCollector } from '../collectors/mysql-collector'; export interface ErdColumn { name: string; type: string; nullable: boolean; isPrimary: boolean; isForeign: boolean; } export interface ErdTable { name: string; columns: ErdColumn[]; } export interface ErdRelation { fromTable: string; fromColumn: string; toTable: string; toColumn: string; cardinality: '1:1' | '1:N'; } export type ErdSourceType = 'postgresql' | 'mysql' | 'entities'; export interface ErdSchema { source: ErdSourceType; label: string; database?: string; tableCount: number; relationCount: number; tables: ErdTable[]; relations: ErdRelation[]; mermaid: string; error?: string; } export declare class ErdService { private readonly entityExplorer; private readonly pgCollector; private readonly mysqlCollector; private readonly logger; private readonly externalPgConfigs; private readonly externalMysqlConfigs; constructor(entityExplorer: EntityExplorerService, pgCollector: PostgresCollector, mysqlCollector: MysqlCollector); registerPostgresConnection(label: string, config: Record): void; registerMysqlConnection(label: string, config: Record): void; getSchemas(): Promise; private pgEnvConfig; private buildPostgresSchema; private buildMysqlSchemaFromConfig; private buildEntityFallback; private buildSchema; private toMermaid; private sanitiseType; private safeName; }