import { Getter } from '@loopback/core'; import { DataObject, DefaultCrudRepository, Entity, Filter, Where, juggler } from '@loopback/repository'; import { Count } from '@loopback/repository/src/common-types'; import { Options } from 'loopback-datasource-juggler'; import { SoftDeleteEntity } from '../models'; import { IUser } from '../types'; export declare abstract class SoftCrudRepository extends DefaultCrudRepository { protected readonly getCurrentUser?: Getter | undefined; constructor(entityClass: typeof Entity & { prototype: E; }, dataSource: juggler.DataSource, getCurrentUser?: Getter | undefined); find(filter?: Filter, options?: Options): Promise<(E & R)[]>; findAll(filter?: Filter, options?: Options): Promise<(E & R)[]>; findOne(filter?: Filter, options?: Options): Promise<(E & R) | null>; findOneIncludeSoftDelete(filter?: Filter, options?: Options): Promise<(E & R) | null>; findById(id: ID, filter?: Filter, options?: Options): Promise; findByIdIncludeSoftDelete(id: ID, filter?: Filter, options?: Options): Promise; updateAll(data: DataObject, where?: Where, options?: Options): Promise; count(where?: Where, options?: Options): Promise; countAll(where?: Where, options?: Options): Promise; delete(entity: E, options?: Options): Promise; deleteAll(where?: Where, options?: Options): Promise; deleteById(id: ID, options?: Options): Promise; /** * Method to perform undo the soft delete by Id. * @param id * @param options */ undoSoftDeleteById(id: ID, options?: Options): Promise; /** * Method to perform undo all the soft deletes * @param where * @param options */ undoSoftDeleteAll(where?: Where, options?: Options): Promise; /** * Method to perform hard delete of entries. Take caution. * @param entity * @param options */ deleteHard(entity: E, options?: Options): Promise; /** * Method to perform hard delete of entries. Take caution. * @param entity * @param options */ deleteAllHard(where?: Where, options?: Options): Promise; /** * Method to perform hard delete of entries. Take caution. * @param entity * @param options */ deleteByIdHard(id: ID, options?: Options): Promise; private getUserId; }