sqlite3orm
Version:
ORM for sqlite3 and TypeScript/JavaScript
31 lines (30 loc) • 1.04 kB
TypeScript
import { FieldOpts } from './decorators';
import { Field } from './Field';
import { KeyType, MetaModel } from './MetaModel';
import { PropertyType } from './PropertyType';
import { ValueTransformer } from './ValueTransformer';
export declare class MetaProperty {
readonly className: string;
readonly key: KeyType;
/**
* The property type enum mapped to this field
*/
private _propertyType;
get propertyType(): PropertyType;
private _field?;
get field(): Field;
private _transform;
get transform(): ValueTransformer;
constructor(className: string, key: KeyType);
setPropertyType(propertyType: Function | string): void;
valueToDB(value: any): any;
getDBValueFromModel(model: any): any;
setDBValueIntoModel(model: any, value: any): void;
/**
* Get the name for the corresponding host parameter
*
* @returns {string}
*/
getHostParameterName(prefix?: string): string;
init(model: MetaModel, name: string, isIdentity: boolean, opts: FieldOpts): void;
}