import { TableCertificateField, TableCertificateX, TableCommission, TableMonitorEvent, TableOutput, TableOutputBasket, TableOutputTag, TableOutputTagMap, TableProvenTx, TableProvenTxReq, TableSettings, TableSyncState, TableTransaction, TableTxLabel, TableTxLabelMap, TableUser } from './schema/tables'; import * as sdk from '../sdk/index'; /** * The `StorageReader` abstract class is the base of the concrete wallet storage provider classes. * * It is the minimal interface required to read all wallet state records and is the base class for sync readers. * * The next class in the heirarchy is the `StorageReaderWriter` which supports sync readers and writers. * * The last class in the heirarchy is the `Storage` class which supports all active wallet operations. * * The ability to construct a properly configured instance of this class implies authentication. * As such there are no user specific authenticated access checks implied in the implementation of any of these methods. */ export declare abstract class StorageReader implements sdk.WalletStorageSyncReader { chain: sdk.Chain; _settings?: TableSettings; whenLastAccess?: Date; get dbtype(): DBType | undefined; constructor(options: StorageReaderOptions); isAvailable(): boolean; makeAvailable(): Promise; getSettings(): TableSettings; isStorageProvider(): boolean; abstract destroy(): Promise; abstract transaction(scope: (trx: sdk.TrxToken) => Promise, trx?: sdk.TrxToken): Promise; abstract readSettings(trx?: sdk.TrxToken): Promise; abstract findCertificateFields(args: sdk.FindCertificateFieldsArgs): Promise; abstract findCertificates(args: sdk.FindCertificatesArgs): Promise; abstract findCommissions(args: sdk.FindCommissionsArgs): Promise; abstract findMonitorEvents(args: sdk.FindMonitorEventsArgs): Promise; abstract findOutputBaskets(args: sdk.FindOutputBasketsArgs): Promise; abstract findOutputs(args: sdk.FindOutputsArgs): Promise; abstract findOutputTags(args: sdk.FindOutputTagsArgs): Promise; abstract findSyncStates(args: sdk.FindSyncStatesArgs): Promise; abstract findTransactions(args: sdk.FindTransactionsArgs): Promise; abstract findTxLabels(args: sdk.FindTxLabelsArgs): Promise; abstract findUsers(args: sdk.FindUsersArgs): Promise; abstract countCertificateFields(args: sdk.FindCertificateFieldsArgs): Promise; abstract countCertificates(args: sdk.FindCertificatesArgs): Promise; abstract countCommissions(args: sdk.FindCommissionsArgs): Promise; abstract countMonitorEvents(args: sdk.FindMonitorEventsArgs): Promise; abstract countOutputBaskets(args: sdk.FindOutputBasketsArgs): Promise; abstract countOutputs(args: sdk.FindOutputsArgs): Promise; abstract countOutputTags(args: sdk.FindOutputTagsArgs): Promise; abstract countSyncStates(args: sdk.FindSyncStatesArgs): Promise; abstract countTransactions(args: sdk.FindTransactionsArgs): Promise; abstract countTxLabels(args: sdk.FindTxLabelsArgs): Promise; abstract countUsers(args: sdk.FindUsersArgs): Promise; abstract getProvenTxsForUser(args: sdk.FindForUserSincePagedArgs): Promise; abstract getProvenTxReqsForUser(args: sdk.FindForUserSincePagedArgs): Promise; abstract getTxLabelMapsForUser(args: sdk.FindForUserSincePagedArgs): Promise; abstract getOutputTagMapsForUser(args: sdk.FindForUserSincePagedArgs): Promise; findUserByIdentityKey(key: string): Promise; getSyncChunk(args: sdk.RequestSyncChunkArgs): Promise; /** * Force dates to strings on SQLite and Date objects on MySQL * @param date * @returns */ validateEntityDate(date: Date | string | number): Date | string; /** * * @param date * @param useNowAsDefault if true and date is null or undefiend, set to current time. * @returns */ validateOptionalEntityDate(date: Date | string | number | null | undefined, useNowAsDefault?: boolean): Date | string | undefined; validateDate(date: Date | string | number): Date; validateOptionalDate(date: Date | string | number | null | undefined): Date | undefined; validateDateForWhere(date: Date | string | number): Date | string | number; } export interface StorageReaderOptions { chain: sdk.Chain; } export type DBType = 'SQLite' | 'MySQL' | 'IndexedDB'; //# sourceMappingURL=StorageReader.d.ts.map