Fix events for mock adapter
[govpp.git] / examples / bin_api / tap / tap.go
1 // Code generated by govpp binapi-generator DO NOT EDIT.
2 // Package tap represents the VPP binary API of the 'tap' VPP module.
3 // Generated from '../../bin_api/tap.api.json'
4 package tap
5
6 import "git.fd.io/govpp.git/api"
7
8 // VlApiVersion contains version of the API.
9 const VlAPIVersion = 0x4eaa2b5a
10
11 // TapConnect represents the VPP binary API message 'tap_connect'.
12 // Generated from '../../bin_api/tap.api.json', line 6:
13 //
14 //        ["tap_connect",
15 //            ["u16", "_vl_msg_id"],
16 //            ["u32", "client_index"],
17 //            ["u32", "context"],
18 //            ["u8", "use_random_mac"],
19 //            ["u8", "tap_name", 64],
20 //            ["u8", "mac_address", 6],
21 //            ["u8", "renumber"],
22 //            ["u32", "custom_dev_instance"],
23 //            ["u8", "ip4_address_set"],
24 //            ["u8", "ip4_address", 4],
25 //            ["u8", "ip4_mask_width"],
26 //            ["u8", "ip6_address_set"],
27 //            ["u8", "ip6_address", 16],
28 //            ["u8", "ip6_mask_width"],
29 //            ["u8", "tag", 64],
30 //            {"crc" : "0x91720de3"}
31 //        ],
32 //
33 type TapConnect struct {
34         UseRandomMac      uint8
35         TapName           []byte `struc:"[64]byte"`
36         MacAddress        []byte `struc:"[6]byte"`
37         Renumber          uint8
38         CustomDevInstance uint32
39         IP4AddressSet     uint8
40         IP4Address        []byte `struc:"[4]byte"`
41         IP4MaskWidth      uint8
42         IP6AddressSet     uint8
43         IP6Address        []byte `struc:"[16]byte"`
44         IP6MaskWidth      uint8
45         Tag               []byte `struc:"[64]byte"`
46 }
47
48 func (*TapConnect) GetMessageName() string {
49         return "tap_connect"
50 }
51 func (*TapConnect) GetMessageType() api.MessageType {
52         return api.RequestMessage
53 }
54 func (*TapConnect) GetCrcString() string {
55         return "91720de3"
56 }
57 func NewTapConnect() api.Message {
58         return &TapConnect{}
59 }
60
61 // TapConnectReply represents the VPP binary API message 'tap_connect_reply'.
62 // Generated from '../../bin_api/tap.api.json', line 24:
63 //
64 //        ["tap_connect_reply",
65 //            ["u16", "_vl_msg_id"],
66 //            ["u32", "context"],
67 //            ["i32", "retval"],
68 //            ["u32", "sw_if_index"],
69 //            {"crc" : "0xf47feac1"}
70 //        ],
71 //
72 type TapConnectReply struct {
73         Retval    int32
74         SwIfIndex uint32
75 }
76
77 func (*TapConnectReply) GetMessageName() string {
78         return "tap_connect_reply"
79 }
80 func (*TapConnectReply) GetMessageType() api.MessageType {
81         return api.ReplyMessage
82 }
83 func (*TapConnectReply) GetCrcString() string {
84         return "f47feac1"
85 }
86 func NewTapConnectReply() api.Message {
87         return &TapConnectReply{}
88 }
89
90 // TapModify represents the VPP binary API message 'tap_modify'.
91 // Generated from '../../bin_api/tap.api.json', line 31:
92 //
93 //        ["tap_modify",
94 //            ["u16", "_vl_msg_id"],
95 //            ["u32", "client_index"],
96 //            ["u32", "context"],
97 //            ["u32", "sw_if_index"],
98 //            ["u8", "use_random_mac"],
99 //            ["u8", "tap_name", 64],
100 //            ["u8", "mac_address", 6],
101 //            ["u8", "renumber"],
102 //            ["u32", "custom_dev_instance"],
103 //            {"crc" : "0x8abcd5f3"}
104 //        ],
105 //
106 type TapModify struct {
107         SwIfIndex         uint32
108         UseRandomMac      uint8
109         TapName           []byte `struc:"[64]byte"`
110         MacAddress        []byte `struc:"[6]byte"`
111         Renumber          uint8
112         CustomDevInstance uint32
113 }
114
115 func (*TapModify) GetMessageName() string {
116         return "tap_modify"
117 }
118 func (*TapModify) GetMessageType() api.MessageType {
119         return api.RequestMessage
120 }
121 func (*TapModify) GetCrcString() string {
122         return "8abcd5f3"
123 }
124 func NewTapModify() api.Message {
125         return &TapModify{}
126 }
127
128 // TapModifyReply represents the VPP binary API message 'tap_modify_reply'.
129 // Generated from '../../bin_api/tap.api.json', line 43:
130 //
131 //        ["tap_modify_reply",
132 //            ["u16", "_vl_msg_id"],
133 //            ["u32", "context"],
134 //            ["i32", "retval"],
135 //            ["u32", "sw_if_index"],
136 //            {"crc" : "0x00aaf940"}
137 //        ],
138 //
139 type TapModifyReply struct {
140         Retval    int32
141         SwIfIndex uint32
142 }
143
144 func (*TapModifyReply) GetMessageName() string {
145         return "tap_modify_reply"
146 }
147 func (*TapModifyReply) GetMessageType() api.MessageType {
148         return api.ReplyMessage
149 }
150 func (*TapModifyReply) GetCrcString() string {
151         return "00aaf940"
152 }
153 func NewTapModifyReply() api.Message {
154         return &TapModifyReply{}
155 }
156
157 // TapDelete represents the VPP binary API message 'tap_delete'.
158 // Generated from '../../bin_api/tap.api.json', line 50:
159 //
160 //        ["tap_delete",
161 //            ["u16", "_vl_msg_id"],
162 //            ["u32", "client_index"],
163 //            ["u32", "context"],
164 //            ["u32", "sw_if_index"],
165 //            {"crc" : "0xe99d41c1"}
166 //        ],
167 //
168 type TapDelete struct {
169         SwIfIndex uint32
170 }
171
172 func (*TapDelete) GetMessageName() string {
173         return "tap_delete"
174 }
175 func (*TapDelete) GetMessageType() api.MessageType {
176         return api.RequestMessage
177 }
178 func (*TapDelete) GetCrcString() string {
179         return "e99d41c1"
180 }
181 func NewTapDelete() api.Message {
182         return &TapDelete{}
183 }
184
185 // TapDeleteReply represents the VPP binary API message 'tap_delete_reply'.
186 // Generated from '../../bin_api/tap.api.json', line 57:
187 //
188 //        ["tap_delete_reply",
189 //            ["u16", "_vl_msg_id"],
190 //            ["u32", "context"],
191 //            ["i32", "retval"],
192 //            {"crc" : "0x0e47d140"}
193 //        ],
194 //
195 type TapDeleteReply struct {
196         Retval int32
197 }
198
199 func (*TapDeleteReply) GetMessageName() string {
200         return "tap_delete_reply"
201 }
202 func (*TapDeleteReply) GetMessageType() api.MessageType {
203         return api.ReplyMessage
204 }
205 func (*TapDeleteReply) GetCrcString() string {
206         return "0e47d140"
207 }
208 func NewTapDeleteReply() api.Message {
209         return &TapDeleteReply{}
210 }
211
212 // SwInterfaceTapDump represents the VPP binary API message 'sw_interface_tap_dump'.
213 // Generated from '../../bin_api/tap.api.json', line 63:
214 //
215 //        ["sw_interface_tap_dump",
216 //            ["u16", "_vl_msg_id"],
217 //            ["u32", "client_index"],
218 //            ["u32", "context"],
219 //            {"crc" : "0xbc6ddbe2"}
220 //        ],
221 //
222 type SwInterfaceTapDump struct {
223 }
224
225 func (*SwInterfaceTapDump) GetMessageName() string {
226         return "sw_interface_tap_dump"
227 }
228 func (*SwInterfaceTapDump) GetMessageType() api.MessageType {
229         return api.RequestMessage
230 }
231 func (*SwInterfaceTapDump) GetCrcString() string {
232         return "bc6ddbe2"
233 }
234 func NewSwInterfaceTapDump() api.Message {
235         return &SwInterfaceTapDump{}
236 }
237
238 // SwInterfaceTapDetails represents the VPP binary API message 'sw_interface_tap_details'.
239 // Generated from '../../bin_api/tap.api.json', line 69:
240 //
241 //        ["sw_interface_tap_details",
242 //            ["u16", "_vl_msg_id"],
243 //            ["u32", "context"],
244 //            ["u32", "sw_if_index"],
245 //            ["u8", "dev_name", 64],
246 //            {"crc" : "0x0df07bc3"}
247 //        ]
248 //
249 type SwInterfaceTapDetails struct {
250         SwIfIndex uint32
251         DevName   []byte `struc:"[64]byte"`
252 }
253
254 func (*SwInterfaceTapDetails) GetMessageName() string {
255         return "sw_interface_tap_details"
256 }
257 func (*SwInterfaceTapDetails) GetMessageType() api.MessageType {
258         return api.ReplyMessage
259 }
260 func (*SwInterfaceTapDetails) GetCrcString() string {
261         return "0df07bc3"
262 }
263 func NewSwInterfaceTapDetails() api.Message {
264         return &SwInterfaceTapDetails{}
265 }