-
Notifications
You must be signed in to change notification settings - Fork 0
/
types.go
59 lines (51 loc) · 952 Bytes
/
types.go
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
52
53
54
55
56
57
58
59
package protodefgen
type Proto struct {
Description string
Package string
Options []Option
Imports []string
Enums []Enum
Messages []Message
Services []Service
}
type Option struct {
GoPackage string
}
type Message struct {
Description string
Name string
Fields []MessageField
Enums []Enum
Messages []Message
}
type MessageField struct {
Description string
Id uint
Name string
Type string
Optional bool
Repeated bool
}
type Enum struct {
Description string
Name string
Constants []EnumConstant
}
type EnumConstant struct {
Description string
Name string
Value uint
}
type Service struct {
Description string
Name string
Methods []ServiceMethod
}
type ServiceMethod struct {
Description string
Name string
Request string
StreamRequest bool
Response string
StreamResponse bool
}