UNPKG

1.5 kBTypeScriptView Raw
1import { GraphQLSchema } from 'graphql';
2import { GraphQLSchemaBuilder } from '../graphql-schema.builder';
3import { GraphQLSchemaHost } from '../graphql-schema.host';
4import { GqlModuleOptions, BuildFederatedSchemaOptions } from '../interfaces';
5import { ResolversExplorerService, ScalarsExplorerService } from '../services';
6export declare class GraphQLFederationFactory {
7 private readonly resolversExplorerService;
8 private readonly scalarsExplorerService;
9 private readonly gqlSchemaBuilder;
10 private readonly gqlSchemaHost;
11 constructor(resolversExplorerService: ResolversExplorerService, scalarsExplorerService: ScalarsExplorerService, gqlSchemaBuilder: GraphQLSchemaBuilder, gqlSchemaHost: GraphQLSchemaHost);
12 mergeWithSchema<T extends GqlModuleOptions>(options?: T, buildFederatedSchema?: (options: BuildFederatedSchemaOptions) => GraphQLSchema): Promise<T>;
13 private buildSchemaFromTypeDefs;
14 private generateSchema;
15 private getResolvers;
16 private extendResolvers;
17 private overrideOrExtendResolvers;
18 /**
19 * Ensures that the resolveType method for unions and interfaces in the federated schema
20 * is properly set from the one in the autoGeneratedSchema.
21 */
22 private overrideFederatedResolveType;
23 buildFederatedSchema<T extends GqlModuleOptions>(autoSchemaFile: string | boolean, options: T, resolvers: Function[]): Promise<GraphQLSchema>;
24 private loadFederationDirectives;
25}
26//# sourceMappingURL=graphql-federation.factory.d.ts.map
\No newline at end of file