import { type AggregateType } from '@aws-sdk/client-iotsitewise'; import type { Resolution, RequestInformation, DataStream, RequestInformationAndRange } from '../types'; import type { DataStreamsStore } from './types'; import type { ErrorDetails } from '../../common/types'; /** * Data Cache Wrapper * * A wrapper around the existing data-cache, as is currently used within SiteWise Monitor. * * This wrapped component allows us to evolve the API of the data-cache, without altering the currently utilized data-cache. */ export declare class DataCache { private dataCache; private observableStore; constructor(initialDataCache?: DataStreamsStore); subscribe: (requestInformations: RequestInformation[], emit: (dataStreams: DataStream[]) => void) => () => void; shouldRequestDataStream: ({ dataStreamId, resolution, aggregationType, }: { dataStreamId: string; resolution: number; aggregationType?: AggregateType; }) => boolean; getState: () => DataStreamsStore; getCachedDataForRange: (requestInfos: RequestInformationAndRange[], emit: (dataStreams: DataStream[]) => void) => void; /** * data-cache bindings * * data-cache utilizes a redux store, the below methods are for ease of use, so you don't have to worry about * coordinating the dispatching of the action throughout the file. */ onSuccess: (dataStreams: DataStream[], requestInformation: RequestInformationAndRange, start: Date, end: Date) => void; onError: ({ id, resolution, error, aggregationType, }: { id: string; resolution: Resolution; error: ErrorDetails; aggregationType?: AggregateType; }) => void; onRequest: (requestInformation: RequestInformationAndRange) => void; } //# sourceMappingURL=dataCacheWrapped.d.ts.map