Class: Google::Apis::StorageV1::Policy::Binding
- Inherits:
-
Object
- Object
- Google::Apis::StorageV1::Policy::Binding
- Includes:
- Core::Hashable, Core::JsonObjectSupport
- Defined in:
- generated/google/apis/storage_v1/classes.rb,
generated/google/apis/storage_v1/representations.rb,
generated/google/apis/storage_v1/representations.rb
Instance Attribute Summary collapse
-
#condition ⇒ Google::Apis::StorageV1::Expr
Represents an expression text.
-
#members ⇒ Array<String>
A collection of identifiers for members who may assume the provided role.
-
#role ⇒ String
The role to which members belong.
Instance Method Summary collapse
-
#initialize(**args) ⇒ Binding
constructor
A new instance of Binding.
-
#update!(**args) ⇒ Object
Update properties of this object.
Methods included from Core::JsonObjectSupport
Methods included from Core::Hashable
Constructor Details
#initialize(**args) ⇒ Binding
Returns a new instance of Binding
1878 1879 1880 |
# File 'generated/google/apis/storage_v1/classes.rb', line 1878 def initialize(**args) update!(**args) end |
Instance Attribute Details
#condition ⇒ Google::Apis::StorageV1::Expr
Represents an expression text. Example: title: "User account presence"
description: "Determines whether the request has a user account" expression: "
size(request.user) > 0"
Corresponds to the JSON property condition
1824 1825 1826 |
# File 'generated/google/apis/storage_v1/classes.rb', line 1824 def condition @condition end |
#members ⇒ Array<String>
A collection of identifiers for members who may assume the provided role. Recognized identifiers are as follows:
- allUsers — A special identifier that represents anyone on the internet; with or without a Google account.
- allAuthenticatedUsers — A special identifier that represents anyone who is authenticated with a Google account or a service account.
- user:emailid — An email address that represents a specific account. For example, user:alice@gmail.com or user:joe@example.com.
- serviceAccount:emailid — An email address that represents a service account. For example, serviceAccount:my-other-app@appspot.gserviceaccount.com .
- group:emailid — An email address that represents a Google group. For example, group:admins@example.com.
- domain:domain — A Google Apps domain name that represents all the users of that domain. For example, domain:google.com or domain:example.com.
- projectOwner:projectid — Owners of the given project. For example, projectOwner:my-example-project
- projectEditor:projectid — Editors of the given project. For example, projectEditor:my-example-project
- projectViewer:projectid — Viewers of the given project. For example,
projectViewer:my-example-project
Corresponds to the JSON property
members
1848 1849 1850 |
# File 'generated/google/apis/storage_v1/classes.rb', line 1848 def members @members end |
#role ⇒ String
The role to which members belong. Two types of roles are supported: new IAM roles, which grant permissions that do not map directly to those provided by ACLs, and legacy IAM roles, which do map directly to ACL permissions. All roles are of the format roles/storage.specificRole. The new IAM roles are:
- roles/storage.admin — Full control of Google Cloud Storage resources.
- roles/storage.objectViewer — Read-Only access to Google Cloud Storage objects.
- roles/storage.objectCreator — Access to create objects in Google Cloud Storage.
- roles/storage.objectAdmin — Full control of Google Cloud Storage objects. The legacy IAM roles are:
- roles/storage.legacyObjectReader — Read-only access to objects without listing. Equivalent to an ACL entry on an object with the READER role.
- roles/storage.legacyObjectOwner — Read/write access to existing objects without listing. Equivalent to an ACL entry on an object with the OWNER role.
- roles/storage.legacyBucketReader — Read access to buckets with object listing. Equivalent to an ACL entry on a bucket with the READER role.
- roles/storage.legacyBucketWriter — Read access to buckets with object listing/creation/deletion. Equivalent to an ACL entry on a bucket with the WRITER role.
- roles/storage.legacyBucketOwner — Read and write access to existing buckets
with object listing/creation/deletion. Equivalent to an ACL entry on a bucket
with the OWNER role.
Corresponds to the JSON property
role
1876 1877 1878 |
# File 'generated/google/apis/storage_v1/classes.rb', line 1876 def role @role end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
1883 1884 1885 1886 1887 |
# File 'generated/google/apis/storage_v1/classes.rb', line 1883 def update!(**args) @condition = args[:condition] if args.key?(:condition) @members = args[:members] if args.key?(:members) @role = args[:role] if args.key?(:role) end |