0 | 0 |
// Code generated by protoc-gen-go. DO NOT EDIT.
|
1 | 1 |
// source: addsvc.proto
|
2 | 2 |
|
3 | |
/*
|
4 | |
Package pb is a generated protocol buffer package.
|
5 | |
|
6 | |
It is generated from these files:
|
7 | |
addsvc.proto
|
8 | |
|
9 | |
It has these top-level messages:
|
10 | |
SumRequest
|
11 | |
SumReply
|
12 | |
ConcatRequest
|
13 | |
ConcatReply
|
14 | |
*/
|
15 | 3 |
package pb
|
16 | 4 |
|
17 | |
import proto "github.com/golang/protobuf/proto"
|
18 | |
import fmt "fmt"
|
19 | |
import math "math"
|
20 | |
|
21 | 5 |
import (
|
22 | |
context "golang.org/x/net/context"
|
|
6 |
context "context"
|
|
7 |
fmt "fmt"
|
|
8 |
proto "github.com/golang/protobuf/proto"
|
23 | 9 |
grpc "google.golang.org/grpc"
|
|
10 |
math "math"
|
24 | 11 |
)
|
25 | 12 |
|
26 | 13 |
// Reference imports to suppress errors if they are not otherwise used.
|
|
32 | 19 |
// is compatible with the proto package it is being compiled against.
|
33 | 20 |
// A compilation error at this line likely means your copy of the
|
34 | 21 |
// proto package needs to be updated.
|
35 | |
const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
|
|
22 |
const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package
|
36 | 23 |
|
37 | 24 |
// The sum request contains two parameters.
|
38 | 25 |
type SumRequest struct {
|
39 | |
A int64 `protobuf:"varint,1,opt,name=a" json:"a,omitempty"`
|
40 | |
B int64 `protobuf:"varint,2,opt,name=b" json:"b,omitempty"`
|
41 | |
}
|
42 | |
|
43 | |
func (m *SumRequest) Reset() { *m = SumRequest{} }
|
44 | |
func (m *SumRequest) String() string { return proto.CompactTextString(m) }
|
45 | |
func (*SumRequest) ProtoMessage() {}
|
46 | |
func (*SumRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
|
|
26 |
A int64 `protobuf:"varint,1,opt,name=a,proto3" json:"a,omitempty"`
|
|
27 |
B int64 `protobuf:"varint,2,opt,name=b,proto3" json:"b,omitempty"`
|
|
28 |
XXX_NoUnkeyedLiteral struct{} `json:"-"`
|
|
29 |
XXX_unrecognized []byte `json:"-"`
|
|
30 |
XXX_sizecache int32 `json:"-"`
|
|
31 |
}
|
|
32 |
|
|
33 |
func (m *SumRequest) Reset() { *m = SumRequest{} }
|
|
34 |
func (m *SumRequest) String() string { return proto.CompactTextString(m) }
|
|
35 |
func (*SumRequest) ProtoMessage() {}
|
|
36 |
func (*SumRequest) Descriptor() ([]byte, []int) {
|
|
37 |
return fileDescriptor_174367f558d60c26, []int{0}
|
|
38 |
}
|
|
39 |
|
|
40 |
func (m *SumRequest) XXX_Unmarshal(b []byte) error {
|
|
41 |
return xxx_messageInfo_SumRequest.Unmarshal(m, b)
|
|
42 |
}
|
|
43 |
func (m *SumRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
|
|
44 |
return xxx_messageInfo_SumRequest.Marshal(b, m, deterministic)
|
|
45 |
}
|
|
46 |
func (m *SumRequest) XXX_Merge(src proto.Message) {
|
|
47 |
xxx_messageInfo_SumRequest.Merge(m, src)
|
|
48 |
}
|
|
49 |
func (m *SumRequest) XXX_Size() int {
|
|
50 |
return xxx_messageInfo_SumRequest.Size(m)
|
|
51 |
}
|
|
52 |
func (m *SumRequest) XXX_DiscardUnknown() {
|
|
53 |
xxx_messageInfo_SumRequest.DiscardUnknown(m)
|
|
54 |
}
|
|
55 |
|
|
56 |
var xxx_messageInfo_SumRequest proto.InternalMessageInfo
|
47 | 57 |
|
48 | 58 |
func (m *SumRequest) GetA() int64 {
|
49 | 59 |
if m != nil {
|
|
61 | 71 |
|
62 | 72 |
// The sum response contains the result of the calculation.
|
63 | 73 |
type SumReply struct {
|
64 | |
V int64 `protobuf:"varint,1,opt,name=v" json:"v,omitempty"`
|
65 | |
Err string `protobuf:"bytes,2,opt,name=err" json:"err,omitempty"`
|
66 | |
}
|
67 | |
|
68 | |
func (m *SumReply) Reset() { *m = SumReply{} }
|
69 | |
func (m *SumReply) String() string { return proto.CompactTextString(m) }
|
70 | |
func (*SumReply) ProtoMessage() {}
|
71 | |
func (*SumReply) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
|
|
74 |
V int64 `protobuf:"varint,1,opt,name=v,proto3" json:"v,omitempty"`
|
|
75 |
Err string `protobuf:"bytes,2,opt,name=err,proto3" json:"err,omitempty"`
|
|
76 |
XXX_NoUnkeyedLiteral struct{} `json:"-"`
|
|
77 |
XXX_unrecognized []byte `json:"-"`
|
|
78 |
XXX_sizecache int32 `json:"-"`
|
|
79 |
}
|
|
80 |
|
|
81 |
func (m *SumReply) Reset() { *m = SumReply{} }
|
|
82 |
func (m *SumReply) String() string { return proto.CompactTextString(m) }
|
|
83 |
func (*SumReply) ProtoMessage() {}
|
|
84 |
func (*SumReply) Descriptor() ([]byte, []int) {
|
|
85 |
return fileDescriptor_174367f558d60c26, []int{1}
|
|
86 |
}
|
|
87 |
|
|
88 |
func (m *SumReply) XXX_Unmarshal(b []byte) error {
|
|
89 |
return xxx_messageInfo_SumReply.Unmarshal(m, b)
|
|
90 |
}
|
|
91 |
func (m *SumReply) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
|
|
92 |
return xxx_messageInfo_SumReply.Marshal(b, m, deterministic)
|
|
93 |
}
|
|
94 |
func (m *SumReply) XXX_Merge(src proto.Message) {
|
|
95 |
xxx_messageInfo_SumReply.Merge(m, src)
|
|
96 |
}
|
|
97 |
func (m *SumReply) XXX_Size() int {
|
|
98 |
return xxx_messageInfo_SumReply.Size(m)
|
|
99 |
}
|
|
100 |
func (m *SumReply) XXX_DiscardUnknown() {
|
|
101 |
xxx_messageInfo_SumReply.DiscardUnknown(m)
|
|
102 |
}
|
|
103 |
|
|
104 |
var xxx_messageInfo_SumReply proto.InternalMessageInfo
|
72 | 105 |
|
73 | 106 |
func (m *SumReply) GetV() int64 {
|
74 | 107 |
if m != nil {
|
|
86 | 119 |
|
87 | 120 |
// The Concat request contains two parameters.
|
88 | 121 |
type ConcatRequest struct {
|
89 | |
A string `protobuf:"bytes,1,opt,name=a" json:"a,omitempty"`
|
90 | |
B string `protobuf:"bytes,2,opt,name=b" json:"b,omitempty"`
|
91 | |
}
|
92 | |
|
93 | |
func (m *ConcatRequest) Reset() { *m = ConcatRequest{} }
|
94 | |
func (m *ConcatRequest) String() string { return proto.CompactTextString(m) }
|
95 | |
func (*ConcatRequest) ProtoMessage() {}
|
96 | |
func (*ConcatRequest) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{2} }
|
|
122 |
A string `protobuf:"bytes,1,opt,name=a,proto3" json:"a,omitempty"`
|
|
123 |
B string `protobuf:"bytes,2,opt,name=b,proto3" json:"b,omitempty"`
|
|
124 |
XXX_NoUnkeyedLiteral struct{} `json:"-"`
|
|
125 |
XXX_unrecognized []byte `json:"-"`
|
|
126 |
XXX_sizecache int32 `json:"-"`
|
|
127 |
}
|
|
128 |
|
|
129 |
func (m *ConcatRequest) Reset() { *m = ConcatRequest{} }
|
|
130 |
func (m *ConcatRequest) String() string { return proto.CompactTextString(m) }
|
|
131 |
func (*ConcatRequest) ProtoMessage() {}
|
|
132 |
func (*ConcatRequest) Descriptor() ([]byte, []int) {
|
|
133 |
return fileDescriptor_174367f558d60c26, []int{2}
|
|
134 |
}
|
|
135 |
|
|
136 |
func (m *ConcatRequest) XXX_Unmarshal(b []byte) error {
|
|
137 |
return xxx_messageInfo_ConcatRequest.Unmarshal(m, b)
|
|
138 |
}
|
|
139 |
func (m *ConcatRequest) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
|
|
140 |
return xxx_messageInfo_ConcatRequest.Marshal(b, m, deterministic)
|
|
141 |
}
|
|
142 |
func (m *ConcatRequest) XXX_Merge(src proto.Message) {
|
|
143 |
xxx_messageInfo_ConcatRequest.Merge(m, src)
|
|
144 |
}
|
|
145 |
func (m *ConcatRequest) XXX_Size() int {
|
|
146 |
return xxx_messageInfo_ConcatRequest.Size(m)
|
|
147 |
}
|
|
148 |
func (m *ConcatRequest) XXX_DiscardUnknown() {
|
|
149 |
xxx_messageInfo_ConcatRequest.DiscardUnknown(m)
|
|
150 |
}
|
|
151 |
|
|
152 |
var xxx_messageInfo_ConcatRequest proto.InternalMessageInfo
|
97 | 153 |
|
98 | 154 |
func (m *ConcatRequest) GetA() string {
|
99 | 155 |
if m != nil {
|
|
111 | 167 |
|
112 | 168 |
// The Concat response contains the result of the concatenation.
|
113 | 169 |
type ConcatReply struct {
|
114 | |
V string `protobuf:"bytes,1,opt,name=v" json:"v,omitempty"`
|
115 | |
Err string `protobuf:"bytes,2,opt,name=err" json:"err,omitempty"`
|
116 | |
}
|
117 | |
|
118 | |
func (m *ConcatReply) Reset() { *m = ConcatReply{} }
|
119 | |
func (m *ConcatReply) String() string { return proto.CompactTextString(m) }
|
120 | |
func (*ConcatReply) ProtoMessage() {}
|
121 | |
func (*ConcatReply) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{3} }
|
|
170 |
V string `protobuf:"bytes,1,opt,name=v,proto3" json:"v,omitempty"`
|
|
171 |
Err string `protobuf:"bytes,2,opt,name=err,proto3" json:"err,omitempty"`
|
|
172 |
XXX_NoUnkeyedLiteral struct{} `json:"-"`
|
|
173 |
XXX_unrecognized []byte `json:"-"`
|
|
174 |
XXX_sizecache int32 `json:"-"`
|
|
175 |
}
|
|
176 |
|
|
177 |
func (m *ConcatReply) Reset() { *m = ConcatReply{} }
|
|
178 |
func (m *ConcatReply) String() string { return proto.CompactTextString(m) }
|
|
179 |
func (*ConcatReply) ProtoMessage() {}
|
|
180 |
func (*ConcatReply) Descriptor() ([]byte, []int) {
|
|
181 |
return fileDescriptor_174367f558d60c26, []int{3}
|
|
182 |
}
|
|
183 |
|
|
184 |
func (m *ConcatReply) XXX_Unmarshal(b []byte) error {
|
|
185 |
return xxx_messageInfo_ConcatReply.Unmarshal(m, b)
|
|
186 |
}
|
|
187 |
func (m *ConcatReply) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
|
|
188 |
return xxx_messageInfo_ConcatReply.Marshal(b, m, deterministic)
|
|
189 |
}
|
|
190 |
func (m *ConcatReply) XXX_Merge(src proto.Message) {
|
|
191 |
xxx_messageInfo_ConcatReply.Merge(m, src)
|
|
192 |
}
|
|
193 |
func (m *ConcatReply) XXX_Size() int {
|
|
194 |
return xxx_messageInfo_ConcatReply.Size(m)
|
|
195 |
}
|
|
196 |
func (m *ConcatReply) XXX_DiscardUnknown() {
|
|
197 |
xxx_messageInfo_ConcatReply.DiscardUnknown(m)
|
|
198 |
}
|
|
199 |
|
|
200 |
var xxx_messageInfo_ConcatReply proto.InternalMessageInfo
|
122 | 201 |
|
123 | 202 |
func (m *ConcatReply) GetV() string {
|
124 | 203 |
if m != nil {
|
|
141 | 220 |
proto.RegisterType((*ConcatReply)(nil), "pb.ConcatReply")
|
142 | 221 |
}
|
143 | 222 |
|
|
223 |
func init() { proto.RegisterFile("addsvc.proto", fileDescriptor_174367f558d60c26) }
|
|
224 |
|
|
225 |
var fileDescriptor_174367f558d60c26 = []byte{
|
|
226 |
// 189 bytes of a gzipped FileDescriptorProto
|
|
227 |
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xe2, 0x49, 0x4c, 0x49, 0x29,
|
|
228 |
0x2e, 0x4b, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x62, 0x2a, 0x48, 0x52, 0xd2, 0xe0, 0xe2,
|
|
229 |
0x0a, 0x2e, 0xcd, 0x0d, 0x4a, 0x2d, 0x2c, 0x4d, 0x2d, 0x2e, 0x11, 0xe2, 0xe1, 0x62, 0x4c, 0x94,
|
|
230 |
0x60, 0x54, 0x60, 0xd4, 0x60, 0x0e, 0x62, 0x4c, 0x04, 0xf1, 0x92, 0x24, 0x98, 0x20, 0xbc, 0x24,
|
|
231 |
0x25, 0x2d, 0x2e, 0x0e, 0xb0, 0xca, 0x82, 0x9c, 0x4a, 0x90, 0x4c, 0x19, 0x4c, 0x5d, 0x99, 0x90,
|
|
232 |
0x00, 0x17, 0x73, 0x6a, 0x51, 0x11, 0x58, 0x25, 0x67, 0x10, 0x88, 0xa9, 0xa4, 0xcd, 0xc5, 0xeb,
|
|
233 |
0x9c, 0x9f, 0x97, 0x9c, 0x58, 0x82, 0x61, 0x30, 0x27, 0x8a, 0xc1, 0x9c, 0x20, 0x83, 0x75, 0xb9,
|
|
234 |
0xb8, 0x61, 0x8a, 0x51, 0xcc, 0xe6, 0xc4, 0x6a, 0xb6, 0x51, 0x0c, 0x17, 0xb3, 0x63, 0x4a, 0x8a,
|
|
235 |
0x90, 0x2a, 0x17, 0x73, 0x70, 0x69, 0xae, 0x10, 0x9f, 0x5e, 0x41, 0x92, 0x1e, 0xc2, 0x07, 0x52,
|
|
236 |
0x3c, 0x70, 0x7e, 0x41, 0x4e, 0xa5, 0x12, 0x83, 0x90, 0x1e, 0x17, 0x1b, 0xc4, 0x70, 0x21, 0x41,
|
|
237 |
0x90, 0x0c, 0x8a, 0xab, 0xa4, 0xf8, 0x91, 0x85, 0xc0, 0xea, 0x93, 0xd8, 0xc0, 0x41, 0x63, 0x0c,
|
|
238 |
0x08, 0x00, 0x00, 0xff, 0xff, 0xdc, 0x37, 0x81, 0x99, 0x2a, 0x01, 0x00, 0x00,
|
|
239 |
}
|
|
240 |
|
144 | 241 |
// Reference imports to suppress errors if they are not otherwise used.
|
145 | 242 |
var _ context.Context
|
146 | 243 |
var _ grpc.ClientConn
|
|
149 | 246 |
// is compatible with the grpc package it is being compiled against.
|
150 | 247 |
const _ = grpc.SupportPackageIsVersion4
|
151 | 248 |
|
152 | |
// Client API for Add service
|
153 | |
|
|
249 |
// AddClient is the client API for Add service.
|
|
250 |
//
|
|
251 |
// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
|
154 | 252 |
type AddClient interface {
|
155 | 253 |
// Sums two integers.
|
156 | 254 |
Sum(ctx context.Context, in *SumRequest, opts ...grpc.CallOption) (*SumReply, error)
|
|
168 | 266 |
|
169 | 267 |
func (c *addClient) Sum(ctx context.Context, in *SumRequest, opts ...grpc.CallOption) (*SumReply, error) {
|
170 | 268 |
out := new(SumReply)
|
171 | |
err := grpc.Invoke(ctx, "/pb.Add/Sum", in, out, c.cc, opts...)
|
|
269 |
err := c.cc.Invoke(ctx, "/pb.Add/Sum", in, out, opts...)
|
172 | 270 |
if err != nil {
|
173 | 271 |
return nil, err
|
174 | 272 |
}
|
|
177 | 275 |
|
178 | 276 |
func (c *addClient) Concat(ctx context.Context, in *ConcatRequest, opts ...grpc.CallOption) (*ConcatReply, error) {
|
179 | 277 |
out := new(ConcatReply)
|
180 | |
err := grpc.Invoke(ctx, "/pb.Add/Concat", in, out, c.cc, opts...)
|
|
278 |
err := c.cc.Invoke(ctx, "/pb.Add/Concat", in, out, opts...)
|
181 | 279 |
if err != nil {
|
182 | 280 |
return nil, err
|
183 | 281 |
}
|
184 | 282 |
return out, nil
|
185 | 283 |
}
|
186 | 284 |
|
187 | |
// Server API for Add service
|
188 | |
|
|
285 |
// AddServer is the server API for Add service.
|
189 | 286 |
type AddServer interface {
|
190 | 287 |
// Sums two integers.
|
191 | 288 |
Sum(context.Context, *SumRequest) (*SumReply, error)
|
|
249 | 346 |
Streams: []grpc.StreamDesc{},
|
250 | 347 |
Metadata: "addsvc.proto",
|
251 | 348 |
}
|
252 | |
|
253 | |
func init() { proto.RegisterFile("addsvc.proto", fileDescriptor0) }
|
254 | |
|
255 | |
var fileDescriptor0 = []byte{
|
256 | |
// 189 bytes of a gzipped FileDescriptorProto
|
257 | |
0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xe2, 0xe2, 0x49, 0x4c, 0x49, 0x29,
|
258 | |
0x2e, 0x4b, 0xd6, 0x2b, 0x28, 0xca, 0x2f, 0xc9, 0x17, 0x62, 0x2a, 0x48, 0x52, 0xd2, 0xe0, 0xe2,
|
259 | |
0x0a, 0x2e, 0xcd, 0x0d, 0x4a, 0x2d, 0x2c, 0x4d, 0x2d, 0x2e, 0x11, 0xe2, 0xe1, 0x62, 0x4c, 0x94,
|
260 | |
0x60, 0x54, 0x60, 0xd4, 0x60, 0x0e, 0x62, 0x4c, 0x04, 0xf1, 0x92, 0x24, 0x98, 0x20, 0xbc, 0x24,
|
261 | |
0x25, 0x2d, 0x2e, 0x0e, 0xb0, 0xca, 0x82, 0x9c, 0x4a, 0x90, 0x4c, 0x19, 0x4c, 0x5d, 0x99, 0x90,
|
262 | |
0x00, 0x17, 0x73, 0x6a, 0x51, 0x11, 0x58, 0x25, 0x67, 0x10, 0x88, 0xa9, 0xa4, 0xcd, 0xc5, 0xeb,
|
263 | |
0x9c, 0x9f, 0x97, 0x9c, 0x58, 0x82, 0x61, 0x30, 0x27, 0x8a, 0xc1, 0x9c, 0x20, 0x83, 0x75, 0xb9,
|
264 | |
0xb8, 0x61, 0x8a, 0x51, 0xcc, 0xe6, 0xc4, 0x6a, 0xb6, 0x51, 0x0c, 0x17, 0xb3, 0x63, 0x4a, 0x8a,
|
265 | |
0x90, 0x2a, 0x17, 0x73, 0x70, 0x69, 0xae, 0x10, 0x9f, 0x5e, 0x41, 0x92, 0x1e, 0xc2, 0x07, 0x52,
|
266 | |
0x3c, 0x70, 0x7e, 0x41, 0x4e, 0xa5, 0x12, 0x83, 0x90, 0x1e, 0x17, 0x1b, 0xc4, 0x70, 0x21, 0x41,
|
267 | |
0x90, 0x0c, 0x8a, 0xab, 0xa4, 0xf8, 0x91, 0x85, 0xc0, 0xea, 0x93, 0xd8, 0xc0, 0x41, 0x63, 0x0c,
|
268 | |
0x08, 0x00, 0x00, 0xff, 0xff, 0xdc, 0x37, 0x81, 0x99, 0x2a, 0x01, 0x00, 0x00,
|
269 | |
}
|