@@ -1692,6 +1692,8 @@ export class ObservableQuery<TData = any, TVariables extends OperationVariables
16921692 hasObservers(): boolean ;
16931693 // (undocumented)
16941694 isDifferentFromLastResult(newResult : ApolloQueryResult <TData >, variables ? : TVariables ): boolean | undefined ;
1695+ // @internal (undocumented)
1696+ protected notify(): void ;
16951697 // (undocumented)
16961698 readonly options: WatchQueryOptions <TVariables , TData >;
16971699 // (undocumented)
@@ -1711,6 +1713,8 @@ export class ObservableQuery<TData = any, TVariables extends OperationVariables
17111713 resetDiff(): void ;
17121714 // (undocumented)
17131715 resetLastResults(): void ;
1716+ // @internal (undocumented)
1717+ protected resetNotifications(): void ;
17141718 // (undocumented)
17151719 resetQueryStoreErrors(): void ;
17161720 // (undocumented)
@@ -1719,15 +1723,17 @@ export class ObservableQuery<TData = any, TVariables extends OperationVariables
17191723 resubscribeAfterError(observer : Observer <ApolloQueryResult <TData >>): ObservableSubscription ;
17201724 // (undocumented)
17211725 result(): Promise <ApolloQueryResult <MaybeMasked <TData >>>;
1726+ // @internal (undocumented)
1727+ protected scheduleNotify(): void ;
17221728 // (undocumented)
17231729 setOptions(newOptions : Partial <WatchQueryOptions <TVariables , TData >>): Promise <ApolloQueryResult <MaybeMasked <TData >>>;
17241730 setVariables(variables : TVariables ): Promise <ApolloQueryResult <MaybeMasked <TData >> | void >;
17251731 // (undocumented)
17261732 silentSetOptions(newOptions : Partial <WatchQueryOptions <TVariables , TData >>): void ;
17271733 startPolling(pollInterval : number ): void ;
17281734 stopPolling(): void ;
1729- subscribeToMore<TSubscriptionData = TData , TSubscriptionVariables extends OperationVariables = TVariables >(options : SubscribeToMoreOptions <TData , TSubscriptionVariables , TSubscriptionData >): () => void ;
1730- updateQuery< TVars extends OperationVariables = TVariables > (mapFn : ( previousQueryResult : Unmasked <TData >, options : Pick < WatchQueryOptions < TVars , TData >, " variables " >) => Unmasked < TData >): void ;
1735+ subscribeToMore<TSubscriptionData = TData , TSubscriptionVariables extends OperationVariables = TVariables >(options : SubscribeToMoreOptions <TData , TSubscriptionVariables , TSubscriptionData , TVariables >): () => void ;
1736+ updateQuery(mapFn : UpdateQueryMapFn <TData , TVariables >): void ;
17311737 get variables(): TVariables | undefined ;
17321738}
17331739
@@ -1864,8 +1870,6 @@ class QueryInfo {
18641870 // (undocumented)
18651871 lastRequestId: number ;
18661872 // (undocumented)
1867- listeners: Set <QueryListener >;
1868- // (undocumented)
18691873 markError(error : ApolloError ): ApolloError ;
18701874 // (undocumented)
18711875 markReady(): NetworkStatus ;
@@ -1878,14 +1882,10 @@ class QueryInfo {
18781882 // (undocumented)
18791883 networkStatus? : NetworkStatus ;
18801884 // (undocumented)
1881- notify(): void ;
1882- // (undocumented)
18831885 readonly observableQuery: ObservableQuery <any , any > | null ;
18841886 // (undocumented)
18851887 readonly queryId: string ;
18861888 // (undocumented)
1887- reset(): void ;
1888- // (undocumented)
18891889 resetDiff(): void ;
18901890 // (undocumented)
18911891 resetLastWrite(): void ;
@@ -1901,9 +1901,6 @@ class QueryInfo {
19011901 variables? : Record <string , any >;
19021902}
19031903
1904- // @public (undocumented)
1905- export type QueryListener = (queryInfo : QueryInfo ) => void ;
1906-
19071904// @public (undocumented)
19081905class QueryManager <TStore > {
19091906 // Warning: (ae-forgotten-export) The symbol "QueryManagerOptions" needs to be exported by the entry point index.d.ts
@@ -1944,6 +1941,8 @@ class QueryManager<TStore> {
19441941 getLocalState(): LocalState <TStore >;
19451942 // (undocumented)
19461943 getObservableQueries(include ? : InternalRefetchQueriesInclude ): Map <string , ObservableQuery <any , OperationVariables >>;
1944+ // (undocumented)
1945+ getOrCreateQuery(queryId : string ): QueryInfo ;
19471946 // Warning: (ae-forgotten-export) The symbol "QueryStoreValue" needs to be exported by the entry point index.d.ts
19481947 //
19491948 // (undocumented)
@@ -2008,8 +2007,6 @@ class QueryManager<TStore> {
20082007 // (undocumented)
20092008 resetErrors(queryId : string ): void ;
20102009 // (undocumented)
2011- setObservableQuery(observableQuery : ObservableQuery <any , any >): void ;
2012- // (undocumented)
20132010 readonly ssrMode: boolean ;
20142011 // (undocumented)
20152012 startGraphQLSubscription<T = any >(options : SubscriptionOptions ): Observable <FetchResult <T >>;
@@ -2317,12 +2314,33 @@ class Stump extends Layer {
23172314}
23182315
23192316// @public (undocumented)
2320- export type SubscribeToMoreOptions <TData = any , TSubscriptionVariables = OperationVariables , TSubscriptionData = TData > = {
2317+ export interface SubscribeToMoreFunction <TData , TVariables extends OperationVariables = OperationVariables > {
2318+ // (undocumented)
2319+ <TSubscriptionData = TData , TSubscriptionVariables extends OperationVariables = TVariables >(options : SubscribeToMoreOptions <TData , TSubscriptionVariables , TSubscriptionData , TVariables >): () => void ;
2320+ }
2321+
2322+ // @public (undocumented)
2323+ export interface SubscribeToMoreOptions <TData = any , TSubscriptionVariables extends OperationVariables = OperationVariables , TSubscriptionData = TData , TVariables extends OperationVariables = TSubscriptionVariables > {
2324+ // (undocumented)
2325+ context? : DefaultContext ;
2326+ // (undocumented)
23212327 document: DocumentNode | TypedDocumentNode <TSubscriptionData , TSubscriptionVariables >;
2322- variables? : TSubscriptionVariables ;
2323- updateQuery? : UpdateQueryFn <TData , TSubscriptionVariables , TSubscriptionData >;
2328+ // (undocumented)
23242329 onError? : (error : Error ) => void ;
2325- context? : DefaultContext ;
2330+ // (undocumented)
2331+ updateQuery? : SubscribeToMoreUpdateQueryFn <TData , TVariables , TSubscriptionData >;
2332+ // (undocumented)
2333+ variables? : TSubscriptionVariables ;
2334+ }
2335+
2336+ // @public (undocumented)
2337+ export type SubscribeToMoreUpdateQueryFn <TData = any , TVariables extends OperationVariables = OperationVariables , TSubscriptionData = TData > = {
2338+ (
2339+ unsafePreviousData : Unmasked <TData >, options : UpdateQueryOptions <TData , TVariables > & {
2340+ subscriptionData: {
2341+ data: Unmasked <TSubscriptionData >;
2342+ };
2343+ }): Unmasked <TData > | void ;
23262344};
23272345
23282346// @public (undocumented)
@@ -2421,18 +2439,22 @@ type UnwrapFragmentRefs<TData> = true extends IsAny<TData> ? TData : TData exten
24212439type UpdateQueries <TData > = MutationOptions <TData , any , any >[" updateQueries" ];
24222440
24232441// @public (undocumented)
2424- type UpdateQueryFn <TData = any , TSubscriptionVariables = OperationVariables , TSubscriptionData = TData > = (previousQueryResult : Unmasked <TData >, options : {
2425- subscriptionData: {
2426- data: Unmasked <TSubscriptionData >;
2427- };
2428- variables? : TSubscriptionVariables ;
2429- }) => Unmasked <TData >;
2442+ export interface UpdateQueryMapFn <TData = any , TVariables = OperationVariables > {
2443+ // (undocumented)
2444+ (
2445+ unsafePreviousData : Unmasked <TData >, options : UpdateQueryOptions <TData , TVariables >): Unmasked <TData > | void ;
2446+ }
24302447
24312448// @public (undocumented)
2432- export interface UpdateQueryOptions <TVariables > {
2433- // (undocumented)
2449+ export type UpdateQueryOptions <TData , TVariables > = {
24342450 variables? : TVariables ;
2435- }
2451+ } & ({
2452+ complete: true ;
2453+ previousData: Unmasked <TData >;
2454+ } | {
2455+ complete: false ;
2456+ previousData: DeepPartial <Unmasked <TData >> | undefined ;
2457+ });
24362458
24372459// @public (undocumented)
24382460export interface UriFunction {
@@ -2508,11 +2530,10 @@ interface WriteContext extends ReadMergeModifyContext {
25082530// src/cache/inmemory/policies.ts:162:3 - (ae-forgotten-export) The symbol "KeySpecifier" needs to be exported by the entry point index.d.ts
25092531// src/cache/inmemory/policies.ts:162:3 - (ae-forgotten-export) The symbol "KeyArgsFunction" needs to be exported by the entry point index.d.ts
25102532// src/cache/inmemory/types.ts:139:3 - (ae-forgotten-export) The symbol "KeyFieldsFunction" needs to be exported by the entry point index.d.ts
2511- // src/core/ObservableQuery.ts:120 :5 - (ae-forgotten-export) The symbol "QueryManager" needs to be exported by the entry point index.d.ts
2512- // src/core/ObservableQuery.ts:121 :5 - (ae-forgotten-export) The symbol "QueryInfo" needs to be exported by the entry point index.d.ts
2533+ // src/core/ObservableQuery.ts:128 :5 - (ae-forgotten-export) The symbol "QueryManager" needs to be exported by the entry point index.d.ts
2534+ // src/core/ObservableQuery.ts:129 :5 - (ae-forgotten-export) The symbol "QueryInfo" needs to be exported by the entry point index.d.ts
25132535// src/core/QueryManager.ts:159:5 - (ae-forgotten-export) The symbol "MutationStoreValue" needs to be exported by the entry point index.d.ts
25142536// src/core/QueryManager.ts:414:7 - (ae-forgotten-export) The symbol "UpdateQueries" needs to be exported by the entry point index.d.ts
2515- // src/core/watchQueryOptions.ts:277:2 - (ae-forgotten-export) The symbol "UpdateQueryFn" needs to be exported by the entry point index.d.ts
25162537// src/link/http/selectHttpOptionsAndBody.ts:128:32 - (ae-forgotten-export) The symbol "HttpQueryOptions" needs to be exported by the entry point index.d.ts
25172538
25182539// (No @packageDocumentation comment for this package)
0 commit comments