import { AbortOptions, ContentId, MaybePromise, CodedError, MaybeAsyncIterableIterator } from '@mithic/commons'; import { AutoKeyMap, AutoKeyMapBatch, MaybeAsyncMap, MaybeAsyncMapBatch } from '../map.js'; /** A content-addressable map store that persists values in a backing {@link MaybeAsyncMap}. */ export declare class ContentAddressedMapStore & Partial & Iterable<[Id, T]> & AsyncIterable<[Id, T]>> = MaybeAsyncMap & Partial & Iterable<[Id, T]> & AsyncIterable<[Id, T]>>> implements AutoKeyMap, AutoKeyMapBatch, Partial & AsyncIterable<[Id, T]>> { /** The underlying map. */ readonly map: M; /** Hash function to use for generating keys for values. */ protected readonly hash: (value: T) => Id; [Symbol.iterator]: M extends Iterable<[Id, T]> ? () => IterableIterator<[Id, T]> : undefined; [Symbol.asyncIterator]: M extends (Iterable<[Id, T]> | AsyncIterable<[Id, T]>) ? () => AsyncIterableIterator<[Id, T]> : undefined; constructor( /** The underlying map. */ map?: M, /** Hash function to use for generating keys for values. */ hash?: (value: T) => Id); put: (value: T, options?: AbortOptions | undefined) => MaybePromise; delete(key: Id, options?: AbortOptions): MaybePromise; get(key: Id, options?: AbortOptions): MaybePromise; getKey(value: T): Id; has(key: Id, options?: AbortOptions): MaybePromise; deleteMany(keys: Iterable, options?: AbortOptions): MaybeAsyncIterableIterator; putMany(values: Iterable, options?: AbortOptions): AsyncIterableIterator<[key: Id, error?: CodedError]>; getMany(keys: Iterable, options?: AbortOptions): AsyncIterableIterator; hasMany(keys: Iterable, options?: AbortOptions): AsyncIterableIterator; get [Symbol.toStringTag](): string; protected deleteEach(keys: Iterable, options?: AbortOptions): AsyncGenerator | undefined, void, unknown>; protected entriesOf(values: Iterable): [Id, T][]; } //# sourceMappingURL=camap.d.ts.map