blob: 0e2fe6a0b01da4895063e89ab512e61285192652 [file] [log] [blame]
Dinesh Belwalkare1e85ad2019-07-31 23:06:47 +00001// Code generated by protoc-gen-go. DO NOT EDIT.
2// source: importer.proto
3
4package importer
5
6import (
7 context "context"
8 fmt "fmt"
9 proto "github.com/golang/protobuf/proto"
10 empty "github.com/golang/protobuf/ptypes/empty"
11 grpc "google.golang.org/grpc"
12 codes "google.golang.org/grpc/codes"
13 status "google.golang.org/grpc/status"
14 math "math"
15)
16
17// Reference imports to suppress errors if they are not otherwise used.
18var _ = proto.Marshal
19var _ = fmt.Errorf
20var _ = math.Inf
21
22// This is a compile-time assertion to ensure that this generated file
23// is compatible with the proto package it is being compiled against.
24// A compilation error at this line likely means your copy of the
25// proto package needs to be updated.
26const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package
27
28type DeviceInfo struct {
29 IpAddress string `protobuf:"bytes,1,opt,name=ip_address,json=ipAddress,proto3" json:"ip_address,omitempty"`
30 Frequency uint32 `protobuf:"varint,2,opt,name=frequency,proto3" json:"frequency,omitempty"`
31 Vendor string `protobuf:"bytes,3,opt,name=vendor,proto3" json:"vendor,omitempty"`
32 Protocol string `protobuf:"bytes,4,opt,name=protocol,proto3" json:"protocol,omitempty"`
33 XXX_NoUnkeyedLiteral struct{} `json:"-"`
34 XXX_unrecognized []byte `json:"-"`
35 XXX_sizecache int32 `json:"-"`
36}
37
38func (m *DeviceInfo) Reset() { *m = DeviceInfo{} }
39func (m *DeviceInfo) String() string { return proto.CompactTextString(m) }
40func (*DeviceInfo) ProtoMessage() {}
41func (*DeviceInfo) Descriptor() ([]byte, []int) {
42 return fileDescriptor_394990ff89e0d02b, []int{0}
43}
44
45func (m *DeviceInfo) XXX_Unmarshal(b []byte) error {
46 return xxx_messageInfo_DeviceInfo.Unmarshal(m, b)
47}
48func (m *DeviceInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
49 return xxx_messageInfo_DeviceInfo.Marshal(b, m, deterministic)
50}
51func (m *DeviceInfo) XXX_Merge(src proto.Message) {
52 xxx_messageInfo_DeviceInfo.Merge(m, src)
53}
54func (m *DeviceInfo) XXX_Size() int {
55 return xxx_messageInfo_DeviceInfo.Size(m)
56}
57func (m *DeviceInfo) XXX_DiscardUnknown() {
58 xxx_messageInfo_DeviceInfo.DiscardUnknown(m)
59}
60
61var xxx_messageInfo_DeviceInfo proto.InternalMessageInfo
62
63func (m *DeviceInfo) GetIpAddress() string {
64 if m != nil {
65 return m.IpAddress
66 }
67 return ""
68}
69
70func (m *DeviceInfo) GetFrequency() uint32 {
71 if m != nil {
72 return m.Frequency
73 }
74 return 0
75}
76
77func (m *DeviceInfo) GetVendor() string {
78 if m != nil {
79 return m.Vendor
80 }
81 return ""
82}
83
84func (m *DeviceInfo) GetProtocol() string {
85 if m != nil {
86 return m.Protocol
87 }
88 return ""
89}
90
91type EventList struct {
92 EventIpAddress string `protobuf:"bytes,1,opt,name=event_ip_address,json=eventIpAddress,proto3" json:"event_ip_address,omitempty"`
93 Events []string `protobuf:"bytes,2,rep,name=events,proto3" json:"events,omitempty"`
94 XXX_NoUnkeyedLiteral struct{} `json:"-"`
95 XXX_unrecognized []byte `json:"-"`
96 XXX_sizecache int32 `json:"-"`
97}
98
99func (m *EventList) Reset() { *m = EventList{} }
100func (m *EventList) String() string { return proto.CompactTextString(m) }
101func (*EventList) ProtoMessage() {}
102func (*EventList) Descriptor() ([]byte, []int) {
103 return fileDescriptor_394990ff89e0d02b, []int{1}
104}
105
106func (m *EventList) XXX_Unmarshal(b []byte) error {
107 return xxx_messageInfo_EventList.Unmarshal(m, b)
108}
109func (m *EventList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
110 return xxx_messageInfo_EventList.Marshal(b, m, deterministic)
111}
112func (m *EventList) XXX_Merge(src proto.Message) {
113 xxx_messageInfo_EventList.Merge(m, src)
114}
115func (m *EventList) XXX_Size() int {
116 return xxx_messageInfo_EventList.Size(m)
117}
118func (m *EventList) XXX_DiscardUnknown() {
119 xxx_messageInfo_EventList.DiscardUnknown(m)
120}
121
122var xxx_messageInfo_EventList proto.InternalMessageInfo
123
124func (m *EventList) GetEventIpAddress() string {
125 if m != nil {
126 return m.EventIpAddress
127 }
128 return ""
129}
130
131func (m *EventList) GetEvents() []string {
132 if m != nil {
133 return m.Events
134 }
135 return nil
136}
137
138type SupportedEventList struct {
139 Events []string `protobuf:"bytes,1,rep,name=events,proto3" json:"events,omitempty"`
140 XXX_NoUnkeyedLiteral struct{} `json:"-"`
141 XXX_unrecognized []byte `json:"-"`
142 XXX_sizecache int32 `json:"-"`
143}
144
145func (m *SupportedEventList) Reset() { *m = SupportedEventList{} }
146func (m *SupportedEventList) String() string { return proto.CompactTextString(m) }
147func (*SupportedEventList) ProtoMessage() {}
148func (*SupportedEventList) Descriptor() ([]byte, []int) {
149 return fileDescriptor_394990ff89e0d02b, []int{2}
150}
151
152func (m *SupportedEventList) XXX_Unmarshal(b []byte) error {
153 return xxx_messageInfo_SupportedEventList.Unmarshal(m, b)
154}
155func (m *SupportedEventList) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
156 return xxx_messageInfo_SupportedEventList.Marshal(b, m, deterministic)
157}
158func (m *SupportedEventList) XXX_Merge(src proto.Message) {
159 xxx_messageInfo_SupportedEventList.Merge(m, src)
160}
161func (m *SupportedEventList) XXX_Size() int {
162 return xxx_messageInfo_SupportedEventList.Size(m)
163}
164func (m *SupportedEventList) XXX_DiscardUnknown() {
165 xxx_messageInfo_SupportedEventList.DiscardUnknown(m)
166}
167
168var xxx_messageInfo_SupportedEventList proto.InternalMessageInfo
169
170func (m *SupportedEventList) GetEvents() []string {
171 if m != nil {
172 return m.Events
173 }
174 return nil
175}
176
177func init() {
178 proto.RegisterType((*DeviceInfo)(nil), "importer.DeviceInfo")
179 proto.RegisterType((*EventList)(nil), "importer.EventList")
180 proto.RegisterType((*SupportedEventList)(nil), "importer.SupportedEventList")
181}
182
183func init() { proto.RegisterFile("importer.proto", fileDescriptor_394990ff89e0d02b) }
184
185var fileDescriptor_394990ff89e0d02b = []byte{
186 // 329 bytes of a gzipped FileDescriptorProto
187 0x1f, 0x8b, 0x08, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0xff, 0xac, 0x90, 0xcf, 0x4a, 0xf3, 0x40,
188 0x14, 0xc5, 0x9b, 0xf6, 0xa3, 0x34, 0x97, 0x7e, 0x45, 0x47, 0xad, 0xa1, 0x56, 0x28, 0x59, 0x75,
189 0x21, 0x29, 0xe8, 0x5e, 0x14, 0xfa, 0xc7, 0x82, 0x6e, 0x1a, 0x5c, 0x97, 0x26, 0xb9, 0x2d, 0x03,
190 0xcd, 0xcc, 0x38, 0x33, 0x09, 0x74, 0xe1, 0x23, 0xfb, 0x0e, 0x92, 0x89, 0xcd, 0x14, 0x2a, 0x82,
191 0xe0, 0xf2, 0xfc, 0xe6, 0x9e, 0xb9, 0xe7, 0x1e, 0xe8, 0xd0, 0x54, 0x70, 0xa9, 0x51, 0x06, 0x42,
192 0x72, 0xcd, 0x49, 0x6b, 0xaf, 0x7b, 0x57, 0x1b, 0xce, 0x37, 0x5b, 0x1c, 0x19, 0x1e, 0x65, 0xeb,
193 0x11, 0xa6, 0x42, 0xef, 0xca, 0x31, 0xff, 0x1d, 0x60, 0x8c, 0x39, 0x8d, 0x71, 0xce, 0xd6, 0x9c,
194 0x5c, 0x03, 0x50, 0xb1, 0x5c, 0x25, 0x89, 0x44, 0xa5, 0x3c, 0x67, 0xe0, 0x0c, 0xdd, 0x85, 0x4b,
195 0xc5, 0x63, 0x09, 0x48, 0x1f, 0xdc, 0xb5, 0xc4, 0xb7, 0x0c, 0x59, 0xbc, 0xf3, 0xea, 0x03, 0x67,
196 0xf8, 0x7f, 0x61, 0x01, 0xe9, 0x42, 0x33, 0x47, 0x96, 0x70, 0xe9, 0x35, 0x8c, 0xf1, 0x4b, 0x91,
197 0x1e, 0xb4, 0xcc, 0xae, 0x98, 0x6f, 0xbd, 0x7f, 0xe6, 0xa5, 0xd2, 0xfe, 0x0b, 0xb8, 0x93, 0x1c,
198 0x99, 0x7e, 0xa6, 0x4a, 0x93, 0x21, 0x9c, 0x60, 0x21, 0x96, 0x47, 0x19, 0x3a, 0x86, 0xcf, 0xab,
199 0x20, 0x5d, 0x68, 0x1a, 0xa2, 0xbc, 0xfa, 0xa0, 0x51, 0xac, 0x2a, 0x95, 0x7f, 0x03, 0x24, 0xcc,
200 0x84, 0xb9, 0x3b, 0xb1, 0xff, 0xda, 0x69, 0xe7, 0x70, 0xfa, 0xf6, 0xa3, 0x0e, 0xa7, 0x89, 0x39,
201 0x7e, 0x99, 0xae, 0xd8, 0x6a, 0x83, 0x29, 0x32, 0x4d, 0x1e, 0xa0, 0x13, 0x22, 0x4b, 0x0e, 0x5a,
202 0x39, 0x0f, 0xaa, 0x6e, 0x2d, 0xed, 0x75, 0x83, 0xb2, 0xd7, 0x60, 0xdf, 0x6b, 0x30, 0x29, 0x7a,
203 0xf5, 0x6b, 0xe4, 0x1e, 0xda, 0x21, 0xea, 0x69, 0x55, 0xcc, 0x6f, 0xfd, 0x63, 0x68, 0xcf, 0x50,
204 0xdb, 0xfc, 0xdf, 0xfb, 0xfb, 0x96, 0x1e, 0xdf, 0xec, 0xd7, 0xc8, 0x14, 0x2e, 0xc2, 0x2c, 0x52,
205 0x32, 0x96, 0x34, 0xc2, 0x19, 0xcd, 0x91, 0x99, 0x57, 0x45, 0xce, 0xac, 0xb1, 0x9a, 0xff, 0x21,
206 0xcd, 0x13, 0x5c, 0xbe, 0xb2, 0xbf, 0xf8, 0x29, 0x6a, 0x1a, 0x72, 0xf7, 0x19, 0x00, 0x00, 0xff,
207 0xff, 0x79, 0x23, 0x4a, 0xc2, 0xab, 0x02, 0x00, 0x00,
208}
209
210// Reference imports to suppress errors if they are not otherwise used.
211var _ context.Context
212var _ grpc.ClientConn
213
214// This is a compile-time assertion to ensure that this generated file
215// is compatible with the grpc package it is being compiled against.
216const _ = grpc.SupportPackageIsVersion4
217
218// DeviceManagementClient is the client API for DeviceManagement service.
219//
220// For semantics around ctx use and closing/ending streaming RPCs, please refer to https://godoc.org/google.golang.org/grpc#ClientConn.NewStream.
221type DeviceManagementClient interface {
222 SendDeviceInfo(ctx context.Context, in *DeviceInfo, opts ...grpc.CallOption) (*empty.Empty, error)
223 SetFrequency(ctx context.Context, in *DeviceInfo, opts ...grpc.CallOption) (*empty.Empty, error)
224 GetEventList(ctx context.Context, in *DeviceInfo, opts ...grpc.CallOption) (*SupportedEventList, error)
225 SubsrcribeGivenEvents(ctx context.Context, in *EventList, opts ...grpc.CallOption) (*empty.Empty, error)
226 UnSubsrcribeGivenEvents(ctx context.Context, in *EventList, opts ...grpc.CallOption) (*empty.Empty, error)
227}
228
229type deviceManagementClient struct {
230 cc *grpc.ClientConn
231}
232
233func NewDeviceManagementClient(cc *grpc.ClientConn) DeviceManagementClient {
234 return &deviceManagementClient{cc}
235}
236
237func (c *deviceManagementClient) SendDeviceInfo(ctx context.Context, in *DeviceInfo, opts ...grpc.CallOption) (*empty.Empty, error) {
238 out := new(empty.Empty)
239 err := c.cc.Invoke(ctx, "/importer.device_management/SendDeviceInfo", in, out, opts...)
240 if err != nil {
241 return nil, err
242 }
243 return out, nil
244}
245
246func (c *deviceManagementClient) SetFrequency(ctx context.Context, in *DeviceInfo, opts ...grpc.CallOption) (*empty.Empty, error) {
247 out := new(empty.Empty)
248 err := c.cc.Invoke(ctx, "/importer.device_management/SetFrequency", in, out, opts...)
249 if err != nil {
250 return nil, err
251 }
252 return out, nil
253}
254
255func (c *deviceManagementClient) GetEventList(ctx context.Context, in *DeviceInfo, opts ...grpc.CallOption) (*SupportedEventList, error) {
256 out := new(SupportedEventList)
257 err := c.cc.Invoke(ctx, "/importer.device_management/GetEventList", in, out, opts...)
258 if err != nil {
259 return nil, err
260 }
261 return out, nil
262}
263
264func (c *deviceManagementClient) SubsrcribeGivenEvents(ctx context.Context, in *EventList, opts ...grpc.CallOption) (*empty.Empty, error) {
265 out := new(empty.Empty)
266 err := c.cc.Invoke(ctx, "/importer.device_management/SubsrcribeGivenEvents", in, out, opts...)
267 if err != nil {
268 return nil, err
269 }
270 return out, nil
271}
272
273func (c *deviceManagementClient) UnSubsrcribeGivenEvents(ctx context.Context, in *EventList, opts ...grpc.CallOption) (*empty.Empty, error) {
274 out := new(empty.Empty)
275 err := c.cc.Invoke(ctx, "/importer.device_management/UnSubsrcribeGivenEvents", in, out, opts...)
276 if err != nil {
277 return nil, err
278 }
279 return out, nil
280}
281
282// DeviceManagementServer is the server API for DeviceManagement service.
283type DeviceManagementServer interface {
284 SendDeviceInfo(context.Context, *DeviceInfo) (*empty.Empty, error)
285 SetFrequency(context.Context, *DeviceInfo) (*empty.Empty, error)
286 GetEventList(context.Context, *DeviceInfo) (*SupportedEventList, error)
287 SubsrcribeGivenEvents(context.Context, *EventList) (*empty.Empty, error)
288 UnSubsrcribeGivenEvents(context.Context, *EventList) (*empty.Empty, error)
289}
290
291// UnimplementedDeviceManagementServer can be embedded to have forward compatible implementations.
292type UnimplementedDeviceManagementServer struct {
293}
294
295func (*UnimplementedDeviceManagementServer) SendDeviceInfo(ctx context.Context, req *DeviceInfo) (*empty.Empty, error) {
296 return nil, status.Errorf(codes.Unimplemented, "method SendDeviceInfo not implemented")
297}
298func (*UnimplementedDeviceManagementServer) SetFrequency(ctx context.Context, req *DeviceInfo) (*empty.Empty, error) {
299 return nil, status.Errorf(codes.Unimplemented, "method SetFrequency not implemented")
300}
301func (*UnimplementedDeviceManagementServer) GetEventList(ctx context.Context, req *DeviceInfo) (*SupportedEventList, error) {
302 return nil, status.Errorf(codes.Unimplemented, "method GetEventList not implemented")
303}
304func (*UnimplementedDeviceManagementServer) SubsrcribeGivenEvents(ctx context.Context, req *EventList) (*empty.Empty, error) {
305 return nil, status.Errorf(codes.Unimplemented, "method SubsrcribeGivenEvents not implemented")
306}
307func (*UnimplementedDeviceManagementServer) UnSubsrcribeGivenEvents(ctx context.Context, req *EventList) (*empty.Empty, error) {
308 return nil, status.Errorf(codes.Unimplemented, "method UnSubsrcribeGivenEvents not implemented")
309}
310
311func RegisterDeviceManagementServer(s *grpc.Server, srv DeviceManagementServer) {
312 s.RegisterService(&_DeviceManagement_serviceDesc, srv)
313}
314
315func _DeviceManagement_SendDeviceInfo_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
316 in := new(DeviceInfo)
317 if err := dec(in); err != nil {
318 return nil, err
319 }
320 if interceptor == nil {
321 return srv.(DeviceManagementServer).SendDeviceInfo(ctx, in)
322 }
323 info := &grpc.UnaryServerInfo{
324 Server: srv,
325 FullMethod: "/importer.device_management/SendDeviceInfo",
326 }
327 handler := func(ctx context.Context, req interface{}) (interface{}, error) {
328 return srv.(DeviceManagementServer).SendDeviceInfo(ctx, req.(*DeviceInfo))
329 }
330 return interceptor(ctx, in, info, handler)
331}
332
333func _DeviceManagement_SetFrequency_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
334 in := new(DeviceInfo)
335 if err := dec(in); err != nil {
336 return nil, err
337 }
338 if interceptor == nil {
339 return srv.(DeviceManagementServer).SetFrequency(ctx, in)
340 }
341 info := &grpc.UnaryServerInfo{
342 Server: srv,
343 FullMethod: "/importer.device_management/SetFrequency",
344 }
345 handler := func(ctx context.Context, req interface{}) (interface{}, error) {
346 return srv.(DeviceManagementServer).SetFrequency(ctx, req.(*DeviceInfo))
347 }
348 return interceptor(ctx, in, info, handler)
349}
350
351func _DeviceManagement_GetEventList_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
352 in := new(DeviceInfo)
353 if err := dec(in); err != nil {
354 return nil, err
355 }
356 if interceptor == nil {
357 return srv.(DeviceManagementServer).GetEventList(ctx, in)
358 }
359 info := &grpc.UnaryServerInfo{
360 Server: srv,
361 FullMethod: "/importer.device_management/GetEventList",
362 }
363 handler := func(ctx context.Context, req interface{}) (interface{}, error) {
364 return srv.(DeviceManagementServer).GetEventList(ctx, req.(*DeviceInfo))
365 }
366 return interceptor(ctx, in, info, handler)
367}
368
369func _DeviceManagement_SubsrcribeGivenEvents_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
370 in := new(EventList)
371 if err := dec(in); err != nil {
372 return nil, err
373 }
374 if interceptor == nil {
375 return srv.(DeviceManagementServer).SubsrcribeGivenEvents(ctx, in)
376 }
377 info := &grpc.UnaryServerInfo{
378 Server: srv,
379 FullMethod: "/importer.device_management/SubsrcribeGivenEvents",
380 }
381 handler := func(ctx context.Context, req interface{}) (interface{}, error) {
382 return srv.(DeviceManagementServer).SubsrcribeGivenEvents(ctx, req.(*EventList))
383 }
384 return interceptor(ctx, in, info, handler)
385}
386
387func _DeviceManagement_UnSubsrcribeGivenEvents_Handler(srv interface{}, ctx context.Context, dec func(interface{}) error, interceptor grpc.UnaryServerInterceptor) (interface{}, error) {
388 in := new(EventList)
389 if err := dec(in); err != nil {
390 return nil, err
391 }
392 if interceptor == nil {
393 return srv.(DeviceManagementServer).UnSubsrcribeGivenEvents(ctx, in)
394 }
395 info := &grpc.UnaryServerInfo{
396 Server: srv,
397 FullMethod: "/importer.device_management/UnSubsrcribeGivenEvents",
398 }
399 handler := func(ctx context.Context, req interface{}) (interface{}, error) {
400 return srv.(DeviceManagementServer).UnSubsrcribeGivenEvents(ctx, req.(*EventList))
401 }
402 return interceptor(ctx, in, info, handler)
403}
404
405var _DeviceManagement_serviceDesc = grpc.ServiceDesc{
406 ServiceName: "importer.device_management",
407 HandlerType: (*DeviceManagementServer)(nil),
408 Methods: []grpc.MethodDesc{
409 {
410 MethodName: "SendDeviceInfo",
411 Handler: _DeviceManagement_SendDeviceInfo_Handler,
412 },
413 {
414 MethodName: "SetFrequency",
415 Handler: _DeviceManagement_SetFrequency_Handler,
416 },
417 {
418 MethodName: "GetEventList",
419 Handler: _DeviceManagement_GetEventList_Handler,
420 },
421 {
422 MethodName: "SubsrcribeGivenEvents",
423 Handler: _DeviceManagement_SubsrcribeGivenEvents_Handler,
424 },
425 {
426 MethodName: "UnSubsrcribeGivenEvents",
427 Handler: _DeviceManagement_UnSubsrcribeGivenEvents_Handler,
428 },
429 },
430 Streams: []grpc.StreamDesc{},
431 Metadata: "importer.proto",
432}