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 map.
14 type RPCService interface {
15 MapAddDelRule(ctx context.Context, in *MapAddDelRule) (*MapAddDelRuleReply, error)
16 MapAddDomain(ctx context.Context, in *MapAddDomain) (*MapAddDomainReply, error)
17 MapDelDomain(ctx context.Context, in *MapDelDomain) (*MapDelDomainReply, error)
18 MapDomainDump(ctx context.Context, in *MapDomainDump) (RPCService_MapDomainDumpClient, error)
19 MapIfEnableDisable(ctx context.Context, in *MapIfEnableDisable) (*MapIfEnableDisableReply, error)
20 MapParamAddDelPreResolve(ctx context.Context, in *MapParamAddDelPreResolve) (*MapParamAddDelPreResolveReply, error)
21 MapParamGet(ctx context.Context, in *MapParamGet) (*MapParamGetReply, error)
22 MapParamSetFragmentation(ctx context.Context, in *MapParamSetFragmentation) (*MapParamSetFragmentationReply, error)
23 MapParamSetICMP(ctx context.Context, in *MapParamSetICMP) (*MapParamSetICMPReply, error)
24 MapParamSetICMP6(ctx context.Context, in *MapParamSetICMP6) (*MapParamSetICMP6Reply, error)
25 MapParamSetSecurityCheck(ctx context.Context, in *MapParamSetSecurityCheck) (*MapParamSetSecurityCheckReply, error)
26 MapParamSetTCP(ctx context.Context, in *MapParamSetTCP) (*MapParamSetTCPReply, error)
27 MapParamSetTrafficClass(ctx context.Context, in *MapParamSetTrafficClass) (*MapParamSetTrafficClassReply, error)
28 MapRuleDump(ctx context.Context, in *MapRuleDump) (RPCService_MapRuleDumpClient, error)
29 MapSummaryStats(ctx context.Context, in *MapSummaryStats) (*MapSummaryStatsReply, error)
32 type serviceClient struct {
36 func NewServiceClient(conn api.Connection) RPCService {
37 return &serviceClient{conn}
40 func (c *serviceClient) MapAddDelRule(ctx context.Context, in *MapAddDelRule) (*MapAddDelRuleReply, error) {
41 out := new(MapAddDelRuleReply)
42 err := c.conn.Invoke(ctx, in, out)
49 func (c *serviceClient) MapAddDomain(ctx context.Context, in *MapAddDomain) (*MapAddDomainReply, error) {
50 out := new(MapAddDomainReply)
51 err := c.conn.Invoke(ctx, in, out)
58 func (c *serviceClient) MapDelDomain(ctx context.Context, in *MapDelDomain) (*MapDelDomainReply, error) {
59 out := new(MapDelDomainReply)
60 err := c.conn.Invoke(ctx, in, out)
67 func (c *serviceClient) MapDomainDump(ctx context.Context, in *MapDomainDump) (RPCService_MapDomainDumpClient, error) {
68 stream, err := c.conn.NewStream(ctx)
72 x := &serviceClient_MapDomainDumpClient{stream}
73 if err := x.Stream.SendMsg(in); err != nil {
76 if err = x.Stream.SendMsg(&vpe.ControlPing{}); err != nil {
82 type RPCService_MapDomainDumpClient interface {
83 Recv() (*MapDomainDetails, error)
87 type serviceClient_MapDomainDumpClient struct {
91 func (c *serviceClient_MapDomainDumpClient) Recv() (*MapDomainDetails, error) {
92 msg, err := c.Stream.RecvMsg()
96 switch m := msg.(type) {
97 case *MapDomainDetails:
99 case *vpe.ControlPingReply:
102 return nil, fmt.Errorf("unexpected message: %T %v", m, m)
106 func (c *serviceClient) MapIfEnableDisable(ctx context.Context, in *MapIfEnableDisable) (*MapIfEnableDisableReply, error) {
107 out := new(MapIfEnableDisableReply)
108 err := c.conn.Invoke(ctx, in, out)
115 func (c *serviceClient) MapParamAddDelPreResolve(ctx context.Context, in *MapParamAddDelPreResolve) (*MapParamAddDelPreResolveReply, error) {
116 out := new(MapParamAddDelPreResolveReply)
117 err := c.conn.Invoke(ctx, in, out)
124 func (c *serviceClient) MapParamGet(ctx context.Context, in *MapParamGet) (*MapParamGetReply, error) {
125 out := new(MapParamGetReply)
126 err := c.conn.Invoke(ctx, in, out)
133 func (c *serviceClient) MapParamSetFragmentation(ctx context.Context, in *MapParamSetFragmentation) (*MapParamSetFragmentationReply, error) {
134 out := new(MapParamSetFragmentationReply)
135 err := c.conn.Invoke(ctx, in, out)
142 func (c *serviceClient) MapParamSetICMP(ctx context.Context, in *MapParamSetICMP) (*MapParamSetICMPReply, error) {
143 out := new(MapParamSetICMPReply)
144 err := c.conn.Invoke(ctx, in, out)
151 func (c *serviceClient) MapParamSetICMP6(ctx context.Context, in *MapParamSetICMP6) (*MapParamSetICMP6Reply, error) {
152 out := new(MapParamSetICMP6Reply)
153 err := c.conn.Invoke(ctx, in, out)
160 func (c *serviceClient) MapParamSetSecurityCheck(ctx context.Context, in *MapParamSetSecurityCheck) (*MapParamSetSecurityCheckReply, error) {
161 out := new(MapParamSetSecurityCheckReply)
162 err := c.conn.Invoke(ctx, in, out)
169 func (c *serviceClient) MapParamSetTCP(ctx context.Context, in *MapParamSetTCP) (*MapParamSetTCPReply, error) {
170 out := new(MapParamSetTCPReply)
171 err := c.conn.Invoke(ctx, in, out)
178 func (c *serviceClient) MapParamSetTrafficClass(ctx context.Context, in *MapParamSetTrafficClass) (*MapParamSetTrafficClassReply, error) {
179 out := new(MapParamSetTrafficClassReply)
180 err := c.conn.Invoke(ctx, in, out)
187 func (c *serviceClient) MapRuleDump(ctx context.Context, in *MapRuleDump) (RPCService_MapRuleDumpClient, error) {
188 stream, err := c.conn.NewStream(ctx)
192 x := &serviceClient_MapRuleDumpClient{stream}
193 if err := x.Stream.SendMsg(in); err != nil {
196 if err = x.Stream.SendMsg(&vpe.ControlPing{}); err != nil {
202 type RPCService_MapRuleDumpClient interface {
203 Recv() (*MapRuleDetails, error)
207 type serviceClient_MapRuleDumpClient struct {
211 func (c *serviceClient_MapRuleDumpClient) Recv() (*MapRuleDetails, error) {
212 msg, err := c.Stream.RecvMsg()
216 switch m := msg.(type) {
217 case *MapRuleDetails:
219 case *vpe.ControlPingReply:
222 return nil, fmt.Errorf("unexpected message: %T %v", m, m)
226 func (c *serviceClient) MapSummaryStats(ctx context.Context, in *MapSummaryStats) (*MapSummaryStatsReply, error) {
227 out := new(MapSummaryStatsReply)
228 err := c.conn.Invoke(ctx, in, out)