1 // Code generated by GoVPP's binapi-generator. DO NOT EDIT.
8 api "git.fd.io/govpp.git/api"
9 vpe "git.fd.io/govpp.git/binapi/vpe"
13 // RPCService defines RPC service interface.
14 type RPCService interface {
15 CollectDetailedInterfaceStats(ctx context.Context, in *CollectDetailedInterfaceStats) (*CollectDetailedInterfaceStatsReply, error)
16 CreateLoopback(ctx context.Context, in *CreateLoopback) (*CreateLoopbackReply, error)
17 CreateLoopbackInstance(ctx context.Context, in *CreateLoopbackInstance) (*CreateLoopbackInstanceReply, error)
18 CreateSubif(ctx context.Context, in *CreateSubif) (*CreateSubifReply, error)
19 CreateVlanSubif(ctx context.Context, in *CreateVlanSubif) (*CreateVlanSubifReply, error)
20 DeleteLoopback(ctx context.Context, in *DeleteLoopback) (*DeleteLoopbackReply, error)
21 DeleteSubif(ctx context.Context, in *DeleteSubif) (*DeleteSubifReply, error)
22 HwInterfaceSetMtu(ctx context.Context, in *HwInterfaceSetMtu) (*HwInterfaceSetMtuReply, error)
23 InterfaceNameRenumber(ctx context.Context, in *InterfaceNameRenumber) (*InterfaceNameRenumberReply, error)
24 SwInterfaceAddDelAddress(ctx context.Context, in *SwInterfaceAddDelAddress) (*SwInterfaceAddDelAddressReply, error)
25 SwInterfaceAddDelMacAddress(ctx context.Context, in *SwInterfaceAddDelMacAddress) (*SwInterfaceAddDelMacAddressReply, error)
26 SwInterfaceAddressReplaceBegin(ctx context.Context, in *SwInterfaceAddressReplaceBegin) (*SwInterfaceAddressReplaceBeginReply, error)
27 SwInterfaceAddressReplaceEnd(ctx context.Context, in *SwInterfaceAddressReplaceEnd) (*SwInterfaceAddressReplaceEndReply, error)
28 SwInterfaceClearStats(ctx context.Context, in *SwInterfaceClearStats) (*SwInterfaceClearStatsReply, error)
29 SwInterfaceDump(ctx context.Context, in *SwInterfaceDump) (RPCService_SwInterfaceDumpClient, error)
30 SwInterfaceGetMacAddress(ctx context.Context, in *SwInterfaceGetMacAddress) (*SwInterfaceGetMacAddressReply, error)
31 SwInterfaceGetTable(ctx context.Context, in *SwInterfaceGetTable) (*SwInterfaceGetTableReply, error)
32 SwInterfaceRxPlacementDump(ctx context.Context, in *SwInterfaceRxPlacementDump) (RPCService_SwInterfaceRxPlacementDumpClient, error)
33 SwInterfaceSetFlags(ctx context.Context, in *SwInterfaceSetFlags) (*SwInterfaceSetFlagsReply, error)
34 SwInterfaceSetIPDirectedBroadcast(ctx context.Context, in *SwInterfaceSetIPDirectedBroadcast) (*SwInterfaceSetIPDirectedBroadcastReply, error)
35 SwInterfaceSetMacAddress(ctx context.Context, in *SwInterfaceSetMacAddress) (*SwInterfaceSetMacAddressReply, error)
36 SwInterfaceSetMtu(ctx context.Context, in *SwInterfaceSetMtu) (*SwInterfaceSetMtuReply, error)
37 SwInterfaceSetRxMode(ctx context.Context, in *SwInterfaceSetRxMode) (*SwInterfaceSetRxModeReply, error)
38 SwInterfaceSetRxPlacement(ctx context.Context, in *SwInterfaceSetRxPlacement) (*SwInterfaceSetRxPlacementReply, error)
39 SwInterfaceSetTable(ctx context.Context, in *SwInterfaceSetTable) (*SwInterfaceSetTableReply, error)
40 SwInterfaceSetUnnumbered(ctx context.Context, in *SwInterfaceSetUnnumbered) (*SwInterfaceSetUnnumberedReply, error)
41 SwInterfaceTagAddDel(ctx context.Context, in *SwInterfaceTagAddDel) (*SwInterfaceTagAddDelReply, error)
42 WantInterfaceEvents(ctx context.Context, in *WantInterfaceEvents) (*WantInterfaceEventsReply, error)
45 type serviceClient struct {
49 func NewServiceClient(conn api.Connection) RPCService {
50 return &serviceClient{conn}
53 func (c *serviceClient) CollectDetailedInterfaceStats(ctx context.Context, in *CollectDetailedInterfaceStats) (*CollectDetailedInterfaceStatsReply, error) {
54 out := new(CollectDetailedInterfaceStatsReply)
55 err := c.conn.Invoke(ctx, in, out)
62 func (c *serviceClient) CreateLoopback(ctx context.Context, in *CreateLoopback) (*CreateLoopbackReply, error) {
63 out := new(CreateLoopbackReply)
64 err := c.conn.Invoke(ctx, in, out)
71 func (c *serviceClient) CreateLoopbackInstance(ctx context.Context, in *CreateLoopbackInstance) (*CreateLoopbackInstanceReply, error) {
72 out := new(CreateLoopbackInstanceReply)
73 err := c.conn.Invoke(ctx, in, out)
80 func (c *serviceClient) CreateSubif(ctx context.Context, in *CreateSubif) (*CreateSubifReply, error) {
81 out := new(CreateSubifReply)
82 err := c.conn.Invoke(ctx, in, out)
89 func (c *serviceClient) CreateVlanSubif(ctx context.Context, in *CreateVlanSubif) (*CreateVlanSubifReply, error) {
90 out := new(CreateVlanSubifReply)
91 err := c.conn.Invoke(ctx, in, out)
98 func (c *serviceClient) DeleteLoopback(ctx context.Context, in *DeleteLoopback) (*DeleteLoopbackReply, error) {
99 out := new(DeleteLoopbackReply)
100 err := c.conn.Invoke(ctx, in, out)
107 func (c *serviceClient) DeleteSubif(ctx context.Context, in *DeleteSubif) (*DeleteSubifReply, error) {
108 out := new(DeleteSubifReply)
109 err := c.conn.Invoke(ctx, in, out)
116 func (c *serviceClient) HwInterfaceSetMtu(ctx context.Context, in *HwInterfaceSetMtu) (*HwInterfaceSetMtuReply, error) {
117 out := new(HwInterfaceSetMtuReply)
118 err := c.conn.Invoke(ctx, in, out)
125 func (c *serviceClient) InterfaceNameRenumber(ctx context.Context, in *InterfaceNameRenumber) (*InterfaceNameRenumberReply, error) {
126 out := new(InterfaceNameRenumberReply)
127 err := c.conn.Invoke(ctx, in, out)
134 func (c *serviceClient) SwInterfaceAddDelAddress(ctx context.Context, in *SwInterfaceAddDelAddress) (*SwInterfaceAddDelAddressReply, error) {
135 out := new(SwInterfaceAddDelAddressReply)
136 err := c.conn.Invoke(ctx, in, out)
143 func (c *serviceClient) SwInterfaceAddDelMacAddress(ctx context.Context, in *SwInterfaceAddDelMacAddress) (*SwInterfaceAddDelMacAddressReply, error) {
144 out := new(SwInterfaceAddDelMacAddressReply)
145 err := c.conn.Invoke(ctx, in, out)
152 func (c *serviceClient) SwInterfaceAddressReplaceBegin(ctx context.Context, in *SwInterfaceAddressReplaceBegin) (*SwInterfaceAddressReplaceBeginReply, error) {
153 out := new(SwInterfaceAddressReplaceBeginReply)
154 err := c.conn.Invoke(ctx, in, out)
161 func (c *serviceClient) SwInterfaceAddressReplaceEnd(ctx context.Context, in *SwInterfaceAddressReplaceEnd) (*SwInterfaceAddressReplaceEndReply, error) {
162 out := new(SwInterfaceAddressReplaceEndReply)
163 err := c.conn.Invoke(ctx, in, out)
170 func (c *serviceClient) SwInterfaceClearStats(ctx context.Context, in *SwInterfaceClearStats) (*SwInterfaceClearStatsReply, error) {
171 out := new(SwInterfaceClearStatsReply)
172 err := c.conn.Invoke(ctx, in, out)
179 func (c *serviceClient) SwInterfaceDump(ctx context.Context, in *SwInterfaceDump) (RPCService_SwInterfaceDumpClient, error) {
180 stream, err := c.conn.NewStream(ctx)
184 x := &serviceClient_SwInterfaceDumpClient{stream}
185 if err := x.Stream.SendMsg(in); err != nil {
188 if err = x.Stream.SendMsg(&vpe.ControlPing{}); err != nil {
194 type RPCService_SwInterfaceDumpClient interface {
195 Recv() (*SwInterfaceDetails, error)
199 type serviceClient_SwInterfaceDumpClient struct {
203 func (c *serviceClient_SwInterfaceDumpClient) Recv() (*SwInterfaceDetails, error) {
204 msg, err := c.Stream.RecvMsg()
208 switch m := msg.(type) {
209 case *SwInterfaceDetails:
211 case *vpe.ControlPingReply:
214 return nil, fmt.Errorf("unexpected message: %T %v", m, m)
218 func (c *serviceClient) SwInterfaceGetMacAddress(ctx context.Context, in *SwInterfaceGetMacAddress) (*SwInterfaceGetMacAddressReply, error) {
219 out := new(SwInterfaceGetMacAddressReply)
220 err := c.conn.Invoke(ctx, in, out)
227 func (c *serviceClient) SwInterfaceGetTable(ctx context.Context, in *SwInterfaceGetTable) (*SwInterfaceGetTableReply, error) {
228 out := new(SwInterfaceGetTableReply)
229 err := c.conn.Invoke(ctx, in, out)
236 func (c *serviceClient) SwInterfaceRxPlacementDump(ctx context.Context, in *SwInterfaceRxPlacementDump) (RPCService_SwInterfaceRxPlacementDumpClient, error) {
237 stream, err := c.conn.NewStream(ctx)
241 x := &serviceClient_SwInterfaceRxPlacementDumpClient{stream}
242 if err := x.Stream.SendMsg(in); err != nil {
245 if err = x.Stream.SendMsg(&vpe.ControlPing{}); err != nil {
251 type RPCService_SwInterfaceRxPlacementDumpClient interface {
252 Recv() (*SwInterfaceRxPlacementDetails, error)
256 type serviceClient_SwInterfaceRxPlacementDumpClient struct {
260 func (c *serviceClient_SwInterfaceRxPlacementDumpClient) Recv() (*SwInterfaceRxPlacementDetails, error) {
261 msg, err := c.Stream.RecvMsg()
265 switch m := msg.(type) {
266 case *SwInterfaceRxPlacementDetails:
268 case *vpe.ControlPingReply:
271 return nil, fmt.Errorf("unexpected message: %T %v", m, m)
275 func (c *serviceClient) SwInterfaceSetFlags(ctx context.Context, in *SwInterfaceSetFlags) (*SwInterfaceSetFlagsReply, error) {
276 out := new(SwInterfaceSetFlagsReply)
277 err := c.conn.Invoke(ctx, in, out)
284 func (c *serviceClient) SwInterfaceSetIPDirectedBroadcast(ctx context.Context, in *SwInterfaceSetIPDirectedBroadcast) (*SwInterfaceSetIPDirectedBroadcastReply, error) {
285 out := new(SwInterfaceSetIPDirectedBroadcastReply)
286 err := c.conn.Invoke(ctx, in, out)
293 func (c *serviceClient) SwInterfaceSetMacAddress(ctx context.Context, in *SwInterfaceSetMacAddress) (*SwInterfaceSetMacAddressReply, error) {
294 out := new(SwInterfaceSetMacAddressReply)
295 err := c.conn.Invoke(ctx, in, out)
302 func (c *serviceClient) SwInterfaceSetMtu(ctx context.Context, in *SwInterfaceSetMtu) (*SwInterfaceSetMtuReply, error) {
303 out := new(SwInterfaceSetMtuReply)
304 err := c.conn.Invoke(ctx, in, out)
311 func (c *serviceClient) SwInterfaceSetRxMode(ctx context.Context, in *SwInterfaceSetRxMode) (*SwInterfaceSetRxModeReply, error) {
312 out := new(SwInterfaceSetRxModeReply)
313 err := c.conn.Invoke(ctx, in, out)
320 func (c *serviceClient) SwInterfaceSetRxPlacement(ctx context.Context, in *SwInterfaceSetRxPlacement) (*SwInterfaceSetRxPlacementReply, error) {
321 out := new(SwInterfaceSetRxPlacementReply)
322 err := c.conn.Invoke(ctx, in, out)
329 func (c *serviceClient) SwInterfaceSetTable(ctx context.Context, in *SwInterfaceSetTable) (*SwInterfaceSetTableReply, error) {
330 out := new(SwInterfaceSetTableReply)
331 err := c.conn.Invoke(ctx, in, out)
338 func (c *serviceClient) SwInterfaceSetUnnumbered(ctx context.Context, in *SwInterfaceSetUnnumbered) (*SwInterfaceSetUnnumberedReply, error) {
339 out := new(SwInterfaceSetUnnumberedReply)
340 err := c.conn.Invoke(ctx, in, out)
347 func (c *serviceClient) SwInterfaceTagAddDel(ctx context.Context, in *SwInterfaceTagAddDel) (*SwInterfaceTagAddDelReply, error) {
348 out := new(SwInterfaceTagAddDelReply)
349 err := c.conn.Invoke(ctx, in, out)
356 func (c *serviceClient) WantInterfaceEvents(ctx context.Context, in *WantInterfaceEvents) (*WantInterfaceEventsReply, error) {
357 out := new(WantInterfaceEventsReply)
358 err := c.conn.Invoke(ctx, in, out)