import { TransactionUnit } from ".."; import mongoose from "mongoose"; export interface TransactToRepoModel { checkoutTransactionUnit(userId: string, transactionId: string, fileName: string, unitCount: number): Promise; rollback(userId: string, transactionId: string, fileName: string): Promise; commit(userId: mongoose.Types.ObjectId, transactionId: mongoose.Types.ObjectId, fileName: string): Promise; } export interface TransactToRepoDoc { userId: mongoose.Types.ObjectId; fileName: string; version: number; pending: boolean; transactionId: mongoose.Types.ObjectId; } export declare const transactToRepoSchema: { userId: { type: mongoose.Types.ObjectIdConstructor; required: boolean; }; version: { type: NumberConstructor; required: boolean; }; pending: BooleanConstructor; transactionId: mongoose.Types.ObjectIdConstructor; fileName: StringConstructor; }; export declare const extendSchemaWithTransactionToRepo: (schema: mongoose.Schema, model: () => mongoose.Model>, getTransactionUnit: (userId: string, transactionId: string, fileName: string, unitId: string, unitCount: number, version: number) => Promise) => void;