Generator improvements and cleanup
[govpp.git] / examples / bin_api / vpe / vpe.ba.go
1 // Code generated by GoVPP binapi-generator. DO NOT EDIT.
2 //  source: vpe.api.json
3
4 /*
5  Package vpe is a generated from VPP binary API module 'vpe'.
6
7  It contains following objects:
8           9 services
9           1 type
10          18 messages
11 */
12 package vpe
13
14 import api "git.fd.io/govpp.git/api"
15 import struc "github.com/lunixbochs/struc"
16 import bytes "bytes"
17
18 // Reference imports to suppress errors if they are not otherwise used.
19 var _ = api.RegisterMessage
20 var _ = struc.Pack
21 var _ = bytes.NewBuffer
22
23 // Services represents VPP binary API services:
24 type Services interface {
25         AddNodeNext(*AddNodeNext) (*AddNodeNextReply, error)
26         Cli(*Cli) (*CliReply, error)
27         CliInband(*CliInband) (*CliInbandReply, error)
28         ControlPing(*ControlPing) (*ControlPingReply, error)
29         GetNextIndex(*GetNextIndex) (*GetNextIndexReply, error)
30         GetNodeGraph(*GetNodeGraph) (*GetNodeGraphReply, error)
31         GetNodeIndex(*GetNodeIndex) (*GetNodeIndexReply, error)
32         ShowThreads(*ShowThreads) (*ShowThreadsReply, error)
33         ShowVersion(*ShowVersion) (*ShowVersionReply, error)
34 }
35
36 /* Types */
37
38 // ThreadData represents VPP binary API type 'thread_data':
39 type ThreadData struct {
40         ID        uint32
41         Name      []byte `struc:"[64]byte"`
42         Type      []byte `struc:"[64]byte"`
43         PID       uint32
44         CPUID     uint32
45         Core      uint32
46         CPUSocket uint32
47 }
48
49 func (*ThreadData) GetTypeName() string {
50         return "thread_data"
51 }
52 func (*ThreadData) GetCrcString() string {
53         return "0f57094e"
54 }
55
56 /* Messages */
57
58 // AddNodeNext represents VPP binary API message 'add_node_next':
59 type AddNodeNext struct {
60         NodeName []byte `struc:"[64]byte"`
61         NextName []byte `struc:"[64]byte"`
62 }
63
64 func (*AddNodeNext) GetMessageName() string {
65         return "add_node_next"
66 }
67 func (*AddNodeNext) GetCrcString() string {
68         return "9ab92f7a"
69 }
70 func (*AddNodeNext) GetMessageType() api.MessageType {
71         return api.RequestMessage
72 }
73
74 // AddNodeNextReply represents VPP binary API message 'add_node_next_reply':
75 type AddNodeNextReply struct {
76         Retval    int32
77         NextIndex uint32
78 }
79
80 func (*AddNodeNextReply) GetMessageName() string {
81         return "add_node_next_reply"
82 }
83 func (*AddNodeNextReply) GetCrcString() string {
84         return "2ed75f32"
85 }
86 func (*AddNodeNextReply) GetMessageType() api.MessageType {
87         return api.ReplyMessage
88 }
89
90 // Cli represents VPP binary API message 'cli':
91 type Cli struct {
92         CmdInShmem uint64
93 }
94
95 func (*Cli) GetMessageName() string {
96         return "cli"
97 }
98 func (*Cli) GetCrcString() string {
99         return "23bfbfff"
100 }
101 func (*Cli) GetMessageType() api.MessageType {
102         return api.RequestMessage
103 }
104
105 // CliInband represents VPP binary API message 'cli_inband':
106 type CliInband struct {
107         XXX_CmdLen uint32 `struc:"sizeof=Cmd"`
108         Cmd        string
109 }
110
111 func (*CliInband) GetMessageName() string {
112         return "cli_inband"
113 }
114 func (*CliInband) GetCrcString() string {
115         return "b1ad59b3"
116 }
117 func (*CliInband) GetMessageType() api.MessageType {
118         return api.RequestMessage
119 }
120
121 // CliInbandReply represents VPP binary API message 'cli_inband_reply':
122 type CliInbandReply struct {
123         Retval       int32
124         XXX_ReplyLen uint32 `struc:"sizeof=Reply"`
125         Reply        string
126 }
127
128 func (*CliInbandReply) GetMessageName() string {
129         return "cli_inband_reply"
130 }
131 func (*CliInbandReply) GetCrcString() string {
132         return "6d3c80a4"
133 }
134 func (*CliInbandReply) GetMessageType() api.MessageType {
135         return api.ReplyMessage
136 }
137
138 // CliReply represents VPP binary API message 'cli_reply':
139 type CliReply struct {
140         Retval       int32
141         ReplyInShmem uint64
142 }
143
144 func (*CliReply) GetMessageName() string {
145         return "cli_reply"
146 }
147 func (*CliReply) GetCrcString() string {
148         return "06d68297"
149 }
150 func (*CliReply) GetMessageType() api.MessageType {
151         return api.ReplyMessage
152 }
153
154 // ControlPing represents VPP binary API message 'control_ping':
155 type ControlPing struct{}
156
157 func (*ControlPing) GetMessageName() string {
158         return "control_ping"
159 }
160 func (*ControlPing) GetCrcString() string {
161         return "51077d14"
162 }
163 func (*ControlPing) GetMessageType() api.MessageType {
164         return api.RequestMessage
165 }
166
167 // ControlPingReply represents VPP binary API message 'control_ping_reply':
168 type ControlPingReply struct {
169         Retval      int32
170         ClientIndex uint32
171         VpePID      uint32
172 }
173
174 func (*ControlPingReply) GetMessageName() string {
175         return "control_ping_reply"
176 }
177 func (*ControlPingReply) GetCrcString() string {
178         return "f6b0b8ca"
179 }
180 func (*ControlPingReply) GetMessageType() api.MessageType {
181         return api.ReplyMessage
182 }
183
184 // GetNextIndex represents VPP binary API message 'get_next_index':
185 type GetNextIndex struct {
186         NodeName []byte `struc:"[64]byte"`
187         NextName []byte `struc:"[64]byte"`
188 }
189
190 func (*GetNextIndex) GetMessageName() string {
191         return "get_next_index"
192 }
193 func (*GetNextIndex) GetCrcString() string {
194         return "9ab92f7a"
195 }
196 func (*GetNextIndex) GetMessageType() api.MessageType {
197         return api.RequestMessage
198 }
199
200 // GetNextIndexReply represents VPP binary API message 'get_next_index_reply':
201 type GetNextIndexReply struct {
202         Retval    int32
203         NextIndex uint32
204 }
205
206 func (*GetNextIndexReply) GetMessageName() string {
207         return "get_next_index_reply"
208 }
209 func (*GetNextIndexReply) GetCrcString() string {
210         return "2ed75f32"
211 }
212 func (*GetNextIndexReply) GetMessageType() api.MessageType {
213         return api.ReplyMessage
214 }
215
216 // GetNodeGraph represents VPP binary API message 'get_node_graph':
217 type GetNodeGraph struct{}
218
219 func (*GetNodeGraph) GetMessageName() string {
220         return "get_node_graph"
221 }
222 func (*GetNodeGraph) GetCrcString() string {
223         return "51077d14"
224 }
225 func (*GetNodeGraph) GetMessageType() api.MessageType {
226         return api.RequestMessage
227 }
228
229 // GetNodeGraphReply represents VPP binary API message 'get_node_graph_reply':
230 type GetNodeGraphReply struct {
231         Retval       int32
232         ReplyInShmem uint64
233 }
234
235 func (*GetNodeGraphReply) GetMessageName() string {
236         return "get_node_graph_reply"
237 }
238 func (*GetNodeGraphReply) GetCrcString() string {
239         return "06d68297"
240 }
241 func (*GetNodeGraphReply) GetMessageType() api.MessageType {
242         return api.ReplyMessage
243 }
244
245 // GetNodeIndex represents VPP binary API message 'get_node_index':
246 type GetNodeIndex struct {
247         NodeName []byte `struc:"[64]byte"`
248 }
249
250 func (*GetNodeIndex) GetMessageName() string {
251         return "get_node_index"
252 }
253 func (*GetNodeIndex) GetCrcString() string {
254         return "6c9a495d"
255 }
256 func (*GetNodeIndex) GetMessageType() api.MessageType {
257         return api.RequestMessage
258 }
259
260 // GetNodeIndexReply represents VPP binary API message 'get_node_index_reply':
261 type GetNodeIndexReply struct {
262         Retval    int32
263         NodeIndex uint32
264 }
265
266 func (*GetNodeIndexReply) GetMessageName() string {
267         return "get_node_index_reply"
268 }
269 func (*GetNodeIndexReply) GetCrcString() string {
270         return "a8600b89"
271 }
272 func (*GetNodeIndexReply) GetMessageType() api.MessageType {
273         return api.ReplyMessage
274 }
275
276 // ShowThreads represents VPP binary API message 'show_threads':
277 type ShowThreads struct{}
278
279 func (*ShowThreads) GetMessageName() string {
280         return "show_threads"
281 }
282 func (*ShowThreads) GetCrcString() string {
283         return "51077d14"
284 }
285 func (*ShowThreads) GetMessageType() api.MessageType {
286         return api.RequestMessage
287 }
288
289 // ShowThreadsReply represents VPP binary API message 'show_threads_reply':
290 type ShowThreadsReply struct {
291         Retval     int32
292         Count      uint32 `struc:"sizeof=ThreadData"`
293         ThreadData []ThreadData
294 }
295
296 func (*ShowThreadsReply) GetMessageName() string {
297         return "show_threads_reply"
298 }
299 func (*ShowThreadsReply) GetCrcString() string {
300         return "6942fb35"
301 }
302 func (*ShowThreadsReply) GetMessageType() api.MessageType {
303         return api.ReplyMessage
304 }
305
306 // ShowVersion represents VPP binary API message 'show_version':
307 type ShowVersion struct{}
308
309 func (*ShowVersion) GetMessageName() string {
310         return "show_version"
311 }
312 func (*ShowVersion) GetCrcString() string {
313         return "51077d14"
314 }
315 func (*ShowVersion) GetMessageType() api.MessageType {
316         return api.RequestMessage
317 }
318
319 // ShowVersionReply represents VPP binary API message 'show_version_reply':
320 type ShowVersionReply struct {
321         Retval                int32
322         XXX_ProgramLen        uint32 `struc:"sizeof=Program"`
323         Program               string
324         XXX_VersionLen        uint32 `struc:"sizeof=Version"`
325         Version               string
326         XXX_BuildDateLen      uint32 `struc:"sizeof=BuildDate"`
327         BuildDate             string
328         XXX_BuildDirectoryLen uint32 `struc:"sizeof=BuildDirectory"`
329         BuildDirectory        string
330 }
331
332 func (*ShowVersionReply) GetMessageName() string {
333         return "show_version_reply"
334 }
335 func (*ShowVersionReply) GetCrcString() string {
336         return "b9bcf6df"
337 }
338 func (*ShowVersionReply) GetMessageType() api.MessageType {
339         return api.ReplyMessage
340 }
341
342 func init() {
343         api.RegisterMessage((*AddNodeNext)(nil), "vpe.AddNodeNext")
344         api.RegisterMessage((*AddNodeNextReply)(nil), "vpe.AddNodeNextReply")
345         api.RegisterMessage((*Cli)(nil), "vpe.Cli")
346         api.RegisterMessage((*CliInband)(nil), "vpe.CliInband")
347         api.RegisterMessage((*CliInbandReply)(nil), "vpe.CliInbandReply")
348         api.RegisterMessage((*CliReply)(nil), "vpe.CliReply")
349         api.RegisterMessage((*ControlPing)(nil), "vpe.ControlPing")
350         api.RegisterMessage((*ControlPingReply)(nil), "vpe.ControlPingReply")
351         api.RegisterMessage((*GetNextIndex)(nil), "vpe.GetNextIndex")
352         api.RegisterMessage((*GetNextIndexReply)(nil), "vpe.GetNextIndexReply")
353         api.RegisterMessage((*GetNodeGraph)(nil), "vpe.GetNodeGraph")
354         api.RegisterMessage((*GetNodeGraphReply)(nil), "vpe.GetNodeGraphReply")
355         api.RegisterMessage((*GetNodeIndex)(nil), "vpe.GetNodeIndex")
356         api.RegisterMessage((*GetNodeIndexReply)(nil), "vpe.GetNodeIndexReply")
357         api.RegisterMessage((*ShowThreads)(nil), "vpe.ShowThreads")
358         api.RegisterMessage((*ShowThreadsReply)(nil), "vpe.ShowThreadsReply")
359         api.RegisterMessage((*ShowVersion)(nil), "vpe.ShowVersion")
360         api.RegisterMessage((*ShowVersionReply)(nil), "vpe.ShowVersionReply")
361 }