1 | import { DirectiveNode, GraphQLSchema, InterfaceTypeDefinitionNode, InterfaceTypeExtensionNode, ObjectTypeDefinitionNode, ObjectTypeExtensionNode, UnionTypeDefinitionNode, UnionTypeExtensionNode } from 'graphql';
|
2 | import { ASTVisitFn } from '../gql16types';
|
3 | import { ServiceDefinition } from './types';
|
4 | export declare type DirectiveUsages = Map<string, DirectiveNode[]>;
|
5 | declare type DirectiveUsagesPerField = Map<string, DirectiveUsages>;
|
6 | declare type DirectiveUsagesPerType = Map<string, {
|
7 | directives: DirectiveUsages;
|
8 | fields: DirectiveUsagesPerField;
|
9 | }>;
|
10 | declare type DirectiveUsagesPerSubgraph = Map<string, DirectiveUsagesPerType>;
|
11 | declare type ObjectInterfaceOrUnionTypeNode = ObjectTypeDefinitionNode | ObjectTypeExtensionNode | InterfaceTypeDefinitionNode | InterfaceTypeExtensionNode | UnionTypeDefinitionNode | UnionTypeExtensionNode;
|
12 | export declare class DirectiveMetadata {
|
13 | directiveUsagesPerSubgraph: DirectiveUsagesPerSubgraph;
|
14 | constructor(subgraphs: ServiceDefinition[]);
|
15 | getTypeVisitor(subgraphName: string): ASTVisitFn<ObjectInterfaceOrUnionTypeNode>;
|
16 | hasUsages(directiveName: string): boolean;
|
17 | applyMetadataToSupergraphSchema(schema: GraphQLSchema): void;
|
18 | }
|
19 | export {};
|
20 |
|
\ | No newline at end of file |