@omnigraph/grpc
Version:
28 lines (27 loc) • 1.12 kB
text/typescript
import protobufjs, { type AnyNestedObject } from 'protobufjs';
import type { Logger, YamlConfig } from '@graphql-mesh/types';
import { type MaybePromise } from '@graphql-tools/utils';
import { type ChannelCredentials } from '@grpc/grpc-js';
import { DisposableStack } from '@whatwg-node/disposablestack';
export declare class GrpcLoaderHelper extends DisposableStack {
private subgraphName;
private baseDir;
private logger;
private config;
private schemaComposer;
constructor(subgraphName: string, baseDir: string, logger: Logger, config: YamlConfig.GrpcHandler);
buildSchema(): Promise<import("graphql").GraphQLSchema>;
private processReflection;
private processDescriptorFile;
private processProtoFile;
private getDescriptorSets;
getCredentials(): MaybePromise<ChannelCredentials>;
visit({ nested, name, currentPath, rootJsonName, rootJson, rootLogger: logger, }: {
nested: AnyNestedObject;
name: string;
currentPath: string[];
rootJsonName: string;
rootJson: protobufjs.INamespace;
rootLogger: Logger;
}): void;
}