Google Cloud Asset V1 Client - Class GovernedIamPolicy (1.16.1)

Reference documentation and code samples for the Google Cloud Asset V1 Client class GovernedIamPolicy.

The IAM policies governed by the organization policies of the AnalyzeOrgPolicyGovernedAssetsRequest.constraint.

Generated from protobuf message google.cloud.asset.v1.AnalyzeOrgPolicyGovernedAssetsResponse.GovernedIamPolicy

Namespace

Google \ Cloud \ Asset \ V1 \ AnalyzeOrgPolicyGovernedAssetsResponse

Methods

__construct

Constructor.

Parameters
Name Description
data array

Optional. Data for populating the Message object.

↳ attached_resource string

The full resource name of the resource on which this IAM policy is set. Example: //compute.googleapis.com/projects/my_project_123/zones/zone1/instances/instance1. See Cloud Asset Inventory Resource Name Format for more information.

↳ policy Google\Cloud\Iam\V1\Policy

The IAM policy directly set on the given resource.

↳ project string

The project that this IAM policy belongs to, in the format of projects/{PROJECT_NUMBER}. This field is available when the IAM policy belongs to a project.

↳ folders array

The folder(s) that this IAM policy belongs to, in the format of folders/{FOLDER_NUMBER}. This field is available when the IAM policy belongs (directly or cascadingly) to one or more folders.

↳ organization string

The organization that this IAM policy belongs to, in the format of organizations/{ORGANIZATION_NUMBER}. This field is available when the IAM policy belongs (directly or cascadingly) to an organization.

↳ asset_type string

The asset type of the AnalyzeOrgPolicyGovernedAssetsResponse.GovernedIamPolicy.attached_resource. Example: cloudresourcemanager.googleapis.com/Project See Cloud Asset Inventory Supported Asset Types for all supported asset types.

getAttachedResource

The full resource name of the resource on which this IAM policy is set.

Example: //compute.googleapis.com/projects/my_project_123/zones/zone1/instances/instance1. See Cloud Asset Inventory Resource Name Format for more information.

Returns
Type Description
string

setAttachedResource

The full resource name of the resource on which this IAM policy is set.

Example: //compute.googleapis.com/projects/my_project_123/zones/zone1/instances/instance1. See Cloud Asset Inventory Resource Name Format for more information.

Parameter
Name Description
var string
Returns
Type Description
$this

getPolicy

The IAM policy directly set on the given resource.

Returns
Type Description
Google\Cloud\Iam\V1\Policy|null

hasPolicy

clearPolicy

setPolicy

The IAM policy directly set on the given resource.

Parameter
Name Description
var Google\Cloud\Iam\V1\Policy
Returns
Type Description
$this

getProject

The project that this IAM policy belongs to, in the format of projects/{PROJECT_NUMBER}. This field is available when the IAM policy belongs to a project.

Returns
Type Description
string

setProject

The project that this IAM policy belongs to, in the format of projects/{PROJECT_NUMBER}. This field is available when the IAM policy belongs to a project.

Parameter
Name Description
var string
Returns
Type Description
$this

getFolders

The folder(s) that this IAM policy belongs to, in the format of folders/{FOLDER_NUMBER}. This field is available when the IAM policy belongs (directly or cascadingly) to one or more folders.

Returns
Type Description
Google\Protobuf\Internal\RepeatedField

setFolders

The folder(s) that this IAM policy belongs to, in the format of folders/{FOLDER_NUMBER}. This field is available when the IAM policy belongs (directly or cascadingly) to one or more folders.

Parameter
Name Description
var string[]
Returns
Type Description
$this

getOrganization

The organization that this IAM policy belongs to, in the format of organizations/{ORGANIZATION_NUMBER}. This field is available when the IAM policy belongs (directly or cascadingly) to an organization.

Returns
Type Description
string

setOrganization

The organization that this IAM policy belongs to, in the format of organizations/{ORGANIZATION_NUMBER}. This field is available when the IAM policy belongs (directly or cascadingly) to an organization.

Parameter
Name Description
var string
Returns
Type Description
$this

getAssetType

The asset type of the AnalyzeOrgPolicyGovernedAssetsResponse.GovernedIamPolicy.attached_resource.

Example: cloudresourcemanager.googleapis.com/Project See Cloud Asset Inventory Supported Asset Types for all supported asset types.

Returns
Type Description
string

setAssetType

The asset type of the AnalyzeOrgPolicyGovernedAssetsResponse.GovernedIamPolicy.attached_resource.

Example: cloudresourcemanager.googleapis.com/Project See Cloud Asset Inventory Supported Asset Types for all supported asset types.

Parameter
Name Description
var string
Returns
Type Description
$this