blob: 8056952e7f726ae8fd867160734d42f61f2713e3 [file] [log] [blame]
Dinesh Belwalkar41229602019-06-21 16:58:06 +00001syntax = "proto3";
2
3
4package importer;
5
6import "google/protobuf/empty.proto";
7//import "google/api/annotations.proto";
8
9
10message DeviceInfo {
Dinesh Belwalkara0493ad2019-07-22 19:58:42 +000011 string ip_address = 1;
12 uint32 frequency = 2;
Dinesh Belwalkar41229602019-06-21 16:58:06 +000013}
14
Dinesh Belwalkarb5db83f2019-10-24 17:27:58 +000015message GivenEventList {
Dinesh Belwalkara0493ad2019-07-22 19:58:42 +000016 string event_ip_address = 1;
Dinesh Belwalkarf57ee2e2019-07-11 17:46:00 +000017 repeated string events = 2;
18}
19
Dinesh Belwalkarb5db83f2019-10-24 17:27:58 +000020message EventList {
Dinesh Belwalkara0493ad2019-07-22 19:58:42 +000021 repeated string events = 1;
22}
Dinesh Belwalkar41229602019-06-21 16:58:06 +000023
Dinesh Belwalkarb5db83f2019-10-24 17:27:58 +000024message FreqInfo {
25 string IpAddress = 1;
26 uint32 Frequency = 2;
27}
28
Dinesh Belwalkarb5db83f2019-10-24 17:27:58 +000029message Device {
30 string IpAddress = 1;
31}
32
Dinesh Belwalkarb5db83f2019-10-24 17:27:58 +000033message Empty {}
dileepbk86ef0102019-11-13 00:08:33 +000034
mc20a4b5f2019-10-16 20:28:24 +000035message DeviceList {
36 repeated DeviceInfo device = 1;
37}
38
39message DeviceListByIp {
40 repeated string Ip = 1;
41}
42
Dinesh Belwalkar41229602019-06-21 16:58:06 +000043service device_management {
mc20a4b5f2019-10-16 20:28:24 +000044 rpc SendDeviceList(DeviceList) returns (google.protobuf.Empty) {}
45
46 rpc DeleteDeviceList(DeviceListByIp) returns (google.protobuf.Empty) {}
Dinesh Belwalkarf57ee2e2019-07-11 17:46:00 +000047
Dinesh Belwalkarb5db83f2019-10-24 17:27:58 +000048 rpc SetFrequency(FreqInfo) returns (google.protobuf.Empty) {}
Dinesh Belwalkarf57ee2e2019-07-11 17:46:00 +000049
mc20a4b5f2019-10-16 20:28:24 +000050 rpc GetEventList(Device) returns (EventList) {}
Dinesh Belwalkarf57ee2e2019-07-11 17:46:00 +000051
mccd7e9502019-12-16 22:04:13 +000052 rpc SubscribeGivenEvents(GivenEventList) returns (google.protobuf.Empty) {}
Dinesh Belwalkarf57ee2e2019-07-11 17:46:00 +000053
mccd7e9502019-12-16 22:04:13 +000054 rpc UnsubscribeGivenEvents(GivenEventList) returns (google.protobuf.Empty) {}
Dinesh Belwalkarb5db83f2019-10-24 17:27:58 +000055
56 rpc GetCurrentEventList(Device) returns (EventList) {}
57
58 rpc ClearCurrentEventList(Device) returns (google.protobuf.Empty) {}
59
mc20a4b5f2019-10-16 20:28:24 +000060 rpc GetCurrentDevices(Empty) returns (DeviceListByIp) {}
Dinesh Belwalkar41229602019-06-21 16:58:06 +000061}
62
63
Dinesh Belwalkarf57ee2e2019-07-11 17:46:00 +000064