-
-
Notifications
You must be signed in to change notification settings - Fork 17
/
devices.pb.go
3226 lines (2848 loc) · 132 KB
/
devices.pb.go
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
// Code generated by protoc-gen-go. DO NOT EDIT.
// versions:
// protoc-gen-go v1.34.1
// protoc v5.26.1
// source: grpc-gateway/pb/devices.proto
package pb
import (
events1 "github.com/plgd-dev/hub/v2/identity-store/events"
commands "github.com/plgd-dev/hub/v2/resource-aggregate/commands"
events "github.com/plgd-dev/hub/v2/resource-aggregate/events"
protoreflect "google.golang.org/protobuf/reflect/protoreflect"
protoimpl "google.golang.org/protobuf/runtime/protoimpl"
reflect "reflect"
sync "sync"
)
const (
// Verify that this generated code is sufficiently up-to-date.
_ = protoimpl.EnforceVersion(20 - protoimpl.MinVersion)
// Verify that runtime/protoimpl is sufficiently up-to-date.
_ = protoimpl.EnforceVersion(protoimpl.MaxVersion - 20)
)
type GetDevicesRequest_Status int32
const (
GetDevicesRequest_ONLINE GetDevicesRequest_Status = 0
GetDevicesRequest_OFFLINE GetDevicesRequest_Status = 1
)
// Enum value maps for GetDevicesRequest_Status.
var (
GetDevicesRequest_Status_name = map[int32]string{
0: "ONLINE",
1: "OFFLINE",
}
GetDevicesRequest_Status_value = map[string]int32{
"ONLINE": 0,
"OFFLINE": 1,
}
)
func (x GetDevicesRequest_Status) Enum() *GetDevicesRequest_Status {
p := new(GetDevicesRequest_Status)
*p = x
return p
}
func (x GetDevicesRequest_Status) String() string {
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
}
func (GetDevicesRequest_Status) Descriptor() protoreflect.EnumDescriptor {
return file_grpc_gateway_pb_devices_proto_enumTypes[0].Descriptor()
}
func (GetDevicesRequest_Status) Type() protoreflect.EnumType {
return &file_grpc_gateway_pb_devices_proto_enumTypes[0]
}
func (x GetDevicesRequest_Status) Number() protoreflect.EnumNumber {
return protoreflect.EnumNumber(x)
}
// Deprecated: Use GetDevicesRequest_Status.Descriptor instead.
func (GetDevicesRequest_Status) EnumDescriptor() ([]byte, []int) {
return file_grpc_gateway_pb_devices_proto_rawDescGZIP(), []int{0, 0}
}
type SubscribeToEvents_CreateSubscription_Event int32
const (
SubscribeToEvents_CreateSubscription_REGISTERED SubscribeToEvents_CreateSubscription_Event = 0
SubscribeToEvents_CreateSubscription_UNREGISTERED SubscribeToEvents_CreateSubscription_Event = 1
SubscribeToEvents_CreateSubscription_DEVICE_METADATA_UPDATED SubscribeToEvents_CreateSubscription_Event = 4
SubscribeToEvents_CreateSubscription_DEVICE_METADATA_UPDATE_PENDING SubscribeToEvents_CreateSubscription_Event = 5
SubscribeToEvents_CreateSubscription_RESOURCE_PUBLISHED SubscribeToEvents_CreateSubscription_Event = 6
SubscribeToEvents_CreateSubscription_RESOURCE_UNPUBLISHED SubscribeToEvents_CreateSubscription_Event = 7
SubscribeToEvents_CreateSubscription_RESOURCE_UPDATE_PENDING SubscribeToEvents_CreateSubscription_Event = 8
SubscribeToEvents_CreateSubscription_RESOURCE_UPDATED SubscribeToEvents_CreateSubscription_Event = 9
SubscribeToEvents_CreateSubscription_RESOURCE_RETRIEVE_PENDING SubscribeToEvents_CreateSubscription_Event = 10
SubscribeToEvents_CreateSubscription_RESOURCE_RETRIEVED SubscribeToEvents_CreateSubscription_Event = 11
SubscribeToEvents_CreateSubscription_RESOURCE_DELETE_PENDING SubscribeToEvents_CreateSubscription_Event = 12
SubscribeToEvents_CreateSubscription_RESOURCE_DELETED SubscribeToEvents_CreateSubscription_Event = 13
SubscribeToEvents_CreateSubscription_RESOURCE_CREATE_PENDING SubscribeToEvents_CreateSubscription_Event = 14
SubscribeToEvents_CreateSubscription_RESOURCE_CREATED SubscribeToEvents_CreateSubscription_Event = 15
SubscribeToEvents_CreateSubscription_RESOURCE_CHANGED SubscribeToEvents_CreateSubscription_Event = 16
)
// Enum value maps for SubscribeToEvents_CreateSubscription_Event.
var (
SubscribeToEvents_CreateSubscription_Event_name = map[int32]string{
0: "REGISTERED",
1: "UNREGISTERED",
4: "DEVICE_METADATA_UPDATED",
5: "DEVICE_METADATA_UPDATE_PENDING",
6: "RESOURCE_PUBLISHED",
7: "RESOURCE_UNPUBLISHED",
8: "RESOURCE_UPDATE_PENDING",
9: "RESOURCE_UPDATED",
10: "RESOURCE_RETRIEVE_PENDING",
11: "RESOURCE_RETRIEVED",
12: "RESOURCE_DELETE_PENDING",
13: "RESOURCE_DELETED",
14: "RESOURCE_CREATE_PENDING",
15: "RESOURCE_CREATED",
16: "RESOURCE_CHANGED",
}
SubscribeToEvents_CreateSubscription_Event_value = map[string]int32{
"REGISTERED": 0,
"UNREGISTERED": 1,
"DEVICE_METADATA_UPDATED": 4,
"DEVICE_METADATA_UPDATE_PENDING": 5,
"RESOURCE_PUBLISHED": 6,
"RESOURCE_UNPUBLISHED": 7,
"RESOURCE_UPDATE_PENDING": 8,
"RESOURCE_UPDATED": 9,
"RESOURCE_RETRIEVE_PENDING": 10,
"RESOURCE_RETRIEVED": 11,
"RESOURCE_DELETE_PENDING": 12,
"RESOURCE_DELETED": 13,
"RESOURCE_CREATE_PENDING": 14,
"RESOURCE_CREATED": 15,
"RESOURCE_CHANGED": 16,
}
)
func (x SubscribeToEvents_CreateSubscription_Event) Enum() *SubscribeToEvents_CreateSubscription_Event {
p := new(SubscribeToEvents_CreateSubscription_Event)
*p = x
return p
}
func (x SubscribeToEvents_CreateSubscription_Event) String() string {
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
}
func (SubscribeToEvents_CreateSubscription_Event) Descriptor() protoreflect.EnumDescriptor {
return file_grpc_gateway_pb_devices_proto_enumTypes[1].Descriptor()
}
func (SubscribeToEvents_CreateSubscription_Event) Type() protoreflect.EnumType {
return &file_grpc_gateway_pb_devices_proto_enumTypes[1]
}
func (x SubscribeToEvents_CreateSubscription_Event) Number() protoreflect.EnumNumber {
return protoreflect.EnumNumber(x)
}
// Deprecated: Use SubscribeToEvents_CreateSubscription_Event.Descriptor instead.
func (SubscribeToEvents_CreateSubscription_Event) EnumDescriptor() ([]byte, []int) {
return file_grpc_gateway_pb_devices_proto_rawDescGZIP(), []int{11, 0, 0}
}
type Event_OperationProcessed_ErrorStatus_Code int32
const (
Event_OperationProcessed_ErrorStatus_OK Event_OperationProcessed_ErrorStatus_Code = 0
Event_OperationProcessed_ErrorStatus_ERROR Event_OperationProcessed_ErrorStatus_Code = 1
Event_OperationProcessed_ErrorStatus_NOT_FOUND Event_OperationProcessed_ErrorStatus_Code = 2
)
// Enum value maps for Event_OperationProcessed_ErrorStatus_Code.
var (
Event_OperationProcessed_ErrorStatus_Code_name = map[int32]string{
0: "OK",
1: "ERROR",
2: "NOT_FOUND",
}
Event_OperationProcessed_ErrorStatus_Code_value = map[string]int32{
"OK": 0,
"ERROR": 1,
"NOT_FOUND": 2,
}
)
func (x Event_OperationProcessed_ErrorStatus_Code) Enum() *Event_OperationProcessed_ErrorStatus_Code {
p := new(Event_OperationProcessed_ErrorStatus_Code)
*p = x
return p
}
func (x Event_OperationProcessed_ErrorStatus_Code) String() string {
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
}
func (Event_OperationProcessed_ErrorStatus_Code) Descriptor() protoreflect.EnumDescriptor {
return file_grpc_gateway_pb_devices_proto_enumTypes[2].Descriptor()
}
func (Event_OperationProcessed_ErrorStatus_Code) Type() protoreflect.EnumType {
return &file_grpc_gateway_pb_devices_proto_enumTypes[2]
}
func (x Event_OperationProcessed_ErrorStatus_Code) Number() protoreflect.EnumNumber {
return protoreflect.EnumNumber(x)
}
// Deprecated: Use Event_OperationProcessed_ErrorStatus_Code.Descriptor instead.
func (Event_OperationProcessed_ErrorStatus_Code) EnumDescriptor() ([]byte, []int) {
return file_grpc_gateway_pb_devices_proto_rawDescGZIP(), []int{12, 2, 0, 0}
}
type Device_OwnershipStatus int32
const (
// cannot determine ownership status
Device_UNKNOWN Device_OwnershipStatus = 0
// device is ready to be owned the user
Device_UNOWNED Device_OwnershipStatus = 1
// device is owned by the user. to determine who own the device you need to get ownership resource /oic/sec/doxm
Device_OWNED Device_OwnershipStatus = 2
// set when device is not secured. (iotivity-lite was built without security)
Device_UNSUPPORTED Device_OwnershipStatus = 3
)
// Enum value maps for Device_OwnershipStatus.
var (
Device_OwnershipStatus_name = map[int32]string{
0: "UNKNOWN",
1: "UNOWNED",
2: "OWNED",
3: "UNSUPPORTED",
}
Device_OwnershipStatus_value = map[string]int32{
"UNKNOWN": 0,
"UNOWNED": 1,
"OWNED": 2,
"UNSUPPORTED": 3,
}
)
func (x Device_OwnershipStatus) Enum() *Device_OwnershipStatus {
p := new(Device_OwnershipStatus)
*p = x
return p
}
func (x Device_OwnershipStatus) String() string {
return protoimpl.X.EnumStringOf(x.Descriptor(), protoreflect.EnumNumber(x))
}
func (Device_OwnershipStatus) Descriptor() protoreflect.EnumDescriptor {
return file_grpc_gateway_pb_devices_proto_enumTypes[3].Descriptor()
}
func (Device_OwnershipStatus) Type() protoreflect.EnumType {
return &file_grpc_gateway_pb_devices_proto_enumTypes[3]
}
func (x Device_OwnershipStatus) Number() protoreflect.EnumNumber {
return protoreflect.EnumNumber(x)
}
// Deprecated: Use Device_OwnershipStatus.Descriptor instead.
func (Device_OwnershipStatus) EnumDescriptor() ([]byte, []int) {
return file_grpc_gateway_pb_devices_proto_rawDescGZIP(), []int{14, 0}
}
type GetDevicesRequest struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
TypeFilter []string `protobuf:"bytes,1,rep,name=type_filter,json=typeFilter,proto3" json:"type_filter,omitempty"`
StatusFilter []GetDevicesRequest_Status `protobuf:"varint,2,rep,packed,name=status_filter,json=statusFilter,proto3,enum=grpcgateway.pb.GetDevicesRequest_Status" json:"status_filter,omitempty"`
DeviceIdFilter []string `protobuf:"bytes,3,rep,name=device_id_filter,json=deviceIdFilter,proto3" json:"device_id_filter,omitempty"`
}
func (x *GetDevicesRequest) Reset() {
*x = GetDevicesRequest{}
if protoimpl.UnsafeEnabled {
mi := &file_grpc_gateway_pb_devices_proto_msgTypes[0]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *GetDevicesRequest) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*GetDevicesRequest) ProtoMessage() {}
func (x *GetDevicesRequest) ProtoReflect() protoreflect.Message {
mi := &file_grpc_gateway_pb_devices_proto_msgTypes[0]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use GetDevicesRequest.ProtoReflect.Descriptor instead.
func (*GetDevicesRequest) Descriptor() ([]byte, []int) {
return file_grpc_gateway_pb_devices_proto_rawDescGZIP(), []int{0}
}
func (x *GetDevicesRequest) GetTypeFilter() []string {
if x != nil {
return x.TypeFilter
}
return nil
}
func (x *GetDevicesRequest) GetStatusFilter() []GetDevicesRequest_Status {
if x != nil {
return x.StatusFilter
}
return nil
}
func (x *GetDevicesRequest) GetDeviceIdFilter() []string {
if x != nil {
return x.DeviceIdFilter
}
return nil
}
type DeleteDevicesRequest struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
DeviceIdFilter []string `protobuf:"bytes,1,rep,name=device_id_filter,json=deviceIdFilter,proto3" json:"device_id_filter,omitempty"`
}
func (x *DeleteDevicesRequest) Reset() {
*x = DeleteDevicesRequest{}
if protoimpl.UnsafeEnabled {
mi := &file_grpc_gateway_pb_devices_proto_msgTypes[1]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *DeleteDevicesRequest) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*DeleteDevicesRequest) ProtoMessage() {}
func (x *DeleteDevicesRequest) ProtoReflect() protoreflect.Message {
mi := &file_grpc_gateway_pb_devices_proto_msgTypes[1]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use DeleteDevicesRequest.ProtoReflect.Descriptor instead.
func (*DeleteDevicesRequest) Descriptor() ([]byte, []int) {
return file_grpc_gateway_pb_devices_proto_rawDescGZIP(), []int{1}
}
func (x *DeleteDevicesRequest) GetDeviceIdFilter() []string {
if x != nil {
return x.DeviceIdFilter
}
return nil
}
type DeleteDevicesResponse struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
DeviceIds []string `protobuf:"bytes,1,rep,name=device_ids,json=deviceIds,proto3" json:"device_ids,omitempty"`
}
func (x *DeleteDevicesResponse) Reset() {
*x = DeleteDevicesResponse{}
if protoimpl.UnsafeEnabled {
mi := &file_grpc_gateway_pb_devices_proto_msgTypes[2]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *DeleteDevicesResponse) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*DeleteDevicesResponse) ProtoMessage() {}
func (x *DeleteDevicesResponse) ProtoReflect() protoreflect.Message {
mi := &file_grpc_gateway_pb_devices_proto_msgTypes[2]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use DeleteDevicesResponse.ProtoReflect.Descriptor instead.
func (*DeleteDevicesResponse) Descriptor() ([]byte, []int) {
return file_grpc_gateway_pb_devices_proto_rawDescGZIP(), []int{2}
}
func (x *DeleteDevicesResponse) GetDeviceIds() []string {
if x != nil {
return x.DeviceIds
}
return nil
}
type GetResourceLinksRequest struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
TypeFilter []string `protobuf:"bytes,1,rep,name=type_filter,json=typeFilter,proto3" json:"type_filter,omitempty"`
DeviceIdFilter []string `protobuf:"bytes,2,rep,name=device_id_filter,json=deviceIdFilter,proto3" json:"device_id_filter,omitempty"`
}
func (x *GetResourceLinksRequest) Reset() {
*x = GetResourceLinksRequest{}
if protoimpl.UnsafeEnabled {
mi := &file_grpc_gateway_pb_devices_proto_msgTypes[3]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *GetResourceLinksRequest) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*GetResourceLinksRequest) ProtoMessage() {}
func (x *GetResourceLinksRequest) ProtoReflect() protoreflect.Message {
mi := &file_grpc_gateway_pb_devices_proto_msgTypes[3]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use GetResourceLinksRequest.ProtoReflect.Descriptor instead.
func (*GetResourceLinksRequest) Descriptor() ([]byte, []int) {
return file_grpc_gateway_pb_devices_proto_rawDescGZIP(), []int{3}
}
func (x *GetResourceLinksRequest) GetTypeFilter() []string {
if x != nil {
return x.TypeFilter
}
return nil
}
func (x *GetResourceLinksRequest) GetDeviceIdFilter() []string {
if x != nil {
return x.DeviceIdFilter
}
return nil
}
type GetResourceFromDeviceRequest struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
ResourceId *commands.ResourceId `protobuf:"bytes,1,opt,name=resource_id,json=resourceId,proto3" json:"resource_id,omitempty"`
ResourceInterface string `protobuf:"bytes,2,opt,name=resource_interface,json=resourceInterface,proto3" json:"resource_interface,omitempty"`
TimeToLive int64 `protobuf:"varint,3,opt,name=time_to_live,json=timeToLive,proto3" json:"time_to_live,omitempty"` // command validity in nanoseconds. 0 means forever and minimal value is 100000000 (100ms).
Etag [][]byte `protobuf:"bytes,4,rep,name=etag,proto3" json:"etag,omitempty"` // optional
}
func (x *GetResourceFromDeviceRequest) Reset() {
*x = GetResourceFromDeviceRequest{}
if protoimpl.UnsafeEnabled {
mi := &file_grpc_gateway_pb_devices_proto_msgTypes[4]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *GetResourceFromDeviceRequest) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*GetResourceFromDeviceRequest) ProtoMessage() {}
func (x *GetResourceFromDeviceRequest) ProtoReflect() protoreflect.Message {
mi := &file_grpc_gateway_pb_devices_proto_msgTypes[4]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use GetResourceFromDeviceRequest.ProtoReflect.Descriptor instead.
func (*GetResourceFromDeviceRequest) Descriptor() ([]byte, []int) {
return file_grpc_gateway_pb_devices_proto_rawDescGZIP(), []int{4}
}
func (x *GetResourceFromDeviceRequest) GetResourceId() *commands.ResourceId {
if x != nil {
return x.ResourceId
}
return nil
}
func (x *GetResourceFromDeviceRequest) GetResourceInterface() string {
if x != nil {
return x.ResourceInterface
}
return ""
}
func (x *GetResourceFromDeviceRequest) GetTimeToLive() int64 {
if x != nil {
return x.TimeToLive
}
return 0
}
func (x *GetResourceFromDeviceRequest) GetEtag() [][]byte {
if x != nil {
return x.Etag
}
return nil
}
type GetResourceFromDeviceResponse struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
Data *events.ResourceRetrieved `protobuf:"bytes,1,opt,name=data,proto3" json:"data,omitempty"`
}
func (x *GetResourceFromDeviceResponse) Reset() {
*x = GetResourceFromDeviceResponse{}
if protoimpl.UnsafeEnabled {
mi := &file_grpc_gateway_pb_devices_proto_msgTypes[5]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *GetResourceFromDeviceResponse) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*GetResourceFromDeviceResponse) ProtoMessage() {}
func (x *GetResourceFromDeviceResponse) ProtoReflect() protoreflect.Message {
mi := &file_grpc_gateway_pb_devices_proto_msgTypes[5]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use GetResourceFromDeviceResponse.ProtoReflect.Descriptor instead.
func (*GetResourceFromDeviceResponse) Descriptor() ([]byte, []int) {
return file_grpc_gateway_pb_devices_proto_rawDescGZIP(), []int{5}
}
func (x *GetResourceFromDeviceResponse) GetData() *events.ResourceRetrieved {
if x != nil {
return x.Data
}
return nil
}
type ResourceIdFilter struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
ResourceId *commands.ResourceId `protobuf:"bytes,1,opt,name=resource_id,json=resourceId,proto3" json:"resource_id,omitempty"` // Filter specific resources
Etag [][]byte `protobuf:"bytes,2,rep,name=etag,proto3" json:"etag,omitempty"` // Optional; resource_id.{deviceId, href} must not be empty
}
func (x *ResourceIdFilter) Reset() {
*x = ResourceIdFilter{}
if protoimpl.UnsafeEnabled {
mi := &file_grpc_gateway_pb_devices_proto_msgTypes[6]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *ResourceIdFilter) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*ResourceIdFilter) ProtoMessage() {}
func (x *ResourceIdFilter) ProtoReflect() protoreflect.Message {
mi := &file_grpc_gateway_pb_devices_proto_msgTypes[6]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use ResourceIdFilter.ProtoReflect.Descriptor instead.
func (*ResourceIdFilter) Descriptor() ([]byte, []int) {
return file_grpc_gateway_pb_devices_proto_rawDescGZIP(), []int{6}
}
func (x *ResourceIdFilter) GetResourceId() *commands.ResourceId {
if x != nil {
return x.ResourceId
}
return nil
}
func (x *ResourceIdFilter) GetEtag() [][]byte {
if x != nil {
return x.Etag
}
return nil
}
type GetResourcesRequest struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// Deprecated: Marked as deprecated in grpc-gateway/pb/devices.proto.
HttpResourceIdFilter []string `protobuf:"bytes,1,rep,name=http_resource_id_filter,json=httpResourceIdFilter,proto3" json:"http_resource_id_filter,omitempty"` // Format: {deviceID}{href}(?etag=abc), e.g., "ae424c58-e517-4494-6de7-583536c48213/oic/d?etag=abc"
DeviceIdFilter []string `protobuf:"bytes,2,rep,name=device_id_filter,json=deviceIdFilter,proto3" json:"device_id_filter,omitempty"` // Filter devices by deviceID
TypeFilter []string `protobuf:"bytes,3,rep,name=type_filter,json=typeFilter,proto3" json:"type_filter,omitempty"` // Filter devices by resource types in the oic/d resource
ResourceIdFilter []*ResourceIdFilter `protobuf:"bytes,4,rep,name=resource_id_filter,json=resourceIdFilter,proto3" json:"resource_id_filter,omitempty"` // New resource ID filter. For HTTP requests, use it multiple times as a query parameter like "resourceIdFilter={deviceID}{href}(?etag=abc)"
}
func (x *GetResourcesRequest) Reset() {
*x = GetResourcesRequest{}
if protoimpl.UnsafeEnabled {
mi := &file_grpc_gateway_pb_devices_proto_msgTypes[7]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *GetResourcesRequest) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*GetResourcesRequest) ProtoMessage() {}
func (x *GetResourcesRequest) ProtoReflect() protoreflect.Message {
mi := &file_grpc_gateway_pb_devices_proto_msgTypes[7]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use GetResourcesRequest.ProtoReflect.Descriptor instead.
func (*GetResourcesRequest) Descriptor() ([]byte, []int) {
return file_grpc_gateway_pb_devices_proto_rawDescGZIP(), []int{7}
}
// Deprecated: Marked as deprecated in grpc-gateway/pb/devices.proto.
func (x *GetResourcesRequest) GetHttpResourceIdFilter() []string {
if x != nil {
return x.HttpResourceIdFilter
}
return nil
}
func (x *GetResourcesRequest) GetDeviceIdFilter() []string {
if x != nil {
return x.DeviceIdFilter
}
return nil
}
func (x *GetResourcesRequest) GetTypeFilter() []string {
if x != nil {
return x.TypeFilter
}
return nil
}
func (x *GetResourcesRequest) GetResourceIdFilter() []*ResourceIdFilter {
if x != nil {
return x.ResourceIdFilter
}
return nil
}
type Resource struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
Types []string `protobuf:"bytes,1,rep,name=types,proto3" json:"types,omitempty"`
Data *events.ResourceChanged `protobuf:"bytes,2,opt,name=data,proto3" json:"data,omitempty"`
}
func (x *Resource) Reset() {
*x = Resource{}
if protoimpl.UnsafeEnabled {
mi := &file_grpc_gateway_pb_devices_proto_msgTypes[8]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *Resource) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*Resource) ProtoMessage() {}
func (x *Resource) ProtoReflect() protoreflect.Message {
mi := &file_grpc_gateway_pb_devices_proto_msgTypes[8]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use Resource.ProtoReflect.Descriptor instead.
func (*Resource) Descriptor() ([]byte, []int) {
return file_grpc_gateway_pb_devices_proto_rawDescGZIP(), []int{8}
}
func (x *Resource) GetTypes() []string {
if x != nil {
return x.Types
}
return nil
}
func (x *Resource) GetData() *events.ResourceChanged {
if x != nil {
return x.Data
}
return nil
}
type UpdateResourceRequest struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
ResourceId *commands.ResourceId `protobuf:"bytes,1,opt,name=resource_id,json=resourceId,proto3" json:"resource_id,omitempty"`
ResourceInterface string `protobuf:"bytes,3,opt,name=resource_interface,json=resourceInterface,proto3" json:"resource_interface,omitempty"`
TimeToLive int64 `protobuf:"varint,4,opt,name=time_to_live,json=timeToLive,proto3" json:"time_to_live,omitempty"` // command validity in nanoseconds. 0 means forever and minimal value is 100000000 (100ms).
Content *Content `protobuf:"bytes,2,opt,name=content,proto3" json:"content,omitempty"`
Force bool `protobuf:"varint,5,opt,name=force,proto3" json:"force,omitempty"` // if true, the command will be executed even if the resource does not exist
Async bool `protobuf:"varint,6,opt,name=async,proto3" json:"async,omitempty"` // if true, the command will finish immediately after pending event is created
}
func (x *UpdateResourceRequest) Reset() {
*x = UpdateResourceRequest{}
if protoimpl.UnsafeEnabled {
mi := &file_grpc_gateway_pb_devices_proto_msgTypes[9]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *UpdateResourceRequest) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*UpdateResourceRequest) ProtoMessage() {}
func (x *UpdateResourceRequest) ProtoReflect() protoreflect.Message {
mi := &file_grpc_gateway_pb_devices_proto_msgTypes[9]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use UpdateResourceRequest.ProtoReflect.Descriptor instead.
func (*UpdateResourceRequest) Descriptor() ([]byte, []int) {
return file_grpc_gateway_pb_devices_proto_rawDescGZIP(), []int{9}
}
func (x *UpdateResourceRequest) GetResourceId() *commands.ResourceId {
if x != nil {
return x.ResourceId
}
return nil
}
func (x *UpdateResourceRequest) GetResourceInterface() string {
if x != nil {
return x.ResourceInterface
}
return ""
}
func (x *UpdateResourceRequest) GetTimeToLive() int64 {
if x != nil {
return x.TimeToLive
}
return 0
}
func (x *UpdateResourceRequest) GetContent() *Content {
if x != nil {
return x.Content
}
return nil
}
func (x *UpdateResourceRequest) GetForce() bool {
if x != nil {
return x.Force
}
return false
}
func (x *UpdateResourceRequest) GetAsync() bool {
if x != nil {
return x.Async
}
return false
}
type UpdateResourceResponse struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
Data *events.ResourceUpdated `protobuf:"bytes,1,opt,name=data,proto3" json:"data,omitempty"`
}
func (x *UpdateResourceResponse) Reset() {
*x = UpdateResourceResponse{}
if protoimpl.UnsafeEnabled {
mi := &file_grpc_gateway_pb_devices_proto_msgTypes[10]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *UpdateResourceResponse) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*UpdateResourceResponse) ProtoMessage() {}
func (x *UpdateResourceResponse) ProtoReflect() protoreflect.Message {
mi := &file_grpc_gateway_pb_devices_proto_msgTypes[10]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use UpdateResourceResponse.ProtoReflect.Descriptor instead.
func (*UpdateResourceResponse) Descriptor() ([]byte, []int) {
return file_grpc_gateway_pb_devices_proto_rawDescGZIP(), []int{10}
}
func (x *UpdateResourceResponse) GetData() *events.ResourceUpdated {
if x != nil {
return x.Data
}
return nil
}
type SubscribeToEvents struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache
unknownFields protoimpl.UnknownFields
// Types that are assignable to Action:
//
// *SubscribeToEvents_CreateSubscription_
// *SubscribeToEvents_CancelSubscription_
Action isSubscribeToEvents_Action `protobuf_oneof:"action"`
CorrelationId string `protobuf:"bytes,101,opt,name=correlation_id,json=correlationId,proto3" json:"correlation_id,omitempty"` // for pairing request SubscribeToEvents with Event.OperationProcessed
}
func (x *SubscribeToEvents) Reset() {
*x = SubscribeToEvents{}
if protoimpl.UnsafeEnabled {
mi := &file_grpc_gateway_pb_devices_proto_msgTypes[11]
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
ms.StoreMessageInfo(mi)
}
}
func (x *SubscribeToEvents) String() string {
return protoimpl.X.MessageStringOf(x)
}
func (*SubscribeToEvents) ProtoMessage() {}
func (x *SubscribeToEvents) ProtoReflect() protoreflect.Message {
mi := &file_grpc_gateway_pb_devices_proto_msgTypes[11]
if protoimpl.UnsafeEnabled && x != nil {
ms := protoimpl.X.MessageStateOf(protoimpl.Pointer(x))
if ms.LoadMessageInfo() == nil {
ms.StoreMessageInfo(mi)
}
return ms
}
return mi.MessageOf(x)
}
// Deprecated: Use SubscribeToEvents.ProtoReflect.Descriptor instead.
func (*SubscribeToEvents) Descriptor() ([]byte, []int) {
return file_grpc_gateway_pb_devices_proto_rawDescGZIP(), []int{11}
}
func (m *SubscribeToEvents) GetAction() isSubscribeToEvents_Action {
if m != nil {
return m.Action
}
return nil
}
func (x *SubscribeToEvents) GetCreateSubscription() *SubscribeToEvents_CreateSubscription {
if x, ok := x.GetAction().(*SubscribeToEvents_CreateSubscription_); ok {
return x.CreateSubscription
}
return nil
}
func (x *SubscribeToEvents) GetCancelSubscription() *SubscribeToEvents_CancelSubscription {
if x, ok := x.GetAction().(*SubscribeToEvents_CancelSubscription_); ok {
return x.CancelSubscription
}
return nil
}
func (x *SubscribeToEvents) GetCorrelationId() string {
if x != nil {
return x.CorrelationId
}
return ""
}
type isSubscribeToEvents_Action interface {
isSubscribeToEvents_Action()
}
type SubscribeToEvents_CreateSubscription_ struct {
CreateSubscription *SubscribeToEvents_CreateSubscription `protobuf:"bytes,1,opt,name=create_subscription,json=createSubscription,proto3,oneof"`
}
type SubscribeToEvents_CancelSubscription_ struct {
CancelSubscription *SubscribeToEvents_CancelSubscription `protobuf:"bytes,2,opt,name=cancel_subscription,json=cancelSubscription,proto3,oneof"`
}
func (*SubscribeToEvents_CreateSubscription_) isSubscribeToEvents_Action() {}
func (*SubscribeToEvents_CancelSubscription_) isSubscribeToEvents_Action() {}
type Event struct {
state protoimpl.MessageState
sizeCache protoimpl.SizeCache