import { Context, OwnerPolicy, Store } from "../index"; interface CoreModelDefinition { new (): CoreModel; getActions(): any; } /** * First basic model for Ident * Will evolve with version 0.2 and Model addition * * @class */ declare class CoreModel extends OwnerPolicy { static __ctx: Context; __store: Store; _creationDate: Date; lastUpdate: Date; _lastUpdate: Date; __deleted: boolean; static getActions(): {}; getAvailableActions(): {}; load(raw: any, secure?: boolean): void; /** * Return the object registered store */ getStore(): Store; /** * Get the object again * * @throws Error if the object is not coming from a store */ refresh(): Promise; /** * Delete this object * * @throws Error if the object is not coming from a store */ delete(): Promise; /** * Save this object * * @throws Error if the object is not coming from a store */ save(): Promise; /** * Update this object * * @throws Error if the object is not coming from a store */ update(changes: any): Promise; /** * Return the object schema, if defined any modification done to the object by external source * must comply to this schema */ _getSchema(): any; validate(ctx: any, updates?: any): Promise; generateUid(object?: any): string; _jsonFilter(key: any, value: any): any; toStoredJSON(stringify?: boolean): any; _getService(service: any): any; _toJSON(secure: any): any; toJSON(): any; _onDelete(): Promise; _onDeleted(): Promise; _onGet(): Promise; _onSave(): Promise; _onSaved(): Promise; _onUpdate(updates: any): Promise; _onUpdated(): Promise; } export { CoreModel, CoreModelDefinition };