e6ef5017b1cc5cd76c278f6b6ea84e75d45a4fc8
[govpp.git] / internal / testbinapi / binapi2001 / nat / nat.ba.go
1 // Code generated by GoVPP's binapi-generator. DO NOT EDIT.
2 // versions:
3 //  binapi-generator: v0.4.0-dev
4 //  VPP:              20.01
5 // source: .vppapi/plugins/nat.api.json
6
7 // Package nat contains generated bindings for API file nat.api.
8 //
9 // Contents:
10 //   6 aliases
11 //  12 enums
12 //   7 structs
13 //   1 union
14 // 131 messages
15 //
16 package nat
17
18 import (
19         "fmt"
20         api "git.fd.io/govpp.git/api"
21         codec "git.fd.io/govpp.git/codec"
22         "net"
23         "strconv"
24         "strings"
25 )
26
27 // This is a compile-time assertion to ensure that this generated file
28 // is compatible with the GoVPP api package it is being compiled against.
29 // A compilation error at this line likely means your copy of the
30 // GoVPP api package needs to be updated.
31 const _ = api.GoVppAPIPackageIsVersion2
32
33 const (
34         APIFile    = "nat"
35         APIVersion = "5.2.0"
36         VersionCrc = 0xef1a1c94
37 )
38
39 // AddressFamily defines enum 'address_family'.
40 type AddressFamily uint32
41
42 const (
43         ADDRESS_IP4 AddressFamily = 0
44         ADDRESS_IP6 AddressFamily = 1
45 )
46
47 var (
48         AddressFamily_name = map[uint32]string{
49                 0: "ADDRESS_IP4",
50                 1: "ADDRESS_IP6",
51         }
52         AddressFamily_value = map[string]uint32{
53                 "ADDRESS_IP4": 0,
54                 "ADDRESS_IP6": 1,
55         }
56 )
57
58 func (x AddressFamily) String() string {
59         s, ok := AddressFamily_name[uint32(x)]
60         if ok {
61                 return s
62         }
63         return "AddressFamily(" + strconv.Itoa(int(x)) + ")"
64 }
65
66 // IfStatusFlags defines enum 'if_status_flags'.
67 type IfStatusFlags uint32
68
69 const (
70         IF_STATUS_API_FLAG_ADMIN_UP IfStatusFlags = 1
71         IF_STATUS_API_FLAG_LINK_UP  IfStatusFlags = 2
72 )
73
74 var (
75         IfStatusFlags_name = map[uint32]string{
76                 1: "IF_STATUS_API_FLAG_ADMIN_UP",
77                 2: "IF_STATUS_API_FLAG_LINK_UP",
78         }
79         IfStatusFlags_value = map[string]uint32{
80                 "IF_STATUS_API_FLAG_ADMIN_UP": 1,
81                 "IF_STATUS_API_FLAG_LINK_UP":  2,
82         }
83 )
84
85 func (x IfStatusFlags) String() string {
86         s, ok := IfStatusFlags_name[uint32(x)]
87         if ok {
88                 return s
89         }
90         str := func(n uint32) string {
91                 s, ok := IfStatusFlags_name[uint32(n)]
92                 if ok {
93                         return s
94                 }
95                 return "IfStatusFlags(" + strconv.Itoa(int(n)) + ")"
96         }
97         for i := uint32(0); i <= 32; i++ {
98                 val := uint32(x)
99                 if val&(1<<i) != 0 {
100                         if s != "" {
101                                 s += "|"
102                         }
103                         s += str(1 << i)
104                 }
105         }
106         if s == "" {
107                 return str(uint32(x))
108         }
109         return s
110 }
111
112 // IfType defines enum 'if_type'.
113 type IfType uint32
114
115 const (
116         IF_API_TYPE_HARDWARE IfType = 1
117         IF_API_TYPE_SUB      IfType = 2
118         IF_API_TYPE_P2P      IfType = 3
119         IF_API_TYPE_PIPE     IfType = 4
120 )
121
122 var (
123         IfType_name = map[uint32]string{
124                 1: "IF_API_TYPE_HARDWARE",
125                 2: "IF_API_TYPE_SUB",
126                 3: "IF_API_TYPE_P2P",
127                 4: "IF_API_TYPE_PIPE",
128         }
129         IfType_value = map[string]uint32{
130                 "IF_API_TYPE_HARDWARE": 1,
131                 "IF_API_TYPE_SUB":      2,
132                 "IF_API_TYPE_P2P":      3,
133                 "IF_API_TYPE_PIPE":     4,
134         }
135 )
136
137 func (x IfType) String() string {
138         s, ok := IfType_name[uint32(x)]
139         if ok {
140                 return s
141         }
142         return "IfType(" + strconv.Itoa(int(x)) + ")"
143 }
144
145 // IPDscp defines enum 'ip_dscp'.
146 type IPDscp uint8
147
148 const (
149         IP_API_DSCP_CS0  IPDscp = 0
150         IP_API_DSCP_CS1  IPDscp = 8
151         IP_API_DSCP_AF11 IPDscp = 10
152         IP_API_DSCP_AF12 IPDscp = 12
153         IP_API_DSCP_AF13 IPDscp = 14
154         IP_API_DSCP_CS2  IPDscp = 16
155         IP_API_DSCP_AF21 IPDscp = 18
156         IP_API_DSCP_AF22 IPDscp = 20
157         IP_API_DSCP_AF23 IPDscp = 22
158         IP_API_DSCP_CS3  IPDscp = 24
159         IP_API_DSCP_AF31 IPDscp = 26
160         IP_API_DSCP_AF32 IPDscp = 28
161         IP_API_DSCP_AF33 IPDscp = 30
162         IP_API_DSCP_CS4  IPDscp = 32
163         IP_API_DSCP_AF41 IPDscp = 34
164         IP_API_DSCP_AF42 IPDscp = 36
165         IP_API_DSCP_AF43 IPDscp = 38
166         IP_API_DSCP_CS5  IPDscp = 40
167         IP_API_DSCP_EF   IPDscp = 46
168         IP_API_DSCP_CS6  IPDscp = 48
169         IP_API_DSCP_CS7  IPDscp = 50
170 )
171
172 var (
173         IPDscp_name = map[uint8]string{
174                 0:  "IP_API_DSCP_CS0",
175                 8:  "IP_API_DSCP_CS1",
176                 10: "IP_API_DSCP_AF11",
177                 12: "IP_API_DSCP_AF12",
178                 14: "IP_API_DSCP_AF13",
179                 16: "IP_API_DSCP_CS2",
180                 18: "IP_API_DSCP_AF21",
181                 20: "IP_API_DSCP_AF22",
182                 22: "IP_API_DSCP_AF23",
183                 24: "IP_API_DSCP_CS3",
184                 26: "IP_API_DSCP_AF31",
185                 28: "IP_API_DSCP_AF32",
186                 30: "IP_API_DSCP_AF33",
187                 32: "IP_API_DSCP_CS4",
188                 34: "IP_API_DSCP_AF41",
189                 36: "IP_API_DSCP_AF42",
190                 38: "IP_API_DSCP_AF43",
191                 40: "IP_API_DSCP_CS5",
192                 46: "IP_API_DSCP_EF",
193                 48: "IP_API_DSCP_CS6",
194                 50: "IP_API_DSCP_CS7",
195         }
196         IPDscp_value = map[string]uint8{
197                 "IP_API_DSCP_CS0":  0,
198                 "IP_API_DSCP_CS1":  8,
199                 "IP_API_DSCP_AF11": 10,
200                 "IP_API_DSCP_AF12": 12,
201                 "IP_API_DSCP_AF13": 14,
202                 "IP_API_DSCP_CS2":  16,
203                 "IP_API_DSCP_AF21": 18,
204                 "IP_API_DSCP_AF22": 20,
205                 "IP_API_DSCP_AF23": 22,
206                 "IP_API_DSCP_CS3":  24,
207                 "IP_API_DSCP_AF31": 26,
208                 "IP_API_DSCP_AF32": 28,
209                 "IP_API_DSCP_AF33": 30,
210                 "IP_API_DSCP_CS4":  32,
211                 "IP_API_DSCP_AF41": 34,
212                 "IP_API_DSCP_AF42": 36,
213                 "IP_API_DSCP_AF43": 38,
214                 "IP_API_DSCP_CS5":  40,
215                 "IP_API_DSCP_EF":   46,
216                 "IP_API_DSCP_CS6":  48,
217                 "IP_API_DSCP_CS7":  50,
218         }
219 )
220
221 func (x IPDscp) String() string {
222         s, ok := IPDscp_name[uint8(x)]
223         if ok {
224                 return s
225         }
226         return "IPDscp(" + strconv.Itoa(int(x)) + ")"
227 }
228
229 // IPEcn defines enum 'ip_ecn'.
230 type IPEcn uint8
231
232 const (
233         IP_API_ECN_NONE IPEcn = 0
234         IP_API_ECN_ECT0 IPEcn = 1
235         IP_API_ECN_ECT1 IPEcn = 2
236         IP_API_ECN_CE   IPEcn = 3
237 )
238
239 var (
240         IPEcn_name = map[uint8]string{
241                 0: "IP_API_ECN_NONE",
242                 1: "IP_API_ECN_ECT0",
243                 2: "IP_API_ECN_ECT1",
244                 3: "IP_API_ECN_CE",
245         }
246         IPEcn_value = map[string]uint8{
247                 "IP_API_ECN_NONE": 0,
248                 "IP_API_ECN_ECT0": 1,
249                 "IP_API_ECN_ECT1": 2,
250                 "IP_API_ECN_CE":   3,
251         }
252 )
253
254 func (x IPEcn) String() string {
255         s, ok := IPEcn_name[uint8(x)]
256         if ok {
257                 return s
258         }
259         return "IPEcn(" + strconv.Itoa(int(x)) + ")"
260 }
261
262 // IPProto defines enum 'ip_proto'.
263 type IPProto uint32
264
265 const (
266         IP_API_PROTO_HOPOPT   IPProto = 0
267         IP_API_PROTO_ICMP     IPProto = 1
268         IP_API_PROTO_IGMP     IPProto = 2
269         IP_API_PROTO_TCP      IPProto = 6
270         IP_API_PROTO_UDP      IPProto = 17
271         IP_API_PROTO_GRE      IPProto = 47
272         IP_API_PROTO_AH       IPProto = 50
273         IP_API_PROTO_ESP      IPProto = 51
274         IP_API_PROTO_EIGRP    IPProto = 88
275         IP_API_PROTO_OSPF     IPProto = 89
276         IP_API_PROTO_SCTP     IPProto = 132
277         IP_API_PROTO_RESERVED IPProto = 255
278 )
279
280 var (
281         IPProto_name = map[uint32]string{
282                 0:   "IP_API_PROTO_HOPOPT",
283                 1:   "IP_API_PROTO_ICMP",
284                 2:   "IP_API_PROTO_IGMP",
285                 6:   "IP_API_PROTO_TCP",
286                 17:  "IP_API_PROTO_UDP",
287                 47:  "IP_API_PROTO_GRE",
288                 50:  "IP_API_PROTO_AH",
289                 51:  "IP_API_PROTO_ESP",
290                 88:  "IP_API_PROTO_EIGRP",
291                 89:  "IP_API_PROTO_OSPF",
292                 132: "IP_API_PROTO_SCTP",
293                 255: "IP_API_PROTO_RESERVED",
294         }
295         IPProto_value = map[string]uint32{
296                 "IP_API_PROTO_HOPOPT":   0,
297                 "IP_API_PROTO_ICMP":     1,
298                 "IP_API_PROTO_IGMP":     2,
299                 "IP_API_PROTO_TCP":      6,
300                 "IP_API_PROTO_UDP":      17,
301                 "IP_API_PROTO_GRE":      47,
302                 "IP_API_PROTO_AH":       50,
303                 "IP_API_PROTO_ESP":      51,
304                 "IP_API_PROTO_EIGRP":    88,
305                 "IP_API_PROTO_OSPF":     89,
306                 "IP_API_PROTO_SCTP":     132,
307                 "IP_API_PROTO_RESERVED": 255,
308         }
309 )
310
311 func (x IPProto) String() string {
312         s, ok := IPProto_name[uint32(x)]
313         if ok {
314                 return s
315         }
316         return "IPProto(" + strconv.Itoa(int(x)) + ")"
317 }
318
319 // LinkDuplex defines enum 'link_duplex'.
320 type LinkDuplex uint32
321
322 const (
323         LINK_DUPLEX_API_UNKNOWN LinkDuplex = 0
324         LINK_DUPLEX_API_HALF    LinkDuplex = 1
325         LINK_DUPLEX_API_FULL    LinkDuplex = 2
326 )
327
328 var (
329         LinkDuplex_name = map[uint32]string{
330                 0: "LINK_DUPLEX_API_UNKNOWN",
331                 1: "LINK_DUPLEX_API_HALF",
332                 2: "LINK_DUPLEX_API_FULL",
333         }
334         LinkDuplex_value = map[string]uint32{
335                 "LINK_DUPLEX_API_UNKNOWN": 0,
336                 "LINK_DUPLEX_API_HALF":    1,
337                 "LINK_DUPLEX_API_FULL":    2,
338         }
339 )
340
341 func (x LinkDuplex) String() string {
342         s, ok := LinkDuplex_name[uint32(x)]
343         if ok {
344                 return s
345         }
346         return "LinkDuplex(" + strconv.Itoa(int(x)) + ")"
347 }
348
349 // MtuProto defines enum 'mtu_proto'.
350 type MtuProto uint32
351
352 const (
353         MTU_PROTO_API_L3   MtuProto = 1
354         MTU_PROTO_API_IP4  MtuProto = 2
355         MTU_PROTO_API_IP6  MtuProto = 3
356         MTU_PROTO_API_MPLS MtuProto = 4
357         MTU_PROTO_API_N    MtuProto = 5
358 )
359
360 var (
361         MtuProto_name = map[uint32]string{
362                 1: "MTU_PROTO_API_L3",
363                 2: "MTU_PROTO_API_IP4",
364                 3: "MTU_PROTO_API_IP6",
365                 4: "MTU_PROTO_API_MPLS",
366                 5: "MTU_PROTO_API_N",
367         }
368         MtuProto_value = map[string]uint32{
369                 "MTU_PROTO_API_L3":   1,
370                 "MTU_PROTO_API_IP4":  2,
371                 "MTU_PROTO_API_IP6":  3,
372                 "MTU_PROTO_API_MPLS": 4,
373                 "MTU_PROTO_API_N":    5,
374         }
375 )
376
377 func (x MtuProto) String() string {
378         s, ok := MtuProto_name[uint32(x)]
379         if ok {
380                 return s
381         }
382         return "MtuProto(" + strconv.Itoa(int(x)) + ")"
383 }
384
385 // NatConfigFlags defines enum 'nat_config_flags'.
386 type NatConfigFlags uint8
387
388 const (
389         NAT_IS_NONE           NatConfigFlags = 0
390         NAT_IS_TWICE_NAT      NatConfigFlags = 1
391         NAT_IS_SELF_TWICE_NAT NatConfigFlags = 2
392         NAT_IS_OUT2IN_ONLY    NatConfigFlags = 4
393         NAT_IS_ADDR_ONLY      NatConfigFlags = 8
394         NAT_IS_OUTSIDE        NatConfigFlags = 16
395         NAT_IS_INSIDE         NatConfigFlags = 32
396         NAT_IS_STATIC         NatConfigFlags = 64
397         NAT_IS_EXT_HOST_VALID NatConfigFlags = 128
398 )
399
400 var (
401         NatConfigFlags_name = map[uint8]string{
402                 0:   "NAT_IS_NONE",
403                 1:   "NAT_IS_TWICE_NAT",
404                 2:   "NAT_IS_SELF_TWICE_NAT",
405                 4:   "NAT_IS_OUT2IN_ONLY",
406                 8:   "NAT_IS_ADDR_ONLY",
407                 16:  "NAT_IS_OUTSIDE",
408                 32:  "NAT_IS_INSIDE",
409                 64:  "NAT_IS_STATIC",
410                 128: "NAT_IS_EXT_HOST_VALID",
411         }
412         NatConfigFlags_value = map[string]uint8{
413                 "NAT_IS_NONE":           0,
414                 "NAT_IS_TWICE_NAT":      1,
415                 "NAT_IS_SELF_TWICE_NAT": 2,
416                 "NAT_IS_OUT2IN_ONLY":    4,
417                 "NAT_IS_ADDR_ONLY":      8,
418                 "NAT_IS_OUTSIDE":        16,
419                 "NAT_IS_INSIDE":         32,
420                 "NAT_IS_STATIC":         64,
421                 "NAT_IS_EXT_HOST_VALID": 128,
422         }
423 )
424
425 func (x NatConfigFlags) String() string {
426         s, ok := NatConfigFlags_name[uint8(x)]
427         if ok {
428                 return s
429         }
430         str := func(n uint8) string {
431                 s, ok := NatConfigFlags_name[uint8(n)]
432                 if ok {
433                         return s
434                 }
435                 return "NatConfigFlags(" + strconv.Itoa(int(n)) + ")"
436         }
437         for i := uint8(0); i <= 8; i++ {
438                 val := uint8(x)
439                 if val&(1<<i) != 0 {
440                         if s != "" {
441                                 s += "|"
442                         }
443                         s += str(1 << i)
444                 }
445         }
446         if s == "" {
447                 return str(uint8(x))
448         }
449         return s
450 }
451
452 // NatLogLevel defines enum 'nat_log_level'.
453 type NatLogLevel uint8
454
455 const (
456         NAT_LOG_NONE    NatLogLevel = 0
457         NAT_LOG_ERROR   NatLogLevel = 1
458         NAT_LOG_WARNING NatLogLevel = 2
459         NAT_LOG_NOTICE  NatLogLevel = 3
460         NAT_LOG_INFO    NatLogLevel = 4
461         NAT_LOG_DEBUG   NatLogLevel = 5
462 )
463
464 var (
465         NatLogLevel_name = map[uint8]string{
466                 0: "NAT_LOG_NONE",
467                 1: "NAT_LOG_ERROR",
468                 2: "NAT_LOG_WARNING",
469                 3: "NAT_LOG_NOTICE",
470                 4: "NAT_LOG_INFO",
471                 5: "NAT_LOG_DEBUG",
472         }
473         NatLogLevel_value = map[string]uint8{
474                 "NAT_LOG_NONE":    0,
475                 "NAT_LOG_ERROR":   1,
476                 "NAT_LOG_WARNING": 2,
477                 "NAT_LOG_NOTICE":  3,
478                 "NAT_LOG_INFO":    4,
479                 "NAT_LOG_DEBUG":   5,
480         }
481 )
482
483 func (x NatLogLevel) String() string {
484         s, ok := NatLogLevel_name[uint8(x)]
485         if ok {
486                 return s
487         }
488         return "NatLogLevel(" + strconv.Itoa(int(x)) + ")"
489 }
490
491 // RxMode defines enum 'rx_mode'.
492 type RxMode uint32
493
494 const (
495         RX_MODE_API_UNKNOWN   RxMode = 0
496         RX_MODE_API_POLLING   RxMode = 1
497         RX_MODE_API_INTERRUPT RxMode = 2
498         RX_MODE_API_ADAPTIVE  RxMode = 3
499         RX_MODE_API_DEFAULT   RxMode = 4
500 )
501
502 var (
503         RxMode_name = map[uint32]string{
504                 0: "RX_MODE_API_UNKNOWN",
505                 1: "RX_MODE_API_POLLING",
506                 2: "RX_MODE_API_INTERRUPT",
507                 3: "RX_MODE_API_ADAPTIVE",
508                 4: "RX_MODE_API_DEFAULT",
509         }
510         RxMode_value = map[string]uint32{
511                 "RX_MODE_API_UNKNOWN":   0,
512                 "RX_MODE_API_POLLING":   1,
513                 "RX_MODE_API_INTERRUPT": 2,
514                 "RX_MODE_API_ADAPTIVE":  3,
515                 "RX_MODE_API_DEFAULT":   4,
516         }
517 )
518
519 func (x RxMode) String() string {
520         s, ok := RxMode_name[uint32(x)]
521         if ok {
522                 return s
523         }
524         return "RxMode(" + strconv.Itoa(int(x)) + ")"
525 }
526
527 // SubIfFlags defines enum 'sub_if_flags'.
528 type SubIfFlags uint32
529
530 const (
531         SUB_IF_API_FLAG_NO_TAGS           SubIfFlags = 1
532         SUB_IF_API_FLAG_ONE_TAG           SubIfFlags = 2
533         SUB_IF_API_FLAG_TWO_TAGS          SubIfFlags = 4
534         SUB_IF_API_FLAG_DOT1AD            SubIfFlags = 8
535         SUB_IF_API_FLAG_EXACT_MATCH       SubIfFlags = 16
536         SUB_IF_API_FLAG_DEFAULT           SubIfFlags = 32
537         SUB_IF_API_FLAG_OUTER_VLAN_ID_ANY SubIfFlags = 64
538         SUB_IF_API_FLAG_INNER_VLAN_ID_ANY SubIfFlags = 128
539         SUB_IF_API_FLAG_MASK_VNET         SubIfFlags = 254
540         SUB_IF_API_FLAG_DOT1AH            SubIfFlags = 256
541 )
542
543 var (
544         SubIfFlags_name = map[uint32]string{
545                 1:   "SUB_IF_API_FLAG_NO_TAGS",
546                 2:   "SUB_IF_API_FLAG_ONE_TAG",
547                 4:   "SUB_IF_API_FLAG_TWO_TAGS",
548                 8:   "SUB_IF_API_FLAG_DOT1AD",
549                 16:  "SUB_IF_API_FLAG_EXACT_MATCH",
550                 32:  "SUB_IF_API_FLAG_DEFAULT",
551                 64:  "SUB_IF_API_FLAG_OUTER_VLAN_ID_ANY",
552                 128: "SUB_IF_API_FLAG_INNER_VLAN_ID_ANY",
553                 254: "SUB_IF_API_FLAG_MASK_VNET",
554                 256: "SUB_IF_API_FLAG_DOT1AH",
555         }
556         SubIfFlags_value = map[string]uint32{
557                 "SUB_IF_API_FLAG_NO_TAGS":           1,
558                 "SUB_IF_API_FLAG_ONE_TAG":           2,
559                 "SUB_IF_API_FLAG_TWO_TAGS":          4,
560                 "SUB_IF_API_FLAG_DOT1AD":            8,
561                 "SUB_IF_API_FLAG_EXACT_MATCH":       16,
562                 "SUB_IF_API_FLAG_DEFAULT":           32,
563                 "SUB_IF_API_FLAG_OUTER_VLAN_ID_ANY": 64,
564                 "SUB_IF_API_FLAG_INNER_VLAN_ID_ANY": 128,
565                 "SUB_IF_API_FLAG_MASK_VNET":         254,
566                 "SUB_IF_API_FLAG_DOT1AH":            256,
567         }
568 )
569
570 func (x SubIfFlags) String() string {
571         s, ok := SubIfFlags_name[uint32(x)]
572         if ok {
573                 return s
574         }
575         str := func(n uint32) string {
576                 s, ok := SubIfFlags_name[uint32(n)]
577                 if ok {
578                         return s
579                 }
580                 return "SubIfFlags(" + strconv.Itoa(int(n)) + ")"
581         }
582         for i := uint32(0); i <= 32; i++ {
583                 val := uint32(x)
584                 if val&(1<<i) != 0 {
585                         if s != "" {
586                                 s += "|"
587                         }
588                         s += str(1 << i)
589                 }
590         }
591         if s == "" {
592                 return str(uint32(x))
593         }
594         return s
595 }
596
597 // AddressWithPrefix defines alias 'address_with_prefix'.
598 type AddressWithPrefix Prefix
599
600 func ParseAddressWithPrefix(s string) (AddressWithPrefix, error) {
601         prefix, err := ParsePrefix(s)
602         if err != nil {
603                 return AddressWithPrefix{}, err
604         }
605         return AddressWithPrefix(prefix), nil
606 }
607 func (x AddressWithPrefix) String() string {
608         return Prefix(x).String()
609 }
610 func (x *AddressWithPrefix) MarshalText() ([]byte, error) {
611         return []byte(x.String()), nil
612 }
613 func (x *AddressWithPrefix) UnmarshalText(text []byte) error {
614         prefix, err := ParseAddressWithPrefix(string(text))
615         if err != nil {
616                 return err
617         }
618         *x = prefix
619         return nil
620 }
621
622 // InterfaceIndex defines alias 'interface_index'.
623 type InterfaceIndex uint32
624
625 // IP4Address defines alias 'ip4_address'.
626 type IP4Address [4]uint8
627
628 func ParseIP4Address(s string) (IP4Address, error) {
629         ip := net.ParseIP(s).To4()
630         if ip == nil {
631                 return IP4Address{}, fmt.Errorf("invalid IP address: %s", s)
632         }
633         var ipaddr IP4Address
634         copy(ipaddr[:], ip.To4())
635         return ipaddr, nil
636 }
637
638 func (x IP4Address) ToIP() net.IP {
639         return net.IP(x[:]).To4()
640 }
641 func (x IP4Address) String() string {
642         return x.ToIP().String()
643 }
644 func (x *IP4Address) MarshalText() ([]byte, error) {
645         return []byte(x.String()), nil
646 }
647 func (x *IP4Address) UnmarshalText(text []byte) error {
648         ipaddr, err := ParseIP4Address(string(text))
649         if err != nil {
650                 return err
651         }
652         *x = ipaddr
653         return nil
654 }
655
656 // IP4AddressWithPrefix defines alias 'ip4_address_with_prefix'.
657 type IP4AddressWithPrefix IP4Prefix
658
659 // IP6Address defines alias 'ip6_address'.
660 type IP6Address [16]uint8
661
662 func ParseIP6Address(s string) (IP6Address, error) {
663         ip := net.ParseIP(s).To16()
664         if ip == nil {
665                 return IP6Address{}, fmt.Errorf("invalid IP address: %s", s)
666         }
667         var ipaddr IP6Address
668         copy(ipaddr[:], ip.To16())
669         return ipaddr, nil
670 }
671
672 func (x IP6Address) ToIP() net.IP {
673         return net.IP(x[:]).To16()
674 }
675 func (x IP6Address) String() string {
676         return x.ToIP().String()
677 }
678 func (x *IP6Address) MarshalText() ([]byte, error) {
679         return []byte(x.String()), nil
680 }
681 func (x *IP6Address) UnmarshalText(text []byte) error {
682         ipaddr, err := ParseIP6Address(string(text))
683         if err != nil {
684                 return err
685         }
686         *x = ipaddr
687         return nil
688 }
689
690 // IP6AddressWithPrefix defines alias 'ip6_address_with_prefix'.
691 type IP6AddressWithPrefix IP6Prefix
692
693 // Address defines type 'address'.
694 type Address struct {
695         Af AddressFamily `binapi:"address_family,name=af" json:"af,omitempty"`
696         Un AddressUnion  `binapi:"address_union,name=un" json:"un,omitempty"`
697 }
698
699 func ParseAddress(s string) (Address, error) {
700         ip := net.ParseIP(s)
701         if ip == nil {
702                 return Address{}, fmt.Errorf("invalid address: %s", s)
703         }
704         var addr Address
705         if ip.To4() == nil {
706                 addr.Af = ADDRESS_IP6
707                 var ip6 IP6Address
708                 copy(ip6[:], ip.To16())
709                 addr.Un.SetIP6(ip6)
710         } else {
711                 addr.Af = ADDRESS_IP4
712                 var ip4 IP4Address
713                 copy(ip4[:], ip.To4())
714                 addr.Un.SetIP4(ip4)
715         }
716         return addr, nil
717 }
718 func (x Address) ToIP() net.IP {
719         if x.Af == ADDRESS_IP6 {
720                 ip6 := x.Un.GetIP6()
721                 return net.IP(ip6[:]).To16()
722         } else {
723                 ip4 := x.Un.GetIP4()
724                 return net.IP(ip4[:]).To4()
725         }
726 }
727 func (x Address) String() string {
728         return x.ToIP().String()
729 }
730 func (x *Address) MarshalText() ([]byte, error) {
731         return []byte(x.String()), nil
732 }
733 func (x *Address) UnmarshalText(text []byte) error {
734         addr, err := ParseAddress(string(text))
735         if err != nil {
736                 return err
737         }
738         *x = addr
739         return nil
740 }
741
742 // IP4Prefix defines type 'ip4_prefix'.
743 type IP4Prefix struct {
744         Address IP4Address `binapi:"ip4_address,name=address" json:"address,omitempty"`
745         Len     uint8      `binapi:"u8,name=len" json:"len,omitempty"`
746 }
747
748 func ParseIP4Prefix(s string) (prefix IP4Prefix, err error) {
749         hasPrefix := strings.Contains(s, "/")
750         if hasPrefix {
751                 ip, network, err := net.ParseCIDR(s)
752                 if err != nil {
753                         return IP4Prefix{}, fmt.Errorf("invalid IP %s: %s", s, err)
754                 }
755                 maskSize, _ := network.Mask.Size()
756                 prefix.Len = byte(maskSize)
757                 prefix.Address, err = ParseIP4Address(ip.String())
758                 if err != nil {
759                         return IP4Prefix{}, fmt.Errorf("invalid IP %s: %s", s, err)
760                 }
761         } else {
762                 ip := net.ParseIP(s)
763                 defaultMaskSize, _ := net.CIDRMask(32, 32).Size()
764                 if ip.To4() == nil {
765                         defaultMaskSize, _ = net.CIDRMask(128, 128).Size()
766                 }
767                 prefix.Len = byte(defaultMaskSize)
768                 prefix.Address, err = ParseIP4Address(ip.String())
769                 if err != nil {
770                         return IP4Prefix{}, fmt.Errorf("invalid IP %s: %s", s, err)
771                 }
772         }
773         return prefix, nil
774 }
775 func (x IP4Prefix) ToIPNet() *net.IPNet {
776         mask := net.CIDRMask(int(x.Len), 32)
777         ipnet := &net.IPNet{IP: x.Address.ToIP(), Mask: mask}
778         return ipnet
779 }
780 func (x IP4Prefix) String() string {
781         ip := x.Address.String()
782         return ip + "/" + strconv.Itoa(int(x.Len))
783 }
784 func (x *IP4Prefix) MarshalText() ([]byte, error) {
785         return []byte(x.String()), nil
786 }
787 func (x *IP4Prefix) UnmarshalText(text []byte) error {
788         prefix, err := ParseIP4Prefix(string(text))
789         if err != nil {
790                 return err
791         }
792         *x = prefix
793         return nil
794 }
795
796 // IP6Prefix defines type 'ip6_prefix'.
797 type IP6Prefix struct {
798         Address IP6Address `binapi:"ip6_address,name=address" json:"address,omitempty"`
799         Len     uint8      `binapi:"u8,name=len" json:"len,omitempty"`
800 }
801
802 func ParseIP6Prefix(s string) (prefix IP6Prefix, err error) {
803         hasPrefix := strings.Contains(s, "/")
804         if hasPrefix {
805                 ip, network, err := net.ParseCIDR(s)
806                 if err != nil {
807                         return IP6Prefix{}, fmt.Errorf("invalid IP %s: %s", s, err)
808                 }
809                 maskSize, _ := network.Mask.Size()
810                 prefix.Len = byte(maskSize)
811                 prefix.Address, err = ParseIP6Address(ip.String())
812                 if err != nil {
813                         return IP6Prefix{}, fmt.Errorf("invalid IP %s: %s", s, err)
814                 }
815         } else {
816                 ip := net.ParseIP(s)
817                 defaultMaskSize, _ := net.CIDRMask(32, 32).Size()
818                 if ip.To4() == nil {
819                         defaultMaskSize, _ = net.CIDRMask(128, 128).Size()
820                 }
821                 prefix.Len = byte(defaultMaskSize)
822                 prefix.Address, err = ParseIP6Address(ip.String())
823                 if err != nil {
824                         return IP6Prefix{}, fmt.Errorf("invalid IP %s: %s", s, err)
825                 }
826         }
827         return prefix, nil
828 }
829 func (x IP6Prefix) ToIPNet() *net.IPNet {
830         mask := net.CIDRMask(int(x.Len), 128)
831         ipnet := &net.IPNet{IP: x.Address.ToIP(), Mask: mask}
832         return ipnet
833 }
834 func (x IP6Prefix) String() string {
835         ip := x.Address.String()
836         return ip + "/" + strconv.Itoa(int(x.Len))
837 }
838 func (x *IP6Prefix) MarshalText() ([]byte, error) {
839         return []byte(x.String()), nil
840 }
841 func (x *IP6Prefix) UnmarshalText(text []byte) error {
842         prefix, err := ParseIP6Prefix(string(text))
843         if err != nil {
844                 return err
845         }
846         *x = prefix
847         return nil
848 }
849
850 // Mprefix defines type 'mprefix'.
851 type Mprefix struct {
852         Af               AddressFamily `binapi:"address_family,name=af" json:"af,omitempty"`
853         GrpAddressLength uint16        `binapi:"u16,name=grp_address_length" json:"grp_address_length,omitempty"`
854         GrpAddress       AddressUnion  `binapi:"address_union,name=grp_address" json:"grp_address,omitempty"`
855         SrcAddress       AddressUnion  `binapi:"address_union,name=src_address" json:"src_address,omitempty"`
856 }
857
858 // Nat44LbAddrPort defines type 'nat44_lb_addr_port'.
859 type Nat44LbAddrPort struct {
860         Addr        IP4Address `binapi:"ip4_address,name=addr" json:"addr,omitempty"`
861         Port        uint16     `binapi:"u16,name=port" json:"port,omitempty"`
862         Probability uint8      `binapi:"u8,name=probability" json:"probability,omitempty"`
863         VrfID       uint32     `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
864 }
865
866 // Prefix defines type 'prefix'.
867 type Prefix struct {
868         Address Address `binapi:"address,name=address" json:"address,omitempty"`
869         Len     uint8   `binapi:"u8,name=len" json:"len,omitempty"`
870 }
871
872 func ParsePrefix(ip string) (prefix Prefix, err error) {
873         hasPrefix := strings.Contains(ip, "/")
874         if hasPrefix {
875                 netIP, network, err := net.ParseCIDR(ip)
876                 if err != nil {
877                         return Prefix{}, fmt.Errorf("invalid IP %s: %s", ip, err)
878                 }
879                 maskSize, _ := network.Mask.Size()
880                 prefix.Len = byte(maskSize)
881                 prefix.Address, err = ParseAddress(netIP.String())
882                 if err != nil {
883                         return Prefix{}, fmt.Errorf("invalid IP %s: %s", ip, err)
884                 }
885         } else {
886                 netIP := net.ParseIP(ip)
887                 defaultMaskSize, _ := net.CIDRMask(32, 32).Size()
888                 if netIP.To4() == nil {
889                         defaultMaskSize, _ = net.CIDRMask(128, 128).Size()
890                 }
891                 prefix.Len = byte(defaultMaskSize)
892                 prefix.Address, err = ParseAddress(netIP.String())
893                 if err != nil {
894                         return Prefix{}, fmt.Errorf("invalid IP %s: %s", ip, err)
895                 }
896         }
897         return prefix, nil
898 }
899 func (x Prefix) ToIPNet() *net.IPNet {
900         var mask net.IPMask
901         if x.Address.Af == ADDRESS_IP4 {
902                 mask = net.CIDRMask(int(x.Len), 32)
903         } else {
904                 mask = net.CIDRMask(int(x.Len), 128)
905         }
906         ipnet := &net.IPNet{IP: x.Address.ToIP(), Mask: mask}
907         return ipnet
908 }
909 func (x Prefix) String() string {
910         ip := x.Address.String()
911         return ip + "/" + strconv.Itoa(int(x.Len))
912 }
913 func (x *Prefix) MarshalText() ([]byte, error) {
914         return []byte(x.String()), nil
915 }
916 func (x *Prefix) UnmarshalText(text []byte) error {
917         prefix, err := ParsePrefix(string(text))
918         if err != nil {
919                 return err
920         }
921         *x = prefix
922         return nil
923 }
924
925 // PrefixMatcher defines type 'prefix_matcher'.
926 type PrefixMatcher struct {
927         Le uint8 `binapi:"u8,name=le" json:"le,omitempty"`
928         Ge uint8 `binapi:"u8,name=ge" json:"ge,omitempty"`
929 }
930
931 // AddressUnion defines union 'address_union'.
932 type AddressUnion struct {
933         // IP4 *IP4Address
934         // IP6 *IP6Address
935         XXX_UnionData [16]byte
936 }
937
938 func AddressUnionIP4(a IP4Address) (u AddressUnion) {
939         u.SetIP4(a)
940         return
941 }
942 func (u *AddressUnion) SetIP4(a IP4Address) {
943         buf := codec.NewBuffer(u.XXX_UnionData[:])
944         buf.EncodeBytes(a[:], 4)
945 }
946 func (u *AddressUnion) GetIP4() (a IP4Address) {
947         buf := codec.NewBuffer(u.XXX_UnionData[:])
948         copy(a[:], buf.DecodeBytes(4))
949         return
950 }
951
952 func AddressUnionIP6(a IP6Address) (u AddressUnion) {
953         u.SetIP6(a)
954         return
955 }
956 func (u *AddressUnion) SetIP6(a IP6Address) {
957         buf := codec.NewBuffer(u.XXX_UnionData[:])
958         buf.EncodeBytes(a[:], 16)
959 }
960 func (u *AddressUnion) GetIP6() (a IP6Address) {
961         buf := codec.NewBuffer(u.XXX_UnionData[:])
962         copy(a[:], buf.DecodeBytes(16))
963         return
964 }
965
966 // DsliteAddDelPoolAddrRange defines message 'dslite_add_del_pool_addr_range'.
967 type DsliteAddDelPoolAddrRange struct {
968         StartAddr IP4Address `binapi:"ip4_address,name=start_addr" json:"start_addr,omitempty"`
969         EndAddr   IP4Address `binapi:"ip4_address,name=end_addr" json:"end_addr,omitempty"`
970         IsAdd     bool       `binapi:"bool,name=is_add" json:"is_add,omitempty"`
971 }
972
973 func (m *DsliteAddDelPoolAddrRange) Reset()               { *m = DsliteAddDelPoolAddrRange{} }
974 func (*DsliteAddDelPoolAddrRange) GetMessageName() string { return "dslite_add_del_pool_addr_range" }
975 func (*DsliteAddDelPoolAddrRange) GetCrcString() string   { return "c448457a" }
976 func (*DsliteAddDelPoolAddrRange) GetMessageType() api.MessageType {
977         return api.RequestMessage
978 }
979
980 func (m *DsliteAddDelPoolAddrRange) Size() (size int) {
981         if m == nil {
982                 return 0
983         }
984         size += 1 * 4 // m.StartAddr
985         size += 1 * 4 // m.EndAddr
986         size += 1     // m.IsAdd
987         return size
988 }
989 func (m *DsliteAddDelPoolAddrRange) Marshal(b []byte) ([]byte, error) {
990         if b == nil {
991                 b = make([]byte, m.Size())
992         }
993         buf := codec.NewBuffer(b)
994         buf.EncodeBytes(m.StartAddr[:], 4)
995         buf.EncodeBytes(m.EndAddr[:], 4)
996         buf.EncodeBool(m.IsAdd)
997         return buf.Bytes(), nil
998 }
999 func (m *DsliteAddDelPoolAddrRange) Unmarshal(b []byte) error {
1000         buf := codec.NewBuffer(b)
1001         copy(m.StartAddr[:], buf.DecodeBytes(4))
1002         copy(m.EndAddr[:], buf.DecodeBytes(4))
1003         m.IsAdd = buf.DecodeBool()
1004         return nil
1005 }
1006
1007 // DsliteAddDelPoolAddrRangeReply defines message 'dslite_add_del_pool_addr_range_reply'.
1008 type DsliteAddDelPoolAddrRangeReply struct {
1009         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
1010 }
1011
1012 func (m *DsliteAddDelPoolAddrRangeReply) Reset() { *m = DsliteAddDelPoolAddrRangeReply{} }
1013 func (*DsliteAddDelPoolAddrRangeReply) GetMessageName() string {
1014         return "dslite_add_del_pool_addr_range_reply"
1015 }
1016 func (*DsliteAddDelPoolAddrRangeReply) GetCrcString() string { return "e8d4e804" }
1017 func (*DsliteAddDelPoolAddrRangeReply) GetMessageType() api.MessageType {
1018         return api.ReplyMessage
1019 }
1020
1021 func (m *DsliteAddDelPoolAddrRangeReply) Size() (size int) {
1022         if m == nil {
1023                 return 0
1024         }
1025         size += 4 // m.Retval
1026         return size
1027 }
1028 func (m *DsliteAddDelPoolAddrRangeReply) Marshal(b []byte) ([]byte, error) {
1029         if b == nil {
1030                 b = make([]byte, m.Size())
1031         }
1032         buf := codec.NewBuffer(b)
1033         buf.EncodeInt32(m.Retval)
1034         return buf.Bytes(), nil
1035 }
1036 func (m *DsliteAddDelPoolAddrRangeReply) Unmarshal(b []byte) error {
1037         buf := codec.NewBuffer(b)
1038         m.Retval = buf.DecodeInt32()
1039         return nil
1040 }
1041
1042 // DsliteAddressDetails defines message 'dslite_address_details'.
1043 type DsliteAddressDetails struct {
1044         IPAddress IP4Address `binapi:"ip4_address,name=ip_address" json:"ip_address,omitempty"`
1045 }
1046
1047 func (m *DsliteAddressDetails) Reset()               { *m = DsliteAddressDetails{} }
1048 func (*DsliteAddressDetails) GetMessageName() string { return "dslite_address_details" }
1049 func (*DsliteAddressDetails) GetCrcString() string   { return "ec26d648" }
1050 func (*DsliteAddressDetails) GetMessageType() api.MessageType {
1051         return api.ReplyMessage
1052 }
1053
1054 func (m *DsliteAddressDetails) Size() (size int) {
1055         if m == nil {
1056                 return 0
1057         }
1058         size += 1 * 4 // m.IPAddress
1059         return size
1060 }
1061 func (m *DsliteAddressDetails) Marshal(b []byte) ([]byte, error) {
1062         if b == nil {
1063                 b = make([]byte, m.Size())
1064         }
1065         buf := codec.NewBuffer(b)
1066         buf.EncodeBytes(m.IPAddress[:], 4)
1067         return buf.Bytes(), nil
1068 }
1069 func (m *DsliteAddressDetails) Unmarshal(b []byte) error {
1070         buf := codec.NewBuffer(b)
1071         copy(m.IPAddress[:], buf.DecodeBytes(4))
1072         return nil
1073 }
1074
1075 // DsliteAddressDump defines message 'dslite_address_dump'.
1076 type DsliteAddressDump struct{}
1077
1078 func (m *DsliteAddressDump) Reset()               { *m = DsliteAddressDump{} }
1079 func (*DsliteAddressDump) GetMessageName() string { return "dslite_address_dump" }
1080 func (*DsliteAddressDump) GetCrcString() string   { return "51077d14" }
1081 func (*DsliteAddressDump) GetMessageType() api.MessageType {
1082         return api.RequestMessage
1083 }
1084
1085 func (m *DsliteAddressDump) Size() (size int) {
1086         if m == nil {
1087                 return 0
1088         }
1089         return size
1090 }
1091 func (m *DsliteAddressDump) Marshal(b []byte) ([]byte, error) {
1092         if b == nil {
1093                 b = make([]byte, m.Size())
1094         }
1095         buf := codec.NewBuffer(b)
1096         return buf.Bytes(), nil
1097 }
1098 func (m *DsliteAddressDump) Unmarshal(b []byte) error {
1099         return nil
1100 }
1101
1102 // DsliteGetAftrAddr defines message 'dslite_get_aftr_addr'.
1103 type DsliteGetAftrAddr struct{}
1104
1105 func (m *DsliteGetAftrAddr) Reset()               { *m = DsliteGetAftrAddr{} }
1106 func (*DsliteGetAftrAddr) GetMessageName() string { return "dslite_get_aftr_addr" }
1107 func (*DsliteGetAftrAddr) GetCrcString() string   { return "51077d14" }
1108 func (*DsliteGetAftrAddr) GetMessageType() api.MessageType {
1109         return api.RequestMessage
1110 }
1111
1112 func (m *DsliteGetAftrAddr) Size() (size int) {
1113         if m == nil {
1114                 return 0
1115         }
1116         return size
1117 }
1118 func (m *DsliteGetAftrAddr) Marshal(b []byte) ([]byte, error) {
1119         if b == nil {
1120                 b = make([]byte, m.Size())
1121         }
1122         buf := codec.NewBuffer(b)
1123         return buf.Bytes(), nil
1124 }
1125 func (m *DsliteGetAftrAddr) Unmarshal(b []byte) error {
1126         return nil
1127 }
1128
1129 // DsliteGetAftrAddrReply defines message 'dslite_get_aftr_addr_reply'.
1130 type DsliteGetAftrAddrReply struct {
1131         Retval  int32      `binapi:"i32,name=retval" json:"retval,omitempty"`
1132         IP4Addr IP4Address `binapi:"ip4_address,name=ip4_addr" json:"ip4_addr,omitempty"`
1133         IP6Addr IP6Address `binapi:"ip6_address,name=ip6_addr" json:"ip6_addr,omitempty"`
1134 }
1135
1136 func (m *DsliteGetAftrAddrReply) Reset()               { *m = DsliteGetAftrAddrReply{} }
1137 func (*DsliteGetAftrAddrReply) GetMessageName() string { return "dslite_get_aftr_addr_reply" }
1138 func (*DsliteGetAftrAddrReply) GetCrcString() string   { return "38e30db1" }
1139 func (*DsliteGetAftrAddrReply) GetMessageType() api.MessageType {
1140         return api.ReplyMessage
1141 }
1142
1143 func (m *DsliteGetAftrAddrReply) Size() (size int) {
1144         if m == nil {
1145                 return 0
1146         }
1147         size += 4      // m.Retval
1148         size += 1 * 4  // m.IP4Addr
1149         size += 1 * 16 // m.IP6Addr
1150         return size
1151 }
1152 func (m *DsliteGetAftrAddrReply) Marshal(b []byte) ([]byte, error) {
1153         if b == nil {
1154                 b = make([]byte, m.Size())
1155         }
1156         buf := codec.NewBuffer(b)
1157         buf.EncodeInt32(m.Retval)
1158         buf.EncodeBytes(m.IP4Addr[:], 4)
1159         buf.EncodeBytes(m.IP6Addr[:], 16)
1160         return buf.Bytes(), nil
1161 }
1162 func (m *DsliteGetAftrAddrReply) Unmarshal(b []byte) error {
1163         buf := codec.NewBuffer(b)
1164         m.Retval = buf.DecodeInt32()
1165         copy(m.IP4Addr[:], buf.DecodeBytes(4))
1166         copy(m.IP6Addr[:], buf.DecodeBytes(16))
1167         return nil
1168 }
1169
1170 // DsliteGetB4Addr defines message 'dslite_get_b4_addr'.
1171 type DsliteGetB4Addr struct{}
1172
1173 func (m *DsliteGetB4Addr) Reset()               { *m = DsliteGetB4Addr{} }
1174 func (*DsliteGetB4Addr) GetMessageName() string { return "dslite_get_b4_addr" }
1175 func (*DsliteGetB4Addr) GetCrcString() string   { return "51077d14" }
1176 func (*DsliteGetB4Addr) GetMessageType() api.MessageType {
1177         return api.RequestMessage
1178 }
1179
1180 func (m *DsliteGetB4Addr) Size() (size int) {
1181         if m == nil {
1182                 return 0
1183         }
1184         return size
1185 }
1186 func (m *DsliteGetB4Addr) Marshal(b []byte) ([]byte, error) {
1187         if b == nil {
1188                 b = make([]byte, m.Size())
1189         }
1190         buf := codec.NewBuffer(b)
1191         return buf.Bytes(), nil
1192 }
1193 func (m *DsliteGetB4Addr) Unmarshal(b []byte) error {
1194         return nil
1195 }
1196
1197 // DsliteGetB4AddrReply defines message 'dslite_get_b4_addr_reply'.
1198 type DsliteGetB4AddrReply struct {
1199         Retval  int32      `binapi:"i32,name=retval" json:"retval,omitempty"`
1200         IP4Addr IP4Address `binapi:"ip4_address,name=ip4_addr" json:"ip4_addr,omitempty"`
1201         IP6Addr IP6Address `binapi:"ip6_address,name=ip6_addr" json:"ip6_addr,omitempty"`
1202 }
1203
1204 func (m *DsliteGetB4AddrReply) Reset()               { *m = DsliteGetB4AddrReply{} }
1205 func (*DsliteGetB4AddrReply) GetMessageName() string { return "dslite_get_b4_addr_reply" }
1206 func (*DsliteGetB4AddrReply) GetCrcString() string   { return "38e30db1" }
1207 func (*DsliteGetB4AddrReply) GetMessageType() api.MessageType {
1208         return api.ReplyMessage
1209 }
1210
1211 func (m *DsliteGetB4AddrReply) Size() (size int) {
1212         if m == nil {
1213                 return 0
1214         }
1215         size += 4      // m.Retval
1216         size += 1 * 4  // m.IP4Addr
1217         size += 1 * 16 // m.IP6Addr
1218         return size
1219 }
1220 func (m *DsliteGetB4AddrReply) Marshal(b []byte) ([]byte, error) {
1221         if b == nil {
1222                 b = make([]byte, m.Size())
1223         }
1224         buf := codec.NewBuffer(b)
1225         buf.EncodeInt32(m.Retval)
1226         buf.EncodeBytes(m.IP4Addr[:], 4)
1227         buf.EncodeBytes(m.IP6Addr[:], 16)
1228         return buf.Bytes(), nil
1229 }
1230 func (m *DsliteGetB4AddrReply) Unmarshal(b []byte) error {
1231         buf := codec.NewBuffer(b)
1232         m.Retval = buf.DecodeInt32()
1233         copy(m.IP4Addr[:], buf.DecodeBytes(4))
1234         copy(m.IP6Addr[:], buf.DecodeBytes(16))
1235         return nil
1236 }
1237
1238 // DsliteSetAftrAddr defines message 'dslite_set_aftr_addr'.
1239 type DsliteSetAftrAddr struct {
1240         IP4Addr IP4Address `binapi:"ip4_address,name=ip4_addr" json:"ip4_addr,omitempty"`
1241         IP6Addr IP6Address `binapi:"ip6_address,name=ip6_addr" json:"ip6_addr,omitempty"`
1242 }
1243
1244 func (m *DsliteSetAftrAddr) Reset()               { *m = DsliteSetAftrAddr{} }
1245 func (*DsliteSetAftrAddr) GetMessageName() string { return "dslite_set_aftr_addr" }
1246 func (*DsliteSetAftrAddr) GetCrcString() string   { return "1e955f8d" }
1247 func (*DsliteSetAftrAddr) GetMessageType() api.MessageType {
1248         return api.RequestMessage
1249 }
1250
1251 func (m *DsliteSetAftrAddr) Size() (size int) {
1252         if m == nil {
1253                 return 0
1254         }
1255         size += 1 * 4  // m.IP4Addr
1256         size += 1 * 16 // m.IP6Addr
1257         return size
1258 }
1259 func (m *DsliteSetAftrAddr) Marshal(b []byte) ([]byte, error) {
1260         if b == nil {
1261                 b = make([]byte, m.Size())
1262         }
1263         buf := codec.NewBuffer(b)
1264         buf.EncodeBytes(m.IP4Addr[:], 4)
1265         buf.EncodeBytes(m.IP6Addr[:], 16)
1266         return buf.Bytes(), nil
1267 }
1268 func (m *DsliteSetAftrAddr) Unmarshal(b []byte) error {
1269         buf := codec.NewBuffer(b)
1270         copy(m.IP4Addr[:], buf.DecodeBytes(4))
1271         copy(m.IP6Addr[:], buf.DecodeBytes(16))
1272         return nil
1273 }
1274
1275 // DsliteSetAftrAddrReply defines message 'dslite_set_aftr_addr_reply'.
1276 type DsliteSetAftrAddrReply struct {
1277         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
1278 }
1279
1280 func (m *DsliteSetAftrAddrReply) Reset()               { *m = DsliteSetAftrAddrReply{} }
1281 func (*DsliteSetAftrAddrReply) GetMessageName() string { return "dslite_set_aftr_addr_reply" }
1282 func (*DsliteSetAftrAddrReply) GetCrcString() string   { return "e8d4e804" }
1283 func (*DsliteSetAftrAddrReply) GetMessageType() api.MessageType {
1284         return api.ReplyMessage
1285 }
1286
1287 func (m *DsliteSetAftrAddrReply) Size() (size int) {
1288         if m == nil {
1289                 return 0
1290         }
1291         size += 4 // m.Retval
1292         return size
1293 }
1294 func (m *DsliteSetAftrAddrReply) Marshal(b []byte) ([]byte, error) {
1295         if b == nil {
1296                 b = make([]byte, m.Size())
1297         }
1298         buf := codec.NewBuffer(b)
1299         buf.EncodeInt32(m.Retval)
1300         return buf.Bytes(), nil
1301 }
1302 func (m *DsliteSetAftrAddrReply) Unmarshal(b []byte) error {
1303         buf := codec.NewBuffer(b)
1304         m.Retval = buf.DecodeInt32()
1305         return nil
1306 }
1307
1308 // DsliteSetB4Addr defines message 'dslite_set_b4_addr'.
1309 type DsliteSetB4Addr struct {
1310         IP4Addr IP4Address `binapi:"ip4_address,name=ip4_addr" json:"ip4_addr,omitempty"`
1311         IP6Addr IP6Address `binapi:"ip6_address,name=ip6_addr" json:"ip6_addr,omitempty"`
1312 }
1313
1314 func (m *DsliteSetB4Addr) Reset()               { *m = DsliteSetB4Addr{} }
1315 func (*DsliteSetB4Addr) GetMessageName() string { return "dslite_set_b4_addr" }
1316 func (*DsliteSetB4Addr) GetCrcString() string   { return "1e955f8d" }
1317 func (*DsliteSetB4Addr) GetMessageType() api.MessageType {
1318         return api.RequestMessage
1319 }
1320
1321 func (m *DsliteSetB4Addr) Size() (size int) {
1322         if m == nil {
1323                 return 0
1324         }
1325         size += 1 * 4  // m.IP4Addr
1326         size += 1 * 16 // m.IP6Addr
1327         return size
1328 }
1329 func (m *DsliteSetB4Addr) Marshal(b []byte) ([]byte, error) {
1330         if b == nil {
1331                 b = make([]byte, m.Size())
1332         }
1333         buf := codec.NewBuffer(b)
1334         buf.EncodeBytes(m.IP4Addr[:], 4)
1335         buf.EncodeBytes(m.IP6Addr[:], 16)
1336         return buf.Bytes(), nil
1337 }
1338 func (m *DsliteSetB4Addr) Unmarshal(b []byte) error {
1339         buf := codec.NewBuffer(b)
1340         copy(m.IP4Addr[:], buf.DecodeBytes(4))
1341         copy(m.IP6Addr[:], buf.DecodeBytes(16))
1342         return nil
1343 }
1344
1345 // DsliteSetB4AddrReply defines message 'dslite_set_b4_addr_reply'.
1346 type DsliteSetB4AddrReply struct {
1347         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
1348 }
1349
1350 func (m *DsliteSetB4AddrReply) Reset()               { *m = DsliteSetB4AddrReply{} }
1351 func (*DsliteSetB4AddrReply) GetMessageName() string { return "dslite_set_b4_addr_reply" }
1352 func (*DsliteSetB4AddrReply) GetCrcString() string   { return "e8d4e804" }
1353 func (*DsliteSetB4AddrReply) GetMessageType() api.MessageType {
1354         return api.ReplyMessage
1355 }
1356
1357 func (m *DsliteSetB4AddrReply) Size() (size int) {
1358         if m == nil {
1359                 return 0
1360         }
1361         size += 4 // m.Retval
1362         return size
1363 }
1364 func (m *DsliteSetB4AddrReply) Marshal(b []byte) ([]byte, error) {
1365         if b == nil {
1366                 b = make([]byte, m.Size())
1367         }
1368         buf := codec.NewBuffer(b)
1369         buf.EncodeInt32(m.Retval)
1370         return buf.Bytes(), nil
1371 }
1372 func (m *DsliteSetB4AddrReply) Unmarshal(b []byte) error {
1373         buf := codec.NewBuffer(b)
1374         m.Retval = buf.DecodeInt32()
1375         return nil
1376 }
1377
1378 // Nat44AddDelAddressRange defines message 'nat44_add_del_address_range'.
1379 type Nat44AddDelAddressRange struct {
1380         FirstIPAddress IP4Address     `binapi:"ip4_address,name=first_ip_address" json:"first_ip_address,omitempty"`
1381         LastIPAddress  IP4Address     `binapi:"ip4_address,name=last_ip_address" json:"last_ip_address,omitempty"`
1382         VrfID          uint32         `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
1383         IsAdd          bool           `binapi:"bool,name=is_add" json:"is_add,omitempty"`
1384         Flags          NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
1385 }
1386
1387 func (m *Nat44AddDelAddressRange) Reset()               { *m = Nat44AddDelAddressRange{} }
1388 func (*Nat44AddDelAddressRange) GetMessageName() string { return "nat44_add_del_address_range" }
1389 func (*Nat44AddDelAddressRange) GetCrcString() string   { return "d4c7568c" }
1390 func (*Nat44AddDelAddressRange) GetMessageType() api.MessageType {
1391         return api.RequestMessage
1392 }
1393
1394 func (m *Nat44AddDelAddressRange) Size() (size int) {
1395         if m == nil {
1396                 return 0
1397         }
1398         size += 1 * 4 // m.FirstIPAddress
1399         size += 1 * 4 // m.LastIPAddress
1400         size += 4     // m.VrfID
1401         size += 1     // m.IsAdd
1402         size += 1     // m.Flags
1403         return size
1404 }
1405 func (m *Nat44AddDelAddressRange) Marshal(b []byte) ([]byte, error) {
1406         if b == nil {
1407                 b = make([]byte, m.Size())
1408         }
1409         buf := codec.NewBuffer(b)
1410         buf.EncodeBytes(m.FirstIPAddress[:], 4)
1411         buf.EncodeBytes(m.LastIPAddress[:], 4)
1412         buf.EncodeUint32(m.VrfID)
1413         buf.EncodeBool(m.IsAdd)
1414         buf.EncodeUint8(uint8(m.Flags))
1415         return buf.Bytes(), nil
1416 }
1417 func (m *Nat44AddDelAddressRange) Unmarshal(b []byte) error {
1418         buf := codec.NewBuffer(b)
1419         copy(m.FirstIPAddress[:], buf.DecodeBytes(4))
1420         copy(m.LastIPAddress[:], buf.DecodeBytes(4))
1421         m.VrfID = buf.DecodeUint32()
1422         m.IsAdd = buf.DecodeBool()
1423         m.Flags = NatConfigFlags(buf.DecodeUint8())
1424         return nil
1425 }
1426
1427 // Nat44AddDelAddressRangeReply defines message 'nat44_add_del_address_range_reply'.
1428 type Nat44AddDelAddressRangeReply struct {
1429         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
1430 }
1431
1432 func (m *Nat44AddDelAddressRangeReply) Reset() { *m = Nat44AddDelAddressRangeReply{} }
1433 func (*Nat44AddDelAddressRangeReply) GetMessageName() string {
1434         return "nat44_add_del_address_range_reply"
1435 }
1436 func (*Nat44AddDelAddressRangeReply) GetCrcString() string { return "e8d4e804" }
1437 func (*Nat44AddDelAddressRangeReply) GetMessageType() api.MessageType {
1438         return api.ReplyMessage
1439 }
1440
1441 func (m *Nat44AddDelAddressRangeReply) Size() (size int) {
1442         if m == nil {
1443                 return 0
1444         }
1445         size += 4 // m.Retval
1446         return size
1447 }
1448 func (m *Nat44AddDelAddressRangeReply) Marshal(b []byte) ([]byte, error) {
1449         if b == nil {
1450                 b = make([]byte, m.Size())
1451         }
1452         buf := codec.NewBuffer(b)
1453         buf.EncodeInt32(m.Retval)
1454         return buf.Bytes(), nil
1455 }
1456 func (m *Nat44AddDelAddressRangeReply) Unmarshal(b []byte) error {
1457         buf := codec.NewBuffer(b)
1458         m.Retval = buf.DecodeInt32()
1459         return nil
1460 }
1461
1462 // Nat44AddDelIdentityMapping defines message 'nat44_add_del_identity_mapping'.
1463 type Nat44AddDelIdentityMapping struct {
1464         IsAdd     bool           `binapi:"bool,name=is_add" json:"is_add,omitempty"`
1465         Flags     NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
1466         IPAddress IP4Address     `binapi:"ip4_address,name=ip_address" json:"ip_address,omitempty"`
1467         Protocol  uint8          `binapi:"u8,name=protocol" json:"protocol,omitempty"`
1468         Port      uint16         `binapi:"u16,name=port" json:"port,omitempty"`
1469         SwIfIndex InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
1470         VrfID     uint32         `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
1471         Tag       string         `binapi:"string[64],name=tag" json:"tag,omitempty"`
1472 }
1473
1474 func (m *Nat44AddDelIdentityMapping) Reset()               { *m = Nat44AddDelIdentityMapping{} }
1475 func (*Nat44AddDelIdentityMapping) GetMessageName() string { return "nat44_add_del_identity_mapping" }
1476 func (*Nat44AddDelIdentityMapping) GetCrcString() string   { return "8e12743f" }
1477 func (*Nat44AddDelIdentityMapping) GetMessageType() api.MessageType {
1478         return api.RequestMessage
1479 }
1480
1481 func (m *Nat44AddDelIdentityMapping) Size() (size int) {
1482         if m == nil {
1483                 return 0
1484         }
1485         size += 1     // m.IsAdd
1486         size += 1     // m.Flags
1487         size += 1 * 4 // m.IPAddress
1488         size += 1     // m.Protocol
1489         size += 2     // m.Port
1490         size += 4     // m.SwIfIndex
1491         size += 4     // m.VrfID
1492         size += 64    // m.Tag
1493         return size
1494 }
1495 func (m *Nat44AddDelIdentityMapping) Marshal(b []byte) ([]byte, error) {
1496         if b == nil {
1497                 b = make([]byte, m.Size())
1498         }
1499         buf := codec.NewBuffer(b)
1500         buf.EncodeBool(m.IsAdd)
1501         buf.EncodeUint8(uint8(m.Flags))
1502         buf.EncodeBytes(m.IPAddress[:], 4)
1503         buf.EncodeUint8(m.Protocol)
1504         buf.EncodeUint16(m.Port)
1505         buf.EncodeUint32(uint32(m.SwIfIndex))
1506         buf.EncodeUint32(m.VrfID)
1507         buf.EncodeString(m.Tag, 64)
1508         return buf.Bytes(), nil
1509 }
1510 func (m *Nat44AddDelIdentityMapping) Unmarshal(b []byte) error {
1511         buf := codec.NewBuffer(b)
1512         m.IsAdd = buf.DecodeBool()
1513         m.Flags = NatConfigFlags(buf.DecodeUint8())
1514         copy(m.IPAddress[:], buf.DecodeBytes(4))
1515         m.Protocol = buf.DecodeUint8()
1516         m.Port = buf.DecodeUint16()
1517         m.SwIfIndex = InterfaceIndex(buf.DecodeUint32())
1518         m.VrfID = buf.DecodeUint32()
1519         m.Tag = buf.DecodeString(64)
1520         return nil
1521 }
1522
1523 // Nat44AddDelIdentityMappingReply defines message 'nat44_add_del_identity_mapping_reply'.
1524 type Nat44AddDelIdentityMappingReply struct {
1525         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
1526 }
1527
1528 func (m *Nat44AddDelIdentityMappingReply) Reset() { *m = Nat44AddDelIdentityMappingReply{} }
1529 func (*Nat44AddDelIdentityMappingReply) GetMessageName() string {
1530         return "nat44_add_del_identity_mapping_reply"
1531 }
1532 func (*Nat44AddDelIdentityMappingReply) GetCrcString() string { return "e8d4e804" }
1533 func (*Nat44AddDelIdentityMappingReply) GetMessageType() api.MessageType {
1534         return api.ReplyMessage
1535 }
1536
1537 func (m *Nat44AddDelIdentityMappingReply) Size() (size int) {
1538         if m == nil {
1539                 return 0
1540         }
1541         size += 4 // m.Retval
1542         return size
1543 }
1544 func (m *Nat44AddDelIdentityMappingReply) Marshal(b []byte) ([]byte, error) {
1545         if b == nil {
1546                 b = make([]byte, m.Size())
1547         }
1548         buf := codec.NewBuffer(b)
1549         buf.EncodeInt32(m.Retval)
1550         return buf.Bytes(), nil
1551 }
1552 func (m *Nat44AddDelIdentityMappingReply) Unmarshal(b []byte) error {
1553         buf := codec.NewBuffer(b)
1554         m.Retval = buf.DecodeInt32()
1555         return nil
1556 }
1557
1558 // Nat44AddDelInterfaceAddr defines message 'nat44_add_del_interface_addr'.
1559 type Nat44AddDelInterfaceAddr struct {
1560         IsAdd     bool           `binapi:"bool,name=is_add" json:"is_add,omitempty"`
1561         SwIfIndex InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
1562         Flags     NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
1563 }
1564
1565 func (m *Nat44AddDelInterfaceAddr) Reset()               { *m = Nat44AddDelInterfaceAddr{} }
1566 func (*Nat44AddDelInterfaceAddr) GetMessageName() string { return "nat44_add_del_interface_addr" }
1567 func (*Nat44AddDelInterfaceAddr) GetCrcString() string   { return "fc835325" }
1568 func (*Nat44AddDelInterfaceAddr) GetMessageType() api.MessageType {
1569         return api.RequestMessage
1570 }
1571
1572 func (m *Nat44AddDelInterfaceAddr) Size() (size int) {
1573         if m == nil {
1574                 return 0
1575         }
1576         size += 1 // m.IsAdd
1577         size += 4 // m.SwIfIndex
1578         size += 1 // m.Flags
1579         return size
1580 }
1581 func (m *Nat44AddDelInterfaceAddr) Marshal(b []byte) ([]byte, error) {
1582         if b == nil {
1583                 b = make([]byte, m.Size())
1584         }
1585         buf := codec.NewBuffer(b)
1586         buf.EncodeBool(m.IsAdd)
1587         buf.EncodeUint32(uint32(m.SwIfIndex))
1588         buf.EncodeUint8(uint8(m.Flags))
1589         return buf.Bytes(), nil
1590 }
1591 func (m *Nat44AddDelInterfaceAddr) Unmarshal(b []byte) error {
1592         buf := codec.NewBuffer(b)
1593         m.IsAdd = buf.DecodeBool()
1594         m.SwIfIndex = InterfaceIndex(buf.DecodeUint32())
1595         m.Flags = NatConfigFlags(buf.DecodeUint8())
1596         return nil
1597 }
1598
1599 // Nat44AddDelInterfaceAddrReply defines message 'nat44_add_del_interface_addr_reply'.
1600 type Nat44AddDelInterfaceAddrReply struct {
1601         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
1602 }
1603
1604 func (m *Nat44AddDelInterfaceAddrReply) Reset() { *m = Nat44AddDelInterfaceAddrReply{} }
1605 func (*Nat44AddDelInterfaceAddrReply) GetMessageName() string {
1606         return "nat44_add_del_interface_addr_reply"
1607 }
1608 func (*Nat44AddDelInterfaceAddrReply) GetCrcString() string { return "e8d4e804" }
1609 func (*Nat44AddDelInterfaceAddrReply) GetMessageType() api.MessageType {
1610         return api.ReplyMessage
1611 }
1612
1613 func (m *Nat44AddDelInterfaceAddrReply) Size() (size int) {
1614         if m == nil {
1615                 return 0
1616         }
1617         size += 4 // m.Retval
1618         return size
1619 }
1620 func (m *Nat44AddDelInterfaceAddrReply) Marshal(b []byte) ([]byte, error) {
1621         if b == nil {
1622                 b = make([]byte, m.Size())
1623         }
1624         buf := codec.NewBuffer(b)
1625         buf.EncodeInt32(m.Retval)
1626         return buf.Bytes(), nil
1627 }
1628 func (m *Nat44AddDelInterfaceAddrReply) Unmarshal(b []byte) error {
1629         buf := codec.NewBuffer(b)
1630         m.Retval = buf.DecodeInt32()
1631         return nil
1632 }
1633
1634 // Nat44AddDelLbStaticMapping defines message 'nat44_add_del_lb_static_mapping'.
1635 type Nat44AddDelLbStaticMapping struct {
1636         IsAdd        bool              `binapi:"bool,name=is_add" json:"is_add,omitempty"`
1637         Flags        NatConfigFlags    `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
1638         ExternalAddr IP4Address        `binapi:"ip4_address,name=external_addr" json:"external_addr,omitempty"`
1639         ExternalPort uint16            `binapi:"u16,name=external_port" json:"external_port,omitempty"`
1640         Protocol     uint8             `binapi:"u8,name=protocol" json:"protocol,omitempty"`
1641         Affinity     uint32            `binapi:"u32,name=affinity" json:"affinity,omitempty"`
1642         Tag          string            `binapi:"string[64],name=tag" json:"tag,omitempty"`
1643         LocalNum     uint32            `binapi:"u32,name=local_num" json:"-"`
1644         Locals       []Nat44LbAddrPort `binapi:"nat44_lb_addr_port[local_num],name=locals" json:"locals,omitempty"`
1645 }
1646
1647 func (m *Nat44AddDelLbStaticMapping) Reset()               { *m = Nat44AddDelLbStaticMapping{} }
1648 func (*Nat44AddDelLbStaticMapping) GetMessageName() string { return "nat44_add_del_lb_static_mapping" }
1649 func (*Nat44AddDelLbStaticMapping) GetCrcString() string   { return "53b24611" }
1650 func (*Nat44AddDelLbStaticMapping) GetMessageType() api.MessageType {
1651         return api.RequestMessage
1652 }
1653
1654 func (m *Nat44AddDelLbStaticMapping) Size() (size int) {
1655         if m == nil {
1656                 return 0
1657         }
1658         size += 1     // m.IsAdd
1659         size += 1     // m.Flags
1660         size += 1 * 4 // m.ExternalAddr
1661         size += 2     // m.ExternalPort
1662         size += 1     // m.Protocol
1663         size += 4     // m.Affinity
1664         size += 64    // m.Tag
1665         size += 4     // m.LocalNum
1666         for j1 := 0; j1 < len(m.Locals); j1++ {
1667                 var s1 Nat44LbAddrPort
1668                 _ = s1
1669                 if j1 < len(m.Locals) {
1670                         s1 = m.Locals[j1]
1671                 }
1672                 size += 1 * 4 // s1.Addr
1673                 size += 2     // s1.Port
1674                 size += 1     // s1.Probability
1675                 size += 4     // s1.VrfID
1676         }
1677         return size
1678 }
1679 func (m *Nat44AddDelLbStaticMapping) Marshal(b []byte) ([]byte, error) {
1680         if b == nil {
1681                 b = make([]byte, m.Size())
1682         }
1683         buf := codec.NewBuffer(b)
1684         buf.EncodeBool(m.IsAdd)
1685         buf.EncodeUint8(uint8(m.Flags))
1686         buf.EncodeBytes(m.ExternalAddr[:], 4)
1687         buf.EncodeUint16(m.ExternalPort)
1688         buf.EncodeUint8(m.Protocol)
1689         buf.EncodeUint32(m.Affinity)
1690         buf.EncodeString(m.Tag, 64)
1691         buf.EncodeUint32(uint32(len(m.Locals)))
1692         for j0 := 0; j0 < len(m.Locals); j0++ {
1693                 var v0 Nat44LbAddrPort // Locals
1694                 if j0 < len(m.Locals) {
1695                         v0 = m.Locals[j0]
1696                 }
1697                 buf.EncodeBytes(v0.Addr[:], 4)
1698                 buf.EncodeUint16(v0.Port)
1699                 buf.EncodeUint8(v0.Probability)
1700                 buf.EncodeUint32(v0.VrfID)
1701         }
1702         return buf.Bytes(), nil
1703 }
1704 func (m *Nat44AddDelLbStaticMapping) Unmarshal(b []byte) error {
1705         buf := codec.NewBuffer(b)
1706         m.IsAdd = buf.DecodeBool()
1707         m.Flags = NatConfigFlags(buf.DecodeUint8())
1708         copy(m.ExternalAddr[:], buf.DecodeBytes(4))
1709         m.ExternalPort = buf.DecodeUint16()
1710         m.Protocol = buf.DecodeUint8()
1711         m.Affinity = buf.DecodeUint32()
1712         m.Tag = buf.DecodeString(64)
1713         m.LocalNum = buf.DecodeUint32()
1714         m.Locals = make([]Nat44LbAddrPort, m.LocalNum)
1715         for j0 := 0; j0 < len(m.Locals); j0++ {
1716                 copy(m.Locals[j0].Addr[:], buf.DecodeBytes(4))
1717                 m.Locals[j0].Port = buf.DecodeUint16()
1718                 m.Locals[j0].Probability = buf.DecodeUint8()
1719                 m.Locals[j0].VrfID = buf.DecodeUint32()
1720         }
1721         return nil
1722 }
1723
1724 // Nat44AddDelLbStaticMappingReply defines message 'nat44_add_del_lb_static_mapping_reply'.
1725 type Nat44AddDelLbStaticMappingReply struct {
1726         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
1727 }
1728
1729 func (m *Nat44AddDelLbStaticMappingReply) Reset() { *m = Nat44AddDelLbStaticMappingReply{} }
1730 func (*Nat44AddDelLbStaticMappingReply) GetMessageName() string {
1731         return "nat44_add_del_lb_static_mapping_reply"
1732 }
1733 func (*Nat44AddDelLbStaticMappingReply) GetCrcString() string { return "e8d4e804" }
1734 func (*Nat44AddDelLbStaticMappingReply) GetMessageType() api.MessageType {
1735         return api.ReplyMessage
1736 }
1737
1738 func (m *Nat44AddDelLbStaticMappingReply) Size() (size int) {
1739         if m == nil {
1740                 return 0
1741         }
1742         size += 4 // m.Retval
1743         return size
1744 }
1745 func (m *Nat44AddDelLbStaticMappingReply) Marshal(b []byte) ([]byte, error) {
1746         if b == nil {
1747                 b = make([]byte, m.Size())
1748         }
1749         buf := codec.NewBuffer(b)
1750         buf.EncodeInt32(m.Retval)
1751         return buf.Bytes(), nil
1752 }
1753 func (m *Nat44AddDelLbStaticMappingReply) Unmarshal(b []byte) error {
1754         buf := codec.NewBuffer(b)
1755         m.Retval = buf.DecodeInt32()
1756         return nil
1757 }
1758
1759 // Nat44AddDelStaticMapping defines message 'nat44_add_del_static_mapping'.
1760 type Nat44AddDelStaticMapping struct {
1761         IsAdd             bool           `binapi:"bool,name=is_add" json:"is_add,omitempty"`
1762         Flags             NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
1763         LocalIPAddress    IP4Address     `binapi:"ip4_address,name=local_ip_address" json:"local_ip_address,omitempty"`
1764         ExternalIPAddress IP4Address     `binapi:"ip4_address,name=external_ip_address" json:"external_ip_address,omitempty"`
1765         Protocol          uint8          `binapi:"u8,name=protocol" json:"protocol,omitempty"`
1766         LocalPort         uint16         `binapi:"u16,name=local_port" json:"local_port,omitempty"`
1767         ExternalPort      uint16         `binapi:"u16,name=external_port" json:"external_port,omitempty"`
1768         ExternalSwIfIndex InterfaceIndex `binapi:"interface_index,name=external_sw_if_index" json:"external_sw_if_index,omitempty"`
1769         VrfID             uint32         `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
1770         Tag               string         `binapi:"string[64],name=tag" json:"tag,omitempty"`
1771 }
1772
1773 func (m *Nat44AddDelStaticMapping) Reset()               { *m = Nat44AddDelStaticMapping{} }
1774 func (*Nat44AddDelStaticMapping) GetMessageName() string { return "nat44_add_del_static_mapping" }
1775 func (*Nat44AddDelStaticMapping) GetCrcString() string   { return "e165e83b" }
1776 func (*Nat44AddDelStaticMapping) GetMessageType() api.MessageType {
1777         return api.RequestMessage
1778 }
1779
1780 func (m *Nat44AddDelStaticMapping) Size() (size int) {
1781         if m == nil {
1782                 return 0
1783         }
1784         size += 1     // m.IsAdd
1785         size += 1     // m.Flags
1786         size += 1 * 4 // m.LocalIPAddress
1787         size += 1 * 4 // m.ExternalIPAddress
1788         size += 1     // m.Protocol
1789         size += 2     // m.LocalPort
1790         size += 2     // m.ExternalPort
1791         size += 4     // m.ExternalSwIfIndex
1792         size += 4     // m.VrfID
1793         size += 64    // m.Tag
1794         return size
1795 }
1796 func (m *Nat44AddDelStaticMapping) Marshal(b []byte) ([]byte, error) {
1797         if b == nil {
1798                 b = make([]byte, m.Size())
1799         }
1800         buf := codec.NewBuffer(b)
1801         buf.EncodeBool(m.IsAdd)
1802         buf.EncodeUint8(uint8(m.Flags))
1803         buf.EncodeBytes(m.LocalIPAddress[:], 4)
1804         buf.EncodeBytes(m.ExternalIPAddress[:], 4)
1805         buf.EncodeUint8(m.Protocol)
1806         buf.EncodeUint16(m.LocalPort)
1807         buf.EncodeUint16(m.ExternalPort)
1808         buf.EncodeUint32(uint32(m.ExternalSwIfIndex))
1809         buf.EncodeUint32(m.VrfID)
1810         buf.EncodeString(m.Tag, 64)
1811         return buf.Bytes(), nil
1812 }
1813 func (m *Nat44AddDelStaticMapping) Unmarshal(b []byte) error {
1814         buf := codec.NewBuffer(b)
1815         m.IsAdd = buf.DecodeBool()
1816         m.Flags = NatConfigFlags(buf.DecodeUint8())
1817         copy(m.LocalIPAddress[:], buf.DecodeBytes(4))
1818         copy(m.ExternalIPAddress[:], buf.DecodeBytes(4))
1819         m.Protocol = buf.DecodeUint8()
1820         m.LocalPort = buf.DecodeUint16()
1821         m.ExternalPort = buf.DecodeUint16()
1822         m.ExternalSwIfIndex = InterfaceIndex(buf.DecodeUint32())
1823         m.VrfID = buf.DecodeUint32()
1824         m.Tag = buf.DecodeString(64)
1825         return nil
1826 }
1827
1828 // Nat44AddDelStaticMappingReply defines message 'nat44_add_del_static_mapping_reply'.
1829 type Nat44AddDelStaticMappingReply struct {
1830         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
1831 }
1832
1833 func (m *Nat44AddDelStaticMappingReply) Reset() { *m = Nat44AddDelStaticMappingReply{} }
1834 func (*Nat44AddDelStaticMappingReply) GetMessageName() string {
1835         return "nat44_add_del_static_mapping_reply"
1836 }
1837 func (*Nat44AddDelStaticMappingReply) GetCrcString() string { return "e8d4e804" }
1838 func (*Nat44AddDelStaticMappingReply) GetMessageType() api.MessageType {
1839         return api.ReplyMessage
1840 }
1841
1842 func (m *Nat44AddDelStaticMappingReply) Size() (size int) {
1843         if m == nil {
1844                 return 0
1845         }
1846         size += 4 // m.Retval
1847         return size
1848 }
1849 func (m *Nat44AddDelStaticMappingReply) Marshal(b []byte) ([]byte, error) {
1850         if b == nil {
1851                 b = make([]byte, m.Size())
1852         }
1853         buf := codec.NewBuffer(b)
1854         buf.EncodeInt32(m.Retval)
1855         return buf.Bytes(), nil
1856 }
1857 func (m *Nat44AddDelStaticMappingReply) Unmarshal(b []byte) error {
1858         buf := codec.NewBuffer(b)
1859         m.Retval = buf.DecodeInt32()
1860         return nil
1861 }
1862
1863 // Nat44AddressDetails defines message 'nat44_address_details'.
1864 type Nat44AddressDetails struct {
1865         IPAddress IP4Address     `binapi:"ip4_address,name=ip_address" json:"ip_address,omitempty"`
1866         Flags     NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
1867         VrfID     uint32         `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
1868 }
1869
1870 func (m *Nat44AddressDetails) Reset()               { *m = Nat44AddressDetails{} }
1871 func (*Nat44AddressDetails) GetMessageName() string { return "nat44_address_details" }
1872 func (*Nat44AddressDetails) GetCrcString() string   { return "45410ac4" }
1873 func (*Nat44AddressDetails) GetMessageType() api.MessageType {
1874         return api.ReplyMessage
1875 }
1876
1877 func (m *Nat44AddressDetails) Size() (size int) {
1878         if m == nil {
1879                 return 0
1880         }
1881         size += 1 * 4 // m.IPAddress
1882         size += 1     // m.Flags
1883         size += 4     // m.VrfID
1884         return size
1885 }
1886 func (m *Nat44AddressDetails) Marshal(b []byte) ([]byte, error) {
1887         if b == nil {
1888                 b = make([]byte, m.Size())
1889         }
1890         buf := codec.NewBuffer(b)
1891         buf.EncodeBytes(m.IPAddress[:], 4)
1892         buf.EncodeUint8(uint8(m.Flags))
1893         buf.EncodeUint32(m.VrfID)
1894         return buf.Bytes(), nil
1895 }
1896 func (m *Nat44AddressDetails) Unmarshal(b []byte) error {
1897         buf := codec.NewBuffer(b)
1898         copy(m.IPAddress[:], buf.DecodeBytes(4))
1899         m.Flags = NatConfigFlags(buf.DecodeUint8())
1900         m.VrfID = buf.DecodeUint32()
1901         return nil
1902 }
1903
1904 // Nat44AddressDump defines message 'nat44_address_dump'.
1905 type Nat44AddressDump struct{}
1906
1907 func (m *Nat44AddressDump) Reset()               { *m = Nat44AddressDump{} }
1908 func (*Nat44AddressDump) GetMessageName() string { return "nat44_address_dump" }
1909 func (*Nat44AddressDump) GetCrcString() string   { return "51077d14" }
1910 func (*Nat44AddressDump) GetMessageType() api.MessageType {
1911         return api.RequestMessage
1912 }
1913
1914 func (m *Nat44AddressDump) Size() (size int) {
1915         if m == nil {
1916                 return 0
1917         }
1918         return size
1919 }
1920 func (m *Nat44AddressDump) Marshal(b []byte) ([]byte, error) {
1921         if b == nil {
1922                 b = make([]byte, m.Size())
1923         }
1924         buf := codec.NewBuffer(b)
1925         return buf.Bytes(), nil
1926 }
1927 func (m *Nat44AddressDump) Unmarshal(b []byte) error {
1928         return nil
1929 }
1930
1931 // Nat44DelSession defines message 'nat44_del_session'.
1932 type Nat44DelSession struct {
1933         Address        IP4Address     `binapi:"ip4_address,name=address" json:"address,omitempty"`
1934         Protocol       uint8          `binapi:"u8,name=protocol" json:"protocol,omitempty"`
1935         Port           uint16         `binapi:"u16,name=port" json:"port,omitempty"`
1936         VrfID          uint32         `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
1937         Flags          NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
1938         ExtHostAddress IP4Address     `binapi:"ip4_address,name=ext_host_address" json:"ext_host_address,omitempty"`
1939         ExtHostPort    uint16         `binapi:"u16,name=ext_host_port" json:"ext_host_port,omitempty"`
1940 }
1941
1942 func (m *Nat44DelSession) Reset()               { *m = Nat44DelSession{} }
1943 func (*Nat44DelSession) GetMessageName() string { return "nat44_del_session" }
1944 func (*Nat44DelSession) GetCrcString() string   { return "4c49c387" }
1945 func (*Nat44DelSession) GetMessageType() api.MessageType {
1946         return api.RequestMessage
1947 }
1948
1949 func (m *Nat44DelSession) Size() (size int) {
1950         if m == nil {
1951                 return 0
1952         }
1953         size += 1 * 4 // m.Address
1954         size += 1     // m.Protocol
1955         size += 2     // m.Port
1956         size += 4     // m.VrfID
1957         size += 1     // m.Flags
1958         size += 1 * 4 // m.ExtHostAddress
1959         size += 2     // m.ExtHostPort
1960         return size
1961 }
1962 func (m *Nat44DelSession) Marshal(b []byte) ([]byte, error) {
1963         if b == nil {
1964                 b = make([]byte, m.Size())
1965         }
1966         buf := codec.NewBuffer(b)
1967         buf.EncodeBytes(m.Address[:], 4)
1968         buf.EncodeUint8(m.Protocol)
1969         buf.EncodeUint16(m.Port)
1970         buf.EncodeUint32(m.VrfID)
1971         buf.EncodeUint8(uint8(m.Flags))
1972         buf.EncodeBytes(m.ExtHostAddress[:], 4)
1973         buf.EncodeUint16(m.ExtHostPort)
1974         return buf.Bytes(), nil
1975 }
1976 func (m *Nat44DelSession) Unmarshal(b []byte) error {
1977         buf := codec.NewBuffer(b)
1978         copy(m.Address[:], buf.DecodeBytes(4))
1979         m.Protocol = buf.DecodeUint8()
1980         m.Port = buf.DecodeUint16()
1981         m.VrfID = buf.DecodeUint32()
1982         m.Flags = NatConfigFlags(buf.DecodeUint8())
1983         copy(m.ExtHostAddress[:], buf.DecodeBytes(4))
1984         m.ExtHostPort = buf.DecodeUint16()
1985         return nil
1986 }
1987
1988 // Nat44DelSessionReply defines message 'nat44_del_session_reply'.
1989 type Nat44DelSessionReply struct {
1990         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
1991 }
1992
1993 func (m *Nat44DelSessionReply) Reset()               { *m = Nat44DelSessionReply{} }
1994 func (*Nat44DelSessionReply) GetMessageName() string { return "nat44_del_session_reply" }
1995 func (*Nat44DelSessionReply) GetCrcString() string   { return "e8d4e804" }
1996 func (*Nat44DelSessionReply) GetMessageType() api.MessageType {
1997         return api.ReplyMessage
1998 }
1999
2000 func (m *Nat44DelSessionReply) Size() (size int) {
2001         if m == nil {
2002                 return 0
2003         }
2004         size += 4 // m.Retval
2005         return size
2006 }
2007 func (m *Nat44DelSessionReply) Marshal(b []byte) ([]byte, error) {
2008         if b == nil {
2009                 b = make([]byte, m.Size())
2010         }
2011         buf := codec.NewBuffer(b)
2012         buf.EncodeInt32(m.Retval)
2013         return buf.Bytes(), nil
2014 }
2015 func (m *Nat44DelSessionReply) Unmarshal(b []byte) error {
2016         buf := codec.NewBuffer(b)
2017         m.Retval = buf.DecodeInt32()
2018         return nil
2019 }
2020
2021 // Nat44ForwardingEnableDisable defines message 'nat44_forwarding_enable_disable'.
2022 type Nat44ForwardingEnableDisable struct {
2023         Enable bool `binapi:"bool,name=enable" json:"enable,omitempty"`
2024 }
2025
2026 func (m *Nat44ForwardingEnableDisable) Reset() { *m = Nat44ForwardingEnableDisable{} }
2027 func (*Nat44ForwardingEnableDisable) GetMessageName() string {
2028         return "nat44_forwarding_enable_disable"
2029 }
2030 func (*Nat44ForwardingEnableDisable) GetCrcString() string { return "b3e225d2" }
2031 func (*Nat44ForwardingEnableDisable) GetMessageType() api.MessageType {
2032         return api.RequestMessage
2033 }
2034
2035 func (m *Nat44ForwardingEnableDisable) Size() (size int) {
2036         if m == nil {
2037                 return 0
2038         }
2039         size += 1 // m.Enable
2040         return size
2041 }
2042 func (m *Nat44ForwardingEnableDisable) Marshal(b []byte) ([]byte, error) {
2043         if b == nil {
2044                 b = make([]byte, m.Size())
2045         }
2046         buf := codec.NewBuffer(b)
2047         buf.EncodeBool(m.Enable)
2048         return buf.Bytes(), nil
2049 }
2050 func (m *Nat44ForwardingEnableDisable) Unmarshal(b []byte) error {
2051         buf := codec.NewBuffer(b)
2052         m.Enable = buf.DecodeBool()
2053         return nil
2054 }
2055
2056 // Nat44ForwardingEnableDisableReply defines message 'nat44_forwarding_enable_disable_reply'.
2057 type Nat44ForwardingEnableDisableReply struct {
2058         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
2059 }
2060
2061 func (m *Nat44ForwardingEnableDisableReply) Reset() { *m = Nat44ForwardingEnableDisableReply{} }
2062 func (*Nat44ForwardingEnableDisableReply) GetMessageName() string {
2063         return "nat44_forwarding_enable_disable_reply"
2064 }
2065 func (*Nat44ForwardingEnableDisableReply) GetCrcString() string { return "e8d4e804" }
2066 func (*Nat44ForwardingEnableDisableReply) GetMessageType() api.MessageType {
2067         return api.ReplyMessage
2068 }
2069
2070 func (m *Nat44ForwardingEnableDisableReply) Size() (size int) {
2071         if m == nil {
2072                 return 0
2073         }
2074         size += 4 // m.Retval
2075         return size
2076 }
2077 func (m *Nat44ForwardingEnableDisableReply) Marshal(b []byte) ([]byte, error) {
2078         if b == nil {
2079                 b = make([]byte, m.Size())
2080         }
2081         buf := codec.NewBuffer(b)
2082         buf.EncodeInt32(m.Retval)
2083         return buf.Bytes(), nil
2084 }
2085 func (m *Nat44ForwardingEnableDisableReply) Unmarshal(b []byte) error {
2086         buf := codec.NewBuffer(b)
2087         m.Retval = buf.DecodeInt32()
2088         return nil
2089 }
2090
2091 // Nat44ForwardingIsEnabled defines message 'nat44_forwarding_is_enabled'.
2092 type Nat44ForwardingIsEnabled struct{}
2093
2094 func (m *Nat44ForwardingIsEnabled) Reset()               { *m = Nat44ForwardingIsEnabled{} }
2095 func (*Nat44ForwardingIsEnabled) GetMessageName() string { return "nat44_forwarding_is_enabled" }
2096 func (*Nat44ForwardingIsEnabled) GetCrcString() string   { return "51077d14" }
2097 func (*Nat44ForwardingIsEnabled) GetMessageType() api.MessageType {
2098         return api.RequestMessage
2099 }
2100
2101 func (m *Nat44ForwardingIsEnabled) Size() (size int) {
2102         if m == nil {
2103                 return 0
2104         }
2105         return size
2106 }
2107 func (m *Nat44ForwardingIsEnabled) Marshal(b []byte) ([]byte, error) {
2108         if b == nil {
2109                 b = make([]byte, m.Size())
2110         }
2111         buf := codec.NewBuffer(b)
2112         return buf.Bytes(), nil
2113 }
2114 func (m *Nat44ForwardingIsEnabled) Unmarshal(b []byte) error {
2115         return nil
2116 }
2117
2118 // Nat44ForwardingIsEnabledReply defines message 'nat44_forwarding_is_enabled_reply'.
2119 type Nat44ForwardingIsEnabledReply struct {
2120         Enabled bool `binapi:"bool,name=enabled" json:"enabled,omitempty"`
2121 }
2122
2123 func (m *Nat44ForwardingIsEnabledReply) Reset() { *m = Nat44ForwardingIsEnabledReply{} }
2124 func (*Nat44ForwardingIsEnabledReply) GetMessageName() string {
2125         return "nat44_forwarding_is_enabled_reply"
2126 }
2127 func (*Nat44ForwardingIsEnabledReply) GetCrcString() string { return "46924a06" }
2128 func (*Nat44ForwardingIsEnabledReply) GetMessageType() api.MessageType {
2129         return api.ReplyMessage
2130 }
2131
2132 func (m *Nat44ForwardingIsEnabledReply) Size() (size int) {
2133         if m == nil {
2134                 return 0
2135         }
2136         size += 1 // m.Enabled
2137         return size
2138 }
2139 func (m *Nat44ForwardingIsEnabledReply) Marshal(b []byte) ([]byte, error) {
2140         if b == nil {
2141                 b = make([]byte, m.Size())
2142         }
2143         buf := codec.NewBuffer(b)
2144         buf.EncodeBool(m.Enabled)
2145         return buf.Bytes(), nil
2146 }
2147 func (m *Nat44ForwardingIsEnabledReply) Unmarshal(b []byte) error {
2148         buf := codec.NewBuffer(b)
2149         m.Enabled = buf.DecodeBool()
2150         return nil
2151 }
2152
2153 // Nat44IdentityMappingDetails defines message 'nat44_identity_mapping_details'.
2154 type Nat44IdentityMappingDetails struct {
2155         Flags     NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
2156         IPAddress IP4Address     `binapi:"ip4_address,name=ip_address" json:"ip_address,omitempty"`
2157         Protocol  uint8          `binapi:"u8,name=protocol" json:"protocol,omitempty"`
2158         Port      uint16         `binapi:"u16,name=port" json:"port,omitempty"`
2159         SwIfIndex InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
2160         VrfID     uint32         `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
2161         Tag       string         `binapi:"string[64],name=tag" json:"tag,omitempty"`
2162 }
2163
2164 func (m *Nat44IdentityMappingDetails) Reset()               { *m = Nat44IdentityMappingDetails{} }
2165 func (*Nat44IdentityMappingDetails) GetMessageName() string { return "nat44_identity_mapping_details" }
2166 func (*Nat44IdentityMappingDetails) GetCrcString() string   { return "36d21351" }
2167 func (*Nat44IdentityMappingDetails) GetMessageType() api.MessageType {
2168         return api.ReplyMessage
2169 }
2170
2171 func (m *Nat44IdentityMappingDetails) Size() (size int) {
2172         if m == nil {
2173                 return 0
2174         }
2175         size += 1     // m.Flags
2176         size += 1 * 4 // m.IPAddress
2177         size += 1     // m.Protocol
2178         size += 2     // m.Port
2179         size += 4     // m.SwIfIndex
2180         size += 4     // m.VrfID
2181         size += 64    // m.Tag
2182         return size
2183 }
2184 func (m *Nat44IdentityMappingDetails) Marshal(b []byte) ([]byte, error) {
2185         if b == nil {
2186                 b = make([]byte, m.Size())
2187         }
2188         buf := codec.NewBuffer(b)
2189         buf.EncodeUint8(uint8(m.Flags))
2190         buf.EncodeBytes(m.IPAddress[:], 4)
2191         buf.EncodeUint8(m.Protocol)
2192         buf.EncodeUint16(m.Port)
2193         buf.EncodeUint32(uint32(m.SwIfIndex))
2194         buf.EncodeUint32(m.VrfID)
2195         buf.EncodeString(m.Tag, 64)
2196         return buf.Bytes(), nil
2197 }
2198 func (m *Nat44IdentityMappingDetails) Unmarshal(b []byte) error {
2199         buf := codec.NewBuffer(b)
2200         m.Flags = NatConfigFlags(buf.DecodeUint8())
2201         copy(m.IPAddress[:], buf.DecodeBytes(4))
2202         m.Protocol = buf.DecodeUint8()
2203         m.Port = buf.DecodeUint16()
2204         m.SwIfIndex = InterfaceIndex(buf.DecodeUint32())
2205         m.VrfID = buf.DecodeUint32()
2206         m.Tag = buf.DecodeString(64)
2207         return nil
2208 }
2209
2210 // Nat44IdentityMappingDump defines message 'nat44_identity_mapping_dump'.
2211 type Nat44IdentityMappingDump struct{}
2212
2213 func (m *Nat44IdentityMappingDump) Reset()               { *m = Nat44IdentityMappingDump{} }
2214 func (*Nat44IdentityMappingDump) GetMessageName() string { return "nat44_identity_mapping_dump" }
2215 func (*Nat44IdentityMappingDump) GetCrcString() string   { return "51077d14" }
2216 func (*Nat44IdentityMappingDump) GetMessageType() api.MessageType {
2217         return api.RequestMessage
2218 }
2219
2220 func (m *Nat44IdentityMappingDump) Size() (size int) {
2221         if m == nil {
2222                 return 0
2223         }
2224         return size
2225 }
2226 func (m *Nat44IdentityMappingDump) Marshal(b []byte) ([]byte, error) {
2227         if b == nil {
2228                 b = make([]byte, m.Size())
2229         }
2230         buf := codec.NewBuffer(b)
2231         return buf.Bytes(), nil
2232 }
2233 func (m *Nat44IdentityMappingDump) Unmarshal(b []byte) error {
2234         return nil
2235 }
2236
2237 // Nat44InterfaceAddDelFeature defines message 'nat44_interface_add_del_feature'.
2238 type Nat44InterfaceAddDelFeature struct {
2239         IsAdd     bool           `binapi:"bool,name=is_add" json:"is_add,omitempty"`
2240         Flags     NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
2241         SwIfIndex InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
2242 }
2243
2244 func (m *Nat44InterfaceAddDelFeature) Reset()               { *m = Nat44InterfaceAddDelFeature{} }
2245 func (*Nat44InterfaceAddDelFeature) GetMessageName() string { return "nat44_interface_add_del_feature" }
2246 func (*Nat44InterfaceAddDelFeature) GetCrcString() string   { return "f3699b83" }
2247 func (*Nat44InterfaceAddDelFeature) GetMessageType() api.MessageType {
2248         return api.RequestMessage
2249 }
2250
2251 func (m *Nat44InterfaceAddDelFeature) Size() (size int) {
2252         if m == nil {
2253                 return 0
2254         }
2255         size += 1 // m.IsAdd
2256         size += 1 // m.Flags
2257         size += 4 // m.SwIfIndex
2258         return size
2259 }
2260 func (m *Nat44InterfaceAddDelFeature) Marshal(b []byte) ([]byte, error) {
2261         if b == nil {
2262                 b = make([]byte, m.Size())
2263         }
2264         buf := codec.NewBuffer(b)
2265         buf.EncodeBool(m.IsAdd)
2266         buf.EncodeUint8(uint8(m.Flags))
2267         buf.EncodeUint32(uint32(m.SwIfIndex))
2268         return buf.Bytes(), nil
2269 }
2270 func (m *Nat44InterfaceAddDelFeature) Unmarshal(b []byte) error {
2271         buf := codec.NewBuffer(b)
2272         m.IsAdd = buf.DecodeBool()
2273         m.Flags = NatConfigFlags(buf.DecodeUint8())
2274         m.SwIfIndex = InterfaceIndex(buf.DecodeUint32())
2275         return nil
2276 }
2277
2278 // Nat44InterfaceAddDelFeatureReply defines message 'nat44_interface_add_del_feature_reply'.
2279 type Nat44InterfaceAddDelFeatureReply struct {
2280         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
2281 }
2282
2283 func (m *Nat44InterfaceAddDelFeatureReply) Reset() { *m = Nat44InterfaceAddDelFeatureReply{} }
2284 func (*Nat44InterfaceAddDelFeatureReply) GetMessageName() string {
2285         return "nat44_interface_add_del_feature_reply"
2286 }
2287 func (*Nat44InterfaceAddDelFeatureReply) GetCrcString() string { return "e8d4e804" }
2288 func (*Nat44InterfaceAddDelFeatureReply) GetMessageType() api.MessageType {
2289         return api.ReplyMessage
2290 }
2291
2292 func (m *Nat44InterfaceAddDelFeatureReply) Size() (size int) {
2293         if m == nil {
2294                 return 0
2295         }
2296         size += 4 // m.Retval
2297         return size
2298 }
2299 func (m *Nat44InterfaceAddDelFeatureReply) Marshal(b []byte) ([]byte, error) {
2300         if b == nil {
2301                 b = make([]byte, m.Size())
2302         }
2303         buf := codec.NewBuffer(b)
2304         buf.EncodeInt32(m.Retval)
2305         return buf.Bytes(), nil
2306 }
2307 func (m *Nat44InterfaceAddDelFeatureReply) Unmarshal(b []byte) error {
2308         buf := codec.NewBuffer(b)
2309         m.Retval = buf.DecodeInt32()
2310         return nil
2311 }
2312
2313 // Nat44InterfaceAddDelOutputFeature defines message 'nat44_interface_add_del_output_feature'.
2314 type Nat44InterfaceAddDelOutputFeature struct {
2315         IsAdd     bool           `binapi:"bool,name=is_add" json:"is_add,omitempty"`
2316         Flags     NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
2317         SwIfIndex InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
2318 }
2319
2320 func (m *Nat44InterfaceAddDelOutputFeature) Reset() { *m = Nat44InterfaceAddDelOutputFeature{} }
2321 func (*Nat44InterfaceAddDelOutputFeature) GetMessageName() string {
2322         return "nat44_interface_add_del_output_feature"
2323 }
2324 func (*Nat44InterfaceAddDelOutputFeature) GetCrcString() string { return "f3699b83" }
2325 func (*Nat44InterfaceAddDelOutputFeature) GetMessageType() api.MessageType {
2326         return api.RequestMessage
2327 }
2328
2329 func (m *Nat44InterfaceAddDelOutputFeature) Size() (size int) {
2330         if m == nil {
2331                 return 0
2332         }
2333         size += 1 // m.IsAdd
2334         size += 1 // m.Flags
2335         size += 4 // m.SwIfIndex
2336         return size
2337 }
2338 func (m *Nat44InterfaceAddDelOutputFeature) Marshal(b []byte) ([]byte, error) {
2339         if b == nil {
2340                 b = make([]byte, m.Size())
2341         }
2342         buf := codec.NewBuffer(b)
2343         buf.EncodeBool(m.IsAdd)
2344         buf.EncodeUint8(uint8(m.Flags))
2345         buf.EncodeUint32(uint32(m.SwIfIndex))
2346         return buf.Bytes(), nil
2347 }
2348 func (m *Nat44InterfaceAddDelOutputFeature) Unmarshal(b []byte) error {
2349         buf := codec.NewBuffer(b)
2350         m.IsAdd = buf.DecodeBool()
2351         m.Flags = NatConfigFlags(buf.DecodeUint8())
2352         m.SwIfIndex = InterfaceIndex(buf.DecodeUint32())
2353         return nil
2354 }
2355
2356 // Nat44InterfaceAddDelOutputFeatureReply defines message 'nat44_interface_add_del_output_feature_reply'.
2357 type Nat44InterfaceAddDelOutputFeatureReply struct {
2358         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
2359 }
2360
2361 func (m *Nat44InterfaceAddDelOutputFeatureReply) Reset() {
2362         *m = Nat44InterfaceAddDelOutputFeatureReply{}
2363 }
2364 func (*Nat44InterfaceAddDelOutputFeatureReply) GetMessageName() string {
2365         return "nat44_interface_add_del_output_feature_reply"
2366 }
2367 func (*Nat44InterfaceAddDelOutputFeatureReply) GetCrcString() string { return "e8d4e804" }
2368 func (*Nat44InterfaceAddDelOutputFeatureReply) GetMessageType() api.MessageType {
2369         return api.ReplyMessage
2370 }
2371
2372 func (m *Nat44InterfaceAddDelOutputFeatureReply) Size() (size int) {
2373         if m == nil {
2374                 return 0
2375         }
2376         size += 4 // m.Retval
2377         return size
2378 }
2379 func (m *Nat44InterfaceAddDelOutputFeatureReply) Marshal(b []byte) ([]byte, error) {
2380         if b == nil {
2381                 b = make([]byte, m.Size())
2382         }
2383         buf := codec.NewBuffer(b)
2384         buf.EncodeInt32(m.Retval)
2385         return buf.Bytes(), nil
2386 }
2387 func (m *Nat44InterfaceAddDelOutputFeatureReply) Unmarshal(b []byte) error {
2388         buf := codec.NewBuffer(b)
2389         m.Retval = buf.DecodeInt32()
2390         return nil
2391 }
2392
2393 // Nat44InterfaceAddrDetails defines message 'nat44_interface_addr_details'.
2394 type Nat44InterfaceAddrDetails struct {
2395         SwIfIndex InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
2396         Flags     NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
2397 }
2398
2399 func (m *Nat44InterfaceAddrDetails) Reset()               { *m = Nat44InterfaceAddrDetails{} }
2400 func (*Nat44InterfaceAddrDetails) GetMessageName() string { return "nat44_interface_addr_details" }
2401 func (*Nat44InterfaceAddrDetails) GetCrcString() string   { return "3e687514" }
2402 func (*Nat44InterfaceAddrDetails) GetMessageType() api.MessageType {
2403         return api.ReplyMessage
2404 }
2405
2406 func (m *Nat44InterfaceAddrDetails) Size() (size int) {
2407         if m == nil {
2408                 return 0
2409         }
2410         size += 4 // m.SwIfIndex
2411         size += 1 // m.Flags
2412         return size
2413 }
2414 func (m *Nat44InterfaceAddrDetails) Marshal(b []byte) ([]byte, error) {
2415         if b == nil {
2416                 b = make([]byte, m.Size())
2417         }
2418         buf := codec.NewBuffer(b)
2419         buf.EncodeUint32(uint32(m.SwIfIndex))
2420         buf.EncodeUint8(uint8(m.Flags))
2421         return buf.Bytes(), nil
2422 }
2423 func (m *Nat44InterfaceAddrDetails) Unmarshal(b []byte) error {
2424         buf := codec.NewBuffer(b)
2425         m.SwIfIndex = InterfaceIndex(buf.DecodeUint32())
2426         m.Flags = NatConfigFlags(buf.DecodeUint8())
2427         return nil
2428 }
2429
2430 // Nat44InterfaceAddrDump defines message 'nat44_interface_addr_dump'.
2431 type Nat44InterfaceAddrDump struct{}
2432
2433 func (m *Nat44InterfaceAddrDump) Reset()               { *m = Nat44InterfaceAddrDump{} }
2434 func (*Nat44InterfaceAddrDump) GetMessageName() string { return "nat44_interface_addr_dump" }
2435 func (*Nat44InterfaceAddrDump) GetCrcString() string   { return "51077d14" }
2436 func (*Nat44InterfaceAddrDump) GetMessageType() api.MessageType {
2437         return api.RequestMessage
2438 }
2439
2440 func (m *Nat44InterfaceAddrDump) Size() (size int) {
2441         if m == nil {
2442                 return 0
2443         }
2444         return size
2445 }
2446 func (m *Nat44InterfaceAddrDump) Marshal(b []byte) ([]byte, error) {
2447         if b == nil {
2448                 b = make([]byte, m.Size())
2449         }
2450         buf := codec.NewBuffer(b)
2451         return buf.Bytes(), nil
2452 }
2453 func (m *Nat44InterfaceAddrDump) Unmarshal(b []byte) error {
2454         return nil
2455 }
2456
2457 // Nat44InterfaceDetails defines message 'nat44_interface_details'.
2458 type Nat44InterfaceDetails struct {
2459         Flags     NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
2460         SwIfIndex InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
2461 }
2462
2463 func (m *Nat44InterfaceDetails) Reset()               { *m = Nat44InterfaceDetails{} }
2464 func (*Nat44InterfaceDetails) GetMessageName() string { return "nat44_interface_details" }
2465 func (*Nat44InterfaceDetails) GetCrcString() string   { return "5d286289" }
2466 func (*Nat44InterfaceDetails) GetMessageType() api.MessageType {
2467         return api.ReplyMessage
2468 }
2469
2470 func (m *Nat44InterfaceDetails) Size() (size int) {
2471         if m == nil {
2472                 return 0
2473         }
2474         size += 1 // m.Flags
2475         size += 4 // m.SwIfIndex
2476         return size
2477 }
2478 func (m *Nat44InterfaceDetails) Marshal(b []byte) ([]byte, error) {
2479         if b == nil {
2480                 b = make([]byte, m.Size())
2481         }
2482         buf := codec.NewBuffer(b)
2483         buf.EncodeUint8(uint8(m.Flags))
2484         buf.EncodeUint32(uint32(m.SwIfIndex))
2485         return buf.Bytes(), nil
2486 }
2487 func (m *Nat44InterfaceDetails) Unmarshal(b []byte) error {
2488         buf := codec.NewBuffer(b)
2489         m.Flags = NatConfigFlags(buf.DecodeUint8())
2490         m.SwIfIndex = InterfaceIndex(buf.DecodeUint32())
2491         return nil
2492 }
2493
2494 // Nat44InterfaceDump defines message 'nat44_interface_dump'.
2495 type Nat44InterfaceDump struct{}
2496
2497 func (m *Nat44InterfaceDump) Reset()               { *m = Nat44InterfaceDump{} }
2498 func (*Nat44InterfaceDump) GetMessageName() string { return "nat44_interface_dump" }
2499 func (*Nat44InterfaceDump) GetCrcString() string   { return "51077d14" }
2500 func (*Nat44InterfaceDump) GetMessageType() api.MessageType {
2501         return api.RequestMessage
2502 }
2503
2504 func (m *Nat44InterfaceDump) Size() (size int) {
2505         if m == nil {
2506                 return 0
2507         }
2508         return size
2509 }
2510 func (m *Nat44InterfaceDump) Marshal(b []byte) ([]byte, error) {
2511         if b == nil {
2512                 b = make([]byte, m.Size())
2513         }
2514         buf := codec.NewBuffer(b)
2515         return buf.Bytes(), nil
2516 }
2517 func (m *Nat44InterfaceDump) Unmarshal(b []byte) error {
2518         return nil
2519 }
2520
2521 // Nat44InterfaceOutputFeatureDetails defines message 'nat44_interface_output_feature_details'.
2522 type Nat44InterfaceOutputFeatureDetails struct {
2523         Flags     NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
2524         SwIfIndex InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
2525 }
2526
2527 func (m *Nat44InterfaceOutputFeatureDetails) Reset() { *m = Nat44InterfaceOutputFeatureDetails{} }
2528 func (*Nat44InterfaceOutputFeatureDetails) GetMessageName() string {
2529         return "nat44_interface_output_feature_details"
2530 }
2531 func (*Nat44InterfaceOutputFeatureDetails) GetCrcString() string { return "5d286289" }
2532 func (*Nat44InterfaceOutputFeatureDetails) GetMessageType() api.MessageType {
2533         return api.ReplyMessage
2534 }
2535
2536 func (m *Nat44InterfaceOutputFeatureDetails) Size() (size int) {
2537         if m == nil {
2538                 return 0
2539         }
2540         size += 1 // m.Flags
2541         size += 4 // m.SwIfIndex
2542         return size
2543 }
2544 func (m *Nat44InterfaceOutputFeatureDetails) Marshal(b []byte) ([]byte, error) {
2545         if b == nil {
2546                 b = make([]byte, m.Size())
2547         }
2548         buf := codec.NewBuffer(b)
2549         buf.EncodeUint8(uint8(m.Flags))
2550         buf.EncodeUint32(uint32(m.SwIfIndex))
2551         return buf.Bytes(), nil
2552 }
2553 func (m *Nat44InterfaceOutputFeatureDetails) Unmarshal(b []byte) error {
2554         buf := codec.NewBuffer(b)
2555         m.Flags = NatConfigFlags(buf.DecodeUint8())
2556         m.SwIfIndex = InterfaceIndex(buf.DecodeUint32())
2557         return nil
2558 }
2559
2560 // Nat44InterfaceOutputFeatureDump defines message 'nat44_interface_output_feature_dump'.
2561 type Nat44InterfaceOutputFeatureDump struct{}
2562
2563 func (m *Nat44InterfaceOutputFeatureDump) Reset() { *m = Nat44InterfaceOutputFeatureDump{} }
2564 func (*Nat44InterfaceOutputFeatureDump) GetMessageName() string {
2565         return "nat44_interface_output_feature_dump"
2566 }
2567 func (*Nat44InterfaceOutputFeatureDump) GetCrcString() string { return "51077d14" }
2568 func (*Nat44InterfaceOutputFeatureDump) GetMessageType() api.MessageType {
2569         return api.RequestMessage
2570 }
2571
2572 func (m *Nat44InterfaceOutputFeatureDump) Size() (size int) {
2573         if m == nil {
2574                 return 0
2575         }
2576         return size
2577 }
2578 func (m *Nat44InterfaceOutputFeatureDump) Marshal(b []byte) ([]byte, error) {
2579         if b == nil {
2580                 b = make([]byte, m.Size())
2581         }
2582         buf := codec.NewBuffer(b)
2583         return buf.Bytes(), nil
2584 }
2585 func (m *Nat44InterfaceOutputFeatureDump) Unmarshal(b []byte) error {
2586         return nil
2587 }
2588
2589 // Nat44LbStaticMappingAddDelLocal defines message 'nat44_lb_static_mapping_add_del_local'.
2590 type Nat44LbStaticMappingAddDelLocal struct {
2591         IsAdd        bool            `binapi:"bool,name=is_add" json:"is_add,omitempty"`
2592         ExternalAddr IP4Address      `binapi:"ip4_address,name=external_addr" json:"external_addr,omitempty"`
2593         ExternalPort uint16          `binapi:"u16,name=external_port" json:"external_port,omitempty"`
2594         Protocol     uint8           `binapi:"u8,name=protocol" json:"protocol,omitempty"`
2595         Local        Nat44LbAddrPort `binapi:"nat44_lb_addr_port,name=local" json:"local,omitempty"`
2596 }
2597
2598 func (m *Nat44LbStaticMappingAddDelLocal) Reset() { *m = Nat44LbStaticMappingAddDelLocal{} }
2599 func (*Nat44LbStaticMappingAddDelLocal) GetMessageName() string {
2600         return "nat44_lb_static_mapping_add_del_local"
2601 }
2602 func (*Nat44LbStaticMappingAddDelLocal) GetCrcString() string { return "2910a151" }
2603 func (*Nat44LbStaticMappingAddDelLocal) GetMessageType() api.MessageType {
2604         return api.RequestMessage
2605 }
2606
2607 func (m *Nat44LbStaticMappingAddDelLocal) Size() (size int) {
2608         if m == nil {
2609                 return 0
2610         }
2611         size += 1     // m.IsAdd
2612         size += 1 * 4 // m.ExternalAddr
2613         size += 2     // m.ExternalPort
2614         size += 1     // m.Protocol
2615         size += 1 * 4 // m.Local.Addr
2616         size += 2     // m.Local.Port
2617         size += 1     // m.Local.Probability
2618         size += 4     // m.Local.VrfID
2619         return size
2620 }
2621 func (m *Nat44LbStaticMappingAddDelLocal) Marshal(b []byte) ([]byte, error) {
2622         if b == nil {
2623                 b = make([]byte, m.Size())
2624         }
2625         buf := codec.NewBuffer(b)
2626         buf.EncodeBool(m.IsAdd)
2627         buf.EncodeBytes(m.ExternalAddr[:], 4)
2628         buf.EncodeUint16(m.ExternalPort)
2629         buf.EncodeUint8(m.Protocol)
2630         buf.EncodeBytes(m.Local.Addr[:], 4)
2631         buf.EncodeUint16(m.Local.Port)
2632         buf.EncodeUint8(m.Local.Probability)
2633         buf.EncodeUint32(m.Local.VrfID)
2634         return buf.Bytes(), nil
2635 }
2636 func (m *Nat44LbStaticMappingAddDelLocal) Unmarshal(b []byte) error {
2637         buf := codec.NewBuffer(b)
2638         m.IsAdd = buf.DecodeBool()
2639         copy(m.ExternalAddr[:], buf.DecodeBytes(4))
2640         m.ExternalPort = buf.DecodeUint16()
2641         m.Protocol = buf.DecodeUint8()
2642         copy(m.Local.Addr[:], buf.DecodeBytes(4))
2643         m.Local.Port = buf.DecodeUint16()
2644         m.Local.Probability = buf.DecodeUint8()
2645         m.Local.VrfID = buf.DecodeUint32()
2646         return nil
2647 }
2648
2649 // Nat44LbStaticMappingAddDelLocalReply defines message 'nat44_lb_static_mapping_add_del_local_reply'.
2650 type Nat44LbStaticMappingAddDelLocalReply struct {
2651         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
2652 }
2653
2654 func (m *Nat44LbStaticMappingAddDelLocalReply) Reset() { *m = Nat44LbStaticMappingAddDelLocalReply{} }
2655 func (*Nat44LbStaticMappingAddDelLocalReply) GetMessageName() string {
2656         return "nat44_lb_static_mapping_add_del_local_reply"
2657 }
2658 func (*Nat44LbStaticMappingAddDelLocalReply) GetCrcString() string { return "e8d4e804" }
2659 func (*Nat44LbStaticMappingAddDelLocalReply) GetMessageType() api.MessageType {
2660         return api.ReplyMessage
2661 }
2662
2663 func (m *Nat44LbStaticMappingAddDelLocalReply) Size() (size int) {
2664         if m == nil {
2665                 return 0
2666         }
2667         size += 4 // m.Retval
2668         return size
2669 }
2670 func (m *Nat44LbStaticMappingAddDelLocalReply) Marshal(b []byte) ([]byte, error) {
2671         if b == nil {
2672                 b = make([]byte, m.Size())
2673         }
2674         buf := codec.NewBuffer(b)
2675         buf.EncodeInt32(m.Retval)
2676         return buf.Bytes(), nil
2677 }
2678 func (m *Nat44LbStaticMappingAddDelLocalReply) Unmarshal(b []byte) error {
2679         buf := codec.NewBuffer(b)
2680         m.Retval = buf.DecodeInt32()
2681         return nil
2682 }
2683
2684 // Nat44LbStaticMappingDetails defines message 'nat44_lb_static_mapping_details'.
2685 type Nat44LbStaticMappingDetails struct {
2686         ExternalAddr IP4Address        `binapi:"ip4_address,name=external_addr" json:"external_addr,omitempty"`
2687         ExternalPort uint16            `binapi:"u16,name=external_port" json:"external_port,omitempty"`
2688         Protocol     uint8             `binapi:"u8,name=protocol" json:"protocol,omitempty"`
2689         Flags        NatConfigFlags    `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
2690         Affinity     uint32            `binapi:"u32,name=affinity" json:"affinity,omitempty"`
2691         Tag          string            `binapi:"string[64],name=tag" json:"tag,omitempty"`
2692         LocalNum     uint32            `binapi:"u32,name=local_num" json:"-"`
2693         Locals       []Nat44LbAddrPort `binapi:"nat44_lb_addr_port[local_num],name=locals" json:"locals,omitempty"`
2694 }
2695
2696 func (m *Nat44LbStaticMappingDetails) Reset()               { *m = Nat44LbStaticMappingDetails{} }
2697 func (*Nat44LbStaticMappingDetails) GetMessageName() string { return "nat44_lb_static_mapping_details" }
2698 func (*Nat44LbStaticMappingDetails) GetCrcString() string   { return "2267b9e8" }
2699 func (*Nat44LbStaticMappingDetails) GetMessageType() api.MessageType {
2700         return api.ReplyMessage
2701 }
2702
2703 func (m *Nat44LbStaticMappingDetails) Size() (size int) {
2704         if m == nil {
2705                 return 0
2706         }
2707         size += 1 * 4 // m.ExternalAddr
2708         size += 2     // m.ExternalPort
2709         size += 1     // m.Protocol
2710         size += 1     // m.Flags
2711         size += 4     // m.Affinity
2712         size += 64    // m.Tag
2713         size += 4     // m.LocalNum
2714         for j1 := 0; j1 < len(m.Locals); j1++ {
2715                 var s1 Nat44LbAddrPort
2716                 _ = s1
2717                 if j1 < len(m.Locals) {
2718                         s1 = m.Locals[j1]
2719                 }
2720                 size += 1 * 4 // s1.Addr
2721                 size += 2     // s1.Port
2722                 size += 1     // s1.Probability
2723                 size += 4     // s1.VrfID
2724         }
2725         return size
2726 }
2727 func (m *Nat44LbStaticMappingDetails) Marshal(b []byte) ([]byte, error) {
2728         if b == nil {
2729                 b = make([]byte, m.Size())
2730         }
2731         buf := codec.NewBuffer(b)
2732         buf.EncodeBytes(m.ExternalAddr[:], 4)
2733         buf.EncodeUint16(m.ExternalPort)
2734         buf.EncodeUint8(m.Protocol)
2735         buf.EncodeUint8(uint8(m.Flags))
2736         buf.EncodeUint32(m.Affinity)
2737         buf.EncodeString(m.Tag, 64)
2738         buf.EncodeUint32(uint32(len(m.Locals)))
2739         for j0 := 0; j0 < len(m.Locals); j0++ {
2740                 var v0 Nat44LbAddrPort // Locals
2741                 if j0 < len(m.Locals) {
2742                         v0 = m.Locals[j0]
2743                 }
2744                 buf.EncodeBytes(v0.Addr[:], 4)
2745                 buf.EncodeUint16(v0.Port)
2746                 buf.EncodeUint8(v0.Probability)
2747                 buf.EncodeUint32(v0.VrfID)
2748         }
2749         return buf.Bytes(), nil
2750 }
2751 func (m *Nat44LbStaticMappingDetails) Unmarshal(b []byte) error {
2752         buf := codec.NewBuffer(b)
2753         copy(m.ExternalAddr[:], buf.DecodeBytes(4))
2754         m.ExternalPort = buf.DecodeUint16()
2755         m.Protocol = buf.DecodeUint8()
2756         m.Flags = NatConfigFlags(buf.DecodeUint8())
2757         m.Affinity = buf.DecodeUint32()
2758         m.Tag = buf.DecodeString(64)
2759         m.LocalNum = buf.DecodeUint32()
2760         m.Locals = make([]Nat44LbAddrPort, m.LocalNum)
2761         for j0 := 0; j0 < len(m.Locals); j0++ {
2762                 copy(m.Locals[j0].Addr[:], buf.DecodeBytes(4))
2763                 m.Locals[j0].Port = buf.DecodeUint16()
2764                 m.Locals[j0].Probability = buf.DecodeUint8()
2765                 m.Locals[j0].VrfID = buf.DecodeUint32()
2766         }
2767         return nil
2768 }
2769
2770 // Nat44LbStaticMappingDump defines message 'nat44_lb_static_mapping_dump'.
2771 type Nat44LbStaticMappingDump struct{}
2772
2773 func (m *Nat44LbStaticMappingDump) Reset()               { *m = Nat44LbStaticMappingDump{} }
2774 func (*Nat44LbStaticMappingDump) GetMessageName() string { return "nat44_lb_static_mapping_dump" }
2775 func (*Nat44LbStaticMappingDump) GetCrcString() string   { return "51077d14" }
2776 func (*Nat44LbStaticMappingDump) GetMessageType() api.MessageType {
2777         return api.RequestMessage
2778 }
2779
2780 func (m *Nat44LbStaticMappingDump) Size() (size int) {
2781         if m == nil {
2782                 return 0
2783         }
2784         return size
2785 }
2786 func (m *Nat44LbStaticMappingDump) Marshal(b []byte) ([]byte, error) {
2787         if b == nil {
2788                 b = make([]byte, m.Size())
2789         }
2790         buf := codec.NewBuffer(b)
2791         return buf.Bytes(), nil
2792 }
2793 func (m *Nat44LbStaticMappingDump) Unmarshal(b []byte) error {
2794         return nil
2795 }
2796
2797 // Nat44StaticMappingDetails defines message 'nat44_static_mapping_details'.
2798 type Nat44StaticMappingDetails struct {
2799         Flags             NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
2800         LocalIPAddress    IP4Address     `binapi:"ip4_address,name=local_ip_address" json:"local_ip_address,omitempty"`
2801         ExternalIPAddress IP4Address     `binapi:"ip4_address,name=external_ip_address" json:"external_ip_address,omitempty"`
2802         Protocol          uint8          `binapi:"u8,name=protocol" json:"protocol,omitempty"`
2803         LocalPort         uint16         `binapi:"u16,name=local_port" json:"local_port,omitempty"`
2804         ExternalPort      uint16         `binapi:"u16,name=external_port" json:"external_port,omitempty"`
2805         ExternalSwIfIndex InterfaceIndex `binapi:"interface_index,name=external_sw_if_index" json:"external_sw_if_index,omitempty"`
2806         VrfID             uint32         `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
2807         Tag               string         `binapi:"string[64],name=tag" json:"tag,omitempty"`
2808 }
2809
2810 func (m *Nat44StaticMappingDetails) Reset()               { *m = Nat44StaticMappingDetails{} }
2811 func (*Nat44StaticMappingDetails) GetMessageName() string { return "nat44_static_mapping_details" }
2812 func (*Nat44StaticMappingDetails) GetCrcString() string   { return "1a433ef7" }
2813 func (*Nat44StaticMappingDetails) GetMessageType() api.MessageType {
2814         return api.ReplyMessage
2815 }
2816
2817 func (m *Nat44StaticMappingDetails) Size() (size int) {
2818         if m == nil {
2819                 return 0
2820         }
2821         size += 1     // m.Flags
2822         size += 1 * 4 // m.LocalIPAddress
2823         size += 1 * 4 // m.ExternalIPAddress
2824         size += 1     // m.Protocol
2825         size += 2     // m.LocalPort
2826         size += 2     // m.ExternalPort
2827         size += 4     // m.ExternalSwIfIndex
2828         size += 4     // m.VrfID
2829         size += 64    // m.Tag
2830         return size
2831 }
2832 func (m *Nat44StaticMappingDetails) Marshal(b []byte) ([]byte, error) {
2833         if b == nil {
2834                 b = make([]byte, m.Size())
2835         }
2836         buf := codec.NewBuffer(b)
2837         buf.EncodeUint8(uint8(m.Flags))
2838         buf.EncodeBytes(m.LocalIPAddress[:], 4)
2839         buf.EncodeBytes(m.ExternalIPAddress[:], 4)
2840         buf.EncodeUint8(m.Protocol)
2841         buf.EncodeUint16(m.LocalPort)
2842         buf.EncodeUint16(m.ExternalPort)
2843         buf.EncodeUint32(uint32(m.ExternalSwIfIndex))
2844         buf.EncodeUint32(m.VrfID)
2845         buf.EncodeString(m.Tag, 64)
2846         return buf.Bytes(), nil
2847 }
2848 func (m *Nat44StaticMappingDetails) Unmarshal(b []byte) error {
2849         buf := codec.NewBuffer(b)
2850         m.Flags = NatConfigFlags(buf.DecodeUint8())
2851         copy(m.LocalIPAddress[:], buf.DecodeBytes(4))
2852         copy(m.ExternalIPAddress[:], buf.DecodeBytes(4))
2853         m.Protocol = buf.DecodeUint8()
2854         m.LocalPort = buf.DecodeUint16()
2855         m.ExternalPort = buf.DecodeUint16()
2856         m.ExternalSwIfIndex = InterfaceIndex(buf.DecodeUint32())
2857         m.VrfID = buf.DecodeUint32()
2858         m.Tag = buf.DecodeString(64)
2859         return nil
2860 }
2861
2862 // Nat44StaticMappingDump defines message 'nat44_static_mapping_dump'.
2863 type Nat44StaticMappingDump struct{}
2864
2865 func (m *Nat44StaticMappingDump) Reset()               { *m = Nat44StaticMappingDump{} }
2866 func (*Nat44StaticMappingDump) GetMessageName() string { return "nat44_static_mapping_dump" }
2867 func (*Nat44StaticMappingDump) GetCrcString() string   { return "51077d14" }
2868 func (*Nat44StaticMappingDump) GetMessageType() api.MessageType {
2869         return api.RequestMessage
2870 }
2871
2872 func (m *Nat44StaticMappingDump) Size() (size int) {
2873         if m == nil {
2874                 return 0
2875         }
2876         return size
2877 }
2878 func (m *Nat44StaticMappingDump) Marshal(b []byte) ([]byte, error) {
2879         if b == nil {
2880                 b = make([]byte, m.Size())
2881         }
2882         buf := codec.NewBuffer(b)
2883         return buf.Bytes(), nil
2884 }
2885 func (m *Nat44StaticMappingDump) Unmarshal(b []byte) error {
2886         return nil
2887 }
2888
2889 // Nat44UserDetails defines message 'nat44_user_details'.
2890 type Nat44UserDetails struct {
2891         VrfID           uint32     `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
2892         IPAddress       IP4Address `binapi:"ip4_address,name=ip_address" json:"ip_address,omitempty"`
2893         Nsessions       uint32     `binapi:"u32,name=nsessions" json:"nsessions,omitempty"`
2894         Nstaticsessions uint32     `binapi:"u32,name=nstaticsessions" json:"nstaticsessions,omitempty"`
2895 }
2896
2897 func (m *Nat44UserDetails) Reset()               { *m = Nat44UserDetails{} }
2898 func (*Nat44UserDetails) GetMessageName() string { return "nat44_user_details" }
2899 func (*Nat44UserDetails) GetCrcString() string   { return "355896c2" }
2900 func (*Nat44UserDetails) GetMessageType() api.MessageType {
2901         return api.ReplyMessage
2902 }
2903
2904 func (m *Nat44UserDetails) Size() (size int) {
2905         if m == nil {
2906                 return 0
2907         }
2908         size += 4     // m.VrfID
2909         size += 1 * 4 // m.IPAddress
2910         size += 4     // m.Nsessions
2911         size += 4     // m.Nstaticsessions
2912         return size
2913 }
2914 func (m *Nat44UserDetails) Marshal(b []byte) ([]byte, error) {
2915         if b == nil {
2916                 b = make([]byte, m.Size())
2917         }
2918         buf := codec.NewBuffer(b)
2919         buf.EncodeUint32(m.VrfID)
2920         buf.EncodeBytes(m.IPAddress[:], 4)
2921         buf.EncodeUint32(m.Nsessions)
2922         buf.EncodeUint32(m.Nstaticsessions)
2923         return buf.Bytes(), nil
2924 }
2925 func (m *Nat44UserDetails) Unmarshal(b []byte) error {
2926         buf := codec.NewBuffer(b)
2927         m.VrfID = buf.DecodeUint32()
2928         copy(m.IPAddress[:], buf.DecodeBytes(4))
2929         m.Nsessions = buf.DecodeUint32()
2930         m.Nstaticsessions = buf.DecodeUint32()
2931         return nil
2932 }
2933
2934 // Nat44UserDump defines message 'nat44_user_dump'.
2935 type Nat44UserDump struct{}
2936
2937 func (m *Nat44UserDump) Reset()               { *m = Nat44UserDump{} }
2938 func (*Nat44UserDump) GetMessageName() string { return "nat44_user_dump" }
2939 func (*Nat44UserDump) GetCrcString() string   { return "51077d14" }
2940 func (*Nat44UserDump) GetMessageType() api.MessageType {
2941         return api.RequestMessage
2942 }
2943
2944 func (m *Nat44UserDump) Size() (size int) {
2945         if m == nil {
2946                 return 0
2947         }
2948         return size
2949 }
2950 func (m *Nat44UserDump) Marshal(b []byte) ([]byte, error) {
2951         if b == nil {
2952                 b = make([]byte, m.Size())
2953         }
2954         buf := codec.NewBuffer(b)
2955         return buf.Bytes(), nil
2956 }
2957 func (m *Nat44UserDump) Unmarshal(b []byte) error {
2958         return nil
2959 }
2960
2961 // Nat44UserSessionDetails defines message 'nat44_user_session_details'.
2962 type Nat44UserSessionDetails struct {
2963         OutsideIPAddress  IP4Address     `binapi:"ip4_address,name=outside_ip_address" json:"outside_ip_address,omitempty"`
2964         OutsidePort       uint16         `binapi:"u16,name=outside_port" json:"outside_port,omitempty"`
2965         InsideIPAddress   IP4Address     `binapi:"ip4_address,name=inside_ip_address" json:"inside_ip_address,omitempty"`
2966         InsidePort        uint16         `binapi:"u16,name=inside_port" json:"inside_port,omitempty"`
2967         Protocol          uint16         `binapi:"u16,name=protocol" json:"protocol,omitempty"`
2968         Flags             NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
2969         LastHeard         uint64         `binapi:"u64,name=last_heard" json:"last_heard,omitempty"`
2970         TotalBytes        uint64         `binapi:"u64,name=total_bytes" json:"total_bytes,omitempty"`
2971         TotalPkts         uint32         `binapi:"u32,name=total_pkts" json:"total_pkts,omitempty"`
2972         ExtHostAddress    IP4Address     `binapi:"ip4_address,name=ext_host_address" json:"ext_host_address,omitempty"`
2973         ExtHostPort       uint16         `binapi:"u16,name=ext_host_port" json:"ext_host_port,omitempty"`
2974         ExtHostNatAddress IP4Address     `binapi:"ip4_address,name=ext_host_nat_address" json:"ext_host_nat_address,omitempty"`
2975         ExtHostNatPort    uint16         `binapi:"u16,name=ext_host_nat_port" json:"ext_host_nat_port,omitempty"`
2976 }
2977
2978 func (m *Nat44UserSessionDetails) Reset()               { *m = Nat44UserSessionDetails{} }
2979 func (*Nat44UserSessionDetails) GetMessageName() string { return "nat44_user_session_details" }
2980 func (*Nat44UserSessionDetails) GetCrcString() string   { return "1965fd69" }
2981 func (*Nat44UserSessionDetails) GetMessageType() api.MessageType {
2982         return api.ReplyMessage
2983 }
2984
2985 func (m *Nat44UserSessionDetails) Size() (size int) {
2986         if m == nil {
2987                 return 0
2988         }
2989         size += 1 * 4 // m.OutsideIPAddress
2990         size += 2     // m.OutsidePort
2991         size += 1 * 4 // m.InsideIPAddress
2992         size += 2     // m.InsidePort
2993         size += 2     // m.Protocol
2994         size += 1     // m.Flags
2995         size += 8     // m.LastHeard
2996         size += 8     // m.TotalBytes
2997         size += 4     // m.TotalPkts
2998         size += 1 * 4 // m.ExtHostAddress
2999         size += 2     // m.ExtHostPort
3000         size += 1 * 4 // m.ExtHostNatAddress
3001         size += 2     // m.ExtHostNatPort
3002         return size
3003 }
3004 func (m *Nat44UserSessionDetails) Marshal(b []byte) ([]byte, error) {
3005         if b == nil {
3006                 b = make([]byte, m.Size())
3007         }
3008         buf := codec.NewBuffer(b)
3009         buf.EncodeBytes(m.OutsideIPAddress[:], 4)
3010         buf.EncodeUint16(m.OutsidePort)
3011         buf.EncodeBytes(m.InsideIPAddress[:], 4)
3012         buf.EncodeUint16(m.InsidePort)
3013         buf.EncodeUint16(m.Protocol)
3014         buf.EncodeUint8(uint8(m.Flags))
3015         buf.EncodeUint64(m.LastHeard)
3016         buf.EncodeUint64(m.TotalBytes)
3017         buf.EncodeUint32(m.TotalPkts)
3018         buf.EncodeBytes(m.ExtHostAddress[:], 4)
3019         buf.EncodeUint16(m.ExtHostPort)
3020         buf.EncodeBytes(m.ExtHostNatAddress[:], 4)
3021         buf.EncodeUint16(m.ExtHostNatPort)
3022         return buf.Bytes(), nil
3023 }
3024 func (m *Nat44UserSessionDetails) Unmarshal(b []byte) error {
3025         buf := codec.NewBuffer(b)
3026         copy(m.OutsideIPAddress[:], buf.DecodeBytes(4))
3027         m.OutsidePort = buf.DecodeUint16()
3028         copy(m.InsideIPAddress[:], buf.DecodeBytes(4))
3029         m.InsidePort = buf.DecodeUint16()
3030         m.Protocol = buf.DecodeUint16()
3031         m.Flags = NatConfigFlags(buf.DecodeUint8())
3032         m.LastHeard = buf.DecodeUint64()
3033         m.TotalBytes = buf.DecodeUint64()
3034         m.TotalPkts = buf.DecodeUint32()
3035         copy(m.ExtHostAddress[:], buf.DecodeBytes(4))
3036         m.ExtHostPort = buf.DecodeUint16()
3037         copy(m.ExtHostNatAddress[:], buf.DecodeBytes(4))
3038         m.ExtHostNatPort = buf.DecodeUint16()
3039         return nil
3040 }
3041
3042 // Nat44UserSessionDump defines message 'nat44_user_session_dump'.
3043 type Nat44UserSessionDump struct {
3044         IPAddress IP4Address `binapi:"ip4_address,name=ip_address" json:"ip_address,omitempty"`
3045         VrfID     uint32     `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
3046 }
3047
3048 func (m *Nat44UserSessionDump) Reset()               { *m = Nat44UserSessionDump{} }
3049 func (*Nat44UserSessionDump) GetMessageName() string { return "nat44_user_session_dump" }
3050 func (*Nat44UserSessionDump) GetCrcString() string   { return "e1899c98" }
3051 func (*Nat44UserSessionDump) GetMessageType() api.MessageType {
3052         return api.RequestMessage
3053 }
3054
3055 func (m *Nat44UserSessionDump) Size() (size int) {
3056         if m == nil {
3057                 return 0
3058         }
3059         size += 1 * 4 // m.IPAddress
3060         size += 4     // m.VrfID
3061         return size
3062 }
3063 func (m *Nat44UserSessionDump) Marshal(b []byte) ([]byte, error) {
3064         if b == nil {
3065                 b = make([]byte, m.Size())
3066         }
3067         buf := codec.NewBuffer(b)
3068         buf.EncodeBytes(m.IPAddress[:], 4)
3069         buf.EncodeUint32(m.VrfID)
3070         return buf.Bytes(), nil
3071 }
3072 func (m *Nat44UserSessionDump) Unmarshal(b []byte) error {
3073         buf := codec.NewBuffer(b)
3074         copy(m.IPAddress[:], buf.DecodeBytes(4))
3075         m.VrfID = buf.DecodeUint32()
3076         return nil
3077 }
3078
3079 // Nat64AddDelInterface defines message 'nat64_add_del_interface'.
3080 type Nat64AddDelInterface struct {
3081         IsAdd     bool           `binapi:"bool,name=is_add" json:"is_add,omitempty"`
3082         Flags     NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
3083         SwIfIndex InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
3084 }
3085
3086 func (m *Nat64AddDelInterface) Reset()               { *m = Nat64AddDelInterface{} }
3087 func (*Nat64AddDelInterface) GetMessageName() string { return "nat64_add_del_interface" }
3088 func (*Nat64AddDelInterface) GetCrcString() string   { return "f3699b83" }
3089 func (*Nat64AddDelInterface) GetMessageType() api.MessageType {
3090         return api.RequestMessage
3091 }
3092
3093 func (m *Nat64AddDelInterface) Size() (size int) {
3094         if m == nil {
3095                 return 0
3096         }
3097         size += 1 // m.IsAdd
3098         size += 1 // m.Flags
3099         size += 4 // m.SwIfIndex
3100         return size
3101 }
3102 func (m *Nat64AddDelInterface) Marshal(b []byte) ([]byte, error) {
3103         if b == nil {
3104                 b = make([]byte, m.Size())
3105         }
3106         buf := codec.NewBuffer(b)
3107         buf.EncodeBool(m.IsAdd)
3108         buf.EncodeUint8(uint8(m.Flags))
3109         buf.EncodeUint32(uint32(m.SwIfIndex))
3110         return buf.Bytes(), nil
3111 }
3112 func (m *Nat64AddDelInterface) Unmarshal(b []byte) error {
3113         buf := codec.NewBuffer(b)
3114         m.IsAdd = buf.DecodeBool()
3115         m.Flags = NatConfigFlags(buf.DecodeUint8())
3116         m.SwIfIndex = InterfaceIndex(buf.DecodeUint32())
3117         return nil
3118 }
3119
3120 // Nat64AddDelInterfaceAddr defines message 'nat64_add_del_interface_addr'.
3121 type Nat64AddDelInterfaceAddr struct {
3122         IsAdd     bool           `binapi:"bool,name=is_add" json:"is_add,omitempty"`
3123         SwIfIndex InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
3124 }
3125
3126 func (m *Nat64AddDelInterfaceAddr) Reset()               { *m = Nat64AddDelInterfaceAddr{} }
3127 func (*Nat64AddDelInterfaceAddr) GetMessageName() string { return "nat64_add_del_interface_addr" }
3128 func (*Nat64AddDelInterfaceAddr) GetCrcString() string   { return "47d6e753" }
3129 func (*Nat64AddDelInterfaceAddr) GetMessageType() api.MessageType {
3130         return api.RequestMessage
3131 }
3132
3133 func (m *Nat64AddDelInterfaceAddr) Size() (size int) {
3134         if m == nil {
3135                 return 0
3136         }
3137         size += 1 // m.IsAdd
3138         size += 4 // m.SwIfIndex
3139         return size
3140 }
3141 func (m *Nat64AddDelInterfaceAddr) Marshal(b []byte) ([]byte, error) {
3142         if b == nil {
3143                 b = make([]byte, m.Size())
3144         }
3145         buf := codec.NewBuffer(b)
3146         buf.EncodeBool(m.IsAdd)
3147         buf.EncodeUint32(uint32(m.SwIfIndex))
3148         return buf.Bytes(), nil
3149 }
3150 func (m *Nat64AddDelInterfaceAddr) Unmarshal(b []byte) error {
3151         buf := codec.NewBuffer(b)
3152         m.IsAdd = buf.DecodeBool()
3153         m.SwIfIndex = InterfaceIndex(buf.DecodeUint32())
3154         return nil
3155 }
3156
3157 // Nat64AddDelInterfaceAddrReply defines message 'nat64_add_del_interface_addr_reply'.
3158 type Nat64AddDelInterfaceAddrReply struct {
3159         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
3160 }
3161
3162 func (m *Nat64AddDelInterfaceAddrReply) Reset() { *m = Nat64AddDelInterfaceAddrReply{} }
3163 func (*Nat64AddDelInterfaceAddrReply) GetMessageName() string {
3164         return "nat64_add_del_interface_addr_reply"
3165 }
3166 func (*Nat64AddDelInterfaceAddrReply) GetCrcString() string { return "e8d4e804" }
3167 func (*Nat64AddDelInterfaceAddrReply) GetMessageType() api.MessageType {
3168         return api.ReplyMessage
3169 }
3170
3171 func (m *Nat64AddDelInterfaceAddrReply) Size() (size int) {
3172         if m == nil {
3173                 return 0
3174         }
3175         size += 4 // m.Retval
3176         return size
3177 }
3178 func (m *Nat64AddDelInterfaceAddrReply) Marshal(b []byte) ([]byte, error) {
3179         if b == nil {
3180                 b = make([]byte, m.Size())
3181         }
3182         buf := codec.NewBuffer(b)
3183         buf.EncodeInt32(m.Retval)
3184         return buf.Bytes(), nil
3185 }
3186 func (m *Nat64AddDelInterfaceAddrReply) Unmarshal(b []byte) error {
3187         buf := codec.NewBuffer(b)
3188         m.Retval = buf.DecodeInt32()
3189         return nil
3190 }
3191
3192 // Nat64AddDelInterfaceReply defines message 'nat64_add_del_interface_reply'.
3193 type Nat64AddDelInterfaceReply struct {
3194         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
3195 }
3196
3197 func (m *Nat64AddDelInterfaceReply) Reset()               { *m = Nat64AddDelInterfaceReply{} }
3198 func (*Nat64AddDelInterfaceReply) GetMessageName() string { return "nat64_add_del_interface_reply" }
3199 func (*Nat64AddDelInterfaceReply) GetCrcString() string   { return "e8d4e804" }
3200 func (*Nat64AddDelInterfaceReply) GetMessageType() api.MessageType {
3201         return api.ReplyMessage
3202 }
3203
3204 func (m *Nat64AddDelInterfaceReply) Size() (size int) {
3205         if m == nil {
3206                 return 0
3207         }
3208         size += 4 // m.Retval
3209         return size
3210 }
3211 func (m *Nat64AddDelInterfaceReply) Marshal(b []byte) ([]byte, error) {
3212         if b == nil {
3213                 b = make([]byte, m.Size())
3214         }
3215         buf := codec.NewBuffer(b)
3216         buf.EncodeInt32(m.Retval)
3217         return buf.Bytes(), nil
3218 }
3219 func (m *Nat64AddDelInterfaceReply) Unmarshal(b []byte) error {
3220         buf := codec.NewBuffer(b)
3221         m.Retval = buf.DecodeInt32()
3222         return nil
3223 }
3224
3225 // Nat64AddDelPoolAddrRange defines message 'nat64_add_del_pool_addr_range'.
3226 type Nat64AddDelPoolAddrRange struct {
3227         StartAddr IP4Address `binapi:"ip4_address,name=start_addr" json:"start_addr,omitempty"`
3228         EndAddr   IP4Address `binapi:"ip4_address,name=end_addr" json:"end_addr,omitempty"`
3229         VrfID     uint32     `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
3230         IsAdd     bool       `binapi:"bool,name=is_add" json:"is_add,omitempty"`
3231 }
3232
3233 func (m *Nat64AddDelPoolAddrRange) Reset()               { *m = Nat64AddDelPoolAddrRange{} }
3234 func (*Nat64AddDelPoolAddrRange) GetMessageName() string { return "nat64_add_del_pool_addr_range" }
3235 func (*Nat64AddDelPoolAddrRange) GetCrcString() string   { return "21234ef3" }
3236 func (*Nat64AddDelPoolAddrRange) GetMessageType() api.MessageType {
3237         return api.RequestMessage
3238 }
3239
3240 func (m *Nat64AddDelPoolAddrRange) Size() (size int) {
3241         if m == nil {
3242                 return 0
3243         }
3244         size += 1 * 4 // m.StartAddr
3245         size += 1 * 4 // m.EndAddr
3246         size += 4     // m.VrfID
3247         size += 1     // m.IsAdd
3248         return size
3249 }
3250 func (m *Nat64AddDelPoolAddrRange) Marshal(b []byte) ([]byte, error) {
3251         if b == nil {
3252                 b = make([]byte, m.Size())
3253         }
3254         buf := codec.NewBuffer(b)
3255         buf.EncodeBytes(m.StartAddr[:], 4)
3256         buf.EncodeBytes(m.EndAddr[:], 4)
3257         buf.EncodeUint32(m.VrfID)
3258         buf.EncodeBool(m.IsAdd)
3259         return buf.Bytes(), nil
3260 }
3261 func (m *Nat64AddDelPoolAddrRange) Unmarshal(b []byte) error {
3262         buf := codec.NewBuffer(b)
3263         copy(m.StartAddr[:], buf.DecodeBytes(4))
3264         copy(m.EndAddr[:], buf.DecodeBytes(4))
3265         m.VrfID = buf.DecodeUint32()
3266         m.IsAdd = buf.DecodeBool()
3267         return nil
3268 }
3269
3270 // Nat64AddDelPoolAddrRangeReply defines message 'nat64_add_del_pool_addr_range_reply'.
3271 type Nat64AddDelPoolAddrRangeReply struct {
3272         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
3273 }
3274
3275 func (m *Nat64AddDelPoolAddrRangeReply) Reset() { *m = Nat64AddDelPoolAddrRangeReply{} }
3276 func (*Nat64AddDelPoolAddrRangeReply) GetMessageName() string {
3277         return "nat64_add_del_pool_addr_range_reply"
3278 }
3279 func (*Nat64AddDelPoolAddrRangeReply) GetCrcString() string { return "e8d4e804" }
3280 func (*Nat64AddDelPoolAddrRangeReply) GetMessageType() api.MessageType {
3281         return api.ReplyMessage
3282 }
3283
3284 func (m *Nat64AddDelPoolAddrRangeReply) Size() (size int) {
3285         if m == nil {
3286                 return 0
3287         }
3288         size += 4 // m.Retval
3289         return size
3290 }
3291 func (m *Nat64AddDelPoolAddrRangeReply) Marshal(b []byte) ([]byte, error) {
3292         if b == nil {
3293                 b = make([]byte, m.Size())
3294         }
3295         buf := codec.NewBuffer(b)
3296         buf.EncodeInt32(m.Retval)
3297         return buf.Bytes(), nil
3298 }
3299 func (m *Nat64AddDelPoolAddrRangeReply) Unmarshal(b []byte) error {
3300         buf := codec.NewBuffer(b)
3301         m.Retval = buf.DecodeInt32()
3302         return nil
3303 }
3304
3305 // Nat64AddDelPrefix defines message 'nat64_add_del_prefix'.
3306 type Nat64AddDelPrefix struct {
3307         Prefix IP6Prefix `binapi:"ip6_prefix,name=prefix" json:"prefix,omitempty"`
3308         VrfID  uint32    `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
3309         IsAdd  bool      `binapi:"bool,name=is_add" json:"is_add,omitempty"`
3310 }
3311
3312 func (m *Nat64AddDelPrefix) Reset()               { *m = Nat64AddDelPrefix{} }
3313 func (*Nat64AddDelPrefix) GetMessageName() string { return "nat64_add_del_prefix" }
3314 func (*Nat64AddDelPrefix) GetCrcString() string   { return "727b2f4c" }
3315 func (*Nat64AddDelPrefix) GetMessageType() api.MessageType {
3316         return api.RequestMessage
3317 }
3318
3319 func (m *Nat64AddDelPrefix) Size() (size int) {
3320         if m == nil {
3321                 return 0
3322         }
3323         size += 1 * 16 // m.Prefix.Address
3324         size += 1      // m.Prefix.Len
3325         size += 4      // m.VrfID
3326         size += 1      // m.IsAdd
3327         return size
3328 }
3329 func (m *Nat64AddDelPrefix) Marshal(b []byte) ([]byte, error) {
3330         if b == nil {
3331                 b = make([]byte, m.Size())
3332         }
3333         buf := codec.NewBuffer(b)
3334         buf.EncodeBytes(m.Prefix.Address[:], 16)
3335         buf.EncodeUint8(m.Prefix.Len)
3336         buf.EncodeUint32(m.VrfID)
3337         buf.EncodeBool(m.IsAdd)
3338         return buf.Bytes(), nil
3339 }
3340 func (m *Nat64AddDelPrefix) Unmarshal(b []byte) error {
3341         buf := codec.NewBuffer(b)
3342         copy(m.Prefix.Address[:], buf.DecodeBytes(16))
3343         m.Prefix.Len = buf.DecodeUint8()
3344         m.VrfID = buf.DecodeUint32()
3345         m.IsAdd = buf.DecodeBool()
3346         return nil
3347 }
3348
3349 // Nat64AddDelPrefixReply defines message 'nat64_add_del_prefix_reply'.
3350 type Nat64AddDelPrefixReply struct {
3351         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
3352 }
3353
3354 func (m *Nat64AddDelPrefixReply) Reset()               { *m = Nat64AddDelPrefixReply{} }
3355 func (*Nat64AddDelPrefixReply) GetMessageName() string { return "nat64_add_del_prefix_reply" }
3356 func (*Nat64AddDelPrefixReply) GetCrcString() string   { return "e8d4e804" }
3357 func (*Nat64AddDelPrefixReply) GetMessageType() api.MessageType {
3358         return api.ReplyMessage
3359 }
3360
3361 func (m *Nat64AddDelPrefixReply) Size() (size int) {
3362         if m == nil {
3363                 return 0
3364         }
3365         size += 4 // m.Retval
3366         return size
3367 }
3368 func (m *Nat64AddDelPrefixReply) Marshal(b []byte) ([]byte, error) {
3369         if b == nil {
3370                 b = make([]byte, m.Size())
3371         }
3372         buf := codec.NewBuffer(b)
3373         buf.EncodeInt32(m.Retval)
3374         return buf.Bytes(), nil
3375 }
3376 func (m *Nat64AddDelPrefixReply) Unmarshal(b []byte) error {
3377         buf := codec.NewBuffer(b)
3378         m.Retval = buf.DecodeInt32()
3379         return nil
3380 }
3381
3382 // Nat64AddDelStaticBib defines message 'nat64_add_del_static_bib'.
3383 type Nat64AddDelStaticBib struct {
3384         IAddr IP6Address `binapi:"ip6_address,name=i_addr" json:"i_addr,omitempty"`
3385         OAddr IP4Address `binapi:"ip4_address,name=o_addr" json:"o_addr,omitempty"`
3386         IPort uint16     `binapi:"u16,name=i_port" json:"i_port,omitempty"`
3387         OPort uint16     `binapi:"u16,name=o_port" json:"o_port,omitempty"`
3388         VrfID uint32     `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
3389         Proto uint8      `binapi:"u8,name=proto" json:"proto,omitempty"`
3390         IsAdd bool       `binapi:"bool,name=is_add" json:"is_add,omitempty"`
3391 }
3392
3393 func (m *Nat64AddDelStaticBib) Reset()               { *m = Nat64AddDelStaticBib{} }
3394 func (*Nat64AddDelStaticBib) GetMessageName() string { return "nat64_add_del_static_bib" }
3395 func (*Nat64AddDelStaticBib) GetCrcString() string   { return "90fae58a" }
3396 func (*Nat64AddDelStaticBib) GetMessageType() api.MessageType {
3397         return api.RequestMessage
3398 }
3399
3400 func (m *Nat64AddDelStaticBib) Size() (size int) {
3401         if m == nil {
3402                 return 0
3403         }
3404         size += 1 * 16 // m.IAddr
3405         size += 1 * 4  // m.OAddr
3406         size += 2      // m.IPort
3407         size += 2      // m.OPort
3408         size += 4      // m.VrfID
3409         size += 1      // m.Proto
3410         size += 1      // m.IsAdd
3411         return size
3412 }
3413 func (m *Nat64AddDelStaticBib) Marshal(b []byte) ([]byte, error) {
3414         if b == nil {
3415                 b = make([]byte, m.Size())
3416         }
3417         buf := codec.NewBuffer(b)
3418         buf.EncodeBytes(m.IAddr[:], 16)
3419         buf.EncodeBytes(m.OAddr[:], 4)
3420         buf.EncodeUint16(m.IPort)
3421         buf.EncodeUint16(m.OPort)
3422         buf.EncodeUint32(m.VrfID)
3423         buf.EncodeUint8(m.Proto)
3424         buf.EncodeBool(m.IsAdd)
3425         return buf.Bytes(), nil
3426 }
3427 func (m *Nat64AddDelStaticBib) Unmarshal(b []byte) error {
3428         buf := codec.NewBuffer(b)
3429         copy(m.IAddr[:], buf.DecodeBytes(16))
3430         copy(m.OAddr[:], buf.DecodeBytes(4))
3431         m.IPort = buf.DecodeUint16()
3432         m.OPort = buf.DecodeUint16()
3433         m.VrfID = buf.DecodeUint32()
3434         m.Proto = buf.DecodeUint8()
3435         m.IsAdd = buf.DecodeBool()
3436         return nil
3437 }
3438
3439 // Nat64AddDelStaticBibReply defines message 'nat64_add_del_static_bib_reply'.
3440 type Nat64AddDelStaticBibReply struct {
3441         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
3442 }
3443
3444 func (m *Nat64AddDelStaticBibReply) Reset()               { *m = Nat64AddDelStaticBibReply{} }
3445 func (*Nat64AddDelStaticBibReply) GetMessageName() string { return "nat64_add_del_static_bib_reply" }
3446 func (*Nat64AddDelStaticBibReply) GetCrcString() string   { return "e8d4e804" }
3447 func (*Nat64AddDelStaticBibReply) GetMessageType() api.MessageType {
3448         return api.ReplyMessage
3449 }
3450
3451 func (m *Nat64AddDelStaticBibReply) Size() (size int) {
3452         if m == nil {
3453                 return 0
3454         }
3455         size += 4 // m.Retval
3456         return size
3457 }
3458 func (m *Nat64AddDelStaticBibReply) Marshal(b []byte) ([]byte, error) {
3459         if b == nil {
3460                 b = make([]byte, m.Size())
3461         }
3462         buf := codec.NewBuffer(b)
3463         buf.EncodeInt32(m.Retval)
3464         return buf.Bytes(), nil
3465 }
3466 func (m *Nat64AddDelStaticBibReply) Unmarshal(b []byte) error {
3467         buf := codec.NewBuffer(b)
3468         m.Retval = buf.DecodeInt32()
3469         return nil
3470 }
3471
3472 // Nat64BibDetails defines message 'nat64_bib_details'.
3473 type Nat64BibDetails struct {
3474         IAddr  IP6Address     `binapi:"ip6_address,name=i_addr" json:"i_addr,omitempty"`
3475         OAddr  IP4Address     `binapi:"ip4_address,name=o_addr" json:"o_addr,omitempty"`
3476         IPort  uint16         `binapi:"u16,name=i_port" json:"i_port,omitempty"`
3477         OPort  uint16         `binapi:"u16,name=o_port" json:"o_port,omitempty"`
3478         VrfID  uint32         `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
3479         Proto  uint8          `binapi:"u8,name=proto" json:"proto,omitempty"`
3480         Flags  NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
3481         SesNum uint32         `binapi:"u32,name=ses_num" json:"ses_num,omitempty"`
3482 }
3483
3484 func (m *Nat64BibDetails) Reset()               { *m = Nat64BibDetails{} }
3485 func (*Nat64BibDetails) GetMessageName() string { return "nat64_bib_details" }
3486 func (*Nat64BibDetails) GetCrcString() string   { return "62c8541d" }
3487 func (*Nat64BibDetails) GetMessageType() api.MessageType {
3488         return api.ReplyMessage
3489 }
3490
3491 func (m *Nat64BibDetails) Size() (size int) {
3492         if m == nil {
3493                 return 0
3494         }
3495         size += 1 * 16 // m.IAddr
3496         size += 1 * 4  // m.OAddr
3497         size += 2      // m.IPort
3498         size += 2      // m.OPort
3499         size += 4      // m.VrfID
3500         size += 1      // m.Proto
3501         size += 1      // m.Flags
3502         size += 4      // m.SesNum
3503         return size
3504 }
3505 func (m *Nat64BibDetails) Marshal(b []byte) ([]byte, error) {
3506         if b == nil {
3507                 b = make([]byte, m.Size())
3508         }
3509         buf := codec.NewBuffer(b)
3510         buf.EncodeBytes(m.IAddr[:], 16)
3511         buf.EncodeBytes(m.OAddr[:], 4)
3512         buf.EncodeUint16(m.IPort)
3513         buf.EncodeUint16(m.OPort)
3514         buf.EncodeUint32(m.VrfID)
3515         buf.EncodeUint8(m.Proto)
3516         buf.EncodeUint8(uint8(m.Flags))
3517         buf.EncodeUint32(m.SesNum)
3518         return buf.Bytes(), nil
3519 }
3520 func (m *Nat64BibDetails) Unmarshal(b []byte) error {
3521         buf := codec.NewBuffer(b)
3522         copy(m.IAddr[:], buf.DecodeBytes(16))
3523         copy(m.OAddr[:], buf.DecodeBytes(4))
3524         m.IPort = buf.DecodeUint16()
3525         m.OPort = buf.DecodeUint16()
3526         m.VrfID = buf.DecodeUint32()
3527         m.Proto = buf.DecodeUint8()
3528         m.Flags = NatConfigFlags(buf.DecodeUint8())
3529         m.SesNum = buf.DecodeUint32()
3530         return nil
3531 }
3532
3533 // Nat64BibDump defines message 'nat64_bib_dump'.
3534 type Nat64BibDump struct {
3535         Proto uint8 `binapi:"u8,name=proto" json:"proto,omitempty"`
3536 }
3537
3538 func (m *Nat64BibDump) Reset()               { *m = Nat64BibDump{} }
3539 func (*Nat64BibDump) GetMessageName() string { return "nat64_bib_dump" }
3540 func (*Nat64BibDump) GetCrcString() string   { return "cfcb6b75" }
3541 func (*Nat64BibDump) GetMessageType() api.MessageType {
3542         return api.RequestMessage
3543 }
3544
3545 func (m *Nat64BibDump) Size() (size int) {
3546         if m == nil {
3547                 return 0
3548         }
3549         size += 1 // m.Proto
3550         return size
3551 }
3552 func (m *Nat64BibDump) Marshal(b []byte) ([]byte, error) {
3553         if b == nil {
3554                 b = make([]byte, m.Size())
3555         }
3556         buf := codec.NewBuffer(b)
3557         buf.EncodeUint8(m.Proto)
3558         return buf.Bytes(), nil
3559 }
3560 func (m *Nat64BibDump) Unmarshal(b []byte) error {
3561         buf := codec.NewBuffer(b)
3562         m.Proto = buf.DecodeUint8()
3563         return nil
3564 }
3565
3566 // Nat64InterfaceDetails defines message 'nat64_interface_details'.
3567 type Nat64InterfaceDetails struct {
3568         Flags     NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
3569         SwIfIndex InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
3570 }
3571
3572 func (m *Nat64InterfaceDetails) Reset()               { *m = Nat64InterfaceDetails{} }
3573 func (*Nat64InterfaceDetails) GetMessageName() string { return "nat64_interface_details" }
3574 func (*Nat64InterfaceDetails) GetCrcString() string   { return "5d286289" }
3575 func (*Nat64InterfaceDetails) GetMessageType() api.MessageType {
3576         return api.ReplyMessage
3577 }
3578
3579 func (m *Nat64InterfaceDetails) Size() (size int) {
3580         if m == nil {
3581                 return 0
3582         }
3583         size += 1 // m.Flags
3584         size += 4 // m.SwIfIndex
3585         return size
3586 }
3587 func (m *Nat64InterfaceDetails) Marshal(b []byte) ([]byte, error) {
3588         if b == nil {
3589                 b = make([]byte, m.Size())
3590         }
3591         buf := codec.NewBuffer(b)
3592         buf.EncodeUint8(uint8(m.Flags))
3593         buf.EncodeUint32(uint32(m.SwIfIndex))
3594         return buf.Bytes(), nil
3595 }
3596 func (m *Nat64InterfaceDetails) Unmarshal(b []byte) error {
3597         buf := codec.NewBuffer(b)
3598         m.Flags = NatConfigFlags(buf.DecodeUint8())
3599         m.SwIfIndex = InterfaceIndex(buf.DecodeUint32())
3600         return nil
3601 }
3602
3603 // Nat64InterfaceDump defines message 'nat64_interface_dump'.
3604 type Nat64InterfaceDump struct{}
3605
3606 func (m *Nat64InterfaceDump) Reset()               { *m = Nat64InterfaceDump{} }
3607 func (*Nat64InterfaceDump) GetMessageName() string { return "nat64_interface_dump" }
3608 func (*Nat64InterfaceDump) GetCrcString() string   { return "51077d14" }
3609 func (*Nat64InterfaceDump) GetMessageType() api.MessageType {
3610         return api.RequestMessage
3611 }
3612
3613 func (m *Nat64InterfaceDump) Size() (size int) {
3614         if m == nil {
3615                 return 0
3616         }
3617         return size
3618 }
3619 func (m *Nat64InterfaceDump) Marshal(b []byte) ([]byte, error) {
3620         if b == nil {
3621                 b = make([]byte, m.Size())
3622         }
3623         buf := codec.NewBuffer(b)
3624         return buf.Bytes(), nil
3625 }
3626 func (m *Nat64InterfaceDump) Unmarshal(b []byte) error {
3627         return nil
3628 }
3629
3630 // Nat64PoolAddrDetails defines message 'nat64_pool_addr_details'.
3631 type Nat64PoolAddrDetails struct {
3632         Address IP4Address `binapi:"ip4_address,name=address" json:"address,omitempty"`
3633         VrfID   uint32     `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
3634 }
3635
3636 func (m *Nat64PoolAddrDetails) Reset()               { *m = Nat64PoolAddrDetails{} }
3637 func (*Nat64PoolAddrDetails) GetMessageName() string { return "nat64_pool_addr_details" }
3638 func (*Nat64PoolAddrDetails) GetCrcString() string   { return "9bb99cdb" }
3639 func (*Nat64PoolAddrDetails) GetMessageType() api.MessageType {
3640         return api.ReplyMessage
3641 }
3642
3643 func (m *Nat64PoolAddrDetails) Size() (size int) {
3644         if m == nil {
3645                 return 0
3646         }
3647         size += 1 * 4 // m.Address
3648         size += 4     // m.VrfID
3649         return size
3650 }
3651 func (m *Nat64PoolAddrDetails) Marshal(b []byte) ([]byte, error) {
3652         if b == nil {
3653                 b = make([]byte, m.Size())
3654         }
3655         buf := codec.NewBuffer(b)
3656         buf.EncodeBytes(m.Address[:], 4)
3657         buf.EncodeUint32(m.VrfID)
3658         return buf.Bytes(), nil
3659 }
3660 func (m *Nat64PoolAddrDetails) Unmarshal(b []byte) error {
3661         buf := codec.NewBuffer(b)
3662         copy(m.Address[:], buf.DecodeBytes(4))
3663         m.VrfID = buf.DecodeUint32()
3664         return nil
3665 }
3666
3667 // Nat64PoolAddrDump defines message 'nat64_pool_addr_dump'.
3668 type Nat64PoolAddrDump struct{}
3669
3670 func (m *Nat64PoolAddrDump) Reset()               { *m = Nat64PoolAddrDump{} }
3671 func (*Nat64PoolAddrDump) GetMessageName() string { return "nat64_pool_addr_dump" }
3672 func (*Nat64PoolAddrDump) GetCrcString() string   { return "51077d14" }
3673 func (*Nat64PoolAddrDump) GetMessageType() api.MessageType {
3674         return api.RequestMessage
3675 }
3676
3677 func (m *Nat64PoolAddrDump) Size() (size int) {
3678         if m == nil {
3679                 return 0
3680         }
3681         return size
3682 }
3683 func (m *Nat64PoolAddrDump) Marshal(b []byte) ([]byte, error) {
3684         if b == nil {
3685                 b = make([]byte, m.Size())
3686         }
3687         buf := codec.NewBuffer(b)
3688         return buf.Bytes(), nil
3689 }
3690 func (m *Nat64PoolAddrDump) Unmarshal(b []byte) error {
3691         return nil
3692 }
3693
3694 // Nat64PrefixDetails defines message 'nat64_prefix_details'.
3695 type Nat64PrefixDetails struct {
3696         Prefix IP6Prefix `binapi:"ip6_prefix,name=prefix" json:"prefix,omitempty"`
3697         VrfID  uint32    `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
3698 }
3699
3700 func (m *Nat64PrefixDetails) Reset()               { *m = Nat64PrefixDetails{} }
3701 func (*Nat64PrefixDetails) GetMessageName() string { return "nat64_prefix_details" }
3702 func (*Nat64PrefixDetails) GetCrcString() string   { return "20568de3" }
3703 func (*Nat64PrefixDetails) GetMessageType() api.MessageType {
3704         return api.ReplyMessage
3705 }
3706
3707 func (m *Nat64PrefixDetails) Size() (size int) {
3708         if m == nil {
3709                 return 0
3710         }
3711         size += 1 * 16 // m.Prefix.Address
3712         size += 1      // m.Prefix.Len
3713         size += 4      // m.VrfID
3714         return size
3715 }
3716 func (m *Nat64PrefixDetails) Marshal(b []byte) ([]byte, error) {
3717         if b == nil {
3718                 b = make([]byte, m.Size())
3719         }
3720         buf := codec.NewBuffer(b)
3721         buf.EncodeBytes(m.Prefix.Address[:], 16)
3722         buf.EncodeUint8(m.Prefix.Len)
3723         buf.EncodeUint32(m.VrfID)
3724         return buf.Bytes(), nil
3725 }
3726 func (m *Nat64PrefixDetails) Unmarshal(b []byte) error {
3727         buf := codec.NewBuffer(b)
3728         copy(m.Prefix.Address[:], buf.DecodeBytes(16))
3729         m.Prefix.Len = buf.DecodeUint8()
3730         m.VrfID = buf.DecodeUint32()
3731         return nil
3732 }
3733
3734 // Nat64PrefixDump defines message 'nat64_prefix_dump'.
3735 type Nat64PrefixDump struct{}
3736
3737 func (m *Nat64PrefixDump) Reset()               { *m = Nat64PrefixDump{} }
3738 func (*Nat64PrefixDump) GetMessageName() string { return "nat64_prefix_dump" }
3739 func (*Nat64PrefixDump) GetCrcString() string   { return "51077d14" }
3740 func (*Nat64PrefixDump) GetMessageType() api.MessageType {
3741         return api.RequestMessage
3742 }
3743
3744 func (m *Nat64PrefixDump) Size() (size int) {
3745         if m == nil {
3746                 return 0
3747         }
3748         return size
3749 }
3750 func (m *Nat64PrefixDump) Marshal(b []byte) ([]byte, error) {
3751         if b == nil {
3752                 b = make([]byte, m.Size())
3753         }
3754         buf := codec.NewBuffer(b)
3755         return buf.Bytes(), nil
3756 }
3757 func (m *Nat64PrefixDump) Unmarshal(b []byte) error {
3758         return nil
3759 }
3760
3761 // Nat64StDetails defines message 'nat64_st_details'.
3762 type Nat64StDetails struct {
3763         IlAddr IP6Address `binapi:"ip6_address,name=il_addr" json:"il_addr,omitempty"`
3764         OlAddr IP4Address `binapi:"ip4_address,name=ol_addr" json:"ol_addr,omitempty"`
3765         IlPort uint16     `binapi:"u16,name=il_port" json:"il_port,omitempty"`
3766         OlPort uint16     `binapi:"u16,name=ol_port" json:"ol_port,omitempty"`
3767         IrAddr IP6Address `binapi:"ip6_address,name=ir_addr" json:"ir_addr,omitempty"`
3768         OrAddr IP4Address `binapi:"ip4_address,name=or_addr" json:"or_addr,omitempty"`
3769         RPort  uint16     `binapi:"u16,name=r_port" json:"r_port,omitempty"`
3770         VrfID  uint32     `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
3771         Proto  uint8      `binapi:"u8,name=proto" json:"proto,omitempty"`
3772 }
3773
3774 func (m *Nat64StDetails) Reset()               { *m = Nat64StDetails{} }
3775 func (*Nat64StDetails) GetMessageName() string { return "nat64_st_details" }
3776 func (*Nat64StDetails) GetCrcString() string   { return "c770d620" }
3777 func (*Nat64StDetails) GetMessageType() api.MessageType {
3778         return api.ReplyMessage
3779 }
3780
3781 func (m *Nat64StDetails) Size() (size int) {
3782         if m == nil {
3783                 return 0
3784         }
3785         size += 1 * 16 // m.IlAddr
3786         size += 1 * 4  // m.OlAddr
3787         size += 2      // m.IlPort
3788         size += 2      // m.OlPort
3789         size += 1 * 16 // m.IrAddr
3790         size += 1 * 4  // m.OrAddr
3791         size += 2      // m.RPort
3792         size += 4      // m.VrfID
3793         size += 1      // m.Proto
3794         return size
3795 }
3796 func (m *Nat64StDetails) Marshal(b []byte) ([]byte, error) {
3797         if b == nil {
3798                 b = make([]byte, m.Size())
3799         }
3800         buf := codec.NewBuffer(b)
3801         buf.EncodeBytes(m.IlAddr[:], 16)
3802         buf.EncodeBytes(m.OlAddr[:], 4)
3803         buf.EncodeUint16(m.IlPort)
3804         buf.EncodeUint16(m.OlPort)
3805         buf.EncodeBytes(m.IrAddr[:], 16)
3806         buf.EncodeBytes(m.OrAddr[:], 4)
3807         buf.EncodeUint16(m.RPort)
3808         buf.EncodeUint32(m.VrfID)
3809         buf.EncodeUint8(m.Proto)
3810         return buf.Bytes(), nil
3811 }
3812 func (m *Nat64StDetails) Unmarshal(b []byte) error {
3813         buf := codec.NewBuffer(b)
3814         copy(m.IlAddr[:], buf.DecodeBytes(16))
3815         copy(m.OlAddr[:], buf.DecodeBytes(4))
3816         m.IlPort = buf.DecodeUint16()
3817         m.OlPort = buf.DecodeUint16()
3818         copy(m.IrAddr[:], buf.DecodeBytes(16))
3819         copy(m.OrAddr[:], buf.DecodeBytes(4))
3820         m.RPort = buf.DecodeUint16()
3821         m.VrfID = buf.DecodeUint32()
3822         m.Proto = buf.DecodeUint8()
3823         return nil
3824 }
3825
3826 // Nat64StDump defines message 'nat64_st_dump'.
3827 type Nat64StDump struct {
3828         Proto uint8 `binapi:"u8,name=proto" json:"proto,omitempty"`
3829 }
3830
3831 func (m *Nat64StDump) Reset()               { *m = Nat64StDump{} }
3832 func (*Nat64StDump) GetMessageName() string { return "nat64_st_dump" }
3833 func (*Nat64StDump) GetCrcString() string   { return "cfcb6b75" }
3834 func (*Nat64StDump) GetMessageType() api.MessageType {
3835         return api.RequestMessage
3836 }
3837
3838 func (m *Nat64StDump) Size() (size int) {
3839         if m == nil {
3840                 return 0
3841         }
3842         size += 1 // m.Proto
3843         return size
3844 }
3845 func (m *Nat64StDump) Marshal(b []byte) ([]byte, error) {
3846         if b == nil {
3847                 b = make([]byte, m.Size())
3848         }
3849         buf := codec.NewBuffer(b)
3850         buf.EncodeUint8(m.Proto)
3851         return buf.Bytes(), nil
3852 }
3853 func (m *Nat64StDump) Unmarshal(b []byte) error {
3854         buf := codec.NewBuffer(b)
3855         m.Proto = buf.DecodeUint8()
3856         return nil
3857 }
3858
3859 // Nat66AddDelInterface defines message 'nat66_add_del_interface'.
3860 type Nat66AddDelInterface struct {
3861         IsAdd     bool           `binapi:"bool,name=is_add" json:"is_add,omitempty"`
3862         Flags     NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
3863         SwIfIndex InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
3864 }
3865
3866 func (m *Nat66AddDelInterface) Reset()               { *m = Nat66AddDelInterface{} }
3867 func (*Nat66AddDelInterface) GetMessageName() string { return "nat66_add_del_interface" }
3868 func (*Nat66AddDelInterface) GetCrcString() string   { return "f3699b83" }
3869 func (*Nat66AddDelInterface) GetMessageType() api.MessageType {
3870         return api.RequestMessage
3871 }
3872
3873 func (m *Nat66AddDelInterface) Size() (size int) {
3874         if m == nil {
3875                 return 0
3876         }
3877         size += 1 // m.IsAdd
3878         size += 1 // m.Flags
3879         size += 4 // m.SwIfIndex
3880         return size
3881 }
3882 func (m *Nat66AddDelInterface) Marshal(b []byte) ([]byte, error) {
3883         if b == nil {
3884                 b = make([]byte, m.Size())
3885         }
3886         buf := codec.NewBuffer(b)
3887         buf.EncodeBool(m.IsAdd)
3888         buf.EncodeUint8(uint8(m.Flags))
3889         buf.EncodeUint32(uint32(m.SwIfIndex))
3890         return buf.Bytes(), nil
3891 }
3892 func (m *Nat66AddDelInterface) Unmarshal(b []byte) error {
3893         buf := codec.NewBuffer(b)
3894         m.IsAdd = buf.DecodeBool()
3895         m.Flags = NatConfigFlags(buf.DecodeUint8())
3896         m.SwIfIndex = InterfaceIndex(buf.DecodeUint32())
3897         return nil
3898 }
3899
3900 // Nat66AddDelInterfaceReply defines message 'nat66_add_del_interface_reply'.
3901 type Nat66AddDelInterfaceReply struct {
3902         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
3903 }
3904
3905 func (m *Nat66AddDelInterfaceReply) Reset()               { *m = Nat66AddDelInterfaceReply{} }
3906 func (*Nat66AddDelInterfaceReply) GetMessageName() string { return "nat66_add_del_interface_reply" }
3907 func (*Nat66AddDelInterfaceReply) GetCrcString() string   { return "e8d4e804" }
3908 func (*Nat66AddDelInterfaceReply) GetMessageType() api.MessageType {
3909         return api.ReplyMessage
3910 }
3911
3912 func (m *Nat66AddDelInterfaceReply) Size() (size int) {
3913         if m == nil {
3914                 return 0
3915         }
3916         size += 4 // m.Retval
3917         return size
3918 }
3919 func (m *Nat66AddDelInterfaceReply) Marshal(b []byte) ([]byte, error) {
3920         if b == nil {
3921                 b = make([]byte, m.Size())
3922         }
3923         buf := codec.NewBuffer(b)
3924         buf.EncodeInt32(m.Retval)
3925         return buf.Bytes(), nil
3926 }
3927 func (m *Nat66AddDelInterfaceReply) Unmarshal(b []byte) error {
3928         buf := codec.NewBuffer(b)
3929         m.Retval = buf.DecodeInt32()
3930         return nil
3931 }
3932
3933 // Nat66AddDelStaticMapping defines message 'nat66_add_del_static_mapping'.
3934 type Nat66AddDelStaticMapping struct {
3935         IsAdd             bool       `binapi:"bool,name=is_add" json:"is_add,omitempty"`
3936         LocalIPAddress    IP6Address `binapi:"ip6_address,name=local_ip_address" json:"local_ip_address,omitempty"`
3937         ExternalIPAddress IP6Address `binapi:"ip6_address,name=external_ip_address" json:"external_ip_address,omitempty"`
3938         VrfID             uint32     `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
3939 }
3940
3941 func (m *Nat66AddDelStaticMapping) Reset()               { *m = Nat66AddDelStaticMapping{} }
3942 func (*Nat66AddDelStaticMapping) GetMessageName() string { return "nat66_add_del_static_mapping" }
3943 func (*Nat66AddDelStaticMapping) GetCrcString() string   { return "fb64e50b" }
3944 func (*Nat66AddDelStaticMapping) GetMessageType() api.MessageType {
3945         return api.RequestMessage
3946 }
3947
3948 func (m *Nat66AddDelStaticMapping) Size() (size int) {
3949         if m == nil {
3950                 return 0
3951         }
3952         size += 1      // m.IsAdd
3953         size += 1 * 16 // m.LocalIPAddress
3954         size += 1 * 16 // m.ExternalIPAddress
3955         size += 4      // m.VrfID
3956         return size
3957 }
3958 func (m *Nat66AddDelStaticMapping) Marshal(b []byte) ([]byte, error) {
3959         if b == nil {
3960                 b = make([]byte, m.Size())
3961         }
3962         buf := codec.NewBuffer(b)
3963         buf.EncodeBool(m.IsAdd)
3964         buf.EncodeBytes(m.LocalIPAddress[:], 16)
3965         buf.EncodeBytes(m.ExternalIPAddress[:], 16)
3966         buf.EncodeUint32(m.VrfID)
3967         return buf.Bytes(), nil
3968 }
3969 func (m *Nat66AddDelStaticMapping) Unmarshal(b []byte) error {
3970         buf := codec.NewBuffer(b)
3971         m.IsAdd = buf.DecodeBool()
3972         copy(m.LocalIPAddress[:], buf.DecodeBytes(16))
3973         copy(m.ExternalIPAddress[:], buf.DecodeBytes(16))
3974         m.VrfID = buf.DecodeUint32()
3975         return nil
3976 }
3977
3978 // Nat66AddDelStaticMappingReply defines message 'nat66_add_del_static_mapping_reply'.
3979 type Nat66AddDelStaticMappingReply struct {
3980         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
3981 }
3982
3983 func (m *Nat66AddDelStaticMappingReply) Reset() { *m = Nat66AddDelStaticMappingReply{} }
3984 func (*Nat66AddDelStaticMappingReply) GetMessageName() string {
3985         return "nat66_add_del_static_mapping_reply"
3986 }
3987 func (*Nat66AddDelStaticMappingReply) GetCrcString() string { return "e8d4e804" }
3988 func (*Nat66AddDelStaticMappingReply) GetMessageType() api.MessageType {
3989         return api.ReplyMessage
3990 }
3991
3992 func (m *Nat66AddDelStaticMappingReply) Size() (size int) {
3993         if m == nil {
3994                 return 0
3995         }
3996         size += 4 // m.Retval
3997         return size
3998 }
3999 func (m *Nat66AddDelStaticMappingReply) Marshal(b []byte) ([]byte, error) {
4000         if b == nil {
4001                 b = make([]byte, m.Size())
4002         }
4003         buf := codec.NewBuffer(b)
4004         buf.EncodeInt32(m.Retval)
4005         return buf.Bytes(), nil
4006 }
4007 func (m *Nat66AddDelStaticMappingReply) Unmarshal(b []byte) error {
4008         buf := codec.NewBuffer(b)
4009         m.Retval = buf.DecodeInt32()
4010         return nil
4011 }
4012
4013 // Nat66InterfaceDetails defines message 'nat66_interface_details'.
4014 type Nat66InterfaceDetails struct {
4015         Flags     NatConfigFlags `binapi:"nat_config_flags,name=flags" json:"flags,omitempty"`
4016         SwIfIndex InterfaceIndex `binapi:"interface_index,name=sw_if_index" json:"sw_if_index,omitempty"`
4017 }
4018
4019 func (m *Nat66InterfaceDetails) Reset()               { *m = Nat66InterfaceDetails{} }
4020 func (*Nat66InterfaceDetails) GetMessageName() string { return "nat66_interface_details" }
4021 func (*Nat66InterfaceDetails) GetCrcString() string   { return "5d286289" }
4022 func (*Nat66InterfaceDetails) GetMessageType() api.MessageType {
4023         return api.ReplyMessage
4024 }
4025
4026 func (m *Nat66InterfaceDetails) Size() (size int) {
4027         if m == nil {
4028                 return 0
4029         }
4030         size += 1 // m.Flags
4031         size += 4 // m.SwIfIndex
4032         return size
4033 }
4034 func (m *Nat66InterfaceDetails) Marshal(b []byte) ([]byte, error) {
4035         if b == nil {
4036                 b = make([]byte, m.Size())
4037         }
4038         buf := codec.NewBuffer(b)
4039         buf.EncodeUint8(uint8(m.Flags))
4040         buf.EncodeUint32(uint32(m.SwIfIndex))
4041         return buf.Bytes(), nil
4042 }
4043 func (m *Nat66InterfaceDetails) Unmarshal(b []byte) error {
4044         buf := codec.NewBuffer(b)
4045         m.Flags = NatConfigFlags(buf.DecodeUint8())
4046         m.SwIfIndex = InterfaceIndex(buf.DecodeUint32())
4047         return nil
4048 }
4049
4050 // Nat66InterfaceDump defines message 'nat66_interface_dump'.
4051 type Nat66InterfaceDump struct{}
4052
4053 func (m *Nat66InterfaceDump) Reset()               { *m = Nat66InterfaceDump{} }
4054 func (*Nat66InterfaceDump) GetMessageName() string { return "nat66_interface_dump" }
4055 func (*Nat66InterfaceDump) GetCrcString() string   { return "51077d14" }
4056 func (*Nat66InterfaceDump) GetMessageType() api.MessageType {
4057         return api.RequestMessage
4058 }
4059
4060 func (m *Nat66InterfaceDump) Size() (size int) {
4061         if m == nil {
4062                 return 0
4063         }
4064         return size
4065 }
4066 func (m *Nat66InterfaceDump) Marshal(b []byte) ([]byte, error) {
4067         if b == nil {
4068                 b = make([]byte, m.Size())
4069         }
4070         buf := codec.NewBuffer(b)
4071         return buf.Bytes(), nil
4072 }
4073 func (m *Nat66InterfaceDump) Unmarshal(b []byte) error {
4074         return nil
4075 }
4076
4077 // Nat66StaticMappingDetails defines message 'nat66_static_mapping_details'.
4078 type Nat66StaticMappingDetails struct {
4079         LocalIPAddress    IP6Address `binapi:"ip6_address,name=local_ip_address" json:"local_ip_address,omitempty"`
4080         ExternalIPAddress IP6Address `binapi:"ip6_address,name=external_ip_address" json:"external_ip_address,omitempty"`
4081         VrfID             uint32     `binapi:"u32,name=vrf_id" json:"vrf_id,omitempty"`
4082         TotalBytes        uint64     `binapi:"u64,name=total_bytes" json:"total_bytes,omitempty"`
4083         TotalPkts         uint64     `binapi:"u64,name=total_pkts" json:"total_pkts,omitempty"`
4084 }
4085
4086 func (m *Nat66StaticMappingDetails) Reset()               { *m = Nat66StaticMappingDetails{} }
4087 func (*Nat66StaticMappingDetails) GetMessageName() string { return "nat66_static_mapping_details" }
4088 func (*Nat66StaticMappingDetails) GetCrcString() string   { return "5c568448" }
4089 func (*Nat66StaticMappingDetails) GetMessageType() api.MessageType {
4090         return api.ReplyMessage
4091 }
4092
4093 func (m *Nat66StaticMappingDetails) Size() (size int) {
4094         if m == nil {
4095                 return 0
4096         }
4097         size += 1 * 16 // m.LocalIPAddress
4098         size += 1 * 16 // m.ExternalIPAddress
4099         size += 4      // m.VrfID
4100         size += 8      // m.TotalBytes
4101         size += 8      // m.TotalPkts
4102         return size
4103 }
4104 func (m *Nat66StaticMappingDetails) Marshal(b []byte) ([]byte, error) {
4105         if b == nil {
4106                 b = make([]byte, m.Size())
4107         }
4108         buf := codec.NewBuffer(b)
4109         buf.EncodeBytes(m.LocalIPAddress[:], 16)
4110         buf.EncodeBytes(m.ExternalIPAddress[:], 16)
4111         buf.EncodeUint32(m.VrfID)
4112         buf.EncodeUint64(m.TotalBytes)
4113         buf.EncodeUint64(m.TotalPkts)
4114         return buf.Bytes(), nil
4115 }
4116 func (m *Nat66StaticMappingDetails) Unmarshal(b []byte) error {
4117         buf := codec.NewBuffer(b)
4118         copy(m.LocalIPAddress[:], buf.DecodeBytes(16))
4119         copy(m.ExternalIPAddress[:], buf.DecodeBytes(16))
4120         m.VrfID = buf.DecodeUint32()
4121         m.TotalBytes = buf.DecodeUint64()
4122         m.TotalPkts = buf.DecodeUint64()
4123         return nil
4124 }
4125
4126 // Nat66StaticMappingDump defines message 'nat66_static_mapping_dump'.
4127 type Nat66StaticMappingDump struct{}
4128
4129 func (m *Nat66StaticMappingDump) Reset()               { *m = Nat66StaticMappingDump{} }
4130 func (*Nat66StaticMappingDump) GetMessageName() string { return "nat66_static_mapping_dump" }
4131 func (*Nat66StaticMappingDump) GetCrcString() string   { return "51077d14" }
4132 func (*Nat66StaticMappingDump) GetMessageType() api.MessageType {
4133         return api.RequestMessage
4134 }
4135
4136 func (m *Nat66StaticMappingDump) Size() (size int) {
4137         if m == nil {
4138                 return 0
4139         }
4140         return size
4141 }
4142 func (m *Nat66StaticMappingDump) Marshal(b []byte) ([]byte, error) {
4143         if b == nil {
4144                 b = make([]byte, m.Size())
4145         }
4146         buf := codec.NewBuffer(b)
4147         return buf.Bytes(), nil
4148 }
4149 func (m *Nat66StaticMappingDump) Unmarshal(b []byte) error {
4150         return nil
4151 }
4152
4153 // NatControlPing defines message 'nat_control_ping'.
4154 type NatControlPing struct{}
4155
4156 func (m *NatControlPing) Reset()               { *m = NatControlPing{} }
4157 func (*NatControlPing) GetMessageName() string { return "nat_control_ping" }
4158 func (*NatControlPing) GetCrcString() string   { return "51077d14" }
4159 func (*NatControlPing) GetMessageType() api.MessageType {
4160         return api.RequestMessage
4161 }
4162
4163 func (m *NatControlPing) Size() (size int) {
4164         if m == nil {
4165                 return 0
4166         }
4167         return size
4168 }
4169 func (m *NatControlPing) Marshal(b []byte) ([]byte, error) {
4170         if b == nil {
4171                 b = make([]byte, m.Size())
4172         }
4173         buf := codec.NewBuffer(b)
4174         return buf.Bytes(), nil
4175 }
4176 func (m *NatControlPing) Unmarshal(b []byte) error {
4177         return nil
4178 }
4179
4180 // NatControlPingReply defines message 'nat_control_ping_reply'.
4181 type NatControlPingReply struct {
4182         Retval      int32  `binapi:"i32,name=retval" json:"retval,omitempty"`
4183         ClientIndex uint32 `binapi:"u32,name=client_index" json:"client_index,omitempty"`
4184         VpePID      uint32 `binapi:"u32,name=vpe_pid" json:"vpe_pid,omitempty"`
4185 }
4186
4187 func (m *NatControlPingReply) Reset()               { *m = NatControlPingReply{} }
4188 func (*NatControlPingReply) GetMessageName() string { return "nat_control_ping_reply" }
4189 func (*NatControlPingReply) GetCrcString() string   { return "f6b0b8ca" }
4190 func (*NatControlPingReply) GetMessageType() api.MessageType {
4191         return api.ReplyMessage
4192 }
4193
4194 func (m *NatControlPingReply) Size() (size int) {
4195         if m == nil {
4196                 return 0
4197         }
4198         size += 4 // m.Retval
4199         size += 4 // m.ClientIndex
4200         size += 4 // m.VpePID
4201         return size
4202 }
4203 func (m *NatControlPingReply) Marshal(b []byte) ([]byte, error) {
4204         if b == nil {
4205                 b = make([]byte, m.Size())
4206         }
4207         buf := codec.NewBuffer(b)
4208         buf.EncodeInt32(m.Retval)
4209         buf.EncodeUint32(m.ClientIndex)
4210         buf.EncodeUint32(m.VpePID)
4211         return buf.Bytes(), nil
4212 }
4213 func (m *NatControlPingReply) Unmarshal(b []byte) error {
4214         buf := codec.NewBuffer(b)
4215         m.Retval = buf.DecodeInt32()
4216         m.ClientIndex = buf.DecodeUint32()
4217         m.VpePID = buf.DecodeUint32()
4218         return nil
4219 }
4220
4221 // NatDetAddDelMap defines message 'nat_det_add_del_map'.
4222 type NatDetAddDelMap struct {
4223         IsAdd   bool       `binapi:"bool,name=is_add" json:"is_add,omitempty"`
4224         InAddr  IP4Address `binapi:"ip4_address,name=in_addr" json:"in_addr,omitempty"`
4225         InPlen  uint8      `binapi:"u8,name=in_plen" json:"in_plen,omitempty"`
4226         OutAddr IP4Address `binapi:"ip4_address,name=out_addr" json:"out_addr,omitempty"`
4227         OutPlen uint8      `binapi:"u8,name=out_plen" json:"out_plen,omitempty"`
4228 }
4229
4230 func (m *NatDetAddDelMap) Reset()               { *m = NatDetAddDelMap{} }
4231 func (*NatDetAddDelMap) GetMessageName() string { return "nat_det_add_del_map" }
4232 func (*NatDetAddDelMap) GetCrcString() string   { return "112fde05" }
4233 func (*NatDetAddDelMap) GetMessageType() api.MessageType {
4234         return api.RequestMessage
4235 }
4236
4237 func (m *NatDetAddDelMap) Size() (size int) {
4238         if m == nil {
4239                 return 0
4240         }
4241         size += 1     // m.IsAdd
4242         size += 1 * 4 // m.InAddr
4243         size += 1     // m.InPlen
4244         size += 1 * 4 // m.OutAddr
4245         size += 1     // m.OutPlen
4246         return size
4247 }
4248 func (m *NatDetAddDelMap) Marshal(b []byte) ([]byte, error) {
4249         if b == nil {
4250                 b = make([]byte, m.Size())
4251         }
4252         buf := codec.NewBuffer(b)
4253         buf.EncodeBool(m.IsAdd)
4254         buf.EncodeBytes(m.InAddr[:], 4)
4255         buf.EncodeUint8(m.InPlen)
4256         buf.EncodeBytes(m.OutAddr[:], 4)
4257         buf.EncodeUint8(m.OutPlen)
4258         return buf.Bytes(), nil
4259 }
4260 func (m *NatDetAddDelMap) Unmarshal(b []byte) error {
4261         buf := codec.NewBuffer(b)
4262         m.IsAdd = buf.DecodeBool()
4263         copy(m.InAddr[:], buf.DecodeBytes(4))
4264         m.InPlen = buf.DecodeUint8()
4265         copy(m.OutAddr[:], buf.DecodeBytes(4))
4266         m.OutPlen = buf.DecodeUint8()
4267         return nil
4268 }
4269
4270 // NatDetAddDelMapReply defines message 'nat_det_add_del_map_reply'.
4271 type NatDetAddDelMapReply struct {
4272         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
4273 }
4274
4275 func (m *NatDetAddDelMapReply) Reset()               { *m = NatDetAddDelMapReply{} }
4276 func (*NatDetAddDelMapReply) GetMessageName() string { return "nat_det_add_del_map_reply" }
4277 func (*NatDetAddDelMapReply) GetCrcString() string   { return "e8d4e804" }
4278 func (*NatDetAddDelMapReply) GetMessageType() api.MessageType {
4279         return api.ReplyMessage
4280 }
4281
4282 func (m *NatDetAddDelMapReply) Size() (size int) {
4283         if m == nil {
4284                 return 0
4285         }
4286         size += 4 // m.Retval
4287         return size
4288 }
4289 func (m *NatDetAddDelMapReply) Marshal(b []byte) ([]byte, error) {
4290         if b == nil {
4291                 b = make([]byte, m.Size())
4292         }
4293         buf := codec.NewBuffer(b)
4294         buf.EncodeInt32(m.Retval)
4295         return buf.Bytes(), nil
4296 }
4297 func (m *NatDetAddDelMapReply) Unmarshal(b []byte) error {
4298         buf := codec.NewBuffer(b)
4299         m.Retval = buf.DecodeInt32()
4300         return nil
4301 }
4302
4303 // NatDetCloseSessionIn defines message 'nat_det_close_session_in'.
4304 type NatDetCloseSessionIn struct {
4305         InAddr  IP4Address `binapi:"ip4_address,name=in_addr" json:"in_addr,omitempty"`
4306         InPort  uint16     `binapi:"u16,name=in_port" json:"in_port,omitempty"`
4307         ExtAddr IP4Address `binapi:"ip4_address,name=ext_addr" json:"ext_addr,omitempty"`
4308         ExtPort uint16     `binapi:"u16,name=ext_port" json:"ext_port,omitempty"`
4309 }
4310
4311 func (m *NatDetCloseSessionIn) Reset()               { *m = NatDetCloseSessionIn{} }
4312 func (*NatDetCloseSessionIn) GetMessageName() string { return "nat_det_close_session_in" }
4313 func (*NatDetCloseSessionIn) GetCrcString() string   { return "0a10ef64" }
4314 func (*NatDetCloseSessionIn) GetMessageType() api.MessageType {
4315         return api.RequestMessage
4316 }
4317
4318 func (m *NatDetCloseSessionIn) Size() (size int) {
4319         if m == nil {
4320                 return 0
4321         }
4322         size += 1 * 4 // m.InAddr
4323         size += 2     // m.InPort
4324         size += 1 * 4 // m.ExtAddr
4325         size += 2     // m.ExtPort
4326         return size
4327 }
4328 func (m *NatDetCloseSessionIn) Marshal(b []byte) ([]byte, error) {
4329         if b == nil {
4330                 b = make([]byte, m.Size())
4331         }
4332         buf := codec.NewBuffer(b)
4333         buf.EncodeBytes(m.InAddr[:], 4)
4334         buf.EncodeUint16(m.InPort)
4335         buf.EncodeBytes(m.ExtAddr[:], 4)
4336         buf.EncodeUint16(m.ExtPort)
4337         return buf.Bytes(), nil
4338 }
4339 func (m *NatDetCloseSessionIn) Unmarshal(b []byte) error {
4340         buf := codec.NewBuffer(b)
4341         copy(m.InAddr[:], buf.DecodeBytes(4))
4342         m.InPort = buf.DecodeUint16()
4343         copy(m.ExtAddr[:], buf.DecodeBytes(4))
4344         m.ExtPort = buf.DecodeUint16()
4345         return nil
4346 }
4347
4348 // NatDetCloseSessionInReply defines message 'nat_det_close_session_in_reply'.
4349 type NatDetCloseSessionInReply struct {
4350         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
4351 }
4352
4353 func (m *NatDetCloseSessionInReply) Reset()               { *m = NatDetCloseSessionInReply{} }
4354 func (*NatDetCloseSessionInReply) GetMessageName() string { return "nat_det_close_session_in_reply" }
4355 func (*NatDetCloseSessionInReply) GetCrcString() string   { return "e8d4e804" }
4356 func (*NatDetCloseSessionInReply) GetMessageType() api.MessageType {
4357         return api.ReplyMessage
4358 }
4359
4360 func (m *NatDetCloseSessionInReply) Size() (size int) {
4361         if m == nil {
4362                 return 0
4363         }
4364         size += 4 // m.Retval
4365         return size
4366 }
4367 func (m *NatDetCloseSessionInReply) Marshal(b []byte) ([]byte, error) {
4368         if b == nil {
4369                 b = make([]byte, m.Size())
4370         }
4371         buf := codec.NewBuffer(b)
4372         buf.EncodeInt32(m.Retval)
4373         return buf.Bytes(), nil
4374 }
4375 func (m *NatDetCloseSessionInReply) Unmarshal(b []byte) error {
4376         buf := codec.NewBuffer(b)
4377         m.Retval = buf.DecodeInt32()
4378         return nil
4379 }
4380
4381 // NatDetCloseSessionOut defines message 'nat_det_close_session_out'.
4382 type NatDetCloseSessionOut struct {
4383         OutAddr IP4Address `binapi:"ip4_address,name=out_addr" json:"out_addr,omitempty"`
4384         OutPort uint16     `binapi:"u16,name=out_port" json:"out_port,omitempty"`
4385         ExtAddr IP4Address `binapi:"ip4_address,name=ext_addr" json:"ext_addr,omitempty"`
4386         ExtPort uint16     `binapi:"u16,name=ext_port" json:"ext_port,omitempty"`
4387 }
4388
4389 func (m *NatDetCloseSessionOut) Reset()               { *m = NatDetCloseSessionOut{} }
4390 func (*NatDetCloseSessionOut) GetMessageName() string { return "nat_det_close_session_out" }
4391 func (*NatDetCloseSessionOut) GetCrcString() string   { return "c1b6cbfb" }
4392 func (*NatDetCloseSessionOut) GetMessageType() api.MessageType {
4393         return api.RequestMessage
4394 }
4395
4396 func (m *NatDetCloseSessionOut) Size() (size int) {
4397         if m == nil {
4398                 return 0
4399         }
4400         size += 1 * 4 // m.OutAddr
4401         size += 2     // m.OutPort
4402         size += 1 * 4 // m.ExtAddr
4403         size += 2     // m.ExtPort
4404         return size
4405 }
4406 func (m *NatDetCloseSessionOut) Marshal(b []byte) ([]byte, error) {
4407         if b == nil {
4408                 b = make([]byte, m.Size())
4409         }
4410         buf := codec.NewBuffer(b)
4411         buf.EncodeBytes(m.OutAddr[:], 4)
4412         buf.EncodeUint16(m.OutPort)
4413         buf.EncodeBytes(m.ExtAddr[:], 4)
4414         buf.EncodeUint16(m.ExtPort)
4415         return buf.Bytes(), nil
4416 }
4417 func (m *NatDetCloseSessionOut) Unmarshal(b []byte) error {
4418         buf := codec.NewBuffer(b)
4419         copy(m.OutAddr[:], buf.DecodeBytes(4))
4420         m.OutPort = buf.DecodeUint16()
4421         copy(m.ExtAddr[:], buf.DecodeBytes(4))
4422         m.ExtPort = buf.DecodeUint16()
4423         return nil
4424 }
4425
4426 // NatDetCloseSessionOutReply defines message 'nat_det_close_session_out_reply'.
4427 type NatDetCloseSessionOutReply struct {
4428         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
4429 }
4430
4431 func (m *NatDetCloseSessionOutReply) Reset()               { *m = NatDetCloseSessionOutReply{} }
4432 func (*NatDetCloseSessionOutReply) GetMessageName() string { return "nat_det_close_session_out_reply" }
4433 func (*NatDetCloseSessionOutReply) GetCrcString() string   { return "e8d4e804" }
4434 func (*NatDetCloseSessionOutReply) GetMessageType() api.MessageType {
4435         return api.ReplyMessage
4436 }
4437
4438 func (m *NatDetCloseSessionOutReply) Size() (size int) {
4439         if m == nil {
4440                 return 0
4441         }
4442         size += 4 // m.Retval
4443         return size
4444 }
4445 func (m *NatDetCloseSessionOutReply) Marshal(b []byte) ([]byte, error) {
4446         if b == nil {
4447                 b = make([]byte, m.Size())
4448         }
4449         buf := codec.NewBuffer(b)
4450         buf.EncodeInt32(m.Retval)
4451         return buf.Bytes(), nil
4452 }
4453 func (m *NatDetCloseSessionOutReply) Unmarshal(b []byte) error {
4454         buf := codec.NewBuffer(b)
4455         m.Retval = buf.DecodeInt32()
4456         return nil
4457 }
4458
4459 // NatDetForward defines message 'nat_det_forward'.
4460 type NatDetForward struct {
4461         InAddr IP4Address `binapi:"ip4_address,name=in_addr" json:"in_addr,omitempty"`
4462 }
4463
4464 func (m *NatDetForward) Reset()               { *m = NatDetForward{} }
4465 func (*NatDetForward) GetMessageName() string { return "nat_det_forward" }
4466 func (*NatDetForward) GetCrcString() string   { return "7f8a89cd" }
4467 func (*NatDetForward) GetMessageType() api.MessageType {
4468         return api.RequestMessage
4469 }
4470
4471 func (m *NatDetForward) Size() (size int) {
4472         if m == nil {
4473                 return 0
4474         }
4475         size += 1 * 4 // m.InAddr
4476         return size
4477 }
4478 func (m *NatDetForward) Marshal(b []byte) ([]byte, error) {
4479         if b == nil {
4480                 b = make([]byte, m.Size())
4481         }
4482         buf := codec.NewBuffer(b)
4483         buf.EncodeBytes(m.InAddr[:], 4)
4484         return buf.Bytes(), nil
4485 }
4486 func (m *NatDetForward) Unmarshal(b []byte) error {
4487         buf := codec.NewBuffer(b)
4488         copy(m.InAddr[:], buf.DecodeBytes(4))
4489         return nil
4490 }
4491
4492 // NatDetForwardReply defines message 'nat_det_forward_reply'.
4493 type NatDetForwardReply struct {
4494         Retval    int32      `binapi:"i32,name=retval" json:"retval,omitempty"`
4495         OutPortLo uint16     `binapi:"u16,name=out_port_lo" json:"out_port_lo,omitempty"`
4496         OutPortHi uint16     `binapi:"u16,name=out_port_hi" json:"out_port_hi,omitempty"`
4497         OutAddr   IP4Address `binapi:"ip4_address,name=out_addr" json:"out_addr,omitempty"`
4498 }
4499
4500 func (m *NatDetForwardReply) Reset()               { *m = NatDetForwardReply{} }
4501 func (*NatDetForwardReply) GetMessageName() string { return "nat_det_forward_reply" }
4502 func (*NatDetForwardReply) GetCrcString() string   { return "a8ccbdc0" }
4503 func (*NatDetForwardReply) GetMessageType() api.MessageType {
4504         return api.ReplyMessage
4505 }
4506
4507 func (m *NatDetForwardReply) Size() (size int) {
4508         if m == nil {
4509                 return 0
4510         }
4511         size += 4     // m.Retval
4512         size += 2     // m.OutPortLo
4513         size += 2     // m.OutPortHi
4514         size += 1 * 4 // m.OutAddr
4515         return size
4516 }
4517 func (m *NatDetForwardReply) Marshal(b []byte) ([]byte, error) {
4518         if b == nil {
4519                 b = make([]byte, m.Size())
4520         }
4521         buf := codec.NewBuffer(b)
4522         buf.EncodeInt32(m.Retval)
4523         buf.EncodeUint16(m.OutPortLo)
4524         buf.EncodeUint16(m.OutPortHi)
4525         buf.EncodeBytes(m.OutAddr[:], 4)
4526         return buf.Bytes(), nil
4527 }
4528 func (m *NatDetForwardReply) Unmarshal(b []byte) error {
4529         buf := codec.NewBuffer(b)
4530         m.Retval = buf.DecodeInt32()
4531         m.OutPortLo = buf.DecodeUint16()
4532         m.OutPortHi = buf.DecodeUint16()
4533         copy(m.OutAddr[:], buf.DecodeBytes(4))
4534         return nil
4535 }
4536
4537 // NatDetMapDetails defines message 'nat_det_map_details'.
4538 type NatDetMapDetails struct {
4539         InAddr       IP4Address `binapi:"ip4_address,name=in_addr" json:"in_addr,omitempty"`
4540         InPlen       uint8      `binapi:"u8,name=in_plen" json:"in_plen,omitempty"`
4541         OutAddr      IP4Address `binapi:"ip4_address,name=out_addr" json:"out_addr,omitempty"`
4542         OutPlen      uint8      `binapi:"u8,name=out_plen" json:"out_plen,omitempty"`
4543         SharingRatio uint32     `binapi:"u32,name=sharing_ratio" json:"sharing_ratio,omitempty"`
4544         PortsPerHost uint16     `binapi:"u16,name=ports_per_host" json:"ports_per_host,omitempty"`
4545         SesNum       uint32     `binapi:"u32,name=ses_num" json:"ses_num,omitempty"`
4546 }
4547
4548 func (m *NatDetMapDetails) Reset()               { *m = NatDetMapDetails{} }
4549 func (*NatDetMapDetails) GetMessageName() string { return "nat_det_map_details" }
4550 func (*NatDetMapDetails) GetCrcString() string   { return "88000ee1" }
4551 func (*NatDetMapDetails) GetMessageType() api.MessageType {
4552         return api.ReplyMessage
4553 }
4554
4555 func (m *NatDetMapDetails) Size() (size int) {
4556         if m == nil {
4557                 return 0
4558         }
4559         size += 1 * 4 // m.InAddr
4560         size += 1     // m.InPlen
4561         size += 1 * 4 // m.OutAddr
4562         size += 1     // m.OutPlen
4563         size += 4     // m.SharingRatio
4564         size += 2     // m.PortsPerHost
4565         size += 4     // m.SesNum
4566         return size
4567 }
4568 func (m *NatDetMapDetails) Marshal(b []byte) ([]byte, error) {
4569         if b == nil {
4570                 b = make([]byte, m.Size())
4571         }
4572         buf := codec.NewBuffer(b)
4573         buf.EncodeBytes(m.InAddr[:], 4)
4574         buf.EncodeUint8(m.InPlen)
4575         buf.EncodeBytes(m.OutAddr[:], 4)
4576         buf.EncodeUint8(m.OutPlen)
4577         buf.EncodeUint32(m.SharingRatio)
4578         buf.EncodeUint16(m.PortsPerHost)
4579         buf.EncodeUint32(m.SesNum)
4580         return buf.Bytes(), nil
4581 }
4582 func (m *NatDetMapDetails) Unmarshal(b []byte) error {
4583         buf := codec.NewBuffer(b)
4584         copy(m.InAddr[:], buf.DecodeBytes(4))
4585         m.InPlen = buf.DecodeUint8()
4586         copy(m.OutAddr[:], buf.DecodeBytes(4))
4587         m.OutPlen = buf.DecodeUint8()
4588         m.SharingRatio = buf.DecodeUint32()
4589         m.PortsPerHost = buf.DecodeUint16()
4590         m.SesNum = buf.DecodeUint32()
4591         return nil
4592 }
4593
4594 // NatDetMapDump defines message 'nat_det_map_dump'.
4595 type NatDetMapDump struct{}
4596
4597 func (m *NatDetMapDump) Reset()               { *m = NatDetMapDump{} }
4598 func (*NatDetMapDump) GetMessageName() string { return "nat_det_map_dump" }
4599 func (*NatDetMapDump) GetCrcString() string   { return "51077d14" }
4600 func (*NatDetMapDump) GetMessageType() api.MessageType {
4601         return api.RequestMessage
4602 }
4603
4604 func (m *NatDetMapDump) Size() (size int) {
4605         if m == nil {
4606                 return 0
4607         }
4608         return size
4609 }
4610 func (m *NatDetMapDump) Marshal(b []byte) ([]byte, error) {
4611         if b == nil {
4612                 b = make([]byte, m.Size())
4613         }
4614         buf := codec.NewBuffer(b)
4615         return buf.Bytes(), nil
4616 }
4617 func (m *NatDetMapDump) Unmarshal(b []byte) error {
4618         return nil
4619 }
4620
4621 // NatDetReverse defines message 'nat_det_reverse'.
4622 type NatDetReverse struct {
4623         OutPort uint16     `binapi:"u16,name=out_port" json:"out_port,omitempty"`
4624         OutAddr IP4Address `binapi:"ip4_address,name=out_addr" json:"out_addr,omitempty"`
4625 }
4626
4627 func (m *NatDetReverse) Reset()               { *m = NatDetReverse{} }
4628 func (*NatDetReverse) GetMessageName() string { return "nat_det_reverse" }
4629 func (*NatDetReverse) GetCrcString() string   { return "a7573fe1" }
4630 func (*NatDetReverse) GetMessageType() api.MessageType {
4631         return api.RequestMessage
4632 }
4633
4634 func (m *NatDetReverse) Size() (size int) {
4635         if m == nil {
4636                 return 0
4637         }
4638         size += 2     // m.OutPort
4639         size += 1 * 4 // m.OutAddr
4640         return size
4641 }
4642 func (m *NatDetReverse) Marshal(b []byte) ([]byte, error) {
4643         if b == nil {
4644                 b = make([]byte, m.Size())
4645         }
4646         buf := codec.NewBuffer(b)
4647         buf.EncodeUint16(m.OutPort)
4648         buf.EncodeBytes(m.OutAddr[:], 4)
4649         return buf.Bytes(), nil
4650 }
4651 func (m *NatDetReverse) Unmarshal(b []byte) error {
4652         buf := codec.NewBuffer(b)
4653         m.OutPort = buf.DecodeUint16()
4654         copy(m.OutAddr[:], buf.DecodeBytes(4))
4655         return nil
4656 }
4657
4658 // NatDetReverseReply defines message 'nat_det_reverse_reply'.
4659 type NatDetReverseReply struct {
4660         Retval int32      `binapi:"i32,name=retval" json:"retval,omitempty"`
4661         InAddr IP4Address `binapi:"ip4_address,name=in_addr" json:"in_addr,omitempty"`
4662 }
4663
4664 func (m *NatDetReverseReply) Reset()               { *m = NatDetReverseReply{} }
4665 func (*NatDetReverseReply) GetMessageName() string { return "nat_det_reverse_reply" }
4666 func (*NatDetReverseReply) GetCrcString() string   { return "34066d48" }
4667 func (*NatDetReverseReply) GetMessageType() api.MessageType {
4668         return api.ReplyMessage
4669 }
4670
4671 func (m *NatDetReverseReply) Size() (size int) {
4672         if m == nil {
4673                 return 0
4674         }
4675         size += 4     // m.Retval
4676         size += 1 * 4 // m.InAddr
4677         return size
4678 }
4679 func (m *NatDetReverseReply) Marshal(b []byte) ([]byte, error) {
4680         if b == nil {
4681                 b = make([]byte, m.Size())
4682         }
4683         buf := codec.NewBuffer(b)
4684         buf.EncodeInt32(m.Retval)
4685         buf.EncodeBytes(m.InAddr[:], 4)
4686         return buf.Bytes(), nil
4687 }
4688 func (m *NatDetReverseReply) Unmarshal(b []byte) error {
4689         buf := codec.NewBuffer(b)
4690         m.Retval = buf.DecodeInt32()
4691         copy(m.InAddr[:], buf.DecodeBytes(4))
4692         return nil
4693 }
4694
4695 // NatDetSessionDetails defines message 'nat_det_session_details'.
4696 type NatDetSessionDetails struct {
4697         InPort  uint16     `binapi:"u16,name=in_port" json:"in_port,omitempty"`
4698         ExtAddr IP4Address `binapi:"ip4_address,name=ext_addr" json:"ext_addr,omitempty"`
4699         ExtPort uint16     `binapi:"u16,name=ext_port" json:"ext_port,omitempty"`
4700         OutPort uint16     `binapi:"u16,name=out_port" json:"out_port,omitempty"`
4701         State   uint8      `binapi:"u8,name=state" json:"state,omitempty"`
4702         Expire  uint32     `binapi:"u32,name=expire" json:"expire,omitempty"`
4703 }
4704
4705 func (m *NatDetSessionDetails) Reset()               { *m = NatDetSessionDetails{} }
4706 func (*NatDetSessionDetails) GetMessageName() string { return "nat_det_session_details" }
4707 func (*NatDetSessionDetails) GetCrcString() string   { return "27f3c171" }
4708 func (*NatDetSessionDetails) GetMessageType() api.MessageType {
4709         return api.ReplyMessage
4710 }
4711
4712 func (m *NatDetSessionDetails) Size() (size int) {
4713         if m == nil {
4714                 return 0
4715         }
4716         size += 2     // m.InPort
4717         size += 1 * 4 // m.ExtAddr
4718         size += 2     // m.ExtPort
4719         size += 2     // m.OutPort
4720         size += 1     // m.State
4721         size += 4     // m.Expire
4722         return size
4723 }
4724 func (m *NatDetSessionDetails) Marshal(b []byte) ([]byte, error) {
4725         if b == nil {
4726                 b = make([]byte, m.Size())
4727         }
4728         buf := codec.NewBuffer(b)
4729         buf.EncodeUint16(m.InPort)
4730         buf.EncodeBytes(m.ExtAddr[:], 4)
4731         buf.EncodeUint16(m.ExtPort)
4732         buf.EncodeUint16(m.OutPort)
4733         buf.EncodeUint8(m.State)
4734         buf.EncodeUint32(m.Expire)
4735         return buf.Bytes(), nil
4736 }
4737 func (m *NatDetSessionDetails) Unmarshal(b []byte) error {
4738         buf := codec.NewBuffer(b)
4739         m.InPort = buf.DecodeUint16()
4740         copy(m.ExtAddr[:], buf.DecodeBytes(4))
4741         m.ExtPort = buf.DecodeUint16()
4742         m.OutPort = buf.DecodeUint16()
4743         m.State = buf.DecodeUint8()
4744         m.Expire = buf.DecodeUint32()
4745         return nil
4746 }
4747
4748 // NatDetSessionDump defines message 'nat_det_session_dump'.
4749 type NatDetSessionDump struct {
4750         UserAddr IP4Address `binapi:"ip4_address,name=user_addr" json:"user_addr,omitempty"`
4751 }
4752
4753 func (m *NatDetSessionDump) Reset()               { *m = NatDetSessionDump{} }
4754 func (*NatDetSessionDump) GetMessageName() string { return "nat_det_session_dump" }
4755 func (*NatDetSessionDump) GetCrcString() string   { return "e45a3af7" }
4756 func (*NatDetSessionDump) GetMessageType() api.MessageType {
4757         return api.RequestMessage
4758 }
4759
4760 func (m *NatDetSessionDump) Size() (size int) {
4761         if m == nil {
4762                 return 0
4763         }
4764         size += 1 * 4 // m.UserAddr
4765         return size
4766 }
4767 func (m *NatDetSessionDump) Marshal(b []byte) ([]byte, error) {
4768         if b == nil {
4769                 b = make([]byte, m.Size())
4770         }
4771         buf := codec.NewBuffer(b)
4772         buf.EncodeBytes(m.UserAddr[:], 4)
4773         return buf.Bytes(), nil
4774 }
4775 func (m *NatDetSessionDump) Unmarshal(b []byte) error {
4776         buf := codec.NewBuffer(b)
4777         copy(m.UserAddr[:], buf.DecodeBytes(4))
4778         return nil
4779 }
4780
4781 // NatGetAddrAndPortAllocAlg defines message 'nat_get_addr_and_port_alloc_alg'.
4782 type NatGetAddrAndPortAllocAlg struct{}
4783
4784 func (m *NatGetAddrAndPortAllocAlg) Reset()               { *m = NatGetAddrAndPortAllocAlg{} }
4785 func (*NatGetAddrAndPortAllocAlg) GetMessageName() string { return "nat_get_addr_and_port_alloc_alg" }
4786 func (*NatGetAddrAndPortAllocAlg) GetCrcString() string   { return "51077d14" }
4787 func (*NatGetAddrAndPortAllocAlg) GetMessageType() api.MessageType {
4788         return api.RequestMessage
4789 }
4790
4791 func (m *NatGetAddrAndPortAllocAlg) Size() (size int) {
4792         if m == nil {
4793                 return 0
4794         }
4795         return size
4796 }
4797 func (m *NatGetAddrAndPortAllocAlg) Marshal(b []byte) ([]byte, error) {
4798         if b == nil {
4799                 b = make([]byte, m.Size())
4800         }
4801         buf := codec.NewBuffer(b)
4802         return buf.Bytes(), nil
4803 }
4804 func (m *NatGetAddrAndPortAllocAlg) Unmarshal(b []byte) error {
4805         return nil
4806 }
4807
4808 // NatGetAddrAndPortAllocAlgReply defines message 'nat_get_addr_and_port_alloc_alg_reply'.
4809 type NatGetAddrAndPortAllocAlgReply struct {
4810         Retval     int32  `binapi:"i32,name=retval" json:"retval,omitempty"`
4811         Alg        uint8  `binapi:"u8,name=alg" json:"alg,omitempty"`
4812         PsidOffset uint8  `binapi:"u8,name=psid_offset" json:"psid_offset,omitempty"`
4813         PsidLength uint8  `binapi:"u8,name=psid_length" json:"psid_length,omitempty"`
4814         Psid       uint16 `binapi:"u16,name=psid" json:"psid,omitempty"`
4815         StartPort  uint16 `binapi:"u16,name=start_port" json:"start_port,omitempty"`
4816         EndPort    uint16 `binapi:"u16,name=end_port" json:"end_port,omitempty"`
4817 }
4818
4819 func (m *NatGetAddrAndPortAllocAlgReply) Reset() { *m = NatGetAddrAndPortAllocAlgReply{} }
4820 func (*NatGetAddrAndPortAllocAlgReply) GetMessageName() string {
4821         return "nat_get_addr_and_port_alloc_alg_reply"
4822 }
4823 func (*NatGetAddrAndPortAllocAlgReply) GetCrcString() string { return "3607a7d0" }
4824 func (*NatGetAddrAndPortAllocAlgReply) GetMessageType() api.MessageType {
4825         return api.ReplyMessage
4826 }
4827
4828 func (m *NatGetAddrAndPortAllocAlgReply) Size() (size int) {
4829         if m == nil {
4830                 return 0
4831         }
4832         size += 4 // m.Retval
4833         size += 1 // m.Alg
4834         size += 1 // m.PsidOffset
4835         size += 1 // m.PsidLength
4836         size += 2 // m.Psid
4837         size += 2 // m.StartPort
4838         size += 2 // m.EndPort
4839         return size
4840 }
4841 func (m *NatGetAddrAndPortAllocAlgReply) Marshal(b []byte) ([]byte, error) {
4842         if b == nil {
4843                 b = make([]byte, m.Size())
4844         }
4845         buf := codec.NewBuffer(b)
4846         buf.EncodeInt32(m.Retval)
4847         buf.EncodeUint8(m.Alg)
4848         buf.EncodeUint8(m.PsidOffset)
4849         buf.EncodeUint8(m.PsidLength)
4850         buf.EncodeUint16(m.Psid)
4851         buf.EncodeUint16(m.StartPort)
4852         buf.EncodeUint16(m.EndPort)
4853         return buf.Bytes(), nil
4854 }
4855 func (m *NatGetAddrAndPortAllocAlgReply) Unmarshal(b []byte) error {
4856         buf := codec.NewBuffer(b)
4857         m.Retval = buf.DecodeInt32()
4858         m.Alg = buf.DecodeUint8()
4859         m.PsidOffset = buf.DecodeUint8()
4860         m.PsidLength = buf.DecodeUint8()
4861         m.Psid = buf.DecodeUint16()
4862         m.StartPort = buf.DecodeUint16()
4863         m.EndPort = buf.DecodeUint16()
4864         return nil
4865 }
4866
4867 // NatGetMssClamping defines message 'nat_get_mss_clamping'.
4868 type NatGetMssClamping struct{}
4869
4870 func (m *NatGetMssClamping) Reset()               { *m = NatGetMssClamping{} }
4871 func (*NatGetMssClamping) GetMessageName() string { return "nat_get_mss_clamping" }
4872 func (*NatGetMssClamping) GetCrcString() string   { return "51077d14" }
4873 func (*NatGetMssClamping) GetMessageType() api.MessageType {
4874         return api.RequestMessage
4875 }
4876
4877 func (m *NatGetMssClamping) Size() (size int) {
4878         if m == nil {
4879                 return 0
4880         }
4881         return size
4882 }
4883 func (m *NatGetMssClamping) Marshal(b []byte) ([]byte, error) {
4884         if b == nil {
4885                 b = make([]byte, m.Size())
4886         }
4887         buf := codec.NewBuffer(b)
4888         return buf.Bytes(), nil
4889 }
4890 func (m *NatGetMssClamping) Unmarshal(b []byte) error {
4891         return nil
4892 }
4893
4894 // NatGetMssClampingReply defines message 'nat_get_mss_clamping_reply'.
4895 type NatGetMssClampingReply struct {
4896         Retval   int32  `binapi:"i32,name=retval" json:"retval,omitempty"`
4897         MssValue uint16 `binapi:"u16,name=mss_value" json:"mss_value,omitempty"`
4898         Enable   bool   `binapi:"bool,name=enable" json:"enable,omitempty"`
4899 }
4900
4901 func (m *NatGetMssClampingReply) Reset()               { *m = NatGetMssClampingReply{} }
4902 func (*NatGetMssClampingReply) GetMessageName() string { return "nat_get_mss_clamping_reply" }
4903 func (*NatGetMssClampingReply) GetCrcString() string   { return "1c0b2a78" }
4904 func (*NatGetMssClampingReply) GetMessageType() api.MessageType {
4905         return api.ReplyMessage
4906 }
4907
4908 func (m *NatGetMssClampingReply) Size() (size int) {
4909         if m == nil {
4910                 return 0
4911         }
4912         size += 4 // m.Retval
4913         size += 2 // m.MssValue
4914         size += 1 // m.Enable
4915         return size
4916 }
4917 func (m *NatGetMssClampingReply) Marshal(b []byte) ([]byte, error) {
4918         if b == nil {
4919                 b = make([]byte, m.Size())
4920         }
4921         buf := codec.NewBuffer(b)
4922         buf.EncodeInt32(m.Retval)
4923         buf.EncodeUint16(m.MssValue)
4924         buf.EncodeBool(m.Enable)
4925         return buf.Bytes(), nil
4926 }
4927 func (m *NatGetMssClampingReply) Unmarshal(b []byte) error {
4928         buf := codec.NewBuffer(b)
4929         m.Retval = buf.DecodeInt32()
4930         m.MssValue = buf.DecodeUint16()
4931         m.Enable = buf.DecodeBool()
4932         return nil
4933 }
4934
4935 // NatGetTimeouts defines message 'nat_get_timeouts'.
4936 type NatGetTimeouts struct{}
4937
4938 func (m *NatGetTimeouts) Reset()               { *m = NatGetTimeouts{} }
4939 func (*NatGetTimeouts) GetMessageName() string { return "nat_get_timeouts" }
4940 func (*NatGetTimeouts) GetCrcString() string   { return "51077d14" }
4941 func (*NatGetTimeouts) GetMessageType() api.MessageType {
4942         return api.RequestMessage
4943 }
4944
4945 func (m *NatGetTimeouts) Size() (size int) {
4946         if m == nil {
4947                 return 0
4948         }
4949         return size
4950 }
4951 func (m *NatGetTimeouts) Marshal(b []byte) ([]byte, error) {
4952         if b == nil {
4953                 b = make([]byte, m.Size())
4954         }
4955         buf := codec.NewBuffer(b)
4956         return buf.Bytes(), nil
4957 }
4958 func (m *NatGetTimeouts) Unmarshal(b []byte) error {
4959         return nil
4960 }
4961
4962 // NatGetTimeoutsReply defines message 'nat_get_timeouts_reply'.
4963 type NatGetTimeoutsReply struct {
4964         Retval         int32  `binapi:"i32,name=retval" json:"retval,omitempty"`
4965         UDP            uint32 `binapi:"u32,name=udp" json:"udp,omitempty"`
4966         TCPEstablished uint32 `binapi:"u32,name=tcp_established" json:"tcp_established,omitempty"`
4967         TCPTransitory  uint32 `binapi:"u32,name=tcp_transitory" json:"tcp_transitory,omitempty"`
4968         ICMP           uint32 `binapi:"u32,name=icmp" json:"icmp,omitempty"`
4969 }
4970
4971 func (m *NatGetTimeoutsReply) Reset()               { *m = NatGetTimeoutsReply{} }
4972 func (*NatGetTimeoutsReply) GetMessageName() string { return "nat_get_timeouts_reply" }
4973 func (*NatGetTimeoutsReply) GetCrcString() string   { return "3c4df4e1" }
4974 func (*NatGetTimeoutsReply) GetMessageType() api.MessageType {
4975         return api.ReplyMessage
4976 }
4977
4978 func (m *NatGetTimeoutsReply) Size() (size int) {
4979         if m == nil {
4980                 return 0
4981         }
4982         size += 4 // m.Retval
4983         size += 4 // m.UDP
4984         size += 4 // m.TCPEstablished
4985         size += 4 // m.TCPTransitory
4986         size += 4 // m.ICMP
4987         return size
4988 }
4989 func (m *NatGetTimeoutsReply) Marshal(b []byte) ([]byte, error) {
4990         if b == nil {
4991                 b = make([]byte, m.Size())
4992         }
4993         buf := codec.NewBuffer(b)
4994         buf.EncodeInt32(m.Retval)
4995         buf.EncodeUint32(m.UDP)
4996         buf.EncodeUint32(m.TCPEstablished)
4997         buf.EncodeUint32(m.TCPTransitory)
4998         buf.EncodeUint32(m.ICMP)
4999         return buf.Bytes(), nil
5000 }
5001 func (m *NatGetTimeoutsReply) Unmarshal(b []byte) error {
5002         buf := codec.NewBuffer(b)
5003         m.Retval = buf.DecodeInt32()
5004         m.UDP = buf.DecodeUint32()
5005         m.TCPEstablished = buf.DecodeUint32()
5006         m.TCPTransitory = buf.DecodeUint32()
5007         m.ICMP = buf.DecodeUint32()
5008         return nil
5009 }
5010
5011 // NatHaFlush defines message 'nat_ha_flush'.
5012 type NatHaFlush struct{}
5013
5014 func (m *NatHaFlush) Reset()               { *m = NatHaFlush{} }
5015 func (*NatHaFlush) GetMessageName() string { return "nat_ha_flush" }
5016 func (*NatHaFlush) GetCrcString() string   { return "51077d14" }
5017 func (*NatHaFlush) GetMessageType() api.MessageType {
5018         return api.RequestMessage
5019 }
5020
5021 func (m *NatHaFlush) Size() (size int) {
5022         if m == nil {
5023                 return 0
5024         }
5025         return size
5026 }
5027 func (m *NatHaFlush) Marshal(b []byte) ([]byte, error) {
5028         if b == nil {
5029                 b = make([]byte, m.Size())
5030         }
5031         buf := codec.NewBuffer(b)
5032         return buf.Bytes(), nil
5033 }
5034 func (m *NatHaFlush) Unmarshal(b []byte) error {
5035         return nil
5036 }
5037
5038 // NatHaFlushReply defines message 'nat_ha_flush_reply'.
5039 type NatHaFlushReply struct {
5040         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
5041 }
5042
5043 func (m *NatHaFlushReply) Reset()               { *m = NatHaFlushReply{} }
5044 func (*NatHaFlushReply) GetMessageName() string { return "nat_ha_flush_reply" }
5045 func (*NatHaFlushReply) GetCrcString() string   { return "e8d4e804" }
5046 func (*NatHaFlushReply) GetMessageType() api.MessageType {
5047         return api.ReplyMessage
5048 }
5049
5050 func (m *NatHaFlushReply) Size() (size int) {
5051         if m == nil {
5052                 return 0
5053         }
5054         size += 4 // m.Retval
5055         return size
5056 }
5057 func (m *NatHaFlushReply) Marshal(b []byte) ([]byte, error) {
5058         if b == nil {
5059                 b = make([]byte, m.Size())
5060         }
5061         buf := codec.NewBuffer(b)
5062         buf.EncodeInt32(m.Retval)
5063         return buf.Bytes(), nil
5064 }
5065 func (m *NatHaFlushReply) Unmarshal(b []byte) error {
5066         buf := codec.NewBuffer(b)
5067         m.Retval = buf.DecodeInt32()
5068         return nil
5069 }
5070
5071 // NatHaGetFailover defines message 'nat_ha_get_failover'.
5072 type NatHaGetFailover struct{}
5073
5074 func (m *NatHaGetFailover) Reset()               { *m = NatHaGetFailover{} }
5075 func (*NatHaGetFailover) GetMessageName() string { return "nat_ha_get_failover" }
5076 func (*NatHaGetFailover) GetCrcString() string   { return "51077d14" }
5077 func (*NatHaGetFailover) GetMessageType() api.MessageType {
5078         return api.RequestMessage
5079 }
5080
5081 func (m *NatHaGetFailover) Size() (size int) {
5082         if m == nil {
5083                 return 0
5084         }
5085         return size
5086 }
5087 func (m *NatHaGetFailover) Marshal(b []byte) ([]byte, error) {
5088         if b == nil {
5089                 b = make([]byte, m.Size())
5090         }
5091         buf := codec.NewBuffer(b)
5092         return buf.Bytes(), nil
5093 }
5094 func (m *NatHaGetFailover) Unmarshal(b []byte) error {
5095         return nil
5096 }
5097
5098 // NatHaGetFailoverReply defines message 'nat_ha_get_failover_reply'.
5099 type NatHaGetFailoverReply struct {
5100         Retval                 int32      `binapi:"i32,name=retval" json:"retval,omitempty"`
5101         IPAddress              IP4Address `binapi:"ip4_address,name=ip_address" json:"ip_address,omitempty"`
5102         Port                   uint16     `binapi:"u16,name=port" json:"port,omitempty"`
5103         SessionRefreshInterval uint32     `binapi:"u32,name=session_refresh_interval" json:"session_refresh_interval,omitempty"`
5104 }
5105
5106 func (m *NatHaGetFailoverReply) Reset()               { *m = NatHaGetFailoverReply{} }
5107 func (*NatHaGetFailoverReply) GetMessageName() string { return "nat_ha_get_failover_reply" }
5108 func (*NatHaGetFailoverReply) GetCrcString() string   { return "a67d8752" }
5109 func (*NatHaGetFailoverReply) GetMessageType() api.MessageType {
5110         return api.ReplyMessage
5111 }
5112
5113 func (m *NatHaGetFailoverReply) Size() (size int) {
5114         if m == nil {
5115                 return 0
5116         }
5117         size += 4     // m.Retval
5118         size += 1 * 4 // m.IPAddress
5119         size += 2     // m.Port
5120         size += 4     // m.SessionRefreshInterval
5121         return size
5122 }
5123 func (m *NatHaGetFailoverReply) Marshal(b []byte) ([]byte, error) {
5124         if b == nil {
5125                 b = make([]byte, m.Size())
5126         }
5127         buf := codec.NewBuffer(b)
5128         buf.EncodeInt32(m.Retval)
5129         buf.EncodeBytes(m.IPAddress[:], 4)
5130         buf.EncodeUint16(m.Port)
5131         buf.EncodeUint32(m.SessionRefreshInterval)
5132         return buf.Bytes(), nil
5133 }
5134 func (m *NatHaGetFailoverReply) Unmarshal(b []byte) error {
5135         buf := codec.NewBuffer(b)
5136         m.Retval = buf.DecodeInt32()
5137         copy(m.IPAddress[:], buf.DecodeBytes(4))
5138         m.Port = buf.DecodeUint16()
5139         m.SessionRefreshInterval = buf.DecodeUint32()
5140         return nil
5141 }
5142
5143 // NatHaGetListener defines message 'nat_ha_get_listener'.
5144 type NatHaGetListener struct{}
5145
5146 func (m *NatHaGetListener) Reset()               { *m = NatHaGetListener{} }
5147 func (*NatHaGetListener) GetMessageName() string { return "nat_ha_get_listener" }
5148 func (*NatHaGetListener) GetCrcString() string   { return "51077d14" }
5149 func (*NatHaGetListener) GetMessageType() api.MessageType {
5150         return api.RequestMessage
5151 }
5152
5153 func (m *NatHaGetListener) Size() (size int) {
5154         if m == nil {
5155                 return 0
5156         }
5157         return size
5158 }
5159 func (m *NatHaGetListener) Marshal(b []byte) ([]byte, error) {
5160         if b == nil {
5161                 b = make([]byte, m.Size())
5162         }
5163         buf := codec.NewBuffer(b)
5164         return buf.Bytes(), nil
5165 }
5166 func (m *NatHaGetListener) Unmarshal(b []byte) error {
5167         return nil
5168 }
5169
5170 // NatHaGetListenerReply defines message 'nat_ha_get_listener_reply'.
5171 type NatHaGetListenerReply struct {
5172         Retval    int32      `binapi:"i32,name=retval" json:"retval,omitempty"`
5173         IPAddress IP4Address `binapi:"ip4_address,name=ip_address" json:"ip_address,omitempty"`
5174         Port      uint16     `binapi:"u16,name=port" json:"port,omitempty"`
5175         PathMtu   uint32     `binapi:"u32,name=path_mtu" json:"path_mtu,omitempty"`
5176 }
5177
5178 func (m *NatHaGetListenerReply) Reset()               { *m = NatHaGetListenerReply{} }
5179 func (*NatHaGetListenerReply) GetMessageName() string { return "nat_ha_get_listener_reply" }
5180 func (*NatHaGetListenerReply) GetCrcString() string   { return "123ea41f" }
5181 func (*NatHaGetListenerReply) GetMessageType() api.MessageType {
5182         return api.ReplyMessage
5183 }
5184
5185 func (m *NatHaGetListenerReply) Size() (size int) {
5186         if m == nil {
5187                 return 0
5188         }
5189         size += 4     // m.Retval
5190         size += 1 * 4 // m.IPAddress
5191         size += 2     // m.Port
5192         size += 4     // m.PathMtu
5193         return size
5194 }
5195 func (m *NatHaGetListenerReply) Marshal(b []byte) ([]byte, error) {
5196         if b == nil {
5197                 b = make([]byte, m.Size())
5198         }
5199         buf := codec.NewBuffer(b)
5200         buf.EncodeInt32(m.Retval)
5201         buf.EncodeBytes(m.IPAddress[:], 4)
5202         buf.EncodeUint16(m.Port)
5203         buf.EncodeUint32(m.PathMtu)
5204         return buf.Bytes(), nil
5205 }
5206 func (m *NatHaGetListenerReply) Unmarshal(b []byte) error {
5207         buf := codec.NewBuffer(b)
5208         m.Retval = buf.DecodeInt32()
5209         copy(m.IPAddress[:], buf.DecodeBytes(4))
5210         m.Port = buf.DecodeUint16()
5211         m.PathMtu = buf.DecodeUint32()
5212         return nil
5213 }
5214
5215 // NatHaResync defines message 'nat_ha_resync'.
5216 type NatHaResync struct {
5217         WantResyncEvent uint8  `binapi:"u8,name=want_resync_event" json:"want_resync_event,omitempty"`
5218         PID             uint32 `binapi:"u32,name=pid" json:"pid,omitempty"`
5219 }
5220
5221 func (m *NatHaResync) Reset()               { *m = NatHaResync{} }
5222 func (*NatHaResync) GetMessageName() string { return "nat_ha_resync" }
5223 func (*NatHaResync) GetCrcString() string   { return "c8ab9e03" }
5224 func (*NatHaResync) GetMessageType() api.MessageType {
5225         return api.RequestMessage
5226 }
5227
5228 func (m *NatHaResync) Size() (size int) {
5229         if m == nil {
5230                 return 0
5231         }
5232         size += 1 // m.WantResyncEvent
5233         size += 4 // m.PID
5234         return size
5235 }
5236 func (m *NatHaResync) Marshal(b []byte) ([]byte, error) {
5237         if b == nil {
5238                 b = make([]byte, m.Size())
5239         }
5240         buf := codec.NewBuffer(b)
5241         buf.EncodeUint8(m.WantResyncEvent)
5242         buf.EncodeUint32(m.PID)
5243         return buf.Bytes(), nil
5244 }
5245 func (m *NatHaResync) Unmarshal(b []byte) error {
5246         buf := codec.NewBuffer(b)
5247         m.WantResyncEvent = buf.DecodeUint8()
5248         m.PID = buf.DecodeUint32()
5249         return nil
5250 }
5251
5252 // NatHaResyncCompletedEvent defines message 'nat_ha_resync_completed_event'.
5253 type NatHaResyncCompletedEvent struct {
5254         PID         uint32 `binapi:"u32,name=pid" json:"pid,omitempty"`
5255         MissedCount uint32 `binapi:"u32,name=missed_count" json:"missed_count,omitempty"`
5256 }
5257
5258 func (m *NatHaResyncCompletedEvent) Reset()               { *m = NatHaResyncCompletedEvent{} }
5259 func (*NatHaResyncCompletedEvent) GetMessageName() string { return "nat_ha_resync_completed_event" }
5260 func (*NatHaResyncCompletedEvent) GetCrcString() string   { return "fdc598fb" }
5261 func (*NatHaResyncCompletedEvent) GetMessageType() api.MessageType {
5262         return api.EventMessage
5263 }
5264
5265 func (m *NatHaResyncCompletedEvent) Size() (size int) {
5266         if m == nil {
5267                 return 0
5268         }
5269         size += 4 // m.PID
5270         size += 4 // m.MissedCount
5271         return size
5272 }
5273 func (m *NatHaResyncCompletedEvent) Marshal(b []byte) ([]byte, error) {
5274         if b == nil {
5275                 b = make([]byte, m.Size())
5276         }
5277         buf := codec.NewBuffer(b)
5278         buf.EncodeUint32(m.PID)
5279         buf.EncodeUint32(m.MissedCount)
5280         return buf.Bytes(), nil
5281 }
5282 func (m *NatHaResyncCompletedEvent) Unmarshal(b []byte) error {
5283         buf := codec.NewBuffer(b)
5284         m.PID = buf.DecodeUint32()
5285         m.MissedCount = buf.DecodeUint32()
5286         return nil
5287 }
5288
5289 // NatHaResyncReply defines message 'nat_ha_resync_reply'.
5290 type NatHaResyncReply struct {
5291         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
5292 }
5293
5294 func (m *NatHaResyncReply) Reset()               { *m = NatHaResyncReply{} }
5295 func (*NatHaResyncReply) GetMessageName() string { return "nat_ha_resync_reply" }
5296 func (*NatHaResyncReply) GetCrcString() string   { return "e8d4e804" }
5297 func (*NatHaResyncReply) GetMessageType() api.MessageType {
5298         return api.ReplyMessage
5299 }
5300
5301 func (m *NatHaResyncReply) Size() (size int) {
5302         if m == nil {
5303                 return 0
5304         }
5305         size += 4 // m.Retval
5306         return size
5307 }
5308 func (m *NatHaResyncReply) Marshal(b []byte) ([]byte, error) {
5309         if b == nil {
5310                 b = make([]byte, m.Size())
5311         }
5312         buf := codec.NewBuffer(b)
5313         buf.EncodeInt32(m.Retval)
5314         return buf.Bytes(), nil
5315 }
5316 func (m *NatHaResyncReply) Unmarshal(b []byte) error {
5317         buf := codec.NewBuffer(b)
5318         m.Retval = buf.DecodeInt32()
5319         return nil
5320 }
5321
5322 // NatHaSetFailover defines message 'nat_ha_set_failover'.
5323 type NatHaSetFailover struct {
5324         IPAddress              IP4Address `binapi:"ip4_address,name=ip_address" json:"ip_address,omitempty"`
5325         Port                   uint16     `binapi:"u16,name=port" json:"port,omitempty"`
5326         SessionRefreshInterval uint32     `binapi:"u32,name=session_refresh_interval" json:"session_refresh_interval,omitempty"`
5327 }
5328
5329 func (m *NatHaSetFailover) Reset()               { *m = NatHaSetFailover{} }
5330 func (*NatHaSetFailover) GetMessageName() string { return "nat_ha_set_failover" }
5331 func (*NatHaSetFailover) GetCrcString() string   { return "718246af" }
5332 func (*NatHaSetFailover) GetMessageType() api.MessageType {
5333         return api.RequestMessage
5334 }
5335
5336 func (m *NatHaSetFailover) Size() (size int) {
5337         if m == nil {
5338                 return 0
5339         }
5340         size += 1 * 4 // m.IPAddress
5341         size += 2     // m.Port
5342         size += 4     // m.SessionRefreshInterval
5343         return size
5344 }
5345 func (m *NatHaSetFailover) Marshal(b []byte) ([]byte, error) {
5346         if b == nil {
5347                 b = make([]byte, m.Size())
5348         }
5349         buf := codec.NewBuffer(b)
5350         buf.EncodeBytes(m.IPAddress[:], 4)
5351         buf.EncodeUint16(m.Port)
5352         buf.EncodeUint32(m.SessionRefreshInterval)
5353         return buf.Bytes(), nil
5354 }
5355 func (m *NatHaSetFailover) Unmarshal(b []byte) error {
5356         buf := codec.NewBuffer(b)
5357         copy(m.IPAddress[:], buf.DecodeBytes(4))
5358         m.Port = buf.DecodeUint16()
5359         m.SessionRefreshInterval = buf.DecodeUint32()
5360         return nil
5361 }
5362
5363 // NatHaSetFailoverReply defines message 'nat_ha_set_failover_reply'.
5364 type NatHaSetFailoverReply struct {
5365         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
5366 }
5367
5368 func (m *NatHaSetFailoverReply) Reset()               { *m = NatHaSetFailoverReply{} }
5369 func (*NatHaSetFailoverReply) GetMessageName() string { return "nat_ha_set_failover_reply" }
5370 func (*NatHaSetFailoverReply) GetCrcString() string   { return "e8d4e804" }
5371 func (*NatHaSetFailoverReply) GetMessageType() api.MessageType {
5372         return api.ReplyMessage
5373 }
5374
5375 func (m *NatHaSetFailoverReply) Size() (size int) {
5376         if m == nil {
5377                 return 0
5378         }
5379         size += 4 // m.Retval
5380         return size
5381 }
5382 func (m *NatHaSetFailoverReply) Marshal(b []byte) ([]byte, error) {
5383         if b == nil {
5384                 b = make([]byte, m.Size())
5385         }
5386         buf := codec.NewBuffer(b)
5387         buf.EncodeInt32(m.Retval)
5388         return buf.Bytes(), nil
5389 }
5390 func (m *NatHaSetFailoverReply) Unmarshal(b []byte) error {
5391         buf := codec.NewBuffer(b)
5392         m.Retval = buf.DecodeInt32()
5393         return nil
5394 }
5395
5396 // NatHaSetListener defines message 'nat_ha_set_listener'.
5397 type NatHaSetListener struct {
5398         IPAddress IP4Address `binapi:"ip4_address,name=ip_address" json:"ip_address,omitempty"`
5399         Port      uint16     `binapi:"u16,name=port" json:"port,omitempty"`
5400         PathMtu   uint32     `binapi:"u32,name=path_mtu" json:"path_mtu,omitempty"`
5401 }
5402
5403 func (m *NatHaSetListener) Reset()               { *m = NatHaSetListener{} }
5404 func (*NatHaSetListener) GetMessageName() string { return "nat_ha_set_listener" }
5405 func (*NatHaSetListener) GetCrcString() string   { return "e4a8cb4e" }
5406 func (*NatHaSetListener) GetMessageType() api.MessageType {
5407         return api.RequestMessage
5408 }
5409
5410 func (m *NatHaSetListener) Size() (size int) {
5411         if m == nil {
5412                 return 0
5413         }
5414         size += 1 * 4 // m.IPAddress
5415         size += 2     // m.Port
5416         size += 4     // m.PathMtu
5417         return size
5418 }
5419 func (m *NatHaSetListener) Marshal(b []byte) ([]byte, error) {
5420         if b == nil {
5421                 b = make([]byte, m.Size())
5422         }
5423         buf := codec.NewBuffer(b)
5424         buf.EncodeBytes(m.IPAddress[:], 4)
5425         buf.EncodeUint16(m.Port)
5426         buf.EncodeUint32(m.PathMtu)
5427         return buf.Bytes(), nil
5428 }
5429 func (m *NatHaSetListener) Unmarshal(b []byte) error {
5430         buf := codec.NewBuffer(b)
5431         copy(m.IPAddress[:], buf.DecodeBytes(4))
5432         m.Port = buf.DecodeUint16()
5433         m.PathMtu = buf.DecodeUint32()
5434         return nil
5435 }
5436
5437 // NatHaSetListenerReply defines message 'nat_ha_set_listener_reply'.
5438 type NatHaSetListenerReply struct {
5439         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
5440 }
5441
5442 func (m *NatHaSetListenerReply) Reset()               { *m = NatHaSetListenerReply{} }
5443 func (*NatHaSetListenerReply) GetMessageName() string { return "nat_ha_set_listener_reply" }
5444 func (*NatHaSetListenerReply) GetCrcString() string   { return "e8d4e804" }
5445 func (*NatHaSetListenerReply) GetMessageType() api.MessageType {
5446         return api.ReplyMessage
5447 }
5448
5449 func (m *NatHaSetListenerReply) Size() (size int) {
5450         if m == nil {
5451                 return 0
5452         }
5453         size += 4 // m.Retval
5454         return size
5455 }
5456 func (m *NatHaSetListenerReply) Marshal(b []byte) ([]byte, error) {
5457         if b == nil {
5458                 b = make([]byte, m.Size())
5459         }
5460         buf := codec.NewBuffer(b)
5461         buf.EncodeInt32(m.Retval)
5462         return buf.Bytes(), nil
5463 }
5464 func (m *NatHaSetListenerReply) Unmarshal(b []byte) error {
5465         buf := codec.NewBuffer(b)
5466         m.Retval = buf.DecodeInt32()
5467         return nil
5468 }
5469
5470 // NatIpfixEnableDisable defines message 'nat_ipfix_enable_disable'.
5471 type NatIpfixEnableDisable struct {
5472         DomainID uint32 `binapi:"u32,name=domain_id" json:"domain_id,omitempty"`
5473         SrcPort  uint16 `binapi:"u16,name=src_port" json:"src_port,omitempty"`
5474         Enable   bool   `binapi:"bool,name=enable" json:"enable,omitempty"`
5475 }
5476
5477 func (m *NatIpfixEnableDisable) Reset()               { *m = NatIpfixEnableDisable{} }
5478 func (*NatIpfixEnableDisable) GetMessageName() string { return "nat_ipfix_enable_disable" }
5479 func (*NatIpfixEnableDisable) GetCrcString() string   { return "9af4a2d2" }
5480 func (*NatIpfixEnableDisable) GetMessageType() api.MessageType {
5481         return api.RequestMessage
5482 }
5483
5484 func (m *NatIpfixEnableDisable) Size() (size int) {
5485         if m == nil {
5486                 return 0
5487         }
5488         size += 4 // m.DomainID
5489         size += 2 // m.SrcPort
5490         size += 1 // m.Enable
5491         return size
5492 }
5493 func (m *NatIpfixEnableDisable) Marshal(b []byte) ([]byte, error) {
5494         if b == nil {
5495                 b = make([]byte, m.Size())
5496         }
5497         buf := codec.NewBuffer(b)
5498         buf.EncodeUint32(m.DomainID)
5499         buf.EncodeUint16(m.SrcPort)
5500         buf.EncodeBool(m.Enable)
5501         return buf.Bytes(), nil
5502 }
5503 func (m *NatIpfixEnableDisable) Unmarshal(b []byte) error {
5504         buf := codec.NewBuffer(b)
5505         m.DomainID = buf.DecodeUint32()
5506         m.SrcPort = buf.DecodeUint16()
5507         m.Enable = buf.DecodeBool()
5508         return nil
5509 }
5510
5511 // NatIpfixEnableDisableReply defines message 'nat_ipfix_enable_disable_reply'.
5512 type NatIpfixEnableDisableReply struct {
5513         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
5514 }
5515
5516 func (m *NatIpfixEnableDisableReply) Reset()               { *m = NatIpfixEnableDisableReply{} }
5517 func (*NatIpfixEnableDisableReply) GetMessageName() string { return "nat_ipfix_enable_disable_reply" }
5518 func (*NatIpfixEnableDisableReply) GetCrcString() string   { return "e8d4e804" }
5519 func (*NatIpfixEnableDisableReply) GetMessageType() api.MessageType {
5520         return api.ReplyMessage
5521 }
5522
5523 func (m *NatIpfixEnableDisableReply) Size() (size int) {
5524         if m == nil {
5525                 return 0
5526         }
5527         size += 4 // m.Retval
5528         return size
5529 }
5530 func (m *NatIpfixEnableDisableReply) Marshal(b []byte) ([]byte, error) {
5531         if b == nil {
5532                 b = make([]byte, m.Size())
5533         }
5534         buf := codec.NewBuffer(b)
5535         buf.EncodeInt32(m.Retval)
5536         return buf.Bytes(), nil
5537 }
5538 func (m *NatIpfixEnableDisableReply) Unmarshal(b []byte) error {
5539         buf := codec.NewBuffer(b)
5540         m.Retval = buf.DecodeInt32()
5541         return nil
5542 }
5543
5544 // NatSetAddrAndPortAllocAlg defines message 'nat_set_addr_and_port_alloc_alg'.
5545 type NatSetAddrAndPortAllocAlg struct {
5546         Alg        uint8  `binapi:"u8,name=alg" json:"alg,omitempty"`
5547         PsidOffset uint8  `binapi:"u8,name=psid_offset" json:"psid_offset,omitempty"`
5548         PsidLength uint8  `binapi:"u8,name=psid_length" json:"psid_length,omitempty"`
5549         Psid       uint16 `binapi:"u16,name=psid" json:"psid,omitempty"`
5550         StartPort  uint16 `binapi:"u16,name=start_port" json:"start_port,omitempty"`
5551         EndPort    uint16 `binapi:"u16,name=end_port" json:"end_port,omitempty"`
5552 }
5553
5554 func (m *NatSetAddrAndPortAllocAlg) Reset()               { *m = NatSetAddrAndPortAllocAlg{} }
5555 func (*NatSetAddrAndPortAllocAlg) GetMessageName() string { return "nat_set_addr_and_port_alloc_alg" }
5556 func (*NatSetAddrAndPortAllocAlg) GetCrcString() string   { return "deeb746f" }
5557 func (*NatSetAddrAndPortAllocAlg) GetMessageType() api.MessageType {
5558         return api.RequestMessage
5559 }
5560
5561 func (m *NatSetAddrAndPortAllocAlg) Size() (size int) {
5562         if m == nil {
5563                 return 0
5564         }
5565         size += 1 // m.Alg
5566         size += 1 // m.PsidOffset
5567         size += 1 // m.PsidLength
5568         size += 2 // m.Psid
5569         size += 2 // m.StartPort
5570         size += 2 // m.EndPort
5571         return size
5572 }
5573 func (m *NatSetAddrAndPortAllocAlg) Marshal(b []byte) ([]byte, error) {
5574         if b == nil {
5575                 b = make([]byte, m.Size())
5576         }
5577         buf := codec.NewBuffer(b)
5578         buf.EncodeUint8(m.Alg)
5579         buf.EncodeUint8(m.PsidOffset)
5580         buf.EncodeUint8(m.PsidLength)
5581         buf.EncodeUint16(m.Psid)
5582         buf.EncodeUint16(m.StartPort)
5583         buf.EncodeUint16(m.EndPort)
5584         return buf.Bytes(), nil
5585 }
5586 func (m *NatSetAddrAndPortAllocAlg) Unmarshal(b []byte) error {
5587         buf := codec.NewBuffer(b)
5588         m.Alg = buf.DecodeUint8()
5589         m.PsidOffset = buf.DecodeUint8()
5590         m.PsidLength = buf.DecodeUint8()
5591         m.Psid = buf.DecodeUint16()
5592         m.StartPort = buf.DecodeUint16()
5593         m.EndPort = buf.DecodeUint16()
5594         return nil
5595 }
5596
5597 // NatSetAddrAndPortAllocAlgReply defines message 'nat_set_addr_and_port_alloc_alg_reply'.
5598 type NatSetAddrAndPortAllocAlgReply struct {
5599         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
5600 }
5601
5602 func (m *NatSetAddrAndPortAllocAlgReply) Reset() { *m = NatSetAddrAndPortAllocAlgReply{} }
5603 func (*NatSetAddrAndPortAllocAlgReply) GetMessageName() string {
5604         return "nat_set_addr_and_port_alloc_alg_reply"
5605 }
5606 func (*NatSetAddrAndPortAllocAlgReply) GetCrcString() string { return "e8d4e804" }
5607 func (*NatSetAddrAndPortAllocAlgReply) GetMessageType() api.MessageType {
5608         return api.ReplyMessage
5609 }
5610
5611 func (m *NatSetAddrAndPortAllocAlgReply) Size() (size int) {
5612         if m == nil {
5613                 return 0
5614         }
5615         size += 4 // m.Retval
5616         return size
5617 }
5618 func (m *NatSetAddrAndPortAllocAlgReply) Marshal(b []byte) ([]byte, error) {
5619         if b == nil {
5620                 b = make([]byte, m.Size())
5621         }
5622         buf := codec.NewBuffer(b)
5623         buf.EncodeInt32(m.Retval)
5624         return buf.Bytes(), nil
5625 }
5626 func (m *NatSetAddrAndPortAllocAlgReply) Unmarshal(b []byte) error {
5627         buf := codec.NewBuffer(b)
5628         m.Retval = buf.DecodeInt32()
5629         return nil
5630 }
5631
5632 // NatSetLogLevel defines message 'nat_set_log_level'.
5633 type NatSetLogLevel struct {
5634         LogLevel NatLogLevel `binapi:"nat_log_level,name=log_level" json:"log_level,omitempty"`
5635 }
5636
5637 func (m *NatSetLogLevel) Reset()               { *m = NatSetLogLevel{} }
5638 func (*NatSetLogLevel) GetMessageName() string { return "nat_set_log_level" }
5639 func (*NatSetLogLevel) GetCrcString() string   { return "70076bfe" }
5640 func (*NatSetLogLevel) GetMessageType() api.MessageType {
5641         return api.RequestMessage
5642 }
5643
5644 func (m *NatSetLogLevel) Size() (size int) {
5645         if m == nil {
5646                 return 0
5647         }
5648         size += 1 // m.LogLevel
5649         return size
5650 }
5651 func (m *NatSetLogLevel) Marshal(b []byte) ([]byte, error) {
5652         if b == nil {
5653                 b = make([]byte, m.Size())
5654         }
5655         buf := codec.NewBuffer(b)
5656         buf.EncodeUint8(uint8(m.LogLevel))
5657         return buf.Bytes(), nil
5658 }
5659 func (m *NatSetLogLevel) Unmarshal(b []byte) error {
5660         buf := codec.NewBuffer(b)
5661         m.LogLevel = NatLogLevel(buf.DecodeUint8())
5662         return nil
5663 }
5664
5665 // NatSetLogLevelReply defines message 'nat_set_log_level_reply'.
5666 type NatSetLogLevelReply struct {
5667         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
5668 }
5669
5670 func (m *NatSetLogLevelReply) Reset()               { *m = NatSetLogLevelReply{} }
5671 func (*NatSetLogLevelReply) GetMessageName() string { return "nat_set_log_level_reply" }
5672 func (*NatSetLogLevelReply) GetCrcString() string   { return "e8d4e804" }
5673 func (*NatSetLogLevelReply) GetMessageType() api.MessageType {
5674         return api.ReplyMessage
5675 }
5676
5677 func (m *NatSetLogLevelReply) Size() (size int) {
5678         if m == nil {
5679                 return 0
5680         }
5681         size += 4 // m.Retval
5682         return size
5683 }
5684 func (m *NatSetLogLevelReply) Marshal(b []byte) ([]byte, error) {
5685         if b == nil {
5686                 b = make([]byte, m.Size())
5687         }
5688         buf := codec.NewBuffer(b)
5689         buf.EncodeInt32(m.Retval)
5690         return buf.Bytes(), nil
5691 }
5692 func (m *NatSetLogLevelReply) Unmarshal(b []byte) error {
5693         buf := codec.NewBuffer(b)
5694         m.Retval = buf.DecodeInt32()
5695         return nil
5696 }
5697
5698 // NatSetMssClamping defines message 'nat_set_mss_clamping'.
5699 type NatSetMssClamping struct {
5700         MssValue uint16 `binapi:"u16,name=mss_value" json:"mss_value,omitempty"`
5701         Enable   bool   `binapi:"bool,name=enable" json:"enable,omitempty"`
5702 }
5703
5704 func (m *NatSetMssClamping) Reset()               { *m = NatSetMssClamping{} }
5705 func (*NatSetMssClamping) GetMessageName() string { return "nat_set_mss_clamping" }
5706 func (*NatSetMssClamping) GetCrcString() string   { return "25e90abb" }
5707 func (*NatSetMssClamping) GetMessageType() api.MessageType {
5708         return api.RequestMessage
5709 }
5710
5711 func (m *NatSetMssClamping) Size() (size int) {
5712         if m == nil {
5713                 return 0
5714         }
5715         size += 2 // m.MssValue
5716         size += 1 // m.Enable
5717         return size
5718 }
5719 func (m *NatSetMssClamping) Marshal(b []byte) ([]byte, error) {
5720         if b == nil {
5721                 b = make([]byte, m.Size())
5722         }
5723         buf := codec.NewBuffer(b)
5724         buf.EncodeUint16(m.MssValue)
5725         buf.EncodeBool(m.Enable)
5726         return buf.Bytes(), nil
5727 }
5728 func (m *NatSetMssClamping) Unmarshal(b []byte) error {
5729         buf := codec.NewBuffer(b)
5730         m.MssValue = buf.DecodeUint16()
5731         m.Enable = buf.DecodeBool()
5732         return nil
5733 }
5734
5735 // NatSetMssClampingReply defines message 'nat_set_mss_clamping_reply'.
5736 type NatSetMssClampingReply struct {
5737         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
5738 }
5739
5740 func (m *NatSetMssClampingReply) Reset()               { *m = NatSetMssClampingReply{} }
5741 func (*NatSetMssClampingReply) GetMessageName() string { return "nat_set_mss_clamping_reply" }
5742 func (*NatSetMssClampingReply) GetCrcString() string   { return "e8d4e804" }
5743 func (*NatSetMssClampingReply) GetMessageType() api.MessageType {
5744         return api.ReplyMessage
5745 }
5746
5747 func (m *NatSetMssClampingReply) Size() (size int) {
5748         if m == nil {
5749                 return 0
5750         }
5751         size += 4 // m.Retval
5752         return size
5753 }
5754 func (m *NatSetMssClampingReply) Marshal(b []byte) ([]byte, error) {
5755         if b == nil {
5756                 b = make([]byte, m.Size())
5757         }
5758         buf := codec.NewBuffer(b)
5759         buf.EncodeInt32(m.Retval)
5760         return buf.Bytes(), nil
5761 }
5762 func (m *NatSetMssClampingReply) Unmarshal(b []byte) error {
5763         buf := codec.NewBuffer(b)
5764         m.Retval = buf.DecodeInt32()
5765         return nil
5766 }
5767
5768 // NatSetTimeouts defines message 'nat_set_timeouts'.
5769 type NatSetTimeouts struct {
5770         UDP            uint32 `binapi:"u32,name=udp" json:"udp,omitempty"`
5771         TCPEstablished uint32 `binapi:"u32,name=tcp_established" json:"tcp_established,omitempty"`
5772         TCPTransitory  uint32 `binapi:"u32,name=tcp_transitory" json:"tcp_transitory,omitempty"`
5773         ICMP           uint32 `binapi:"u32,name=icmp" json:"icmp,omitempty"`
5774 }
5775
5776 func (m *NatSetTimeouts) Reset()               { *m = NatSetTimeouts{} }
5777 func (*NatSetTimeouts) GetMessageName() string { return "nat_set_timeouts" }
5778 func (*NatSetTimeouts) GetCrcString() string   { return "d4746b16" }
5779 func (*NatSetTimeouts) GetMessageType() api.MessageType {
5780         return api.RequestMessage
5781 }
5782
5783 func (m *NatSetTimeouts) Size() (size int) {
5784         if m == nil {
5785                 return 0
5786         }
5787         size += 4 // m.UDP
5788         size += 4 // m.TCPEstablished
5789         size += 4 // m.TCPTransitory
5790         size += 4 // m.ICMP
5791         return size
5792 }
5793 func (m *NatSetTimeouts) Marshal(b []byte) ([]byte, error) {
5794         if b == nil {
5795                 b = make([]byte, m.Size())
5796         }
5797         buf := codec.NewBuffer(b)
5798         buf.EncodeUint32(m.UDP)
5799         buf.EncodeUint32(m.TCPEstablished)
5800         buf.EncodeUint32(m.TCPTransitory)
5801         buf.EncodeUint32(m.ICMP)
5802         return buf.Bytes(), nil
5803 }
5804 func (m *NatSetTimeouts) Unmarshal(b []byte) error {
5805         buf := codec.NewBuffer(b)
5806         m.UDP = buf.DecodeUint32()
5807         m.TCPEstablished = buf.DecodeUint32()
5808         m.TCPTransitory = buf.DecodeUint32()
5809         m.ICMP = buf.DecodeUint32()
5810         return nil
5811 }
5812
5813 // NatSetTimeoutsReply defines message 'nat_set_timeouts_reply'.
5814 type NatSetTimeoutsReply struct {
5815         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
5816 }
5817
5818 func (m *NatSetTimeoutsReply) Reset()               { *m = NatSetTimeoutsReply{} }
5819 func (*NatSetTimeoutsReply) GetMessageName() string { return "nat_set_timeouts_reply" }
5820 func (*NatSetTimeoutsReply) GetCrcString() string   { return "e8d4e804" }
5821 func (*NatSetTimeoutsReply) GetMessageType() api.MessageType {
5822         return api.ReplyMessage
5823 }
5824
5825 func (m *NatSetTimeoutsReply) Size() (size int) {
5826         if m == nil {
5827                 return 0
5828         }
5829         size += 4 // m.Retval
5830         return size
5831 }
5832 func (m *NatSetTimeoutsReply) Marshal(b []byte) ([]byte, error) {
5833         if b == nil {
5834                 b = make([]byte, m.Size())
5835         }
5836         buf := codec.NewBuffer(b)
5837         buf.EncodeInt32(m.Retval)
5838         return buf.Bytes(), nil
5839 }
5840 func (m *NatSetTimeoutsReply) Unmarshal(b []byte) error {
5841         buf := codec.NewBuffer(b)
5842         m.Retval = buf.DecodeInt32()
5843         return nil
5844 }
5845
5846 // NatSetWorkers defines message 'nat_set_workers'.
5847 type NatSetWorkers struct {
5848         WorkerMask uint64 `binapi:"u64,name=worker_mask" json:"worker_mask,omitempty"`
5849 }
5850
5851 func (m *NatSetWorkers) Reset()               { *m = NatSetWorkers{} }
5852 func (*NatSetWorkers) GetMessageName() string { return "nat_set_workers" }
5853 func (*NatSetWorkers) GetCrcString() string   { return "da926638" }
5854 func (*NatSetWorkers) GetMessageType() api.MessageType {
5855         return api.RequestMessage
5856 }
5857
5858 func (m *NatSetWorkers) Size() (size int) {
5859         if m == nil {
5860                 return 0
5861         }
5862         size += 8 // m.WorkerMask
5863         return size
5864 }
5865 func (m *NatSetWorkers) Marshal(b []byte) ([]byte, error) {
5866         if b == nil {
5867                 b = make([]byte, m.Size())
5868         }
5869         buf := codec.NewBuffer(b)
5870         buf.EncodeUint64(m.WorkerMask)
5871         return buf.Bytes(), nil
5872 }
5873 func (m *NatSetWorkers) Unmarshal(b []byte) error {
5874         buf := codec.NewBuffer(b)
5875         m.WorkerMask = buf.DecodeUint64()
5876         return nil
5877 }
5878
5879 // NatSetWorkersReply defines message 'nat_set_workers_reply'.
5880 type NatSetWorkersReply struct {
5881         Retval int32 `binapi:"i32,name=retval" json:"retval,omitempty"`
5882 }
5883
5884 func (m *NatSetWorkersReply) Reset()               { *m = NatSetWorkersReply{} }
5885 func (*NatSetWorkersReply) GetMessageName() string { return "nat_set_workers_reply" }
5886 func (*NatSetWorkersReply) GetCrcString() string   { return "e8d4e804" }
5887 func (*NatSetWorkersReply) GetMessageType() api.MessageType {
5888         return api.ReplyMessage
5889 }
5890
5891 func (m *NatSetWorkersReply) Size() (size int) {
5892         if m == nil {
5893                 return 0
5894         }
5895         size += 4 // m.Retval
5896         return size
5897 }
5898 func (m *NatSetWorkersReply) Marshal(b []byte) ([]byte, error) {
5899         if b == nil {
5900                 b = make([]byte, m.Size())
5901         }
5902         buf := codec.NewBuffer(b)
5903         buf.EncodeInt32(m.Retval)
5904         return buf.Bytes(), nil
5905 }
5906 func (m *NatSetWorkersReply) Unmarshal(b []byte) error {
5907         buf := codec.NewBuffer(b)
5908         m.Retval = buf.DecodeInt32()
5909         return nil
5910 }
5911
5912 // NatShowConfig defines message 'nat_show_config'.
5913 type NatShowConfig struct{}
5914
5915 func (m *NatShowConfig) Reset()               { *m = NatShowConfig{} }
5916 func (*NatShowConfig) GetMessageName() string { return "nat_show_config" }
5917 func (*NatShowConfig) GetCrcString() string   { return "51077d14" }
5918 func (*NatShowConfig) GetMessageType() api.MessageType {
5919         return api.RequestMessage
5920 }
5921
5922 func (m *NatShowConfig) Size() (size int) {
5923         if m == nil {
5924                 return 0
5925         }
5926         return size
5927 }
5928 func (m *NatShowConfig) Marshal(b []byte) ([]byte, error) {
5929         if b == nil {
5930                 b = make([]byte, m.Size())
5931         }
5932         buf := codec.NewBuffer(b)
5933         return buf.Bytes(), nil
5934 }
5935 func (m *NatShowConfig) Unmarshal(b []byte) error {
5936         return nil
5937 }
5938
5939 // NatShowConfigReply defines message 'nat_show_config_reply'.
5940 type NatShowConfigReply struct {
5941         Retval                          int32  `binapi:"i32,name=retval" json:"retval,omitempty"`
5942         StaticMappingOnly               bool   `binapi:"bool,name=static_mapping_only" json:"static_mapping_only,omitempty"`
5943         StaticMappingConnectionTracking bool   `binapi:"bool,name=static_mapping_connection_tracking" json:"static_mapping_connection_tracking,omitempty"`
5944         Deterministic                   bool   `binapi:"bool,name=deterministic" json:"deterministic,omitempty"`
5945         EndpointDependent               bool   `binapi:"bool,name=endpoint_dependent" json:"endpoint_dependent,omitempty"`
5946         Out2inDpo                       bool   `binapi:"bool,name=out2in_dpo" json:"out2in_dpo,omitempty"`
5947         DsliteCe                        bool   `binapi:"bool,name=dslite_ce" json:"dslite_ce,omitempty"`
5948         TranslationBuckets              uint32 `binapi:"u32,name=translation_buckets" json:"translation_buckets,omitempty"`
5949         TranslationMemorySize           uint32 `binapi:"u32,name=translation_memory_size" json:"translation_memory_size,omitempty"`
5950         UserBuckets                     uint32 `binapi:"u32,name=user_buckets" json:"user_buckets,omitempty"`
5951         UserMemorySize                  uint32 `binapi:"u32,name=user_memory_size" json:"user_memory_size,omitempty"`
5952         MaxTranslationsPerUser          uint32 `binapi:"u32,name=max_translations_per_user" json:"max_translations_per_user,omitempty"`
5953         OutsideVrfID                    uint32 `binapi:"u32,name=outside_vrf_id" json:"outside_vrf_id,omitempty"`
5954         InsideVrfID                     uint32 `binapi:"u32,name=inside_vrf_id" json:"inside_vrf_id,omitempty"`
5955         Nat64BibBuckets                 uint32 `binapi:"u32,name=nat64_bib_buckets" json:"nat64_bib_buckets,omitempty"`
5956         Nat64BibMemorySize              uint32 `binapi:"u32,name=nat64_bib_memory_size" json:"nat64_bib_memory_size,omitempty"`
5957         Nat64StBuckets                  uint32 `binapi:"u32,name=nat64_st_buckets" json:"nat64_st_buckets,omitempty"`
5958         Nat64StMemorySize               uint32 `binapi:"u32,name=nat64_st_memory_size" json:"nat64_st_memory_size,omitempty"`
5959 }
5960
5961 func (m *NatShowConfigReply) Reset()               { *m = NatShowConfigReply{} }
5962 func (*NatShowConfigReply) GetMessageName() string { return "nat_show_config_reply" }
5963 func (*NatShowConfigReply) GetCrcString() string   { return "006a0786" }
5964 func (*NatShowConfigReply) GetMessageType() api.MessageType {
5965         return api.ReplyMessage
5966 }
5967
5968 func (m *NatShowConfigReply) Size() (size int) {
5969         if m == nil {
5970                 return 0
5971         }
5972         size += 4 // m.Retval
5973         size += 1 // m.StaticMappingOnly
5974         size += 1 // m.StaticMappingConnectionTracking
5975         size += 1 // m.Deterministic
5976         size += 1 // m.EndpointDependent
5977         size += 1 // m.Out2inDpo
5978         size += 1 // m.DsliteCe
5979         size += 4 // m.TranslationBuckets
5980         size += 4 // m.TranslationMemorySize
5981         size += 4 // m.UserBuckets
5982         size += 4 // m.UserMemorySize
5983         size += 4 // m.MaxTranslationsPerUser
5984         size += 4 // m.OutsideVrfID
5985         size += 4 // m.InsideVrfID
5986         size += 4 // m.Nat64BibBuckets
5987         size += 4 // m.Nat64BibMemorySize
5988         size += 4 // m.Nat64StBuckets
5989         size += 4 // m.Nat64StMemorySize
5990         return size
5991 }
5992 func (m *NatShowConfigReply) Marshal(b []byte) ([]byte, error) {
5993         if b == nil {
5994                 b = make([]byte, m.Size())
5995         }
5996         buf := codec.NewBuffer(b)
5997         buf.EncodeInt32(m.Retval)
5998         buf.EncodeBool(m.StaticMappingOnly)
5999         buf.EncodeBool(m.StaticMappingConnectionTracking)
6000         buf.EncodeBool(m.Deterministic)
6001         buf.EncodeBool(m.EndpointDependent)
6002         buf.EncodeBool(m.Out2inDpo)
6003         buf.EncodeBool(m.DsliteCe)
6004         buf.EncodeUint32(m.TranslationBuckets)
6005         buf.EncodeUint32(m.TranslationMemorySize)
6006         buf.EncodeUint32(m.UserBuckets)
6007         buf.EncodeUint32(m.UserMemorySize)
6008         buf.EncodeUint32(m.MaxTranslationsPerUser)
6009         buf.EncodeUint32(m.OutsideVrfID)
6010         buf.EncodeUint32(m.InsideVrfID)
6011         buf.EncodeUint32(m.Nat64BibBuckets)
6012         buf.EncodeUint32(m.Nat64BibMemorySize)
6013         buf.EncodeUint32(m.Nat64StBuckets)
6014         buf.EncodeUint32(m.Nat64StMemorySize)
6015         return buf.Bytes(), nil
6016 }
6017 func (m *NatShowConfigReply) Unmarshal(b []byte) error {
6018         buf := codec.NewBuffer(b)
6019         m.Retval = buf.DecodeInt32()
6020         m.StaticMappingOnly = buf.DecodeBool()
6021         m.StaticMappingConnectionTracking = buf.DecodeBool()
6022         m.Deterministic = buf.DecodeBool()
6023         m.EndpointDependent = buf.DecodeBool()
6024         m.Out2inDpo = buf.DecodeBool()
6025         m.DsliteCe = buf.DecodeBool()
6026         m.TranslationBuckets = buf.DecodeUint32()
6027         m.TranslationMemorySize = buf.DecodeUint32()
6028         m.UserBuckets = buf.DecodeUint32()
6029         m.UserMemorySize = buf.DecodeUint32()
6030         m.MaxTranslationsPerUser = buf.DecodeUint32()
6031         m.OutsideVrfID = buf.DecodeUint32()
6032         m.InsideVrfID = buf.DecodeUint32()
6033         m.Nat64BibBuckets = buf.DecodeUint32()
6034         m.Nat64BibMemorySize = buf.DecodeUint32()
6035         m.Nat64StBuckets = buf.DecodeUint32()
6036         m.Nat64StMemorySize = buf.DecodeUint32()
6037         return nil
6038 }
6039
6040 // NatWorkerDetails defines message 'nat_worker_details'.
6041 type NatWorkerDetails struct {
6042         WorkerIndex uint32 `binapi:"u32,name=worker_index" json:"worker_index,omitempty"`
6043         LcoreID     uint32 `binapi:"u32,name=lcore_id" json:"lcore_id,omitempty"`
6044         Name        string `binapi:"string[64],name=name" json:"name,omitempty"`
6045 }
6046
6047 func (m *NatWorkerDetails) Reset()               { *m = NatWorkerDetails{} }
6048 func (*NatWorkerDetails) GetMessageName() string { return "nat_worker_details" }
6049 func (*NatWorkerDetails) GetCrcString() string   { return "84bf06fc" }
6050 func (*NatWorkerDetails) GetMessageType() api.MessageType {
6051         return api.ReplyMessage
6052 }
6053
6054 func (m *NatWorkerDetails) Size() (size int) {
6055         if m == nil {
6056                 return 0
6057         }
6058         size += 4  // m.WorkerIndex
6059         size += 4  // m.LcoreID
6060         size += 64 // m.Name
6061         return size
6062 }
6063 func (m *NatWorkerDetails) Marshal(b []byte) ([]byte, error) {
6064         if b == nil {
6065                 b = make([]byte, m.Size())
6066         }
6067         buf := codec.NewBuffer(b)
6068         buf.EncodeUint32(m.WorkerIndex)
6069         buf.EncodeUint32(m.LcoreID)
6070         buf.EncodeString(m.Name, 64)
6071         return buf.Bytes(), nil
6072 }
6073 func (m *NatWorkerDetails) Unmarshal(b []byte) error {
6074         buf := codec.NewBuffer(b)
6075         m.WorkerIndex = buf.DecodeUint32()
6076         m.LcoreID = buf.DecodeUint32()
6077         m.Name = buf.DecodeString(64)
6078         return nil
6079 }
6080
6081 // NatWorkerDump defines message 'nat_worker_dump'.
6082 type NatWorkerDump struct{}
6083
6084 func (m *NatWorkerDump) Reset()               { *m = NatWorkerDump{} }
6085 func (*NatWorkerDump) GetMessageName() string { return "nat_worker_dump" }
6086 func (*NatWorkerDump) GetCrcString() string   { return "51077d14" }
6087 func (*NatWorkerDump) GetMessageType() api.MessageType {
6088         return api.RequestMessage
6089 }
6090
6091 func (m *NatWorkerDump) Size() (size int) {
6092         if m == nil {
6093                 return 0
6094         }
6095         return size
6096 }
6097 func (m *NatWorkerDump) Marshal(b []byte) ([]byte, error) {
6098         if b == nil {
6099                 b = make([]byte, m.Size())
6100         }
6101         buf := codec.NewBuffer(b)
6102         return buf.Bytes(), nil
6103 }
6104 func (m *NatWorkerDump) Unmarshal(b []byte) error {
6105         return nil
6106 }
6107
6108 func init() { file_nat_binapi_init() }
6109 func file_nat_binapi_init() {
6110         api.RegisterMessage((*DsliteAddDelPoolAddrRange)(nil), "dslite_add_del_pool_addr_range_c448457a")
6111         api.RegisterMessage((*DsliteAddDelPoolAddrRangeReply)(nil), "dslite_add_del_pool_addr_range_reply_e8d4e804")
6112         api.RegisterMessage((*DsliteAddressDetails)(nil), "dslite_address_details_ec26d648")
6113         api.RegisterMessage((*DsliteAddressDump)(nil), "dslite_address_dump_51077d14")
6114         api.RegisterMessage((*DsliteGetAftrAddr)(nil), "dslite_get_aftr_addr_51077d14")
6115         api.RegisterMessage((*DsliteGetAftrAddrReply)(nil), "dslite_get_aftr_addr_reply_38e30db1")
6116         api.RegisterMessage((*DsliteGetB4Addr)(nil), "dslite_get_b4_addr_51077d14")
6117         api.RegisterMessage((*DsliteGetB4AddrReply)(nil), "dslite_get_b4_addr_reply_38e30db1")
6118         api.RegisterMessage((*DsliteSetAftrAddr)(nil), "dslite_set_aftr_addr_1e955f8d")
6119         api.RegisterMessage((*DsliteSetAftrAddrReply)(nil), "dslite_set_aftr_addr_reply_e8d4e804")
6120         api.RegisterMessage((*DsliteSetB4Addr)(nil), "dslite_set_b4_addr_1e955f8d")
6121         api.RegisterMessage((*DsliteSetB4AddrReply)(nil), "dslite_set_b4_addr_reply_e8d4e804")
6122         api.RegisterMessage((*Nat44AddDelAddressRange)(nil), "nat44_add_del_address_range_d4c7568c")
6123         api.RegisterMessage((*Nat44AddDelAddressRangeReply)(nil), "nat44_add_del_address_range_reply_e8d4e804")
6124         api.RegisterMessage((*Nat44AddDelIdentityMapping)(nil), "nat44_add_del_identity_mapping_8e12743f")
6125         api.RegisterMessage((*Nat44AddDelIdentityMappingReply)(nil), "nat44_add_del_identity_mapping_reply_e8d4e804")
6126         api.RegisterMessage((*Nat44AddDelInterfaceAddr)(nil), "nat44_add_del_interface_addr_fc835325")
6127         api.RegisterMessage((*Nat44AddDelInterfaceAddrReply)(nil), "nat44_add_del_interface_addr_reply_e8d4e804")
6128         api.RegisterMessage((*Nat44AddDelLbStaticMapping)(nil), "nat44_add_del_lb_static_mapping_53b24611")
6129         api.RegisterMessage((*Nat44AddDelLbStaticMappingReply)(nil), "nat44_add_del_lb_static_mapping_reply_e8d4e804")
6130         api.RegisterMessage((*Nat44AddDelStaticMapping)(nil), "nat44_add_del_static_mapping_e165e83b")
6131         api.RegisterMessage((*Nat44AddDelStaticMappingReply)(nil), "nat44_add_del_static_mapping_reply_e8d4e804")
6132         api.RegisterMessage((*Nat44AddressDetails)(nil), "nat44_address_details_45410ac4")
6133         api.RegisterMessage((*Nat44AddressDump)(nil), "nat44_address_dump_51077d14")
6134         api.RegisterMessage((*Nat44DelSession)(nil), "nat44_del_session_4c49c387")
6135         api.RegisterMessage((*Nat44DelSessionReply)(nil), "nat44_del_session_reply_e8d4e804")
6136         api.RegisterMessage((*Nat44ForwardingEnableDisable)(nil), "nat44_forwarding_enable_disable_b3e225d2")
6137         api.RegisterMessage((*Nat44ForwardingEnableDisableReply)(nil), "nat44_forwarding_enable_disable_reply_e8d4e804")
6138         api.RegisterMessage((*Nat44ForwardingIsEnabled)(nil), "nat44_forwarding_is_enabled_51077d14")
6139         api.RegisterMessage((*Nat44ForwardingIsEnabledReply)(nil), "nat44_forwarding_is_enabled_reply_46924a06")
6140         api.RegisterMessage((*Nat44IdentityMappingDetails)(nil), "nat44_identity_mapping_details_36d21351")
6141         api.RegisterMessage((*Nat44IdentityMappingDump)(nil), "nat44_identity_mapping_dump_51077d14")
6142         api.RegisterMessage((*Nat44InterfaceAddDelFeature)(nil), "nat44_interface_add_del_feature_f3699b83")
6143         api.RegisterMessage((*Nat44InterfaceAddDelFeatureReply)(nil), "nat44_interface_add_del_feature_reply_e8d4e804")
6144         api.RegisterMessage((*Nat44InterfaceAddDelOutputFeature)(nil), "nat44_interface_add_del_output_feature_f3699b83")
6145         api.RegisterMessage((*Nat44InterfaceAddDelOutputFeatureReply)(nil), "nat44_interface_add_del_output_feature_reply_e8d4e804")
6146         api.RegisterMessage((*Nat44InterfaceAddrDetails)(nil), "nat44_interface_addr_details_3e687514")
6147         api.RegisterMessage((*Nat44InterfaceAddrDump)(nil), "nat44_interface_addr_dump_51077d14")
6148         api.RegisterMessage((*Nat44InterfaceDetails)(nil), "nat44_interface_details_5d286289")
6149         api.RegisterMessage((*Nat44InterfaceDump)(nil), "nat44_interface_dump_51077d14")
6150         api.RegisterMessage((*Nat44InterfaceOutputFeatureDetails)(nil), "nat44_interface_output_feature_details_5d286289")
6151         api.RegisterMessage((*Nat44InterfaceOutputFeatureDump)(nil), "nat44_interface_output_feature_dump_51077d14")
6152         api.RegisterMessage((*Nat44LbStaticMappingAddDelLocal)(nil), "nat44_lb_static_mapping_add_del_local_2910a151")
6153         api.RegisterMessage((*Nat44LbStaticMappingAddDelLocalReply)(nil), "nat44_lb_static_mapping_add_del_local_reply_e8d4e804")
6154         api.RegisterMessage((*Nat44LbStaticMappingDetails)(nil), "nat44_lb_static_mapping_details_2267b9e8")
6155         api.RegisterMessage((*Nat44LbStaticMappingDump)(nil), "nat44_lb_static_mapping_dump_51077d14")
6156         api.RegisterMessage((*Nat44StaticMappingDetails)(nil), "nat44_static_mapping_details_1a433ef7")
6157         api.RegisterMessage((*Nat44StaticMappingDump)(nil), "nat44_static_mapping_dump_51077d14")
6158         api.RegisterMessage((*Nat44UserDetails)(nil), "nat44_user_details_355896c2")
6159         api.RegisterMessage((*Nat44UserDump)(nil), "nat44_user_dump_51077d14")
6160         api.RegisterMessage((*Nat44UserSessionDetails)(nil), "nat44_user_session_details_1965fd69")
6161         api.RegisterMessage((*Nat44UserSessionDump)(nil), "nat44_user_session_dump_e1899c98")
6162         api.RegisterMessage((*Nat64AddDelInterface)(nil), "nat64_add_del_interface_f3699b83")
6163         api.RegisterMessage((*Nat64AddDelInterfaceAddr)(nil), "nat64_add_del_interface_addr_47d6e753")
6164         api.RegisterMessage((*Nat64AddDelInterfaceAddrReply)(nil), "nat64_add_del_interface_addr_reply_e8d4e804")
6165         api.RegisterMessage((*Nat64AddDelInterfaceReply)(nil), "nat64_add_del_interface_reply_e8d4e804")
6166         api.RegisterMessage((*Nat64AddDelPoolAddrRange)(nil), "nat64_add_del_pool_addr_range_21234ef3")
6167         api.RegisterMessage((*Nat64AddDelPoolAddrRangeReply)(nil), "nat64_add_del_pool_addr_range_reply_e8d4e804")
6168         api.RegisterMessage((*Nat64AddDelPrefix)(nil), "nat64_add_del_prefix_727b2f4c")
6169         api.RegisterMessage((*Nat64AddDelPrefixReply)(nil), "nat64_add_del_prefix_reply_e8d4e804")
6170         api.RegisterMessage((*Nat64AddDelStaticBib)(nil), "nat64_add_del_static_bib_90fae58a")
6171         api.RegisterMessage((*Nat64AddDelStaticBibReply)(nil), "nat64_add_del_static_bib_reply_e8d4e804")
6172         api.RegisterMessage((*Nat64BibDetails)(nil), "nat64_bib_details_62c8541d")
6173         api.RegisterMessage((*Nat64BibDump)(nil), "nat64_bib_dump_cfcb6b75")
6174         api.RegisterMessage((*Nat64InterfaceDetails)(nil), "nat64_interface_details_5d286289")
6175         api.RegisterMessage((*Nat64InterfaceDump)(nil), "nat64_interface_dump_51077d14")
6176         api.RegisterMessage((*Nat64PoolAddrDetails)(nil), "nat64_pool_addr_details_9bb99cdb")
6177         api.RegisterMessage((*Nat64PoolAddrDump)(nil), "nat64_pool_addr_dump_51077d14")
6178         api.RegisterMessage((*Nat64PrefixDetails)(nil), "nat64_prefix_details_20568de3")
6179         api.RegisterMessage((*Nat64PrefixDump)(nil), "nat64_prefix_dump_51077d14")
6180         api.RegisterMessage((*Nat64StDetails)(nil), "nat64_st_details_c770d620")
6181         api.RegisterMessage((*Nat64StDump)(nil), "nat64_st_dump_cfcb6b75")
6182         api.RegisterMessage((*Nat66AddDelInterface)(nil), "nat66_add_del_interface_f3699b83")
6183         api.RegisterMessage((*Nat66AddDelInterfaceReply)(nil), "nat66_add_del_interface_reply_e8d4e804")
6184         api.RegisterMessage((*Nat66AddDelStaticMapping)(nil), "nat66_add_del_static_mapping_fb64e50b")
6185         api.RegisterMessage((*Nat66AddDelStaticMappingReply)(nil), "nat66_add_del_static_mapping_reply_e8d4e804")
6186         api.RegisterMessage((*Nat66InterfaceDetails)(nil), "nat66_interface_details_5d286289")
6187         api.RegisterMessage((*Nat66InterfaceDump)(nil), "nat66_interface_dump_51077d14")
6188         api.RegisterMessage((*Nat66StaticMappingDetails)(nil), "nat66_static_mapping_details_5c568448")
6189         api.RegisterMessage((*Nat66StaticMappingDump)(nil), "nat66_static_mapping_dump_51077d14")
6190         api.RegisterMessage((*NatControlPing)(nil), "nat_control_ping_51077d14")
6191         api.RegisterMessage((*NatControlPingReply)(nil), "nat_control_ping_reply_f6b0b8ca")
6192         api.RegisterMessage((*NatDetAddDelMap)(nil), "nat_det_add_del_map_112fde05")
6193         api.RegisterMessage((*NatDetAddDelMapReply)(nil), "nat_det_add_del_map_reply_e8d4e804")
6194         api.RegisterMessage((*NatDetCloseSessionIn)(nil), "nat_det_close_session_in_0a10ef64")
6195         api.RegisterMessage((*NatDetCloseSessionInReply)(nil), "nat_det_close_session_in_reply_e8d4e804")
6196         api.RegisterMessage((*NatDetCloseSessionOut)(nil), "nat_det_close_session_out_c1b6cbfb")
6197         api.RegisterMessage((*NatDetCloseSessionOutReply)(nil), "nat_det_close_session_out_reply_e8d4e804")
6198         api.RegisterMessage((*NatDetForward)(nil), "nat_det_forward_7f8a89cd")
6199         api.RegisterMessage((*NatDetForwardReply)(nil), "nat_det_forward_reply_a8ccbdc0")
6200         api.RegisterMessage((*NatDetMapDetails)(nil), "nat_det_map_details_88000ee1")
6201         api.RegisterMessage((*NatDetMapDump)(nil), "nat_det_map_dump_51077d14")
6202         api.RegisterMessage((*NatDetReverse)(nil), "nat_det_reverse_a7573fe1")
6203         api.RegisterMessage((*NatDetReverseReply)(nil), "nat_det_reverse_reply_34066d48")
6204         api.RegisterMessage((*NatDetSessionDetails)(nil), "nat_det_session_details_27f3c171")
6205         api.RegisterMessage((*NatDetSessionDump)(nil), "nat_det_session_dump_e45a3af7")
6206         api.RegisterMessage((*NatGetAddrAndPortAllocAlg)(nil), "nat_get_addr_and_port_alloc_alg_51077d14")
6207         api.RegisterMessage((*NatGetAddrAndPortAllocAlgReply)(nil), "nat_get_addr_and_port_alloc_alg_reply_3607a7d0")
6208         api.RegisterMessage((*NatGetMssClamping)(nil), "nat_get_mss_clamping_51077d14")
6209         api.RegisterMessage((*NatGetMssClampingReply)(nil), "nat_get_mss_clamping_reply_1c0b2a78")
6210         api.RegisterMessage((*NatGetTimeouts)(nil), "nat_get_timeouts_51077d14")
6211         api.RegisterMessage((*NatGetTimeoutsReply)(nil), "nat_get_timeouts_reply_3c4df4e1")
6212         api.RegisterMessage((*NatHaFlush)(nil), "nat_ha_flush_51077d14")
6213         api.RegisterMessage((*NatHaFlushReply)(nil), "nat_ha_flush_reply_e8d4e804")
6214         api.RegisterMessage((*NatHaGetFailover)(nil), "nat_ha_get_failover_51077d14")
6215         api.RegisterMessage((*NatHaGetFailoverReply)(nil), "nat_ha_get_failover_reply_a67d8752")
6216         api.RegisterMessage((*NatHaGetListener)(nil), "nat_ha_get_listener_51077d14")
6217         api.RegisterMessage((*NatHaGetListenerReply)(nil), "nat_ha_get_listener_reply_123ea41f")
6218         api.RegisterMessage((*NatHaResync)(nil), "nat_ha_resync_c8ab9e03")
6219         api.RegisterMessage((*NatHaResyncCompletedEvent)(nil), "nat_ha_resync_completed_event_fdc598fb")
6220         api.RegisterMessage((*NatHaResyncReply)(nil), "nat_ha_resync_reply_e8d4e804")
6221         api.RegisterMessage((*NatHaSetFailover)(nil), "nat_ha_set_failover_718246af")
6222         api.RegisterMessage((*NatHaSetFailoverReply)(nil), "nat_ha_set_failover_reply_e8d4e804")
6223         api.RegisterMessage((*NatHaSetListener)(nil), "nat_ha_set_listener_e4a8cb4e")
6224         api.RegisterMessage((*NatHaSetListenerReply)(nil), "nat_ha_set_listener_reply_e8d4e804")
6225         api.RegisterMessage((*NatIpfixEnableDisable)(nil), "nat_ipfix_enable_disable_9af4a2d2")
6226         api.RegisterMessage((*NatIpfixEnableDisableReply)(nil), "nat_ipfix_enable_disable_reply_e8d4e804")
6227         api.RegisterMessage((*NatSetAddrAndPortAllocAlg)(nil), "nat_set_addr_and_port_alloc_alg_deeb746f")
6228         api.RegisterMessage((*NatSetAddrAndPortAllocAlgReply)(nil), "nat_set_addr_and_port_alloc_alg_reply_e8d4e804")
6229         api.RegisterMessage((*NatSetLogLevel)(nil), "nat_set_log_level_70076bfe")
6230         api.RegisterMessage((*NatSetLogLevelReply)(nil), "nat_set_log_level_reply_e8d4e804")
6231         api.RegisterMessage((*NatSetMssClamping)(nil), "nat_set_mss_clamping_25e90abb")
6232         api.RegisterMessage((*NatSetMssClampingReply)(nil), "nat_set_mss_clamping_reply_e8d4e804")
6233         api.RegisterMessage((*NatSetTimeouts)(nil), "nat_set_timeouts_d4746b16")
6234         api.RegisterMessage((*NatSetTimeoutsReply)(nil), "nat_set_timeouts_reply_e8d4e804")
6235         api.RegisterMessage((*NatSetWorkers)(nil), "nat_set_workers_da926638")
6236         api.RegisterMessage((*NatSetWorkersReply)(nil), "nat_set_workers_reply_e8d4e804")
6237         api.RegisterMessage((*NatShowConfig)(nil), "nat_show_config_51077d14")
6238         api.RegisterMessage((*NatShowConfigReply)(nil), "nat_show_config_reply_006a0786")
6239         api.RegisterMessage((*NatWorkerDetails)(nil), "nat_worker_details_84bf06fc")
6240         api.RegisterMessage((*NatWorkerDump)(nil), "nat_worker_dump_51077d14")
6241 }
6242
6243 // Messages returns list of all messages in this module.
6244 func AllMessages() []api.Message {
6245         return []api.Message{
6246                 (*DsliteAddDelPoolAddrRange)(nil),
6247                 (*DsliteAddDelPoolAddrRangeReply)(nil),
6248                 (*DsliteAddressDetails)(nil),
6249                 (*DsliteAddressDump)(nil),
6250                 (*DsliteGetAftrAddr)(nil),
6251                 (*DsliteGetAftrAddrReply)(nil),
6252                 (*DsliteGetB4Addr)(nil),
6253                 (*DsliteGetB4AddrReply)(nil),
6254                 (*DsliteSetAftrAddr)(nil),
6255                 (*DsliteSetAftrAddrReply)(nil),
6256                 (*DsliteSetB4Addr)(nil),
6257                 (*DsliteSetB4AddrReply)(nil),
6258                 (*Nat44AddDelAddressRange)(nil),
6259                 (*Nat44AddDelAddressRangeReply)(nil),
6260                 (*Nat44AddDelIdentityMapping)(nil),
6261                 (*Nat44AddDelIdentityMappingReply)(nil),
6262                 (*Nat44AddDelInterfaceAddr)(nil),
6263                 (*Nat44AddDelInterfaceAddrReply)(nil),
6264                 (*Nat44AddDelLbStaticMapping)(nil),
6265                 (*Nat44AddDelLbStaticMappingReply)(nil),
6266                 (*Nat44AddDelStaticMapping)(nil),
6267                 (*Nat44AddDelStaticMappingReply)(nil),
6268                 (*Nat44AddressDetails)(nil),
6269                 (*Nat44AddressDump)(nil),
6270                 (*Nat44DelSession)(nil),
6271                 (*Nat44DelSessionReply)(nil),
6272                 (*Nat44ForwardingEnableDisable)(nil),
6273                 (*Nat44ForwardingEnableDisableReply)(nil),
6274                 (*Nat44ForwardingIsEnabled)(nil),
6275                 (*Nat44ForwardingIsEnabledReply)(nil),
6276                 (*Nat44IdentityMappingDetails)(nil),
6277                 (*Nat44IdentityMappingDump)(nil),
6278                 (*Nat44InterfaceAddDelFeature)(nil),
6279                 (*Nat44InterfaceAddDelFeatureReply)(nil),
6280                 (*Nat44InterfaceAddDelOutputFeature)(nil),
6281                 (*Nat44InterfaceAddDelOutputFeatureReply)(nil),
6282                 (*Nat44InterfaceAddrDetails)(nil),
6283                 (*Nat44InterfaceAddrDump)(nil),
6284                 (*Nat44InterfaceDetails)(nil),
6285                 (*Nat44InterfaceDump)(nil),
6286                 (*Nat44InterfaceOutputFeatureDetails)(nil),
6287                 (*Nat44InterfaceOutputFeatureDump)(nil),
6288                 (*Nat44LbStaticMappingAddDelLocal)(nil),
6289                 (*Nat44LbStaticMappingAddDelLocalReply)(nil),
6290                 (*Nat44LbStaticMappingDetails)(nil),
6291                 (*Nat44LbStaticMappingDump)(nil),
6292                 (*Nat44StaticMappingDetails)(nil),
6293                 (*Nat44StaticMappingDump)(nil),
6294                 (*Nat44UserDetails)(nil),
6295                 (*Nat44UserDump)(nil),
6296                 (*Nat44UserSessionDetails)(nil),
6297                 (*Nat44UserSessionDump)(nil),
6298                 (*Nat64AddDelInterface)(nil),
6299                 (*Nat64AddDelInterfaceAddr)(nil),
6300                 (*Nat64AddDelInterfaceAddrReply)(nil),
6301                 (*Nat64AddDelInterfaceReply)(nil),
6302                 (*Nat64AddDelPoolAddrRange)(nil),
6303                 (*Nat64AddDelPoolAddrRangeReply)(nil),
6304                 (*Nat64AddDelPrefix)(nil),
6305                 (*Nat64AddDelPrefixReply)(nil),
6306                 (*Nat64AddDelStaticBib)(nil),
6307                 (*Nat64AddDelStaticBibReply)(nil),
6308                 (*Nat64BibDetails)(nil),
6309                 (*Nat64BibDump)(nil),
6310                 (*Nat64InterfaceDetails)(nil),
6311                 (*Nat64InterfaceDump)(nil),
6312                 (*Nat64PoolAddrDetails)(nil),
6313                 (*Nat64PoolAddrDump)(nil),
6314                 (*Nat64PrefixDetails)(nil),
6315                 (*Nat64PrefixDump)(nil),
6316                 (*Nat64StDetails)(nil),
6317                 (*Nat64StDump)(nil),
6318                 (*Nat66AddDelInterface)(nil),
6319                 (*Nat66AddDelInterfaceReply)(nil),
6320                 (*Nat66AddDelStaticMapping)(nil),
6321                 (*Nat66AddDelStaticMappingReply)(nil),
6322                 (*Nat66InterfaceDetails)(nil),
6323                 (*Nat66InterfaceDump)(nil),
6324                 (*Nat66StaticMappingDetails)(nil),
6325                 (*Nat66StaticMappingDump)(nil),
6326                 (*NatControlPing)(nil),
6327                 (*NatControlPingReply)(nil),
6328                 (*NatDetAddDelMap)(nil),
6329                 (*NatDetAddDelMapReply)(nil),
6330                 (*NatDetCloseSessionIn)(nil),
6331                 (*NatDetCloseSessionInReply)(nil),
6332                 (*NatDetCloseSessionOut)(nil),
6333                 (*NatDetCloseSessionOutReply)(nil),
6334                 (*NatDetForward)(nil),
6335                 (*NatDetForwardReply)(nil),
6336                 (*NatDetMapDetails)(nil),
6337                 (*NatDetMapDump)(nil),
6338                 (*NatDetReverse)(nil),
6339                 (*NatDetReverseReply)(nil),
6340                 (*NatDetSessionDetails)(nil),
6341                 (*NatDetSessionDump)(nil),
6342                 (*NatGetAddrAndPortAllocAlg)(nil),
6343                 (*NatGetAddrAndPortAllocAlgReply)(nil),
6344                 (*NatGetMssClamping)(nil),
6345                 (*NatGetMssClampingReply)(nil),
6346                 (*NatGetTimeouts)(nil),
6347                 (*NatGetTimeoutsReply)(nil),
6348                 (*NatHaFlush)(nil),
6349                 (*NatHaFlushReply)(nil),
6350                 (*NatHaGetFailover)(nil),
6351                 (*NatHaGetFailoverReply)(nil),
6352                 (*NatHaGetListener)(nil),
6353                 (*NatHaGetListenerReply)(nil),
6354                 (*NatHaResync)(nil),
6355                 (*NatHaResyncCompletedEvent)(nil),
6356                 (*NatHaResyncReply)(nil),
6357                 (*NatHaSetFailover)(nil),
6358                 (*NatHaSetFailoverReply)(nil),
6359                 (*NatHaSetListener)(nil),
6360                 (*NatHaSetListenerReply)(nil),
6361                 (*NatIpfixEnableDisable)(nil),
6362                 (*NatIpfixEnableDisableReply)(nil),
6363                 (*NatSetAddrAndPortAllocAlg)(nil),
6364                 (*NatSetAddrAndPortAllocAlgReply)(nil),
6365                 (*NatSetLogLevel)(nil),
6366                 (*NatSetLogLevelReply)(nil),
6367                 (*NatSetMssClamping)(nil),
6368                 (*NatSetMssClampingReply)(nil),
6369                 (*NatSetTimeouts)(nil),
6370                 (*NatSetTimeoutsReply)(nil),
6371                 (*NatSetWorkers)(nil),
6372                 (*NatSetWorkersReply)(nil),
6373                 (*NatShowConfig)(nil),
6374                 (*NatShowConfigReply)(nil),
6375                 (*NatWorkerDetails)(nil),
6376                 (*NatWorkerDump)(nil),
6377         }
6378 }