-
Notifications
You must be signed in to change notification settings - Fork 13
/
Copy pathresources.pb.go
1690 lines (1509 loc) · 60.4 KB
/
resources.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.
// source: cs3/storage/provider/v1beta1/resources.proto
package providerv1beta1
import (
fmt "fmt"
v1beta12 "github.com/cs3org/go-cs3apis/cs3/identity/group/v1beta1"
v1beta11 "github.com/cs3org/go-cs3apis/cs3/identity/user/v1beta1"
v1beta1 "github.com/cs3org/go-cs3apis/cs3/types/v1beta1"
proto "github.com/golang/protobuf/proto"
math "math"
)
// Reference imports to suppress errors if they are not otherwise used.
var _ = proto.Marshal
var _ = fmt.Errorf
var _ = math.Inf
// This is a compile-time assertion to ensure that this generated file
// is compatible with the proto package it is being compiled against.
// A compilation error at this line likely means your copy of the
// proto package needs to be updated.
const _ = proto.ProtoPackageIsVersion3 // please upgrade the proto package
// The available types of resources.
type ResourceType int32
const (
ResourceType_RESOURCE_TYPE_INVALID ResourceType = 0
// The file type represents a type
// that holds arbitrary data.
// Service implementors usually map this type
// to files (local filesystem) or objects
// (Amazon S3).
ResourceType_RESOURCE_TYPE_FILE ResourceType = 1
// The container type represents a type
// that can contain another types.
// Service implementors usually map this type
// to folders (local filesystem) or buckets
// (Amazon S3).
ResourceType_RESOURCE_TYPE_CONTAINER ResourceType = 2
// This represents a reference type which points
// to another resource where client MAY be redirected.
// Client SHOULD use the ResourceInfo.target
// reference for a subsequent call.
ResourceType_RESOURCE_TYPE_REFERENCE ResourceType = 3
// This represents a symbolic link type if the underlying
// storage system supports it.
// Symlink target SHOULD NOT be interpreted by the clients.
ResourceType_RESOURCE_TYPE_SYMLINK ResourceType = 4
// Internal resource type for some specific resources inside
// a storage implementation.
// For example, this type could be used to represent
// a device file on a Linux filesystem.
// Another example could be to represent an ongoing upload,
// where an hypothetically user interface could show a loading icon
// on this type of resources until the upload operation is completed.
// Internal resources SHOULD NOT be moved to a different storage
// provider.
ResourceType_RESOURCE_TYPE_INTERNAL ResourceType = 5
)
var ResourceType_name = map[int32]string{
0: "RESOURCE_TYPE_INVALID",
1: "RESOURCE_TYPE_FILE",
2: "RESOURCE_TYPE_CONTAINER",
3: "RESOURCE_TYPE_REFERENCE",
4: "RESOURCE_TYPE_SYMLINK",
5: "RESOURCE_TYPE_INTERNAL",
}
var ResourceType_value = map[string]int32{
"RESOURCE_TYPE_INVALID": 0,
"RESOURCE_TYPE_FILE": 1,
"RESOURCE_TYPE_CONTAINER": 2,
"RESOURCE_TYPE_REFERENCE": 3,
"RESOURCE_TYPE_SYMLINK": 4,
"RESOURCE_TYPE_INTERNAL": 5,
}
func (x ResourceType) String() string {
return proto.EnumName(ResourceType_name, int32(x))
}
func (ResourceType) EnumDescriptor() ([]byte, []int) {
return fileDescriptor_b91600c359c2e479, []int{0}
}
// The type of checksum to use.
type ResourceChecksumType int32
const (
ResourceChecksumType_RESOURCE_CHECKSUM_TYPE_INVALID ResourceChecksumType = 0
// unset means no checksum is set.
ResourceChecksumType_RESOURCE_CHECKSUM_TYPE_UNSET ResourceChecksumType = 1
// Use Adler32 checksum.
ResourceChecksumType_RESOURCE_CHECKSUM_TYPE_ADLER32 ResourceChecksumType = 2
// Use MD5 checksum.
ResourceChecksumType_RESOURCE_CHECKSUM_TYPE_MD5 ResourceChecksumType = 3
// Use SHA-1 checksum.
ResourceChecksumType_RESOURCE_CHECKSUM_TYPE_SHA1 ResourceChecksumType = 4
)
var ResourceChecksumType_name = map[int32]string{
0: "RESOURCE_CHECKSUM_TYPE_INVALID",
1: "RESOURCE_CHECKSUM_TYPE_UNSET",
2: "RESOURCE_CHECKSUM_TYPE_ADLER32",
3: "RESOURCE_CHECKSUM_TYPE_MD5",
4: "RESOURCE_CHECKSUM_TYPE_SHA1",
}
var ResourceChecksumType_value = map[string]int32{
"RESOURCE_CHECKSUM_TYPE_INVALID": 0,
"RESOURCE_CHECKSUM_TYPE_UNSET": 1,
"RESOURCE_CHECKSUM_TYPE_ADLER32": 2,
"RESOURCE_CHECKSUM_TYPE_MD5": 3,
"RESOURCE_CHECKSUM_TYPE_SHA1": 4,
}
func (x ResourceChecksumType) String() string {
return proto.EnumName(ResourceChecksumType_name, int32(x))
}
func (ResourceChecksumType) EnumDescriptor() ([]byte, []int) {
return fileDescriptor_b91600c359c2e479, []int{1}
}
// The type of the grantee.
type GranteeType int32
const (
GranteeType_GRANTEE_TYPE_INVALID GranteeType = 0
// This type represents an individual.
GranteeType_GRANTEE_TYPE_USER GranteeType = 1
// This type represents a group of individuals.
GranteeType_GRANTEE_TYPE_GROUP GranteeType = 2
)
var GranteeType_name = map[int32]string{
0: "GRANTEE_TYPE_INVALID",
1: "GRANTEE_TYPE_USER",
2: "GRANTEE_TYPE_GROUP",
}
var GranteeType_value = map[string]int32{
"GRANTEE_TYPE_INVALID": 0,
"GRANTEE_TYPE_USER": 1,
"GRANTEE_TYPE_GROUP": 2,
}
func (x GranteeType) String() string {
return proto.EnumName(GranteeType_name, int32(x))
}
func (GranteeType) EnumDescriptor() ([]byte, []int) {
return fileDescriptor_b91600c359c2e479, []int{2}
}
// Represents the information (metadata) about
// a storage resource organized in a hierarchical namespace (file, directory/container, reference, symlink, ...).
type ResourceInfo struct {
// OPTIONAL.
// Opaque information.
Opaque *v1beta1.Opaque `protobuf:"bytes,1,opt,name=opaque,proto3" json:"opaque,omitempty"`
// REQUIRED.
// The type of the resource (container, file, ...)
// See the enum ResourceType for all possible types.
Type ResourceType `protobuf:"varint,2,opt,name=type,proto3,enum=cs3.storage.provider.v1beta1.ResourceType" json:"type,omitempty"`
// REQUIRED.
// Opaque unique identifier of the resource.
Id *ResourceId `protobuf:"bytes,3,opt,name=id,proto3" json:"id,omitempty"`
// REQUIRED.
// The data checksum for the file resource.
// For all other resources, the checksum is unset.
Checksum *ResourceChecksum `protobuf:"bytes,4,opt,name=checksum,proto3" json:"checksum,omitempty"`
// REQUIRED.
// As decribed in https://tools.ietf.org/html/rfc7232#section-2.3
// For file resources, the etag must change if data or metadata changes.
// For container types, the etag must change if etag of any of the (indirectly) contained resources change.
// For reference types, the etag must change if etag of the target changes and the target is on the same storage provider.
// In all other cases the etag does not change.
Etag string `protobuf:"bytes,5,opt,name=etag,proto3" json:"etag,omitempty"`
// REQUIRED.
// As described in [RFC 2015](https://tools.ietf.org/html/rfc2045#page-7)
MimeType string `protobuf:"bytes,6,opt,name=mime_type,json=mimeType,proto3" json:"mime_type,omitempty"`
// REQUIRED.
// Last modification time (mtime) of file or directory contents.
// For reference types this is NOT the mtime of the target.
Mtime *v1beta1.Timestamp `protobuf:"bytes,7,opt,name=mtime,proto3" json:"mtime,omitempty"`
// REQUIRED.
// The path for the resource:
// MUST start with `/` when the reference had no resource_id, indicating an absolute path.
// MUST start with `.` when the reference had a resource_id, indicating a relative path.
Path string `protobuf:"bytes,8,opt,name=path,proto3" json:"path,omitempty"`
// REQUIRED.
// The set of permissions for the resource effective for the authenticated user.
PermissionSet *ResourcePermissions `protobuf:"bytes,9,opt,name=permission_set,json=permissionSet,proto3" json:"permission_set,omitempty"`
// REQUIRED.
// The size of the resource in bytes (file size)
// TODO(moscicki): This is undefined for container type.
// Is the accounting recursive?, could it be set to 0 for directories if recursive not supported? use another field?
// TODO(moscicki): This needs to be defined also for other types (such as a symlink to a directory or file)
Size uint64 `protobuf:"varint,10,opt,name=size,proto3" json:"size,omitempty"`
// REQUIRED:
// Identifier of the owner of the resource.
Owner *v1beta11.UserId `protobuf:"bytes,11,opt,name=owner,proto3" json:"owner,omitempty"`
// REQUIRED if ResourceType is either RESOURCE_TYPE_SYMLINK or RESOURCE_TYPE_REFERENCE
Target string `protobuf:"bytes,12,opt,name=target,proto3" json:"target,omitempty"`
// OPTIONAL.
// Additional metadata attached to the resource.
// If resource type is RESOURCE_TYPE_REFERENCE it MUST
// be specified.
CanonicalMetadata *CanonicalMetadata `protobuf:"bytes,13,opt,name=canonical_metadata,json=canonicalMetadata,proto3" json:"canonical_metadata,omitempty"`
// OPTIONAL.
// Arbitrary metadata attached to a resource.
ArbitraryMetadata *ArbitraryMetadata `protobuf:"bytes,14,opt,name=arbitrary_metadata,json=arbitraryMetadata,proto3" json:"arbitrary_metadata,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *ResourceInfo) Reset() { *m = ResourceInfo{} }
func (m *ResourceInfo) String() string { return proto.CompactTextString(m) }
func (*ResourceInfo) ProtoMessage() {}
func (*ResourceInfo) Descriptor() ([]byte, []int) {
return fileDescriptor_b91600c359c2e479, []int{0}
}
func (m *ResourceInfo) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_ResourceInfo.Unmarshal(m, b)
}
func (m *ResourceInfo) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_ResourceInfo.Marshal(b, m, deterministic)
}
func (m *ResourceInfo) XXX_Merge(src proto.Message) {
xxx_messageInfo_ResourceInfo.Merge(m, src)
}
func (m *ResourceInfo) XXX_Size() int {
return xxx_messageInfo_ResourceInfo.Size(m)
}
func (m *ResourceInfo) XXX_DiscardUnknown() {
xxx_messageInfo_ResourceInfo.DiscardUnknown(m)
}
var xxx_messageInfo_ResourceInfo proto.InternalMessageInfo
func (m *ResourceInfo) GetOpaque() *v1beta1.Opaque {
if m != nil {
return m.Opaque
}
return nil
}
func (m *ResourceInfo) GetType() ResourceType {
if m != nil {
return m.Type
}
return ResourceType_RESOURCE_TYPE_INVALID
}
func (m *ResourceInfo) GetId() *ResourceId {
if m != nil {
return m.Id
}
return nil
}
func (m *ResourceInfo) GetChecksum() *ResourceChecksum {
if m != nil {
return m.Checksum
}
return nil
}
func (m *ResourceInfo) GetEtag() string {
if m != nil {
return m.Etag
}
return ""
}
func (m *ResourceInfo) GetMimeType() string {
if m != nil {
return m.MimeType
}
return ""
}
func (m *ResourceInfo) GetMtime() *v1beta1.Timestamp {
if m != nil {
return m.Mtime
}
return nil
}
func (m *ResourceInfo) GetPath() string {
if m != nil {
return m.Path
}
return ""
}
func (m *ResourceInfo) GetPermissionSet() *ResourcePermissions {
if m != nil {
return m.PermissionSet
}
return nil
}
func (m *ResourceInfo) GetSize() uint64 {
if m != nil {
return m.Size
}
return 0
}
func (m *ResourceInfo) GetOwner() *v1beta11.UserId {
if m != nil {
return m.Owner
}
return nil
}
func (m *ResourceInfo) GetTarget() string {
if m != nil {
return m.Target
}
return ""
}
func (m *ResourceInfo) GetCanonicalMetadata() *CanonicalMetadata {
if m != nil {
return m.CanonicalMetadata
}
return nil
}
func (m *ResourceInfo) GetArbitraryMetadata() *ArbitraryMetadata {
if m != nil {
return m.ArbitraryMetadata
}
return nil
}
// CanonicalMetadata contains extra metadata
// attached to a resource. This message and the Opaque
// message differ in that Opaque allows service implementors
// to include any extra metadata in any format and most clients
// will ignore it. However, the CanonicalMetadata message
// contains well defined fileds that clients MUST understand if
// they are specified.
type CanonicalMetadata struct {
// REQUIRED if resource type is RESOURCE_TYPE_REFERENCE.
// The target reference the resource points to.
Target *Reference `protobuf:"bytes,1,opt,name=target,proto3" json:"target,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *CanonicalMetadata) Reset() { *m = CanonicalMetadata{} }
func (m *CanonicalMetadata) String() string { return proto.CompactTextString(m) }
func (*CanonicalMetadata) ProtoMessage() {}
func (*CanonicalMetadata) Descriptor() ([]byte, []int) {
return fileDescriptor_b91600c359c2e479, []int{1}
}
func (m *CanonicalMetadata) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_CanonicalMetadata.Unmarshal(m, b)
}
func (m *CanonicalMetadata) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_CanonicalMetadata.Marshal(b, m, deterministic)
}
func (m *CanonicalMetadata) XXX_Merge(src proto.Message) {
xxx_messageInfo_CanonicalMetadata.Merge(m, src)
}
func (m *CanonicalMetadata) XXX_Size() int {
return xxx_messageInfo_CanonicalMetadata.Size(m)
}
func (m *CanonicalMetadata) XXX_DiscardUnknown() {
xxx_messageInfo_CanonicalMetadata.DiscardUnknown(m)
}
var xxx_messageInfo_CanonicalMetadata proto.InternalMessageInfo
func (m *CanonicalMetadata) GetTarget() *Reference {
if m != nil {
return m.Target
}
return nil
}
// Arbitrary metadata than can be set to the resource.
type ArbitraryMetadata struct {
Metadata map[string]string `protobuf:"bytes,1,rep,name=metadata,proto3" json:"metadata,omitempty" protobuf_key:"bytes,1,opt,name=key,proto3" protobuf_val:"bytes,2,opt,name=value,proto3"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *ArbitraryMetadata) Reset() { *m = ArbitraryMetadata{} }
func (m *ArbitraryMetadata) String() string { return proto.CompactTextString(m) }
func (*ArbitraryMetadata) ProtoMessage() {}
func (*ArbitraryMetadata) Descriptor() ([]byte, []int) {
return fileDescriptor_b91600c359c2e479, []int{2}
}
func (m *ArbitraryMetadata) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_ArbitraryMetadata.Unmarshal(m, b)
}
func (m *ArbitraryMetadata) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_ArbitraryMetadata.Marshal(b, m, deterministic)
}
func (m *ArbitraryMetadata) XXX_Merge(src proto.Message) {
xxx_messageInfo_ArbitraryMetadata.Merge(m, src)
}
func (m *ArbitraryMetadata) XXX_Size() int {
return xxx_messageInfo_ArbitraryMetadata.Size(m)
}
func (m *ArbitraryMetadata) XXX_DiscardUnknown() {
xxx_messageInfo_ArbitraryMetadata.DiscardUnknown(m)
}
var xxx_messageInfo_ArbitraryMetadata proto.InternalMessageInfo
func (m *ArbitraryMetadata) GetMetadata() map[string]string {
if m != nil {
return m.Metadata
}
return nil
}
// The checksum to verify
// the integrity of a resource.
type ResourceChecksum struct {
// REQUIRED.
// The type of checksum to use.
// If no checksum is provided,
// type MUST be RESOURCE_CHECKSUM_TYPE_UNSET.
Type ResourceChecksumType `protobuf:"varint,1,opt,name=type,proto3,enum=cs3.storage.provider.v1beta1.ResourceChecksumType" json:"type,omitempty"`
// MUST be specified if type is not
// RESOURCE_CHECKSUM_TYPE_UNSET or type is not
// RESOURCE_CHECKSUM_TYPE_INVALID.
// MUST be the hexadecimal representation of the cheksum.
// The value is case-insensitive, so
// "1E603A8", "1e603a8" or "1e603A8" are the same.
Sum string `protobuf:"bytes,2,opt,name=sum,proto3" json:"sum,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *ResourceChecksum) Reset() { *m = ResourceChecksum{} }
func (m *ResourceChecksum) String() string { return proto.CompactTextString(m) }
func (*ResourceChecksum) ProtoMessage() {}
func (*ResourceChecksum) Descriptor() ([]byte, []int) {
return fileDescriptor_b91600c359c2e479, []int{3}
}
func (m *ResourceChecksum) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_ResourceChecksum.Unmarshal(m, b)
}
func (m *ResourceChecksum) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_ResourceChecksum.Marshal(b, m, deterministic)
}
func (m *ResourceChecksum) XXX_Merge(src proto.Message) {
xxx_messageInfo_ResourceChecksum.Merge(m, src)
}
func (m *ResourceChecksum) XXX_Size() int {
return xxx_messageInfo_ResourceChecksum.Size(m)
}
func (m *ResourceChecksum) XXX_DiscardUnknown() {
xxx_messageInfo_ResourceChecksum.DiscardUnknown(m)
}
var xxx_messageInfo_ResourceChecksum proto.InternalMessageInfo
func (m *ResourceChecksum) GetType() ResourceChecksumType {
if m != nil {
return m.Type
}
return ResourceChecksumType_RESOURCE_CHECKSUM_TYPE_INVALID
}
func (m *ResourceChecksum) GetSum() string {
if m != nil {
return m.Sum
}
return ""
}
// When negotiating the user of checksum types
// between client and server, this structure
// defines the priority of the checksum.
// Priority 0 means highest priority.
type ResourceChecksumPriority struct {
Type ResourceChecksumType `protobuf:"varint,1,opt,name=type,proto3,enum=cs3.storage.provider.v1beta1.ResourceChecksumType" json:"type,omitempty"`
Priority uint32 `protobuf:"varint,2,opt,name=priority,proto3" json:"priority,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *ResourceChecksumPriority) Reset() { *m = ResourceChecksumPriority{} }
func (m *ResourceChecksumPriority) String() string { return proto.CompactTextString(m) }
func (*ResourceChecksumPriority) ProtoMessage() {}
func (*ResourceChecksumPriority) Descriptor() ([]byte, []int) {
return fileDescriptor_b91600c359c2e479, []int{4}
}
func (m *ResourceChecksumPriority) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_ResourceChecksumPriority.Unmarshal(m, b)
}
func (m *ResourceChecksumPriority) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_ResourceChecksumPriority.Marshal(b, m, deterministic)
}
func (m *ResourceChecksumPriority) XXX_Merge(src proto.Message) {
xxx_messageInfo_ResourceChecksumPriority.Merge(m, src)
}
func (m *ResourceChecksumPriority) XXX_Size() int {
return xxx_messageInfo_ResourceChecksumPriority.Size(m)
}
func (m *ResourceChecksumPriority) XXX_DiscardUnknown() {
xxx_messageInfo_ResourceChecksumPriority.DiscardUnknown(m)
}
var xxx_messageInfo_ResourceChecksumPriority proto.InternalMessageInfo
func (m *ResourceChecksumPriority) GetType() ResourceChecksumType {
if m != nil {
return m.Type
}
return ResourceChecksumType_RESOURCE_CHECKSUM_TYPE_INVALID
}
func (m *ResourceChecksumPriority) GetPriority() uint32 {
if m != nil {
return m.Priority
}
return 0
}
// The mechanism to identify a resource in the CS3 namespace.
// It can represent path based, id based and combined references:
// The storage registry uses the storage_id to determine the responsible storage provider.
// When the storage_id is not available it will use the path.
// In a URL the different components can be represented in a string using the following layout:
// <storage_id>!<node_id>:<path>
type Reference struct {
// OPTIONAL
ResourceId *ResourceId `protobuf:"bytes,1,opt,name=resource_id,json=resourceId,proto3" json:"resource_id,omitempty"`
// OPTIONAL.
// When starting with `/` represents an absolute path. In this case the resource_id MUST be empty.
// When starting with `.` represents a path relative to the resource_id. The resource_id MUST be given.
// When path is empty the resource_id must be set. Used to look up the path for a resource_id.
Path string `protobuf:"bytes,2,opt,name=path,proto3" json:"path,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Reference) Reset() { *m = Reference{} }
func (m *Reference) String() string { return proto.CompactTextString(m) }
func (*Reference) ProtoMessage() {}
func (*Reference) Descriptor() ([]byte, []int) {
return fileDescriptor_b91600c359c2e479, []int{5}
}
func (m *Reference) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Reference.Unmarshal(m, b)
}
func (m *Reference) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Reference.Marshal(b, m, deterministic)
}
func (m *Reference) XXX_Merge(src proto.Message) {
xxx_messageInfo_Reference.Merge(m, src)
}
func (m *Reference) XXX_Size() int {
return xxx_messageInfo_Reference.Size(m)
}
func (m *Reference) XXX_DiscardUnknown() {
xxx_messageInfo_Reference.DiscardUnknown(m)
}
var xxx_messageInfo_Reference proto.InternalMessageInfo
func (m *Reference) GetResourceId() *ResourceId {
if m != nil {
return m.ResourceId
}
return nil
}
func (m *Reference) GetPath() string {
if m != nil {
return m.Path
}
return ""
}
// A resource id uniquely identifies a
// resource in the storage provider namespace.
// A ResourceId MUST be unique in the storage provider.
type ResourceId struct {
// REQUIRED.
// The logical id of a storage. Used by the storage
// registry to determine the responsible storage provider.
StorageId string `protobuf:"bytes,1,opt,name=storage_id,json=storageId,proto3" json:"storage_id,omitempty"`
// REQUIRED.
// The internal id used by service implementor to
// uniquely identity the resource in the internal
// implementation of the service.
OpaqueId string `protobuf:"bytes,2,opt,name=opaque_id,json=opaqueId,proto3" json:"opaque_id,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *ResourceId) Reset() { *m = ResourceId{} }
func (m *ResourceId) String() string { return proto.CompactTextString(m) }
func (*ResourceId) ProtoMessage() {}
func (*ResourceId) Descriptor() ([]byte, []int) {
return fileDescriptor_b91600c359c2e479, []int{6}
}
func (m *ResourceId) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_ResourceId.Unmarshal(m, b)
}
func (m *ResourceId) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_ResourceId.Marshal(b, m, deterministic)
}
func (m *ResourceId) XXX_Merge(src proto.Message) {
xxx_messageInfo_ResourceId.Merge(m, src)
}
func (m *ResourceId) XXX_Size() int {
return xxx_messageInfo_ResourceId.Size(m)
}
func (m *ResourceId) XXX_DiscardUnknown() {
xxx_messageInfo_ResourceId.DiscardUnknown(m)
}
var xxx_messageInfo_ResourceId proto.InternalMessageInfo
func (m *ResourceId) GetStorageId() string {
if m != nil {
return m.StorageId
}
return ""
}
func (m *ResourceId) GetOpaqueId() string {
if m != nil {
return m.OpaqueId
}
return ""
}
// The representation of permissions attached to a resource.
type ResourcePermissions struct {
AddGrant bool `protobuf:"varint,1,opt,name=add_grant,json=addGrant,proto3" json:"add_grant,omitempty"`
CreateContainer bool `protobuf:"varint,2,opt,name=create_container,json=createContainer,proto3" json:"create_container,omitempty"`
Delete bool `protobuf:"varint,3,opt,name=delete,proto3" json:"delete,omitempty"`
GetPath bool `protobuf:"varint,5,opt,name=get_path,json=getPath,proto3" json:"get_path,omitempty"`
GetQuota bool `protobuf:"varint,6,opt,name=get_quota,json=getQuota,proto3" json:"get_quota,omitempty"`
InitiateFileDownload bool `protobuf:"varint,7,opt,name=initiate_file_download,json=initiateFileDownload,proto3" json:"initiate_file_download,omitempty"`
InitiateFileUpload bool `protobuf:"varint,8,opt,name=initiate_file_upload,json=initiateFileUpload,proto3" json:"initiate_file_upload,omitempty"`
ListGrants bool `protobuf:"varint,9,opt,name=list_grants,json=listGrants,proto3" json:"list_grants,omitempty"`
ListContainer bool `protobuf:"varint,10,opt,name=list_container,json=listContainer,proto3" json:"list_container,omitempty"`
ListFileVersions bool `protobuf:"varint,11,opt,name=list_file_versions,json=listFileVersions,proto3" json:"list_file_versions,omitempty"`
ListRecycle bool `protobuf:"varint,12,opt,name=list_recycle,json=listRecycle,proto3" json:"list_recycle,omitempty"`
Move bool `protobuf:"varint,13,opt,name=move,proto3" json:"move,omitempty"`
RemoveGrant bool `protobuf:"varint,14,opt,name=remove_grant,json=removeGrant,proto3" json:"remove_grant,omitempty"`
PurgeRecycle bool `protobuf:"varint,15,opt,name=purge_recycle,json=purgeRecycle,proto3" json:"purge_recycle,omitempty"`
RestoreFileVersion bool `protobuf:"varint,16,opt,name=restore_file_version,json=restoreFileVersion,proto3" json:"restore_file_version,omitempty"`
RestoreRecycleItem bool `protobuf:"varint,17,opt,name=restore_recycle_item,json=restoreRecycleItem,proto3" json:"restore_recycle_item,omitempty"`
Stat bool `protobuf:"varint,18,opt,name=stat,proto3" json:"stat,omitempty"`
UpdateGrant bool `protobuf:"varint,19,opt,name=update_grant,json=updateGrant,proto3" json:"update_grant,omitempty"`
DenyGrant bool `protobuf:"varint,20,opt,name=deny_grant,json=denyGrant,proto3" json:"deny_grant,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *ResourcePermissions) Reset() { *m = ResourcePermissions{} }
func (m *ResourcePermissions) String() string { return proto.CompactTextString(m) }
func (*ResourcePermissions) ProtoMessage() {}
func (*ResourcePermissions) Descriptor() ([]byte, []int) {
return fileDescriptor_b91600c359c2e479, []int{7}
}
func (m *ResourcePermissions) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_ResourcePermissions.Unmarshal(m, b)
}
func (m *ResourcePermissions) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_ResourcePermissions.Marshal(b, m, deterministic)
}
func (m *ResourcePermissions) XXX_Merge(src proto.Message) {
xxx_messageInfo_ResourcePermissions.Merge(m, src)
}
func (m *ResourcePermissions) XXX_Size() int {
return xxx_messageInfo_ResourcePermissions.Size(m)
}
func (m *ResourcePermissions) XXX_DiscardUnknown() {
xxx_messageInfo_ResourcePermissions.DiscardUnknown(m)
}
var xxx_messageInfo_ResourcePermissions proto.InternalMessageInfo
func (m *ResourcePermissions) GetAddGrant() bool {
if m != nil {
return m.AddGrant
}
return false
}
func (m *ResourcePermissions) GetCreateContainer() bool {
if m != nil {
return m.CreateContainer
}
return false
}
func (m *ResourcePermissions) GetDelete() bool {
if m != nil {
return m.Delete
}
return false
}
func (m *ResourcePermissions) GetGetPath() bool {
if m != nil {
return m.GetPath
}
return false
}
func (m *ResourcePermissions) GetGetQuota() bool {
if m != nil {
return m.GetQuota
}
return false
}
func (m *ResourcePermissions) GetInitiateFileDownload() bool {
if m != nil {
return m.InitiateFileDownload
}
return false
}
func (m *ResourcePermissions) GetInitiateFileUpload() bool {
if m != nil {
return m.InitiateFileUpload
}
return false
}
func (m *ResourcePermissions) GetListGrants() bool {
if m != nil {
return m.ListGrants
}
return false
}
func (m *ResourcePermissions) GetListContainer() bool {
if m != nil {
return m.ListContainer
}
return false
}
func (m *ResourcePermissions) GetListFileVersions() bool {
if m != nil {
return m.ListFileVersions
}
return false
}
func (m *ResourcePermissions) GetListRecycle() bool {
if m != nil {
return m.ListRecycle
}
return false
}
func (m *ResourcePermissions) GetMove() bool {
if m != nil {
return m.Move
}
return false
}
func (m *ResourcePermissions) GetRemoveGrant() bool {
if m != nil {
return m.RemoveGrant
}
return false
}
func (m *ResourcePermissions) GetPurgeRecycle() bool {
if m != nil {
return m.PurgeRecycle
}
return false
}
func (m *ResourcePermissions) GetRestoreFileVersion() bool {
if m != nil {
return m.RestoreFileVersion
}
return false
}
func (m *ResourcePermissions) GetRestoreRecycleItem() bool {
if m != nil {
return m.RestoreRecycleItem
}
return false
}
func (m *ResourcePermissions) GetStat() bool {
if m != nil {
return m.Stat
}
return false
}
func (m *ResourcePermissions) GetUpdateGrant() bool {
if m != nil {
return m.UpdateGrant
}
return false
}
func (m *ResourcePermissions) GetDenyGrant() bool {
if m != nil {
return m.DenyGrant
}
return false
}
// A grant grants permissions
// to a resource to a grantee.
type Grant struct {
// REQUIRED.
// The grantee of the grant.
Grantee *Grantee `protobuf:"bytes,1,opt,name=grantee,proto3" json:"grantee,omitempty"`
// REQUIRED.
// The permissions for the grant.
Permissions *ResourcePermissions `protobuf:"bytes,2,opt,name=permissions,proto3" json:"permissions,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Grant) Reset() { *m = Grant{} }
func (m *Grant) String() string { return proto.CompactTextString(m) }
func (*Grant) ProtoMessage() {}
func (*Grant) Descriptor() ([]byte, []int) {
return fileDescriptor_b91600c359c2e479, []int{8}
}
func (m *Grant) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Grant.Unmarshal(m, b)
}
func (m *Grant) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Grant.Marshal(b, m, deterministic)
}
func (m *Grant) XXX_Merge(src proto.Message) {
xxx_messageInfo_Grant.Merge(m, src)
}
func (m *Grant) XXX_Size() int {
return xxx_messageInfo_Grant.Size(m)
}
func (m *Grant) XXX_DiscardUnknown() {
xxx_messageInfo_Grant.DiscardUnknown(m)
}
var xxx_messageInfo_Grant proto.InternalMessageInfo
func (m *Grant) GetGrantee() *Grantee {
if m != nil {
return m.Grantee
}
return nil
}
func (m *Grant) GetPermissions() *ResourcePermissions {
if m != nil {
return m.Permissions
}
return nil
}
// A grantee is the receiver of a grant.
type Grantee struct {
// REQUIRED.
// The type of the grantee.
Type GranteeType `protobuf:"varint,1,opt,name=type,proto3,enum=cs3.storage.provider.v1beta1.GranteeType" json:"type,omitempty"`
// REQUIRED.
// The unique id for the grantee.
// One of the ids MUST be specified.
//
// Types that are valid to be assigned to Id:
// *Grantee_UserId
// *Grantee_GroupId
Id isGrantee_Id `protobuf_oneof:"id"`
// OPTIONAL.
// Opaque information such as UID or GID.
Opaque *v1beta1.Opaque `protobuf:"bytes,5,opt,name=opaque,proto3" json:"opaque,omitempty"`
XXX_NoUnkeyedLiteral struct{} `json:"-"`
XXX_unrecognized []byte `json:"-"`
XXX_sizecache int32 `json:"-"`
}
func (m *Grantee) Reset() { *m = Grantee{} }
func (m *Grantee) String() string { return proto.CompactTextString(m) }
func (*Grantee) ProtoMessage() {}
func (*Grantee) Descriptor() ([]byte, []int) {
return fileDescriptor_b91600c359c2e479, []int{9}
}
func (m *Grantee) XXX_Unmarshal(b []byte) error {
return xxx_messageInfo_Grantee.Unmarshal(m, b)
}
func (m *Grantee) XXX_Marshal(b []byte, deterministic bool) ([]byte, error) {
return xxx_messageInfo_Grantee.Marshal(b, m, deterministic)
}
func (m *Grantee) XXX_Merge(src proto.Message) {
xxx_messageInfo_Grantee.Merge(m, src)
}
func (m *Grantee) XXX_Size() int {
return xxx_messageInfo_Grantee.Size(m)
}
func (m *Grantee) XXX_DiscardUnknown() {
xxx_messageInfo_Grantee.DiscardUnknown(m)
}
var xxx_messageInfo_Grantee proto.InternalMessageInfo
func (m *Grantee) GetType() GranteeType {
if m != nil {
return m.Type
}
return GranteeType_GRANTEE_TYPE_INVALID
}
type isGrantee_Id interface {
isGrantee_Id()
}
type Grantee_UserId struct {
UserId *v1beta11.UserId `protobuf:"bytes,3,opt,name=user_id,json=userId,proto3,oneof"`
}
type Grantee_GroupId struct {
GroupId *v1beta12.GroupId `protobuf:"bytes,4,opt,name=group_id,json=groupId,proto3,oneof"`
}
func (*Grantee_UserId) isGrantee_Id() {}
func (*Grantee_GroupId) isGrantee_Id() {}
func (m *Grantee) GetId() isGrantee_Id {
if m != nil {
return m.Id
}
return nil
}
func (m *Grantee) GetUserId() *v1beta11.UserId {
if x, ok := m.GetId().(*Grantee_UserId); ok {
return x.UserId
}
return nil
}
func (m *Grantee) GetGroupId() *v1beta12.GroupId {
if x, ok := m.GetId().(*Grantee_GroupId); ok {
return x.GroupId
}
return nil
}
func (m *Grantee) GetOpaque() *v1beta1.Opaque {
if m != nil {
return m.Opaque
}
return nil
}
// XXX_OneofWrappers is for the internal use of the proto package.
func (*Grantee) XXX_OneofWrappers() []interface{} {
return []interface{}{
(*Grantee_UserId)(nil),
(*Grantee_GroupId)(nil),
}
}