forked from meshtastic/meshtastic
-
Notifications
You must be signed in to change notification settings - Fork 0
/
protobuf.tmpl
51 lines (43 loc) · 1.22 KB
/
protobuf.tmpl
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
---
id: protobuf-api
title: Protobuf API Reference
slug: /developers/protobufs/api
sidebar_label: Protobufs
sidebar_position: 20
---
<!-- THIS PAGE IS AUTOGENERATED FROM ./scripts/gen-proto-docs.sh DO NOT EDIT -->
{{range .Files}}
## {{.Name}}
{{if .Messages}}
{{range .Messages}}
### {{.LongName}}
{{if .Description}}
:::note `message` description
{{.Description}}
:::
{{end}}
{{if .HasFields}}
| Field | Type | Description |
| ----- | ---- | ----------- |
{{range .Fields -}}
| {{if .IsOneof}}[**oneof**](https://developers.google.com/protocol-buffers/docs/proto3#oneof) {{.OneofDecl}}.{{end}}{{.Name}} | {{if eq (index .LongType 0) (index (.LongType | upper) 0 )}}[`{{.LongType}}`](#{{.LongType | lower | replace "." ""}}){{else}}{{.LongType}}{{end}} | {{if .Description}}{{nobr .Description}}{{if .DefaultValue}} Default: {{.DefaultValue}}{{end}}{{else}}none{{end}} |
{{end}}
{{end}}
{{end}}
{{end}}
{{if .Enums}}
{{range .Enums}}
### {{.LongName}}
{{if .Description}}
:::note `enum` description
{{.Description}}
:::
{{end}}
| Name | Number | Description |
| ---- | ------ | ----------- |
{{range .Values -}}
| `{{.Name}}` | `{{.Number}}` | {{if .Description}}{{nobr .Description}}{{else}}none{{end}} |
{{end}}
{{end}}
{{end}}
{{end}}