import { CacheDescriptor, CacheDescriptorInternal, NsFallback, TranslationsFlat, TranslationValue, TreeTranslationsData, BackendGetRecordInternal } from '../../types'; import { JioTranslateStaticData } from '../State/initState'; import { ValueObserverInstance } from '../ValueObserver'; import { EventsInstance } from '../Events/Events'; export declare function Cache(events: EventsInstance, backendGetRecord: BackendGetRecordInternal, backendGetDevRecord: BackendGetRecordInternal, withDefaultNs: (descriptor: CacheDescriptor) => CacheDescriptorInternal, isInitialLoading: () => boolean, fetchingObserver: ValueObserverInstance, loadingObserver: ValueObserverInstance): Readonly<{ addStaticData(data: JioTranslateStaticData | undefined): void; invalidate(): void; addRecord(descriptor: CacheDescriptorInternal, data: TreeTranslationsData): void; exists(descriptor: CacheDescriptorInternal, strict?: boolean): boolean; getRecord(descriptor: CacheDescriptor): TranslationsFlat | undefined; getTranslation(descriptor: CacheDescriptorInternal, key: string): TranslationValue; getTranslationNs(namespaces: string[], languages: string[], key: string): string[]; getTranslationFallback(namespaces: string[], languages: string[], key: string): string | undefined; changeTranslation(descriptor: CacheDescriptorInternal, key: string, value: TranslationValue): void; isFetching(ns?: NsFallback): boolean; isLoading(language: string | undefined, ns?: NsFallback): boolean; loadRecords(descriptors: CacheDescriptor[], isDev: boolean): Promise; getAllRecords(): { data: TranslationsFlat; language: string; namespace: string; }[]; }>; export type CacheInstance = ReturnType;