Update generated binapi to v22.02 & makefile changes
[govpp.git] / internal / testbinapi / binapi2001 / lisp_gpe / lisp_gpe.ba.go
1 // Code generated by GoVPP's binapi-generator. DO NOT EDIT.
2 // versions:
3 //  binapi-generator: v0.5.0-dev
4 //  VPP:              20.01
5 // source: .vppapi/core/lisp_gpe.api.json
6
7 // Package lisp_gpe contains generated bindings for API file lisp_gpe.api.
8 //
9 // Contents:
10 //   3 structs
11 //  20 messages
12 //
13 package lisp_gpe
14
15 import (
16         api "git.fd.io/govpp.git/api"
17         codec "git.fd.io/govpp.git/codec"
18 )
19
20 // This is a compile-time assertion to ensure that this generated file
21 // is compatible with the GoVPP api package it is being compiled against.
22 // A compilation error at this line likely means your copy of the
23 // GoVPP api package needs to be updated.
24 const _ = api.GoVppAPIPackageIsVersion2
25
26 const (
27         APIFile    = "lisp_gpe"
28         APIVersion = "1.0.0"
29         VersionCrc = 0x9396c80c
30 )
31
32 // GpeFwdEntry defines type 'gpe_fwd_entry'.
33 type GpeFwdEntry struct {
34         FwdEntryIndex uint32 `binapi:"u32,name=fwd_entry_index" json:"fwd_entry_index,omitempty"`
35         DpTable       uint32 `binapi:"u32,name=dp_table" json:"dp_table,omitempty"`
36         EidType       uint8  `binapi:"u8,name=eid_type" json:"eid_type,omitempty"`
37         LeidPrefixLen uint8  `binapi:"u8,name=leid_prefix_len" json:"leid_prefix_len,omitempty"`
38         ReidPrefixLen uint8  `binapi:"u8,name=reid_prefix_len" json:"reid_prefix_len,omitempty"`
39         Leid          []byte `binapi:"u8[16],name=leid" json:"leid,omitempty"`
40         Reid          []byte `binapi:"u8[16],name=reid" json:"reid,omitempty"`
41         Vni           uint32 `binapi:"u32,name=vni" json:"vni,omitempty"`
42         Action        uint8  `binapi:"u8,name=action" json:"action,omitempty"`
43 }
44
45 // GpeLocator defines type 'gpe_locator'.
46 type GpeLocator struct {
47         IsIP4  uint8  `binapi:"u8,name=is_ip4" json:"is_ip4,omitempty"`
48         Weight uint8  `binapi:"u8,name=weight" json:"weight,omitempty"`
49         Addr   []byte `binapi:"u8[16],name=addr" json:"addr,omitempty"`
50 }
51
52 // GpeNativeFwdRpath defines type 'gpe_native_fwd_rpath'.
53 type GpeNativeFwdRpath struct {
54         FibIndex    uint32 `binapi:"u32,name=fib_index" json:"fib_index,omitempty"`
55         NhSwIfIndex uint32 `binapi:"u32,name=nh_sw_if_index" json:"nh_sw_if_index,omitempty"`
56         IsIP4       uint8  `binapi:"u8,name=is_ip4" json:"is_ip4,omitempty"`
57         NhAddr      []byte `binapi:"u8[16],name=nh_addr" json:"nh_addr,omitempty"`
58 }
59
60 // GpeAddDelFwdEntry defines message 'gpe_add_del_fwd_entry'.
61 type GpeAddDelFwdEntry struct {
62         IsAdd   uint8        `binapi:"u8,name=is_add" json:"is_add,omitempty"`
63         EidType uint8        `binapi:"u8,name=eid_type" json:"eid_type,omitempty"`
64         RmtEid  []byte       `binapi:"u8[16],name=rmt_eid" json:"rmt_eid,omitempty"`
65         LclEid  []byte       `binapi:"u8[16],name=lcl_eid" json:"lcl_eid,omitempty"`
66         RmtLen  uint8        `binapi:"u8,name=rmt_len" json:"rmt_len,omitempty"`
67         LclLen  uint8        `binapi:"u8,name=lcl_len" json:"lcl_len,omitempty"`
68         Vni     uint32       `binapi:"u32,name=vni" json:"vni,omitempty"`
69         DpTable uint32       `binapi:"u32,name=dp_table" json:"dp_table,omitempty"`
70         Action  uint8        `binapi:"u8,name=action" json:"action,omitempty"`
71         LocNum  uint32       `binapi:"u32,name=loc_num" json:"-"`
72         Locs    []GpeLocator `binapi:"gpe_locator[loc_num],name=locs" json:"locs,omitempty"`
73 }
74
75 func (m *GpeAddDelFwdEntry) Reset()               { *m = GpeAddDelFwdEntry{} }
76 func (*GpeAddDelFwdEntry) GetMessageName() string { return "gpe_add_del_fwd_entry" }
77 func (*GpeAddDelFwdEntry) GetCrcString() string   { return "afbf857a" }
78 func (*GpeAddDelFwdEntry) GetMessageType() api.MessageType {
79         return api.RequestMessage
80 }
81
82 func (m *GpeAddDelFwdEntry) Size() (size int) {
83         if m == nil {
84                 return 0
85         }
86         size += 1      // m.IsAdd
87         size += 1      // m.EidType
88         size += 1 * 16 // m.RmtEid
89         size += 1 * 16 // m.LclEid
90         size += 1      // m.RmtLen
91         size += 1      // m.LclLen
92         size += 4      // m.Vni
93         size += 4      // m.DpTable
94         size += 1      // m.Action
95         size += 4      // m.LocNum
96         for j1 := 0; j1 < len(m.Locs); j1++ {
97                 var s1 GpeLocator
98                 _ = s1
99                 if j1 < len(m.Locs) {
100                         s1 = m.Locs[j1]
101                 }
102                 size += 1      // s1.IsIP4
103                 size += 1      // s1.Weight
104                 size += 1 * 16 // s1.Addr
105         }
106         return size
107 }
108 func (m *GpeAddDelFwdEntry) Marshal(b []byte) ([]byte, error) {
109         if b == nil {
110                 b = make([]byte, m.Size())
111         }
112         buf := codec.NewBuffer(b)
113         buf.EncodeUint8(m.IsAdd)
114         buf.EncodeUint8(m.EidType)
115         buf.EncodeBytes(m.RmtEid, 16)
116         buf.EncodeBytes(m.LclEid, 16)
117         buf.EncodeUint8(m.RmtLen)
118         buf.EncodeUint8(m.LclLen)
119         buf.EncodeUint32(m.Vni)
120         buf.EncodeUint32(m.DpTable)
121         buf.EncodeUint8(m.Action)
122         buf.EncodeUint32(uint32(len(m.Locs)))
123         for j0 := 0; j0 < len(m.Locs); j0++ {
124                 var v0 GpeLocator // Locs
125                 if j0 < len(m.Locs) {
126                         v0 = m.Locs[j0]
127                 }
128                 buf.EncodeUint8(v0.IsIP4)
129                 buf.EncodeUint8(v0.Weight)
130                 buf.EncodeBytes(v0.Addr, 16)
131         }
132         return buf.Bytes(), nil
133 }
134 func (m *GpeAddDelFwdEntry) Unmarshal(b []byte) error {
135         buf := codec.NewBuffer(b)
136         m.IsAdd = buf.DecodeUint8()
137         m.EidType = buf.DecodeUint8()
138         m.RmtEid = make([]byte, 16)
139         copy(m.RmtEid, buf.DecodeBytes(len(m.RmtEid)))
140         m.LclEid = make([]byte, 16)
141         copy(m.LclEid, buf.DecodeBytes(len(m.LclEid)))
142         m.RmtLen = buf.DecodeUint8()
143         m.LclLen = buf.DecodeUint8()
144         m.Vni = buf.DecodeUint32()
145         m.DpTable = buf.DecodeUint32()
146         m.Action = buf.DecodeUint8()
147         m.LocNum = buf.DecodeUint32()
148         m.Locs = make([]GpeLocator, m.LocNum)
149         for j0 := 0; j0 < len(m.Locs); j0++ {
150                 m.Locs[j0].IsIP4 = buf.DecodeUint8()
151                 m.Locs[j0].Weight = buf.DecodeUint8()
152                 m.Locs[j0].Addr = make([]byte, 16)
153                 copy(m.Locs[j0].Addr, buf.DecodeBytes(len(m.Locs[j0].Addr)))
154         }
155         return nil
156 }
157
158 // GpeAddDelFwdEntryReply defines message 'gpe_add_del_fwd_entry_reply'.
159 type GpeAddDelFwdEntryReply struct {
160         Retval        int32  `binapi:"i32,name=retval" json:"retval,omitempty"`
161         FwdEntryIndex uint32 `binapi:"u32,name=fwd_entry_index" json:"fwd_entry_index,omitempty"`
162 }
163
164 func (m *GpeAddDelFwdEntryReply) Reset()               { *m = GpeAddDelFwdEntryReply{} }
165 func (*GpeAddDelFwdEntryReply) GetMessageName() string { return "gpe_add_del_fwd_entry_reply" }
166 func (*GpeAddDelFwdEntryReply) GetCrcString() string   { return "efe5f176" }
167 func (*GpeAddDelFwdEntryReply) GetMessageType() api.MessageType {
168         return api.ReplyMessage
169 }
170
171 func (m *GpeAddDelFwdEntryReply) Size() (size int) {
172         if m == nil {
173                 return 0
174         }
175         size += 4 // m.Retval
176         size += 4 // m.FwdEntryIndex
177         return size
178 }
179 func (m *GpeAddDelFwdEntryReply) Marshal(b []byte) ([]byte, error) {
180         if b == nil {
181                 b = make([]byte, m.Size())
182         }
183         buf := codec.NewBuffer(b)
184         buf.EncodeInt32(m.Retval)
185         buf.EncodeUint32(m.FwdEntryIndex)
186         return buf.Bytes(), nil
187 }
188 func (m *GpeAddDelFwdEntryReply) Unmarshal(b []byte) error {
189         buf := codec.NewBuffer(b)
190         m.Retval = buf.DecodeInt32()
191         m.FwdEntryIndex = buf.DecodeUint32()
192         return nil
193 }
194
195 // GpeAddDelIface defines message 'gpe_add_del_iface'.
196 type GpeAddDelIface struct {
197         IsAdd   uint8  `binapi:"u8,name=is_add" json:"is_add,omitempty"`
198         IsL2    uint8  `binapi:"u8,name=is_l2" json:"is_l2,omitempty"`
199         DpTable uint32 `binapi:"u32,name=dp_table" json:"dp_table,omitempty"`
200         Vni     uint32 `binapi:"u32,name=vni" json:"vni,omitempty"`
201 }
202
203 func (m *GpeAddDelIface) Reset()               { *m = GpeAddDelIface{} }
204 func (*GpeAddDelIface) GetMessageName() string { return "gpe_add_del_iface" }
205 func (*GpeAddDelIface) GetCrcString() string   { return "42d6b533" }
206 func (*GpeAddDelIface) GetMessageType() api.MessageType {
207         return api.RequestMessage
208 }
209
210 func (m *GpeAddDelIface) Size() (size int) {
211         if m == nil {
212                 return 0
213         }
214         size += 1 // m.IsAdd
215         size += 1 // m.IsL2
216         size += 4 // m.DpTable
217         size += 4 // m.Vni
218         return size
219 }
220 func (m *GpeAddDelIface) Marshal(b []byte) ([]byte, error) {
221         if b == nil {
222                 b = make([]byte, m.Size())
223         }
224         buf := codec.NewBuffer(b)
225         buf.EncodeUint8(m.IsAdd)
226         buf.EncodeUint8(m.IsL2)
227         buf.EncodeUint32(m.DpTable)
228         buf.EncodeUint32(m.Vni)
229         return buf.Bytes(), nil
230 }
231 func (m *GpeAddDelIface) Unmarshal(b []byte) error {
232         buf := codec.NewBuffer(b)
233         m.IsAdd = buf.DecodeUint8()
234         m.IsL2 = buf.DecodeUint8()
235         m.DpTable = buf.DecodeUint32()
236         m.Vni = buf.DecodeUint32()
237         return nil
238 }
239
240 // GpeAddDelIfaceReply defines message 'gpe_add_del_iface_reply'.
241 type GpeAddDelIfaceReply struct {
242         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
243 }
244
245 func (m *GpeAddDelIfaceReply) Reset()               { *m = GpeAddDelIfaceReply{} }
246 func (*GpeAddDelIfaceReply) GetMessageName() string { return "gpe_add_del_iface_reply" }
247 func (*GpeAddDelIfaceReply) GetCrcString() string   { return "e8d4e804" }
248 func (*GpeAddDelIfaceReply) GetMessageType() api.MessageType {
249         return api.ReplyMessage
250 }
251
252 func (m *GpeAddDelIfaceReply) Size() (size int) {
253         if m == nil {
254                 return 0
255         }
256         size += 4 // m.Retval
257         return size
258 }
259 func (m *GpeAddDelIfaceReply) Marshal(b []byte) ([]byte, error) {
260         if b == nil {
261                 b = make([]byte, m.Size())
262         }
263         buf := codec.NewBuffer(b)
264         buf.EncodeInt32(m.Retval)
265         return buf.Bytes(), nil
266 }
267 func (m *GpeAddDelIfaceReply) Unmarshal(b []byte) error {
268         buf := codec.NewBuffer(b)
269         m.Retval = buf.DecodeInt32()
270         return nil
271 }
272
273 // GpeAddDelNativeFwdRpath defines message 'gpe_add_del_native_fwd_rpath'.
274 type GpeAddDelNativeFwdRpath struct {
275         IsAdd       uint8  `binapi:"u8,name=is_add" json:"is_add,omitempty"`
276         TableID     uint32 `binapi:"u32,name=table_id" json:"table_id,omitempty"`
277         NhSwIfIndex uint32 `binapi:"u32,name=nh_sw_if_index" json:"nh_sw_if_index,omitempty"`
278         IsIP4       uint8  `binapi:"u8,name=is_ip4" json:"is_ip4,omitempty"`
279         NhAddr      []byte `binapi:"u8[16],name=nh_addr" json:"nh_addr,omitempty"`
280 }
281
282 func (m *GpeAddDelNativeFwdRpath) Reset()               { *m = GpeAddDelNativeFwdRpath{} }
283 func (*GpeAddDelNativeFwdRpath) GetMessageName() string { return "gpe_add_del_native_fwd_rpath" }
284 func (*GpeAddDelNativeFwdRpath) GetCrcString() string   { return "bfc42b8f" }
285 func (*GpeAddDelNativeFwdRpath) GetMessageType() api.MessageType {
286         return api.RequestMessage
287 }
288
289 func (m *GpeAddDelNativeFwdRpath) Size() (size int) {
290         if m == nil {
291                 return 0
292         }
293         size += 1      // m.IsAdd
294         size += 4      // m.TableID
295         size += 4      // m.NhSwIfIndex
296         size += 1      // m.IsIP4
297         size += 1 * 16 // m.NhAddr
298         return size
299 }
300 func (m *GpeAddDelNativeFwdRpath) Marshal(b []byte) ([]byte, error) {
301         if b == nil {
302                 b = make([]byte, m.Size())
303         }
304         buf := codec.NewBuffer(b)
305         buf.EncodeUint8(m.IsAdd)
306         buf.EncodeUint32(m.TableID)
307         buf.EncodeUint32(m.NhSwIfIndex)
308         buf.EncodeUint8(m.IsIP4)
309         buf.EncodeBytes(m.NhAddr, 16)
310         return buf.Bytes(), nil
311 }
312 func (m *GpeAddDelNativeFwdRpath) Unmarshal(b []byte) error {
313         buf := codec.NewBuffer(b)
314         m.IsAdd = buf.DecodeUint8()
315         m.TableID = buf.DecodeUint32()
316         m.NhSwIfIndex = buf.DecodeUint32()
317         m.IsIP4 = buf.DecodeUint8()
318         m.NhAddr = make([]byte, 16)
319         copy(m.NhAddr, buf.DecodeBytes(len(m.NhAddr)))
320         return nil
321 }
322
323 // GpeAddDelNativeFwdRpathReply defines message 'gpe_add_del_native_fwd_rpath_reply'.
324 type GpeAddDelNativeFwdRpathReply struct {
325         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
326 }
327
328 func (m *GpeAddDelNativeFwdRpathReply) Reset() { *m = GpeAddDelNativeFwdRpathReply{} }
329 func (*GpeAddDelNativeFwdRpathReply) GetMessageName() string {
330         return "gpe_add_del_native_fwd_rpath_reply"
331 }
332 func (*GpeAddDelNativeFwdRpathReply) GetCrcString() string { return "e8d4e804" }
333 func (*GpeAddDelNativeFwdRpathReply) GetMessageType() api.MessageType {
334         return api.ReplyMessage
335 }
336
337 func (m *GpeAddDelNativeFwdRpathReply) Size() (size int) {
338         if m == nil {
339                 return 0
340         }
341         size += 4 // m.Retval
342         return size
343 }
344 func (m *GpeAddDelNativeFwdRpathReply) Marshal(b []byte) ([]byte, error) {
345         if b == nil {
346                 b = make([]byte, m.Size())
347         }
348         buf := codec.NewBuffer(b)
349         buf.EncodeInt32(m.Retval)
350         return buf.Bytes(), nil
351 }
352 func (m *GpeAddDelNativeFwdRpathReply) Unmarshal(b []byte) error {
353         buf := codec.NewBuffer(b)
354         m.Retval = buf.DecodeInt32()
355         return nil
356 }
357
358 // GpeEnableDisable defines message 'gpe_enable_disable'.
359 type GpeEnableDisable struct {
360         IsEn uint8 `binapi:"u8,name=is_en" json:"is_en,omitempty"`
361 }
362
363 func (m *GpeEnableDisable) Reset()               { *m = GpeEnableDisable{} }
364 func (*GpeEnableDisable) GetMessageName() string { return "gpe_enable_disable" }
365 func (*GpeEnableDisable) GetCrcString() string   { return "eb0e943b" }
366 func (*GpeEnableDisable) GetMessageType() api.MessageType {
367         return api.RequestMessage
368 }
369
370 func (m *GpeEnableDisable) Size() (size int) {
371         if m == nil {
372                 return 0
373         }
374         size += 1 // m.IsEn
375         return size
376 }
377 func (m *GpeEnableDisable) Marshal(b []byte) ([]byte, error) {
378         if b == nil {
379                 b = make([]byte, m.Size())
380         }
381         buf := codec.NewBuffer(b)
382         buf.EncodeUint8(m.IsEn)
383         return buf.Bytes(), nil
384 }
385 func (m *GpeEnableDisable) Unmarshal(b []byte) error {
386         buf := codec.NewBuffer(b)
387         m.IsEn = buf.DecodeUint8()
388         return nil
389 }
390
391 // GpeEnableDisableReply defines message 'gpe_enable_disable_reply'.
392 type GpeEnableDisableReply struct {
393         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
394 }
395
396 func (m *GpeEnableDisableReply) Reset()               { *m = GpeEnableDisableReply{} }
397 func (*GpeEnableDisableReply) GetMessageName() string { return "gpe_enable_disable_reply" }
398 func (*GpeEnableDisableReply) GetCrcString() string   { return "e8d4e804" }
399 func (*GpeEnableDisableReply) GetMessageType() api.MessageType {
400         return api.ReplyMessage
401 }
402
403 func (m *GpeEnableDisableReply) Size() (size int) {
404         if m == nil {
405                 return 0
406         }
407         size += 4 // m.Retval
408         return size
409 }
410 func (m *GpeEnableDisableReply) Marshal(b []byte) ([]byte, error) {
411         if b == nil {
412                 b = make([]byte, m.Size())
413         }
414         buf := codec.NewBuffer(b)
415         buf.EncodeInt32(m.Retval)
416         return buf.Bytes(), nil
417 }
418 func (m *GpeEnableDisableReply) Unmarshal(b []byte) error {
419         buf := codec.NewBuffer(b)
420         m.Retval = buf.DecodeInt32()
421         return nil
422 }
423
424 // GpeFwdEntriesGet defines message 'gpe_fwd_entries_get'.
425 type GpeFwdEntriesGet struct {
426         Vni uint32 `binapi:"u32,name=vni" json:"vni,omitempty"`
427 }
428
429 func (m *GpeFwdEntriesGet) Reset()               { *m = GpeFwdEntriesGet{} }
430 func (*GpeFwdEntriesGet) GetMessageName() string { return "gpe_fwd_entries_get" }
431 func (*GpeFwdEntriesGet) GetCrcString() string   { return "8d1f2fe9" }
432 func (*GpeFwdEntriesGet) GetMessageType() api.MessageType {
433         return api.RequestMessage
434 }
435
436 func (m *GpeFwdEntriesGet) Size() (size int) {
437         if m == nil {
438                 return 0
439         }
440         size += 4 // m.Vni
441         return size
442 }
443 func (m *GpeFwdEntriesGet) Marshal(b []byte) ([]byte, error) {
444         if b == nil {
445                 b = make([]byte, m.Size())
446         }
447         buf := codec.NewBuffer(b)
448         buf.EncodeUint32(m.Vni)
449         return buf.Bytes(), nil
450 }
451 func (m *GpeFwdEntriesGet) Unmarshal(b []byte) error {
452         buf := codec.NewBuffer(b)
453         m.Vni = buf.DecodeUint32()
454         return nil
455 }
456
457 // GpeFwdEntriesGetReply defines message 'gpe_fwd_entries_get_reply'.
458 type GpeFwdEntriesGetReply struct {
459         Retval  int32         `binapi:"i32,name=retval" json:"retval,omitempty"`
460         Count   uint32        `binapi:"u32,name=count" json:"-"`
461         Entries []GpeFwdEntry `binapi:"gpe_fwd_entry[count],name=entries" json:"entries,omitempty"`
462 }
463
464 func (m *GpeFwdEntriesGetReply) Reset()               { *m = GpeFwdEntriesGetReply{} }
465 func (*GpeFwdEntriesGetReply) GetMessageName() string { return "gpe_fwd_entries_get_reply" }
466 func (*GpeFwdEntriesGetReply) GetCrcString() string   { return "07b02c34" }
467 func (*GpeFwdEntriesGetReply) GetMessageType() api.MessageType {
468         return api.ReplyMessage
469 }
470
471 func (m *GpeFwdEntriesGetReply) Size() (size int) {
472         if m == nil {
473                 return 0
474         }
475         size += 4 // m.Retval
476         size += 4 // m.Count
477         for j1 := 0; j1 < len(m.Entries); j1++ {
478                 var s1 GpeFwdEntry
479                 _ = s1
480                 if j1 < len(m.Entries) {
481                         s1 = m.Entries[j1]
482                 }
483                 size += 4      // s1.FwdEntryIndex
484                 size += 4      // s1.DpTable
485                 size += 1      // s1.EidType
486                 size += 1      // s1.LeidPrefixLen
487                 size += 1      // s1.ReidPrefixLen
488                 size += 1 * 16 // s1.Leid
489                 size += 1 * 16 // s1.Reid
490                 size += 4      // s1.Vni
491                 size += 1      // s1.Action
492         }
493         return size
494 }
495 func (m *GpeFwdEntriesGetReply) Marshal(b []byte) ([]byte, error) {
496         if b == nil {
497                 b = make([]byte, m.Size())
498         }
499         buf := codec.NewBuffer(b)
500         buf.EncodeInt32(m.Retval)
501         buf.EncodeUint32(uint32(len(m.Entries)))
502         for j0 := 0; j0 < len(m.Entries); j0++ {
503                 var v0 GpeFwdEntry // Entries
504                 if j0 < len(m.Entries) {
505                         v0 = m.Entries[j0]
506                 }
507                 buf.EncodeUint32(v0.FwdEntryIndex)
508                 buf.EncodeUint32(v0.DpTable)
509                 buf.EncodeUint8(v0.EidType)
510                 buf.EncodeUint8(v0.LeidPrefixLen)
511                 buf.EncodeUint8(v0.ReidPrefixLen)
512                 buf.EncodeBytes(v0.Leid, 16)
513                 buf.EncodeBytes(v0.Reid, 16)
514                 buf.EncodeUint32(v0.Vni)
515                 buf.EncodeUint8(v0.Action)
516         }
517         return buf.Bytes(), nil
518 }
519 func (m *GpeFwdEntriesGetReply) Unmarshal(b []byte) error {
520         buf := codec.NewBuffer(b)
521         m.Retval = buf.DecodeInt32()
522         m.Count = buf.DecodeUint32()
523         m.Entries = make([]GpeFwdEntry, m.Count)
524         for j0 := 0; j0 < len(m.Entries); j0++ {
525                 m.Entries[j0].FwdEntryIndex = buf.DecodeUint32()
526                 m.Entries[j0].DpTable = buf.DecodeUint32()
527                 m.Entries[j0].EidType = buf.DecodeUint8()
528                 m.Entries[j0].LeidPrefixLen = buf.DecodeUint8()
529                 m.Entries[j0].ReidPrefixLen = buf.DecodeUint8()
530                 m.Entries[j0].Leid = make([]byte, 16)
531                 copy(m.Entries[j0].Leid, buf.DecodeBytes(len(m.Entries[j0].Leid)))
532                 m.Entries[j0].Reid = make([]byte, 16)
533                 copy(m.Entries[j0].Reid, buf.DecodeBytes(len(m.Entries[j0].Reid)))
534                 m.Entries[j0].Vni = buf.DecodeUint32()
535                 m.Entries[j0].Action = buf.DecodeUint8()
536         }
537         return nil
538 }
539
540 // GpeFwdEntryPathDetails defines message 'gpe_fwd_entry_path_details'.
541 type GpeFwdEntryPathDetails struct {
542         LclLoc GpeLocator `binapi:"gpe_locator,name=lcl_loc" json:"lcl_loc,omitempty"`
543         RmtLoc GpeLocator `binapi:"gpe_locator,name=rmt_loc" json:"rmt_loc,omitempty"`
544 }
545
546 func (m *GpeFwdEntryPathDetails) Reset()               { *m = GpeFwdEntryPathDetails{} }
547 func (*GpeFwdEntryPathDetails) GetMessageName() string { return "gpe_fwd_entry_path_details" }
548 func (*GpeFwdEntryPathDetails) GetCrcString() string   { return "a9bdc1f1" }
549 func (*GpeFwdEntryPathDetails) GetMessageType() api.MessageType {
550         return api.ReplyMessage
551 }
552
553 func (m *GpeFwdEntryPathDetails) Size() (size int) {
554         if m == nil {
555                 return 0
556         }
557         size += 1      // m.LclLoc.IsIP4
558         size += 1      // m.LclLoc.Weight
559         size += 1 * 16 // m.LclLoc.Addr
560         size += 1      // m.RmtLoc.IsIP4
561         size += 1      // m.RmtLoc.Weight
562         size += 1 * 16 // m.RmtLoc.Addr
563         return size
564 }
565 func (m *GpeFwdEntryPathDetails) Marshal(b []byte) ([]byte, error) {
566         if b == nil {
567                 b = make([]byte, m.Size())
568         }
569         buf := codec.NewBuffer(b)
570         buf.EncodeUint8(m.LclLoc.IsIP4)
571         buf.EncodeUint8(m.LclLoc.Weight)
572         buf.EncodeBytes(m.LclLoc.Addr, 16)
573         buf.EncodeUint8(m.RmtLoc.IsIP4)
574         buf.EncodeUint8(m.RmtLoc.Weight)
575         buf.EncodeBytes(m.RmtLoc.Addr, 16)
576         return buf.Bytes(), nil
577 }
578 func (m *GpeFwdEntryPathDetails) Unmarshal(b []byte) error {
579         buf := codec.NewBuffer(b)
580         m.LclLoc.IsIP4 = buf.DecodeUint8()
581         m.LclLoc.Weight = buf.DecodeUint8()
582         m.LclLoc.Addr = make([]byte, 16)
583         copy(m.LclLoc.Addr, buf.DecodeBytes(len(m.LclLoc.Addr)))
584         m.RmtLoc.IsIP4 = buf.DecodeUint8()
585         m.RmtLoc.Weight = buf.DecodeUint8()
586         m.RmtLoc.Addr = make([]byte, 16)
587         copy(m.RmtLoc.Addr, buf.DecodeBytes(len(m.RmtLoc.Addr)))
588         return nil
589 }
590
591 // GpeFwdEntryPathDump defines message 'gpe_fwd_entry_path_dump'.
592 type GpeFwdEntryPathDump struct {
593         FwdEntryIndex uint32 `binapi:"u32,name=fwd_entry_index" json:"fwd_entry_index,omitempty"`
594 }
595
596 func (m *GpeFwdEntryPathDump) Reset()               { *m = GpeFwdEntryPathDump{} }
597 func (*GpeFwdEntryPathDump) GetMessageName() string { return "gpe_fwd_entry_path_dump" }
598 func (*GpeFwdEntryPathDump) GetCrcString() string   { return "39bce980" }
599 func (*GpeFwdEntryPathDump) GetMessageType() api.MessageType {
600         return api.RequestMessage
601 }
602
603 func (m *GpeFwdEntryPathDump) Size() (size int) {
604         if m == nil {
605                 return 0
606         }
607         size += 4 // m.FwdEntryIndex
608         return size
609 }
610 func (m *GpeFwdEntryPathDump) Marshal(b []byte) ([]byte, error) {
611         if b == nil {
612                 b = make([]byte, m.Size())
613         }
614         buf := codec.NewBuffer(b)
615         buf.EncodeUint32(m.FwdEntryIndex)
616         return buf.Bytes(), nil
617 }
618 func (m *GpeFwdEntryPathDump) Unmarshal(b []byte) error {
619         buf := codec.NewBuffer(b)
620         m.FwdEntryIndex = buf.DecodeUint32()
621         return nil
622 }
623
624 // GpeFwdEntryVnisGet defines message 'gpe_fwd_entry_vnis_get'.
625 type GpeFwdEntryVnisGet struct{}
626
627 func (m *GpeFwdEntryVnisGet) Reset()               { *m = GpeFwdEntryVnisGet{} }
628 func (*GpeFwdEntryVnisGet) GetMessageName() string { return "gpe_fwd_entry_vnis_get" }
629 func (*GpeFwdEntryVnisGet) GetCrcString() string   { return "51077d14" }
630 func (*GpeFwdEntryVnisGet) GetMessageType() api.MessageType {
631         return api.RequestMessage
632 }
633
634 func (m *GpeFwdEntryVnisGet) Size() (size int) {
635         if m == nil {
636                 return 0
637         }
638         return size
639 }
640 func (m *GpeFwdEntryVnisGet) Marshal(b []byte) ([]byte, error) {
641         if b == nil {
642                 b = make([]byte, m.Size())
643         }
644         buf := codec.NewBuffer(b)
645         return buf.Bytes(), nil
646 }
647 func (m *GpeFwdEntryVnisGet) Unmarshal(b []byte) error {
648         return nil
649 }
650
651 // GpeFwdEntryVnisGetReply defines message 'gpe_fwd_entry_vnis_get_reply'.
652 type GpeFwdEntryVnisGetReply struct {
653         Retval int32    `binapi:"i32,name=retval" json:"retval,omitempty"`
654         Count  uint32   `binapi:"u32,name=count" json:"-"`
655         Vnis   []uint32 `binapi:"u32[count],name=vnis" json:"vnis,omitempty"`
656 }
657
658 func (m *GpeFwdEntryVnisGetReply) Reset()               { *m = GpeFwdEntryVnisGetReply{} }
659 func (*GpeFwdEntryVnisGetReply) GetMessageName() string { return "gpe_fwd_entry_vnis_get_reply" }
660 func (*GpeFwdEntryVnisGetReply) GetCrcString() string   { return "aa70da20" }
661 func (*GpeFwdEntryVnisGetReply) GetMessageType() api.MessageType {
662         return api.ReplyMessage
663 }
664
665 func (m *GpeFwdEntryVnisGetReply) Size() (size int) {
666         if m == nil {
667                 return 0
668         }
669         size += 4               // m.Retval
670         size += 4               // m.Count
671         size += 4 * len(m.Vnis) // m.Vnis
672         return size
673 }
674 func (m *GpeFwdEntryVnisGetReply) Marshal(b []byte) ([]byte, error) {
675         if b == nil {
676                 b = make([]byte, m.Size())
677         }
678         buf := codec.NewBuffer(b)
679         buf.EncodeInt32(m.Retval)
680         buf.EncodeUint32(uint32(len(m.Vnis)))
681         for i := 0; i < len(m.Vnis); i++ {
682                 var x uint32
683                 if i < len(m.Vnis) {
684                         x = uint32(m.Vnis[i])
685                 }
686                 buf.EncodeUint32(x)
687         }
688         return buf.Bytes(), nil
689 }
690 func (m *GpeFwdEntryVnisGetReply) Unmarshal(b []byte) error {
691         buf := codec.NewBuffer(b)
692         m.Retval = buf.DecodeInt32()
693         m.Count = buf.DecodeUint32()
694         m.Vnis = make([]uint32, m.Count)
695         for i := 0; i < len(m.Vnis); i++ {
696                 m.Vnis[i] = buf.DecodeUint32()
697         }
698         return nil
699 }
700
701 // GpeGetEncapMode defines message 'gpe_get_encap_mode'.
702 type GpeGetEncapMode struct{}
703
704 func (m *GpeGetEncapMode) Reset()               { *m = GpeGetEncapMode{} }
705 func (*GpeGetEncapMode) GetMessageName() string { return "gpe_get_encap_mode" }
706 func (*GpeGetEncapMode) GetCrcString() string   { return "51077d14" }
707 func (*GpeGetEncapMode) GetMessageType() api.MessageType {
708         return api.RequestMessage
709 }
710
711 func (m *GpeGetEncapMode) Size() (size int) {
712         if m == nil {
713                 return 0
714         }
715         return size
716 }
717 func (m *GpeGetEncapMode) Marshal(b []byte) ([]byte, error) {
718         if b == nil {
719                 b = make([]byte, m.Size())
720         }
721         buf := codec.NewBuffer(b)
722         return buf.Bytes(), nil
723 }
724 func (m *GpeGetEncapMode) Unmarshal(b []byte) error {
725         return nil
726 }
727
728 // GpeGetEncapModeReply defines message 'gpe_get_encap_mode_reply'.
729 type GpeGetEncapModeReply struct {
730         Retval    int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
731         EncapMode uint8 `binapi:"u8,name=encap_mode" json:"encap_mode,omitempty"`
732 }
733
734 func (m *GpeGetEncapModeReply) Reset()               { *m = GpeGetEncapModeReply{} }
735 func (*GpeGetEncapModeReply) GetMessageName() string { return "gpe_get_encap_mode_reply" }
736 func (*GpeGetEncapModeReply) GetCrcString() string   { return "36e3f7ca" }
737 func (*GpeGetEncapModeReply) GetMessageType() api.MessageType {
738         return api.ReplyMessage
739 }
740
741 func (m *GpeGetEncapModeReply) Size() (size int) {
742         if m == nil {
743                 return 0
744         }
745         size += 4 // m.Retval
746         size += 1 // m.EncapMode
747         return size
748 }
749 func (m *GpeGetEncapModeReply) Marshal(b []byte) ([]byte, error) {
750         if b == nil {
751                 b = make([]byte, m.Size())
752         }
753         buf := codec.NewBuffer(b)
754         buf.EncodeInt32(m.Retval)
755         buf.EncodeUint8(m.EncapMode)
756         return buf.Bytes(), nil
757 }
758 func (m *GpeGetEncapModeReply) Unmarshal(b []byte) error {
759         buf := codec.NewBuffer(b)
760         m.Retval = buf.DecodeInt32()
761         m.EncapMode = buf.DecodeUint8()
762         return nil
763 }
764
765 // GpeNativeFwdRpathsGet defines message 'gpe_native_fwd_rpaths_get'.
766 type GpeNativeFwdRpathsGet struct {
767         IsIP4 uint8 `binapi:"u8,name=is_ip4" json:"is_ip4,omitempty"`
768 }
769
770 func (m *GpeNativeFwdRpathsGet) Reset()               { *m = GpeNativeFwdRpathsGet{} }
771 func (*GpeNativeFwdRpathsGet) GetMessageName() string { return "gpe_native_fwd_rpaths_get" }
772 func (*GpeNativeFwdRpathsGet) GetCrcString() string   { return "c5e0d91b" }
773 func (*GpeNativeFwdRpathsGet) GetMessageType() api.MessageType {
774         return api.RequestMessage
775 }
776
777 func (m *GpeNativeFwdRpathsGet) Size() (size int) {
778         if m == nil {
779                 return 0
780         }
781         size += 1 // m.IsIP4
782         return size
783 }
784 func (m *GpeNativeFwdRpathsGet) Marshal(b []byte) ([]byte, error) {
785         if b == nil {
786                 b = make([]byte, m.Size())
787         }
788         buf := codec.NewBuffer(b)
789         buf.EncodeUint8(m.IsIP4)
790         return buf.Bytes(), nil
791 }
792 func (m *GpeNativeFwdRpathsGet) Unmarshal(b []byte) error {
793         buf := codec.NewBuffer(b)
794         m.IsIP4 = buf.DecodeUint8()
795         return nil
796 }
797
798 // GpeNativeFwdRpathsGetReply defines message 'gpe_native_fwd_rpaths_get_reply'.
799 type GpeNativeFwdRpathsGetReply struct {
800         Retval  int32               `binapi:"i32,name=retval" json:"retval,omitempty"`
801         Count   uint32              `binapi:"u32,name=count" json:"-"`
802         Entries []GpeNativeFwdRpath `binapi:"gpe_native_fwd_rpath[count],name=entries" json:"entries,omitempty"`
803 }
804
805 func (m *GpeNativeFwdRpathsGetReply) Reset()               { *m = GpeNativeFwdRpathsGetReply{} }
806 func (*GpeNativeFwdRpathsGetReply) GetMessageName() string { return "gpe_native_fwd_rpaths_get_reply" }
807 func (*GpeNativeFwdRpathsGetReply) GetCrcString() string   { return "1e4536e3" }
808 func (*GpeNativeFwdRpathsGetReply) GetMessageType() api.MessageType {
809         return api.ReplyMessage
810 }
811
812 func (m *GpeNativeFwdRpathsGetReply) Size() (size int) {
813         if m == nil {
814                 return 0
815         }
816         size += 4 // m.Retval
817         size += 4 // m.Count
818         for j1 := 0; j1 < len(m.Entries); j1++ {
819                 var s1 GpeNativeFwdRpath
820                 _ = s1
821                 if j1 < len(m.Entries) {
822                         s1 = m.Entries[j1]
823                 }
824                 size += 4      // s1.FibIndex
825                 size += 4      // s1.NhSwIfIndex
826                 size += 1      // s1.IsIP4
827                 size += 1 * 16 // s1.NhAddr
828         }
829         return size
830 }
831 func (m *GpeNativeFwdRpathsGetReply) Marshal(b []byte) ([]byte, error) {
832         if b == nil {
833                 b = make([]byte, m.Size())
834         }
835         buf := codec.NewBuffer(b)
836         buf.EncodeInt32(m.Retval)
837         buf.EncodeUint32(uint32(len(m.Entries)))
838         for j0 := 0; j0 < len(m.Entries); j0++ {
839                 var v0 GpeNativeFwdRpath // Entries
840                 if j0 < len(m.Entries) {
841                         v0 = m.Entries[j0]
842                 }
843                 buf.EncodeUint32(v0.FibIndex)
844                 buf.EncodeUint32(v0.NhSwIfIndex)
845                 buf.EncodeUint8(v0.IsIP4)
846                 buf.EncodeBytes(v0.NhAddr, 16)
847         }
848         return buf.Bytes(), nil
849 }
850 func (m *GpeNativeFwdRpathsGetReply) Unmarshal(b []byte) error {
851         buf := codec.NewBuffer(b)
852         m.Retval = buf.DecodeInt32()
853         m.Count = buf.DecodeUint32()
854         m.Entries = make([]GpeNativeFwdRpath, m.Count)
855         for j0 := 0; j0 < len(m.Entries); j0++ {
856                 m.Entries[j0].FibIndex = buf.DecodeUint32()
857                 m.Entries[j0].NhSwIfIndex = buf.DecodeUint32()
858                 m.Entries[j0].IsIP4 = buf.DecodeUint8()
859                 m.Entries[j0].NhAddr = make([]byte, 16)
860                 copy(m.Entries[j0].NhAddr, buf.DecodeBytes(len(m.Entries[j0].NhAddr)))
861         }
862         return nil
863 }
864
865 // GpeSetEncapMode defines message 'gpe_set_encap_mode'.
866 type GpeSetEncapMode struct {
867         Mode uint8 `binapi:"u8,name=mode" json:"mode,omitempty"`
868 }
869
870 func (m *GpeSetEncapMode) Reset()               { *m = GpeSetEncapMode{} }
871 func (*GpeSetEncapMode) GetMessageName() string { return "gpe_set_encap_mode" }
872 func (*GpeSetEncapMode) GetCrcString() string   { return "f3f93ce9" }
873 func (*GpeSetEncapMode) GetMessageType() api.MessageType {
874         return api.RequestMessage
875 }
876
877 func (m *GpeSetEncapMode) Size() (size int) {
878         if m == nil {
879                 return 0
880         }
881         size += 1 // m.Mode
882         return size
883 }
884 func (m *GpeSetEncapMode) Marshal(b []byte) ([]byte, error) {
885         if b == nil {
886                 b = make([]byte, m.Size())
887         }
888         buf := codec.NewBuffer(b)
889         buf.EncodeUint8(m.Mode)
890         return buf.Bytes(), nil
891 }
892 func (m *GpeSetEncapMode) Unmarshal(b []byte) error {
893         buf := codec.NewBuffer(b)
894         m.Mode = buf.DecodeUint8()
895         return nil
896 }
897
898 // GpeSetEncapModeReply defines message 'gpe_set_encap_mode_reply'.
899 type GpeSetEncapModeReply struct {
900         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
901 }
902
903 func (m *GpeSetEncapModeReply) Reset()               { *m = GpeSetEncapModeReply{} }
904 func (*GpeSetEncapModeReply) GetMessageName() string { return "gpe_set_encap_mode_reply" }
905 func (*GpeSetEncapModeReply) GetCrcString() string   { return "e8d4e804" }
906 func (*GpeSetEncapModeReply) GetMessageType() api.MessageType {
907         return api.ReplyMessage
908 }
909
910 func (m *GpeSetEncapModeReply) Size() (size int) {
911         if m == nil {
912                 return 0
913         }
914         size += 4 // m.Retval
915         return size
916 }
917 func (m *GpeSetEncapModeReply) Marshal(b []byte) ([]byte, error) {
918         if b == nil {
919                 b = make([]byte, m.Size())
920         }
921         buf := codec.NewBuffer(b)
922         buf.EncodeInt32(m.Retval)
923         return buf.Bytes(), nil
924 }
925 func (m *GpeSetEncapModeReply) Unmarshal(b []byte) error {
926         buf := codec.NewBuffer(b)
927         m.Retval = buf.DecodeInt32()
928         return nil
929 }
930
931 func init() { file_lisp_gpe_binapi_init() }
932 func file_lisp_gpe_binapi_init() {
933         api.RegisterMessage((*GpeAddDelFwdEntry)(nil), "gpe_add_del_fwd_entry_afbf857a")
934         api.RegisterMessage((*GpeAddDelFwdEntryReply)(nil), "gpe_add_del_fwd_entry_reply_efe5f176")
935         api.RegisterMessage((*GpeAddDelIface)(nil), "gpe_add_del_iface_42d6b533")
936         api.RegisterMessage((*GpeAddDelIfaceReply)(nil), "gpe_add_del_iface_reply_e8d4e804")
937         api.RegisterMessage((*GpeAddDelNativeFwdRpath)(nil), "gpe_add_del_native_fwd_rpath_bfc42b8f")
938         api.RegisterMessage((*GpeAddDelNativeFwdRpathReply)(nil), "gpe_add_del_native_fwd_rpath_reply_e8d4e804")
939         api.RegisterMessage((*GpeEnableDisable)(nil), "gpe_enable_disable_eb0e943b")
940         api.RegisterMessage((*GpeEnableDisableReply)(nil), "gpe_enable_disable_reply_e8d4e804")
941         api.RegisterMessage((*GpeFwdEntriesGet)(nil), "gpe_fwd_entries_get_8d1f2fe9")
942         api.RegisterMessage((*GpeFwdEntriesGetReply)(nil), "gpe_fwd_entries_get_reply_07b02c34")
943         api.RegisterMessage((*GpeFwdEntryPathDetails)(nil), "gpe_fwd_entry_path_details_a9bdc1f1")
944         api.RegisterMessage((*GpeFwdEntryPathDump)(nil), "gpe_fwd_entry_path_dump_39bce980")
945         api.RegisterMessage((*GpeFwdEntryVnisGet)(nil), "gpe_fwd_entry_vnis_get_51077d14")
946         api.RegisterMessage((*GpeFwdEntryVnisGetReply)(nil), "gpe_fwd_entry_vnis_get_reply_aa70da20")
947         api.RegisterMessage((*GpeGetEncapMode)(nil), "gpe_get_encap_mode_51077d14")
948         api.RegisterMessage((*GpeGetEncapModeReply)(nil), "gpe_get_encap_mode_reply_36e3f7ca")
949         api.RegisterMessage((*GpeNativeFwdRpathsGet)(nil), "gpe_native_fwd_rpaths_get_c5e0d91b")
950         api.RegisterMessage((*GpeNativeFwdRpathsGetReply)(nil), "gpe_native_fwd_rpaths_get_reply_1e4536e3")
951         api.RegisterMessage((*GpeSetEncapMode)(nil), "gpe_set_encap_mode_f3f93ce9")
952         api.RegisterMessage((*GpeSetEncapModeReply)(nil), "gpe_set_encap_mode_reply_e8d4e804")
953 }
954
955 // Messages returns list of all messages in this module.
956 func AllMessages() []api.Message {
957         return []api.Message{
958                 (*GpeAddDelFwdEntry)(nil),
959                 (*GpeAddDelFwdEntryReply)(nil),
960                 (*GpeAddDelIface)(nil),
961                 (*GpeAddDelIfaceReply)(nil),
962                 (*GpeAddDelNativeFwdRpath)(nil),
963                 (*GpeAddDelNativeFwdRpathReply)(nil),
964                 (*GpeEnableDisable)(nil),
965                 (*GpeEnableDisableReply)(nil),
966                 (*GpeFwdEntriesGet)(nil),
967                 (*GpeFwdEntriesGetReply)(nil),
968                 (*GpeFwdEntryPathDetails)(nil),
969                 (*GpeFwdEntryPathDump)(nil),
970                 (*GpeFwdEntryVnisGet)(nil),
971                 (*GpeFwdEntryVnisGetReply)(nil),
972                 (*GpeGetEncapMode)(nil),
973                 (*GpeGetEncapModeReply)(nil),
974                 (*GpeNativeFwdRpathsGet)(nil),
975                 (*GpeNativeFwdRpathsGetReply)(nil),
976                 (*GpeSetEncapMode)(nil),
977                 (*GpeSetEncapModeReply)(nil),
978         }
979 }