# GrpcParser

**Kind:** Class

**Source:** [`atloria-monorepo/apps/api-schema-parser/src/parsers/grpc.parser.ts`](https://github.com/sherkety/atloria/blob/main/atloria-monorepo/apps/api-schema-parser/src/parsers/grpc.parser.ts#L37)

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

- `GrpcParser` stops the work with an early return when `!message.fields`.
- `GrpcParser` stops the work with an early return when `typeName.includes('.')`.

## When something fails

- `GrpcParser` handles failure in 1 place: it turns it into a return value in all 1.

## Referenced By

- `AppModule` (MODULE_PROVIDES)
- `AppModule` (MODULE_EXPORTS)
