UNPKG

mongoose-management

Version:
40 lines (39 loc) 2.28 kB
import AbstractColumnsDataset, { InterfaceColumnDataset } from './abstractColumn'; import CollectionDataset from './collection'; import IndexDataset from './index'; import { dataColumnInternalValuesType, dataColumnType, dataIndexColumnValueType, schemaIndexType, schemaNormalType } from '../../types'; export declare type optionsType = Exclude<keyof dataColumnType, keyof dataColumnInternalValuesType | 'name'>; export default class ColumnDataset extends AbstractColumnsDataset<ColumnDataset | CollectionDataset, ColumnDataset> implements InterfaceColumnDataset<ColumnDataset> { protected column: dataColumnType; protected collection: CollectionDataset; protected readonly: boolean; protected columns: ColumnDataset[]; protected subTypes: schemaNormalType[]; protected index?: IndexDataset; protected populate?: CollectionDataset | ColumnDataset; constructor(column: dataColumnType, parent: ColumnDataset | CollectionDataset, collection: CollectionDataset, readonly?: boolean); setReference(): void; getName(withBrackets?: boolean): string; setName(name: string): void; getFullname(withBracketsForThisColumn?: boolean, withBrackets?: boolean): string; get<K extends optionsType>(key: K): dataColumnType[K]; set<K extends optionsType>(key: K, value: dataColumnType[K]): void; isset<K extends optionsType>(key: K, withEmptyString?: boolean): boolean; getTableName(selectedColumn?: ColumnDataset, withArrayBrackets?: boolean): string; getTableType(): string; getSubTypes(): ("string" | "number" | "boolean" | "decimal" | "buffer" | "arrayType" | "date" | "objectId" | "mixed")[]; setSubTypes(subTypes: schemaNormalType[]): void; getIndexName(): string; getIndex(): IndexDataset | undefined; getIndexType(): schemaIndexType | undefined; getIndexValue(): dataIndexColumnValueType | undefined; setIndex(value: dataIndexColumnValueType, type: schemaIndexType): void; removeIndex(): void; getPopulate(): ColumnDataset | CollectionDataset | undefined; getPopulateName(): string | undefined; setPopulate(collection?: CollectionDataset | ColumnDataset): void; isReadonly(): boolean; remove(): void; getCollection(): CollectionDataset; getObject(): dataColumnType; }