import { ICacheUpdater } from './ICacheUpdater'; import { Observable } from 'rxjs'; import { IChangeSet } from './IChangeSet'; import { IIntermediateCache } from './IIntermediateCache'; /** * Cache designed to be used for custom operator construction. It requires no key to be specified * but instead relies on the user specifying the key when amending data * * @typeparam TObject The type of the object. * @typeparam TKey The type of the key. */ export declare class IntermediateCache implements IIntermediateCache { private readonly _innerCache; /** * Initializes a new instance of the class. * * @param source The source. */ constructor(source?: Observable>); getKey(item: TObject): TKey; [Symbol.toStringTag]: "ObservableCache"; [Symbol.iterator](): IterableIterator<[TKey, TObject]>; /** * Action to apply a batch update to a cache. Multiple update methods can be invoked within a single batch operation. * These operations are invoked within the cache's lock and is therefore thread safe. * The result of the action will produce a single changeset * * @param updateAction The update action. * */ edit(updateAction: (updater: ICacheUpdater) => void): void; /** * A count changed observable starting with the current count */ get countChanged(): Observable; /** * Returns a filtered changeset of cache changes preceded with the initial state * * @param predicate The predicate. */ connect(predicate?: (value: TObject) => boolean): Observable>; preview(predicate?: (value: TObject) => boolean): Observable>; /** * Returns an observable of any changes which match the specified key. The sequence starts with the initial item in the cache (if there is one). * * @param key The key. */ watch(key: TKey): Observable>; /** * The total count of cached items */ get size(): number; /** * Gets the values */ values(): IterableIterator; /** * Gets the entries */ entries(): IterableIterator<[TKey, TObject]>; /** * Gets the keys */ keys(): IterableIterator; /** * Lookup a single item using the specified key. * @param key The key. */ lookup(key: TKey): TObject | undefined; /** @internal */ getInitialUpdates(filter?: (value: TObject) => boolean): import("./ChangeSet").ChangeSet; dispose(): void; }