eae0ab495cfce2035d7a79916821194cca3e3a64
[govpp.git] / binapi / udp_ping / udp_ping_rpc.ba.go
1 // Code generated by GoVPP's binapi-generator. DO NOT EDIT.
2
3 package udp_ping
4
5 import (
6         "context"
7         api "git.fd.io/govpp.git/api"
8 )
9
10 // RPCService defines RPC service  udp_ping.
11 type RPCService interface {
12         UDPPingAddDel(ctx context.Context, in *UDPPingAddDel) (*UDPPingAddDelReply, error)
13         UDPPingExport(ctx context.Context, in *UDPPingExport) (*UDPPingExportReply, error)
14 }
15
16 type serviceClient struct {
17         conn api.Connection
18 }
19
20 func NewServiceClient(conn api.Connection) RPCService {
21         return &serviceClient{conn}
22 }
23
24 func (c *serviceClient) UDPPingAddDel(ctx context.Context, in *UDPPingAddDel) (*UDPPingAddDelReply, error) {
25         out := new(UDPPingAddDelReply)
26         err := c.conn.Invoke(ctx, in, out)
27         if err != nil {
28                 return nil, err
29         }
30         return out, nil
31 }
32
33 func (c *serviceClient) UDPPingExport(ctx context.Context, in *UDPPingExport) (*UDPPingExportReply, error) {
34         out := new(UDPPingExportReply)
35         err := c.conn.Invoke(ctx, in, out)
36         if err != nil {
37                 return nil, err
38         }
39         return out, nil
40 }