export type AccessorQueryResultFetchMore = () => Promise>; export type AccessorQueryResultClear = () => void; export type AccessorQueryResultInvalidate = () => void; export type AccessorQueryCacheStoreSet = { (store: T): void; }; export type AccessorQueryCacheStore = { dataAccess: { set: (store: AccessorQueryCacheStoreSet) => any; query: Map>; } | Error>; suspense: Map AccessorQueryResultCacheSetResult>; }; }; type AccessorQueryConfigurationCacheSet = (args: { cache: () => TCache; cacheId: string; args: TQueryRequest; request: (args: TQueryRequest) => Promise>; response: { status: number; data: TQueryResponse; }; }) => { data: TData; }; type AccessorQueryConfigurationCacheGet = (args: { cache: () => TCache; cacheId: string; args: TQueryRequest; request: (args: TQueryRequest) => Promise>; }) => AccessorQueryResultCacheSetResult | null; type AccessorQueryConfigurationCacheClear = (args: { cacheId: string; args: TQueryRequest; set: (store: AccessorQueryCacheStoreSet) => any; }) => void; export type AccessorQueryConfiguration = { debug?: boolean; cache: { duration: number; isPrimableFromCache: boolean; id: (args: { args: TQueryRequest; }) => string; invalidate?: { auto?: { enable: boolean; interval?: number; }; }; set: AccessorQueryConfigurationCacheSet; get: AccessorQueryConfigurationCacheGet; clear: AccessorQueryConfigurationCacheClear; }; constraints?: { enforce?: boolean; maxDelay?: number; }; query: (args: TQueryRequest) => Promise>; }; export type AccessorQueryContext = { queryName: string; requestQueryPromise: (getCacheStore: () => TCache, args: TQueryRequest) => Promise>; suspenseRequestQuery: ({ getCacheStore, onDone, args, }: { getCacheStore: () => TCache; onDone?: () => void; args: TQueryRequest; }) => () => AccessorQueryResultCacheSetResult; }; export type AccessorQueryResultCacheSetResult = { data: null | TData; fetchMore?: null | AccessorQueryResultFetchMore; }; export type AccessorQueryResult = { data: null | TData; fetchMore?: null | AccessorQueryResultFetchMore; clear: AccessorQueryResultClear; invalidate: AccessorQueryResultInvalidate; }; export type AccessorQueryRequestResponse = { status: number; data?: null | T; error?: string; }; export declare class ErrorTimedOut extends Error { constructor(queryName: string, cacheId: string); } export {};