import { Collection, CollectionInsertOneOptions, CollectionOptions, Cursor, Db, DeleteWriteOpResultObject, InsertOneWriteOpResult, ObjectID, ReplaceOneOptions, UpdateWriteOpResult } from 'mongodb'; import { Constructor } from '../helpers/constructor-type'; import { SakuraApi } from '../sakura-api'; import { IDbGetParams, IFromDbOptions } from './'; export declare function SapiModelMixin>(base?: C): { new (...args: any[]): { _id: ObjectID; id: ObjectID; create: (options?: CollectionInsertOneOptions) => Promise; getCollection: () => Collection; getDb: () => Db; remove: (filter: any, options?: CollectionOptions) => Promise; save: (set?: { [key: string]: any; }, options?: ReplaceOneOptions) => Promise; toDb: (changeSet?: object) => any; toJson: (projection?: any, context?: string) => any; toJsonString: (replacer?: () => any, space?: string | number) => string; }; fromDb: (this: new () => T, json: any, options?: IFromDbOptions) => T; fromJson: (this: new (...params: any[]) => T, json: object, context?: string) => T; fromJsonToDb: (json: any, context?: string) => any; fromDbArray: (this: new () => T, jsons: object[], options?: IFromDbOptions) => T[]; fromJsonArray: (this: new () => T, jsons: object[]) => T[]; get: (this: new () => T, params: IDbGetParams) => Promise; getById: (this: new () => T, id: string | ObjectID, project?: any) => Promise; getCollection: () => Collection; getCursor: (filter: any, project?: any) => Cursor; getCursorById: (id: any, project?: any) => Cursor; getDb: () => Db; getOne: (this: new () => T, filter: any, project?: any) => Promise; removeAll: (filter: any, options?: CollectionOptions) => Promise; removeById: (id: ObjectID, options?: CollectionOptions) => Promise; sapi: SakuraApi; sapiConfig?: any; } & C;