UNPKG

874 BTypeScriptView Raw
1import type { DocumentNode } from 'graphql';
2import type { ApolloQueryResult, TypedDocumentNode } from '@apollo/client/core';
3import type { Observable } from 'rxjs';
4import { Apollo } from './apollo';
5import { QueryRef } from './query-ref';
6import { WatchQueryOptionsAlone, QueryOptionsAlone, EmptyObject } from './types';
7import * as i0 from "@angular/core";
8export declare class Query<T = {}, V = EmptyObject> {
9 protected apollo: Apollo;
10 readonly document: DocumentNode | TypedDocumentNode<T, V>;
11 client: string;
12 constructor(apollo: Apollo);
13 watch(variables?: V, options?: WatchQueryOptionsAlone<V, T>): QueryRef<T, V>;
14 fetch(variables?: V, options?: QueryOptionsAlone<V, T>): Observable<ApolloQueryResult<T>>;
15 static ɵfac: i0.ɵɵFactoryDeclaration<Query<any, any>, never>;
16 static ɵprov: i0.ɵɵInjectableDeclaration<Query<any, any>>;
17}