initial commit
[govpp.git] / examples / bin_api / memif / memif.go
1 // Package memif represents the VPP binary API of the 'memif' VPP module.
2 // DO NOT EDIT. Generated from 'bin_api/memif.api.json' on Fri, 21 Apr 2017 17:10:06 CEST.
3 package memif
4
5 import "gerrit.fd.io/r/govpp/api"
6
7 // VlApiVersion contains version of the API.
8 const VlAPIVersion = 0xadb63e82
9
10 // MemifCreate represents the VPP binary API message 'memif_create'.
11 // Generated from 'bin_api/memif.api.json', line 6:
12 //
13 //        ["memif_create",
14 //            ["u16", "_vl_msg_id"],
15 //            ["u32", "client_index"],
16 //            ["u32", "context"],
17 //            ["u8", "role"],
18 //            ["u64", "key"],
19 //            ["u8", "socket_filename", 128],
20 //            ["u32", "ring_size"],
21 //            ["u16", "buffer_size"],
22 //            ["u8", "hw_addr", 6],
23 //            {"crc" : "0x23fe3309"}
24 //        ],
25 //
26 type MemifCreate struct {
27         Role           uint8
28         Key            uint64
29         SocketFilename []byte `struc:"[128]byte"`
30         RingSize       uint32
31         BufferSize     uint16
32         HwAddr         []byte `struc:"[6]byte"`
33 }
34
35 func (*MemifCreate) GetMessageName() string {
36         return "memif_create"
37 }
38 func (*MemifCreate) GetMessageType() api.MessageType {
39         return api.RequestMessage
40 }
41 func (*MemifCreate) GetCrcString() string {
42         return "23fe3309"
43 }
44 func NewMemifCreate() api.Message {
45         return &MemifCreate{}
46 }
47
48 // MemifCreateReply represents the VPP binary API message 'memif_create_reply'.
49 // Generated from 'bin_api/memif.api.json', line 18:
50 //
51 //        ["memif_create_reply",
52 //            ["u16", "_vl_msg_id"],
53 //            ["u32", "context"],
54 //            ["i32", "retval"],
55 //            ["u32", "sw_if_index"],
56 //            {"crc" : "0x93d7498b"}
57 //        ],
58 //
59 type MemifCreateReply struct {
60         Retval    int32
61         SwIfIndex uint32
62 }
63
64 func (*MemifCreateReply) GetMessageName() string {
65         return "memif_create_reply"
66 }
67 func (*MemifCreateReply) GetMessageType() api.MessageType {
68         return api.ReplyMessage
69 }
70 func (*MemifCreateReply) GetCrcString() string {
71         return "93d7498b"
72 }
73 func NewMemifCreateReply() api.Message {
74         return &MemifCreateReply{}
75 }
76
77 // MemifDelete represents the VPP binary API message 'memif_delete'.
78 // Generated from 'bin_api/memif.api.json', line 25:
79 //
80 //        ["memif_delete",
81 //            ["u16", "_vl_msg_id"],
82 //            ["u32", "client_index"],
83 //            ["u32", "context"],
84 //            ["u32", "sw_if_index"],
85 //            {"crc" : "0x12814e3d"}
86 //        ],
87 //
88 type MemifDelete struct {
89         SwIfIndex uint32
90 }
91
92 func (*MemifDelete) GetMessageName() string {
93         return "memif_delete"
94 }
95 func (*MemifDelete) GetMessageType() api.MessageType {
96         return api.RequestMessage
97 }
98 func (*MemifDelete) GetCrcString() string {
99         return "12814e3d"
100 }
101 func NewMemifDelete() api.Message {
102         return &MemifDelete{}
103 }
104
105 // MemifDeleteReply represents the VPP binary API message 'memif_delete_reply'.
106 // Generated from 'bin_api/memif.api.json', line 32:
107 //
108 //        ["memif_delete_reply",
109 //            ["u16", "_vl_msg_id"],
110 //            ["u32", "context"],
111 //            ["i32", "retval"],
112 //            {"crc" : "0x72c9fa3c"}
113 //        ],
114 //
115 type MemifDeleteReply struct {
116         Retval int32
117 }
118
119 func (*MemifDeleteReply) GetMessageName() string {
120         return "memif_delete_reply"
121 }
122 func (*MemifDeleteReply) GetMessageType() api.MessageType {
123         return api.ReplyMessage
124 }
125 func (*MemifDeleteReply) GetCrcString() string {
126         return "72c9fa3c"
127 }
128 func NewMemifDeleteReply() api.Message {
129         return &MemifDeleteReply{}
130 }
131
132 // MemifDetails represents the VPP binary API message 'memif_details'.
133 // Generated from 'bin_api/memif.api.json', line 38:
134 //
135 //        ["memif_details",
136 //            ["u16", "_vl_msg_id"],
137 //            ["u32", "context"],
138 //            ["u32", "sw_if_index"],
139 //            ["u8", "if_name", 64],
140 //            ["u8", "hw_addr", 6],
141 //            ["u64", "key"],
142 //            ["u8", "role"],
143 //            ["u8", "socket_filename", 128],
144 //            ["u32", "ring_size"],
145 //            ["u16", "buffer_size"],
146 //            ["u8", "admin_up_down"],
147 //            ["u8", "link_up_down"],
148 //            {"crc" : "0xcf105583"}
149 //        ],
150 //
151 type MemifDetails struct {
152         SwIfIndex      uint32
153         IfName         []byte `struc:"[64]byte"`
154         HwAddr         []byte `struc:"[6]byte"`
155         Key            uint64
156         Role           uint8
157         SocketFilename []byte `struc:"[128]byte"`
158         RingSize       uint32
159         BufferSize     uint16
160         AdminUpDown    uint8
161         LinkUpDown     uint8
162 }
163
164 func (*MemifDetails) GetMessageName() string {
165         return "memif_details"
166 }
167 func (*MemifDetails) GetMessageType() api.MessageType {
168         return api.ReplyMessage
169 }
170 func (*MemifDetails) GetCrcString() string {
171         return "cf105583"
172 }
173 func NewMemifDetails() api.Message {
174         return &MemifDetails{}
175 }
176
177 // MemifDump represents the VPP binary API message 'memif_dump'.
178 // Generated from 'bin_api/memif.api.json', line 53:
179 //
180 //        ["memif_dump",
181 //            ["u16", "_vl_msg_id"],
182 //            ["u32", "client_index"],
183 //            ["u32", "context"],
184 //            {"crc" : "0x68d39e95"}
185 //        ]
186 //
187 type MemifDump struct {
188 }
189
190 func (*MemifDump) GetMessageName() string {
191         return "memif_dump"
192 }
193 func (*MemifDump) GetMessageType() api.MessageType {
194         return api.RequestMessage
195 }
196 func (*MemifDump) GetCrcString() string {
197         return "68d39e95"
198 }
199 func NewMemifDump() api.Message {
200         return &MemifDump{}
201 }