UNPKG

@mastra/core

Version:

The core foundation of the Mastra framework, providing essential components and interfaces for building AI-powered applications.

37 lines 1.39 kB
import { MastraBase } from '../../../base'; import type { TABLE_NAMES } from '../../constants'; import type { StorageColumn } from '../../types'; export declare abstract class StoreOperations extends MastraBase { constructor(); abstract hasColumn(table: string, column: string): Promise<boolean>; protected getSqlType(type: StorageColumn['type']): string; protected getDefaultValue(type: StorageColumn['type']): string; abstract createTable({ tableName }: { tableName: TABLE_NAMES; schema: Record<string, StorageColumn>; }): Promise<void>; abstract clearTable({ tableName }: { tableName: TABLE_NAMES; }): Promise<void>; abstract dropTable({ tableName }: { tableName: TABLE_NAMES; }): Promise<void>; abstract alterTable(args: { tableName: TABLE_NAMES; schema: Record<string, StorageColumn>; ifNotExists: string[]; }): Promise<void>; abstract insert({ tableName, record }: { tableName: TABLE_NAMES; record: Record<string, any>; }): Promise<void>; abstract batchInsert({ tableName, records, }: { tableName: TABLE_NAMES; records: Record<string, any>[]; }): Promise<void>; abstract load<R>({ tableName, keys }: { tableName: TABLE_NAMES; keys: Record<string, any>; }): Promise<R | null>; } //# sourceMappingURL=base.d.ts.map