OSDN Git Service

new repo
[bytom/vapor.git] / vendor / google.golang.org / grpc / reflection / grpc_testingv3 / testv3.pb.go
1 // Code generated by protoc-gen-go.
2 // source: testv3.proto
3 // DO NOT EDIT!
4
5 /*
6 Package grpc_testingv3 is a generated protocol buffer package.
7
8 It is generated from these files:
9         testv3.proto
10
11 It has these top-level messages:
12         SearchResponseV3
13         SearchRequestV3
14 */
15 package grpc_testingv3
16
17 import proto "github.com/golang/protobuf/proto"
18 import fmt "fmt"
19 import math "math"
20
21 import (
22         context "golang.org/x/net/context"
23         grpc "google.golang.org/grpc"
24 )
25
26 // Reference imports to suppress errors if they are not otherwise used.
27 var _ = proto.Marshal
28 var _ = fmt.Errorf
29 var _ = math.Inf
30
31 // This is a compile-time assertion to ensure that this generated file
32 // is compatible with the proto package it is being compiled against.
33 // A compilation error at this line likely means your copy of the
34 // proto package needs to be updated.
35 const _ = proto.ProtoPackageIsVersion2 // please upgrade the proto package
36
37 type SearchResponseV3 struct {
38         Results []*SearchResponseV3_Result `protobuf:"bytes,1,rep,name=results" json:"results,omitempty"`
39 }
40
41 func (m *SearchResponseV3) Reset()                    { *m = SearchResponseV3{} }
42 func (m *SearchResponseV3) String() string            { return proto.CompactTextString(m) }
43 func (*SearchResponseV3) ProtoMessage()               {}
44 func (*SearchResponseV3) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0} }
45
46 func (m *SearchResponseV3) GetResults() []*SearchResponseV3_Result {
47         if m != nil {
48                 return m.Results
49         }
50         return nil
51 }
52
53 type SearchResponseV3_Result struct {
54         Url      string   `protobuf:"bytes,1,opt,name=url" json:"url,omitempty"`
55         Title    string   `protobuf:"bytes,2,opt,name=title" json:"title,omitempty"`
56         Snippets []string `protobuf:"bytes,3,rep,name=snippets" json:"snippets,omitempty"`
57 }
58
59 func (m *SearchResponseV3_Result) Reset()                    { *m = SearchResponseV3_Result{} }
60 func (m *SearchResponseV3_Result) String() string            { return proto.CompactTextString(m) }
61 func (*SearchResponseV3_Result) ProtoMessage()               {}
62 func (*SearchResponseV3_Result) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{0, 0} }
63
64 type SearchRequestV3 struct {
65         Query string `protobuf:"bytes,1,opt,name=query" json:"query,omitempty"`
66 }
67
68 func (m *SearchRequestV3) Reset()                    { *m = SearchRequestV3{} }
69 func (m *SearchRequestV3) String() string            { return proto.CompactTextString(m) }
70 func (*SearchRequestV3) ProtoMessage()               {}
71 func (*SearchRequestV3) Descriptor() ([]byte, []int) { return fileDescriptor0, []int{1} }
72
73 func init() {
74         proto.RegisterType((*SearchResponseV3)(nil), "grpc.testingv3.SearchResponseV3")
75         proto.RegisterType((*SearchResponseV3_Result)(nil), "grpc.testingv3.SearchResponseV3.Result")
76         proto.RegisterType((*SearchRequestV3)(nil), "grpc.testingv3.SearchRequestV3")
77 }
78
79 // Reference imports to suppress errors if they are not otherwise used.
80 var _ context.Context
81 var _ grpc.ClientConn
82
83 // This is a compile-time assertion to ensure that this generated file
84 // is compatible with the grpc package it is being compiled against.
85 const _ = grpc.SupportPackageIsVersion3
86
87 // Client API for SearchServiceV3 service
88
89 type SearchServiceV3Client interface {
90         Search(ctx context.Context, in *SearchRequestV3, opts ...grpc.CallOption) (*SearchResponseV3, error)
91         StreamingSearch(ctx context.Context, opts ...grpc.CallOption) (SearchServiceV3_StreamingSearchClient, error)
92 }
93
94 type searchServiceV3Client struct {
95         cc *grpc.ClientConn
96 }
97
98 func NewSearchServiceV3Client(cc *grpc.ClientConn) SearchServiceV3Client {
99         return &searchServiceV3Client{cc}
100 }
101
102 func (c *searchServiceV3Client) Search(ctx context.Context, in *SearchRequestV3, opts ...grpc.CallOption) (*SearchResponseV3, error) {
103         out := new(SearchResponseV3)
104         err := grpc.Invoke(ctx, "/grpc.testingv3.SearchServiceV3/Search", in, out, c.cc, opts...)
105         if err != nil {
106                 return nil, err
107         }
108         return out, nil
109 }
110
111 func (c *searchServiceV3Client) StreamingSearch(ctx context.Context, opts ...grpc.CallOption) (SearchServiceV3_StreamingSearchClient, error) {
112         stream, err := grpc.NewClientStream(ctx, &_SearchServiceV3_serviceDesc.Streams[0], c.cc, "/grpc.testingv3.SearchServiceV3/StreamingSearch", opts...)
113         if err != nil {
114                 return nil, err
115         }
116         x := &searchServiceV3StreamingSearchClient{stream}
117         return x, nil
118 }
119
120 type SearchServiceV3_StreamingSearchClient interface {
121         Send(*SearchRequestV3) error
122         Recv() (*SearchResponseV3, error)
123         grpc.ClientStream
124 }
125
126 type searchServiceV3StreamingSearchClient struct {
127         grpc.ClientStream
128 }
129
130 func (x *searchServiceV3StreamingSearchClient) Send(m *SearchRequestV3) error {
131         return x.ClientStream.SendMsg(m)
132 }
133
134 func (x *searchServiceV3StreamingSearchClient) Recv() (*SearchResponseV3, error) {
135         m := new(SearchResponseV3)
136         if err := x.ClientStream.RecvMsg(m); err != nil {
137                 return nil, err
138         }
139         return m, nil
140 }
141
142 // Server API for SearchServiceV3 service
143
144 type SearchServiceV3Server interface {
145         Search(context.Context, *SearchRequestV3) (*SearchResponseV3, error)
146         StreamingSearch(SearchServiceV3_StreamingSearchServer) error
147 }
148
149 func RegisterSearchServiceV3Server(s *grpc.Server, srv SearchServiceV3Server) {
150         s.RegisterService(&_SearchServiceV3_serviceDesc, srv)
151 }
152
153 func _SearchServiceV3_Search_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
154         in := new(SearchRequestV3)
155         if err := dec(in); err != nil {
156                 return nil, err
157         }
158         if interceptor == nil {
159                 return srv.(SearchServiceV3Server).Search(ctx, in)
160         }
161         info := &grpc.UnaryServerInfo{
162                 Server:     srv,
163                 FullMethod: "/grpc.testingv3.SearchServiceV3/Search",
164         }
165         handler := func(ctx context.Context, req interface{}) (interface{}, error) {
166                 return srv.(SearchServiceV3Server).Search(ctx, req.(*SearchRequestV3))
167         }
168         return interceptor(ctx, in, info, handler)
169 }
170
171 func _SearchServiceV3_StreamingSearch_Handler(srv interface{}, stream grpc.ServerStream) error {
172         return srv.(SearchServiceV3Server).StreamingSearch(&searchServiceV3StreamingSearchServer{stream})
173 }
174
175 type SearchServiceV3_StreamingSearchServer interface {
176         Send(*SearchResponseV3) error
177         Recv() (*SearchRequestV3, error)
178         grpc.ServerStream
179 }
180
181 type searchServiceV3StreamingSearchServer struct {
182         grpc.ServerStream
183 }
184
185 func (x *searchServiceV3StreamingSearchServer) Send(m *SearchResponseV3) error {
186         return x.ServerStream.SendMsg(m)
187 }
188
189 func (x *searchServiceV3StreamingSearchServer) Recv() (*SearchRequestV3, error) {
190         m := new(SearchRequestV3)
191         if err := x.ServerStream.RecvMsg(m); err != nil {
192                 return nil, err
193         }
194         return m, nil
195 }
196
197 var _SearchServiceV3_serviceDesc = grpc.ServiceDesc{
198         ServiceName: "grpc.testingv3.SearchServiceV3",
199         HandlerType: (*SearchServiceV3Server)(nil),
200         Methods: []grpc.MethodDesc{
201                 {
202                         MethodName: "Search",
203                         Handler:    _SearchServiceV3_Search_Handler,
204                 },
205         },
206         Streams: []grpc.StreamDesc{
207                 {
208                         StreamName:    "StreamingSearch",
209                         Handler:       _SearchServiceV3_StreamingSearch_Handler,
210                         ServerStreams: true,
211                         ClientStreams: true,
212                 },
213         },
214         Metadata: fileDescriptor0,
215 }
216
217 func init() { proto.RegisterFile("testv3.proto", fileDescriptor0) }
218
219 var fileDescriptor0 = []byte{
220         // 240 bytes of a gzipped FileDescriptorProto
221         0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x91, 0x41, 0x4b, 0xc3, 0x40,
222         0x10, 0x85, 0x59, 0x83, 0xd1, 0x8e, 0x62, 0xcb, 0xe2, 0x21, 0xe4, 0x62, 0xe8, 0xa5, 0x39, 0x2d,
223         0xd2, 0xfd, 0x05, 0x9e, 0xf5, 0xb4, 0x81, 0xe2, 0xb5, 0x86, 0x21, 0x2e, 0xc4, 0x64, 0x3b, 0x33,
224         0x09, 0xf8, 0x7b, 0xfc, 0x13, 0xfe, 0x3c, 0x49, 0xd2, 0x08, 0x0a, 0xe2, 0xa5, 0xb7, 0x7d, 0x8f,
225         0xf7, 0xbe, 0xe5, 0x31, 0x70, 0x2d, 0xc8, 0xd2, 0x5b, 0x13, 0xa8, 0x95, 0x56, 0xdf, 0x54, 0x14,
226         0x4a, 0x33, 0x58, 0xbe, 0xa9, 0x7a, 0xbb, 0xfe, 0x50, 0xb0, 0x2a, 0x70, 0x4f, 0xe5, 0xab, 0x43,
227         0x0e, 0x6d, 0xc3, 0xb8, 0xb3, 0xfa, 0x01, 0x2e, 0x08, 0xb9, 0xab, 0x85, 0x13, 0x95, 0x45, 0xf9,
228         0xd5, 0x76, 0x63, 0x7e, 0xd6, 0xcc, 0xef, 0x8a, 0x71, 0x63, 0xde, 0xcd, 0xbd, 0xf4, 0x09, 0xe2,
229         0xc9, 0xd2, 0x2b, 0x88, 0x3a, 0xaa, 0x13, 0x95, 0xa9, 0x7c, 0xe1, 0x86, 0xa7, 0xbe, 0x85, 0x73,
230         0xf1, 0x52, 0x63, 0x72, 0x36, 0x7a, 0x93, 0xd0, 0x29, 0x5c, 0x72, 0xe3, 0x43, 0x40, 0xe1, 0x24,
231         0xca, 0xa2, 0x7c, 0xe1, 0xbe, 0xf5, 0x7a, 0x03, 0xcb, 0xf9, 0xc7, 0x43, 0x87, 0x2c, 0x3b, 0x3b,
232         0x40, 0x0e, 0x1d, 0xd2, 0xfb, 0x11, 0x3c, 0x89, 0xed, 0xa7, 0x9a, 0x93, 0x05, 0x52, 0xef, 0xcb,
233         0x61, 0xcd, 0x23, 0xc4, 0x93, 0xa5, 0xef, 0xfe, 0x9a, 0x71, 0x84, 0xa6, 0xd9, 0x7f, 0x3b, 0xf5,
234         0x33, 0x2c, 0x0b, 0x21, 0xdc, 0xbf, 0xf9, 0xa6, 0x3a, 0x19, 0x35, 0x57, 0xf7, 0xea, 0x25, 0x1e,
235         0x0f, 0x64, 0xbf, 0x02, 0x00, 0x00, 0xff, 0xff, 0xd4, 0xe6, 0xa0, 0xf9, 0xb0, 0x01, 0x00, 0x00,
236 }