1 // Code generated by GoVPP's binapi-generator. DO NOT EDIT.
10 api "git.fd.io/govpp.git/api"
11 vpe "git.fd.io/govpp.git/binapi/vpe"
14 // RPCService defines RPC service ip_neighbor.
15 type RPCService interface {
16 IPNeighborAddDel(ctx context.Context, in *IPNeighborAddDel) (*IPNeighborAddDelReply, error)
17 IPNeighborConfig(ctx context.Context, in *IPNeighborConfig) (*IPNeighborConfigReply, error)
18 IPNeighborDump(ctx context.Context, in *IPNeighborDump) (RPCService_IPNeighborDumpClient, error)
19 IPNeighborFlush(ctx context.Context, in *IPNeighborFlush) (*IPNeighborFlushReply, error)
20 IPNeighborReplaceBegin(ctx context.Context, in *IPNeighborReplaceBegin) (*IPNeighborReplaceBeginReply, error)
21 IPNeighborReplaceEnd(ctx context.Context, in *IPNeighborReplaceEnd) (*IPNeighborReplaceEndReply, error)
22 WantIPNeighborEvents(ctx context.Context, in *WantIPNeighborEvents) (*WantIPNeighborEventsReply, error)
25 type serviceClient struct {
29 func NewServiceClient(conn api.Connection) RPCService {
30 return &serviceClient{conn}
33 func (c *serviceClient) IPNeighborAddDel(ctx context.Context, in *IPNeighborAddDel) (*IPNeighborAddDelReply, error) {
34 out := new(IPNeighborAddDelReply)
35 err := c.conn.Invoke(ctx, in, out)
42 func (c *serviceClient) IPNeighborConfig(ctx context.Context, in *IPNeighborConfig) (*IPNeighborConfigReply, error) {
43 out := new(IPNeighborConfigReply)
44 err := c.conn.Invoke(ctx, in, out)
51 func (c *serviceClient) IPNeighborDump(ctx context.Context, in *IPNeighborDump) (RPCService_IPNeighborDumpClient, error) {
52 stream, err := c.conn.NewStream(ctx)
56 x := &serviceClient_IPNeighborDumpClient{stream}
57 if err := x.Stream.SendMsg(in); err != nil {
60 if err = x.Stream.SendMsg(&vpe.ControlPing{}); err != nil {
66 type RPCService_IPNeighborDumpClient interface {
67 Recv() (*IPNeighborDetails, error)
71 type serviceClient_IPNeighborDumpClient struct {
75 func (c *serviceClient_IPNeighborDumpClient) Recv() (*IPNeighborDetails, error) {
76 msg, err := c.Stream.RecvMsg()
80 switch m := msg.(type) {
81 case *IPNeighborDetails:
83 case *vpe.ControlPingReply:
86 return nil, fmt.Errorf("unexpected message: %T %v", m, m)
90 func (c *serviceClient) IPNeighborFlush(ctx context.Context, in *IPNeighborFlush) (*IPNeighborFlushReply, error) {
91 out := new(IPNeighborFlushReply)
92 err := c.conn.Invoke(ctx, in, out)
99 func (c *serviceClient) IPNeighborReplaceBegin(ctx context.Context, in *IPNeighborReplaceBegin) (*IPNeighborReplaceBeginReply, error) {
100 out := new(IPNeighborReplaceBeginReply)
101 err := c.conn.Invoke(ctx, in, out)
108 func (c *serviceClient) IPNeighborReplaceEnd(ctx context.Context, in *IPNeighborReplaceEnd) (*IPNeighborReplaceEndReply, error) {
109 out := new(IPNeighborReplaceEndReply)
110 err := c.conn.Invoke(ctx, in, out)
117 func (c *serviceClient) WantIPNeighborEvents(ctx context.Context, in *WantIPNeighborEvents) (*WantIPNeighborEventsReply, error) {
118 out := new(WantIPNeighborEventsReply)
119 err := c.conn.Invoke(ctx, in, out)