@themost/jspa
Version:
MOST Web Framework Persistence API
25 lines (24 loc) • 754 B
TypeScript
import 'reflect-metadata';
declare type AnyConstructor<T> = Function & {
prototype: T;
};
declare interface ColumnAnnotation {
name?: string;
description?: string;
nullable?: boolean;
unique?: boolean;
length?: number;
precision?: number;
scale?: number;
insertable?: boolean;
updatable?: boolean;
type?: string | AnyConstructor<unknown>;
additionalType?: string | AnyConstructor<unknown>;
entity?: string;
}
declare interface EntityColumnAnnotation {
Column?: Map<string, ColumnAnnotation>;
}
declare function Column(annotation?: ColumnAnnotation): PropertyDecorator;
declare function Basic(): PropertyDecorator;
export { AnyConstructor, ColumnAnnotation, EntityColumnAnnotation, Column, Basic };