deploymentmanager
v2
|
#include <policy.h>
Public Member Functions | |
Policy (const Json::Value &storage) | |
Policy (Json::Value *storage) | |
virtual | ~Policy () |
const StringPiece | GetTypeName () const |
bool | has_audit_configs () const |
void | clear_audit_configs () |
const client::JsonCppArray< AuditConfig > | get_audit_configs () const |
client::JsonCppArray< AuditConfig > | mutable_auditConfigs () |
bool | has_bindings () const |
void | clear_bindings () |
const client::JsonCppArray< Binding > | get_bindings () const |
client::JsonCppArray< Binding > | mutable_bindings () |
bool | has_etag () const |
void | clear_etag () |
const StringPiece | get_etag () const |
void | set_etag (const StringPiece &value) |
bool | has_iam_owned () const |
void | clear_iam_owned () |
bool | get_iam_owned () const |
void | set_iam_owned (bool value) |
bool | has_rules () const |
void | clear_rules () |
const client::JsonCppArray< Rule > | get_rules () const |
client::JsonCppArray< Rule > | mutable_rules () |
bool | has_version () const |
void | clear_version () |
int32 | get_version () const |
void | set_version (int32 value) |
Static Public Member Functions | |
static Policy * | New () |
Defines an Identity and Access Management (IAM) policy. It is used to specify access control policies for Cloud Platform resources.
A Policy
consists of a list of bindings
. A binding
binds a list of members
to a role
, where the members can be user accounts, Google groups, Google domains, and service accounts. A role
is a named list of permissions defined by IAM.
JSON Example
{ "bindings": [ { "role": "roles/owner", "members": [ "user:mike@example.com", "group:admins@example.com", "domain:google.com", "serviceAccount:my-other-app@appspot.gserviceaccount.com" ] }, { "role": "roles/viewer", "members": ["user:sean@example.com"] } ] }
YAML Example
bindings: - members: - user:mike@ - group: exam ple.c omadmin - domain:google.com - serviceAccount: s@ex ample .commy-ot role: roles/owner - members: - user: her- app@a ppsp ot.gs ervi ceacc ount .comsean@ role: roles/viewer exam ple.c om
For a description of IAM and its features, see the IAM developer's guide.
|
explicit |
Standard constructor for an immutable data object instance.
[in] | storage | The underlying data storage for this instance. |
|
explicit |
Standard constructor for a mutable data object instance.
[in] | storage | The underlying data storage for this instance. |
|
virtual |
Standard destructor.
|
inline |
Clears the 'auditConfigs
' attribute.
|
inline |
Clears the 'bindings
' attribute.
|
inline |
Clears the 'etag
' attribute.
|
inline |
Clears the 'iamOwned
' attribute.
|
inline |
Clears the 'rules
' attribute.
|
inline |
Clears the 'version
' attribute.
const client::JsonCppArray<AuditConfig > google_deploymentmanager_api::Policy::get_audit_configs | ( | ) | const |
Get a reference to the value of the 'auditConfigs
' attribute.
const client::JsonCppArray<Binding > google_deploymentmanager_api::Policy::get_bindings | ( | ) | const |
Get a reference to the value of the 'bindings
' attribute.
|
inline |
Get the value of the 'etag
' attribute.
|
inline |
Get the value of the 'iamOwned
' attribute.
const client::JsonCppArray<Rule > google_deploymentmanager_api::Policy::get_rules | ( | ) | const |
Get a reference to the value of the 'rules
' attribute.
|
inline |
Get the value of the 'version
' attribute.
|
inline |
Returns a string denoting the type of this data object.
|
inline |
Determine if the 'auditConfigs
' attribute was set.
auditConfigs
' attribute was set.
|
inline |
Determine if the 'bindings
' attribute was set.
bindings
' attribute was set.
|
inline |
Determine if the 'etag
' attribute was set.
etag
' attribute was set.
|
inline |
Determine if the 'iamOwned
' attribute was set.
iamOwned
' attribute was set.
|
inline |
Determine if the 'rules
' attribute was set.
rules
' attribute was set.
|
inline |
Determine if the 'version
' attribute was set.
version
' attribute was set. client::JsonCppArray<AuditConfig > google_deploymentmanager_api::Policy::mutable_auditConfigs | ( | ) |
Gets a reference to a mutable value of the 'auditConfigs
' property.
Specifies cloud audit logging configuration for this policy.
client::JsonCppArray<Binding > google_deploymentmanager_api::Policy::mutable_bindings | ( | ) |
Gets a reference to a mutable value of the 'bindings
' property.
Associates a list of members
to a role
. bindings
with no members will result in an error.
client::JsonCppArray<Rule > google_deploymentmanager_api::Policy::mutable_rules | ( | ) |
Gets a reference to a mutable value of the 'rules
' property.
If more than one rule is specified, the rules are applied in the following manner: - All matching LOG rules are always applied. - If any DENY/DENY_WITH_LOG rule matches, permission is denied. Logging will be applied if one or more matching rule requires logging. - Otherwise, if any ALLOW/ALLOW_WITH_LOG rule matches, permission is granted. Logging will be applied if one or more matching rule requires logging. - Otherwise, if no rule applies, permission is denied.
|
static |
Creates a new default instance.
|
inline |
Change the 'etag
' attribute.
etag
is used for optimistic concurrency control as a way to help prevent simultaneous updates of a policy from overwriting each other. It is strongly suggested that systems make use of the etag
in the read-modify- write cycle to perform policy updates in order to avoid race conditions: An etag
is returned in the response to getIamPolicy
, and systems are expected to put that etag in the request to setIamPolicy
to ensure that their change will be applied to the same version of the policy.
If no etag
is provided in the call to setIamPolicy
, then the existing policy is overwritten blindly.
[in] | value | The new value. |
|
inline |
Change the 'iamOwned
' attribute.
[in] | value | The new value. |
|
inline |