import { FindParams, FindResult } from '../interfaces'; /** * MongoDB Pagination class for finding instances in a collection. * This module provides a function to retrieve paginated results from a MongoDB collection. * It allows filtering, sorting, and projecting fields in the results. * The results can be paginated using a cursor for efficient data retrieval. * all the parameters are optional and are passed to the findInstances method. * * `sort` fields can be specified as an object with field names as keys and 1 (ascending) or -1 (descending) as values. * * Sort by `_id` in descending order by default. * * Sort field can be a nested field, e.g., `data.caseId` * * Sort field can be a numeric or date field. * * `filter` is an object that specifies the criteria for filtering the results. * * `after` is a string that specifies the cursor for pagination, allowing you to retrieve results after a specific document. * * * `limit` is a number that specifies the maximum number of documents to return in the result set. * * * `projection` is an object that specifies which fields to include or exclude in the returned documents. * * * */ export declare class Aggregate { db: any; configuration: any; dbConfiguration: any; constructor(db: any, configuration: any, dbConfiguration: any); find({ filter, after, limit, sort, projection, lastItem, latestItem, getTotalCount }: FindParams): Promise; }