15 #ifndef GOOGLE_CLOUD_CPP_GOOGLE_CLOUD_STORAGE_BUCKET_ACCESS_CONTROL_H
16 #define GOOGLE_CLOUD_CPP_GOOGLE_CLOUD_STORAGE_BUCKET_ACCESS_CONTROL_H
18 #include "google/cloud/storage/internal/access_control_common.h"
19 #include "google/cloud/storage/internal/patch_builder.h"
20 #include "google/cloud/storage/version.h"
21 #include "google/cloud/status_or.h"
29 struct BucketAccessControlParser;
30 struct GrpcBucketAccessControlParser;
47 using AccessControlCommon::ROLE_OWNER;
48 using AccessControlCommon::ROLE_READER;
49 using AccessControlCommon::TEAM_EDITORS;
50 using AccessControlCommon::TEAM_OWNERS;
51 using AccessControlCommon::TEAM_VIEWERS;
53 using AccessControlCommon::bucket;
54 using AccessControlCommon::domain;
55 using AccessControlCommon::email;
57 using AccessControlCommon::entity;
59 AccessControlCommon::set_entity(std::move(v));
63 using AccessControlCommon::entity_id;
64 using AccessControlCommon::etag;
65 using AccessControlCommon::has_project_team;
66 using AccessControlCommon::id;
67 using AccessControlCommon::kind;
68 using AccessControlCommon::project_team;
70 using AccessControlCommon::role;
72 AccessControlCommon::set_role(std::move(v));
76 using AccessControlCommon::self_link;
85 friend struct internal::BucketAccessControlParser;
86 friend struct internal::GrpcBucketAccessControlParser;
112 impl_.SetStringField(
"entity", v);
117 impl_.RemoveField(
"entity");
122 impl_.SetStringField(
"role", v);
127 impl_.RemoveField(
"role");
132 friend struct internal::GrpcBucketAccessControlParser;
134 internal::PatchBuilder impl_;