Kind: Class
Source: atloria-monorepo/apps/api-schema-parser/src/parsers/grpc.parser.ts
gRPC Parser Implementation
Supports:
- Protocol Buffers syntax (proto2 and proto3)
- Services and RPCs
- Messages and nested types
- Enums
- Options and comments
Implements: IParser
Methods
| Method | Signature | Returns |
|---|---|---|
initialize | initialize(config: ParserConfig) | Promise<void> |
canParse | canParse(filePath: string) | boolean |
parseFile | parseFile(filePath: string, content: string) | Promise<ParseResult> |
parseFiles | parseFiles(files: ParseFileInput[]) | Promise<ParseResult[]> |
destroy | destroy() | Promise<void> |
Properties
| Property | Type |
|---|---|
name | any |
version | any |
supportedPatterns | any |
Where it refuses work
GrpcParserstops the work with an early return when!message.fields.GrpcParserstops the work with an early return whentypeName.includes('.').
When something fails
GrpcParserhandles failure in 1 place: it turns it into a return value in all 1.
Referenced By
AppModule(MODULE_PROVIDES)AppModule(MODULE_EXPORTS)
Was this page helpful?