import { Db, Document, Filter, FindOptions, MongoClient, UpdateFilter, UpdateOptions } from 'mongodb'; import { Provider, ProviderTypes } from '../lib/structures/Provider'; /** * The class that represents the MongoDB provider. * @extends {Provider} */ export declare class MongoDBProvider extends Provider { /** * MongoDB connection uri * @type {string} */ uri: string; /** * MongoDB database name * @type {?string} */ dbName?: string | undefined; /** * MongoDB client * @type {MongoClient} */ client: MongoClient; /** * MongoDB database * @type {?Db} */ db: Db | null; /** * The type of the provider. * @type {ProviderTypes} */ type: ProviderTypes; constructor(uri: string, dbName?: string); /** * The method that initializes the provider. */ init(): Promise; /** * The method that create a new collection. * @param {String} collectionName The collection name to create document into. * @param {Document} document The document to create. * @returns {any} */ insert(collectionName: string, document: Document): Promise>; /** * The method that return an existing document. * @param {String} collectionName The collection name to search document into. * @param {Filter} filter The filter to search document. * @param {FindOptions} options The options to search document. * @returns {Promise>} */ get(collectionName: string, filter: Filter, options?: FindOptions): Promise>; /** * The method that return an existing documents. * @param {String} collectionName The collection name to search documents into. * @param {Filter} filter The filter to search documents. * @param {FindOptions} options The options to search documents. * @returns {Promise>>} */ getMany(collectionName: string, filter: Filter, options?: FindOptions): Promise>>; /** * The method that update an existing document. * @param {String} collectionName The collection name to update document into. * @param {Filter }filter The filter to update document. * @param {UpdateFilter} set New options for document. * @param {UpdateOptions} options The options to update document. * @returns {Promise} */ update(collectionName: string, filter: Filter, set: UpdateFilter, options?: UpdateOptions): Promise; /** * The method that deletes an existing documents. * @param {String} collectionName The collection name to delete documents into. * @param {Filter} filter The filter to delete document. * @returns {Promise} */ delete(collectionName: string, filter: Filter): Promise; } //# sourceMappingURL=MongoDBProvider.d.ts.map