# Google Cloud Security Command Center V1 Client - Class Asset (2.5.1)

2.5.1 (latest) 2.5.0 2.4.2 2.3.0 2.2.1 2.1.1 2.0.4 1.32.0 1.31.0 1.30.0 1.29.0 1.28.2 1.21.0 1.20.2 1.19.1 1.18.0 1.17.0 1.16.0 1.15.1 1.14.2 1.13.1 Reference documentation and code samples for the Google Cloud Security Command Center V1 Client class Asset.

Security Command Center representation of a Google Cloud
resource.

The Asset is a Security Command Center resource that captures information
about a single Google Cloud resource. All modifications to an Asset are only
within the context of Security Command Center and don't affect the referenced
Google Cloud resource.

Generated from protobuf message `google.cloud.securitycenter.v1.Asset`

## Namespace

Google \\ Cloud \\ SecurityCenter \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ name` | `string` The relative resource name of this asset. See: <https://cloud.google.com/apis/design/resource_names#relative_resource_name> Example: "organizations/{organization_id}/assets/{asset_id}". |
| `↳ security_center_properties` | `https://docs.cloud.google.com/php/docs/reference/cloud-security-center/latest/V1.Asset.SecurityCenterProperties` Security Command Center managed properties. These properties are managed by Security Command Center and cannot be modified by the user. |
| `↳ resource_properties` | `array|https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Internal/MapField` Resource managed properties. These properties are managed and defined by the Google Cloud resource and cannot be modified by the user. |
| `↳ security_marks` | `https://docs.cloud.google.com/php/docs/reference/cloud-security-center/latest/V1.SecurityMarks` User specified security marks. These marks are entirely managed by the user and come from the SecurityMarks resource that belongs to the asset. |
| `↳ create_time` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp` The time at which the asset was created in Security Command Center. |
| `↳ update_time` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp` The time at which the asset was last updated or added in Cloud SCC. |
| `↳ iam_policy` | `https://docs.cloud.google.com/php/docs/reference/cloud-security-center/latest/V1.Asset.IamPolicy` Cloud IAM Policy information associated with the Google Cloud resource described by the Security Command Center asset. This information is managed and defined by the Google Cloud resource and cannot be modified by the user. |
| `↳ canonical_name` | `string` The canonical name of the resource. It's either "organizations/{organization_id}/assets/{asset_id}", "folders/{folder_id}/assets/{asset_id}" or "projects/{project_number}/assets/{asset_id}", depending on the closest CRM ancestor of the resource. |

### getName

The relative resource name of this asset. See:
<https://cloud.google.com/apis/design/resource_names#relative_resource_name>
Example:
"organizations/{organization_id}/assets/{asset_id}".

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### setName

The relative resource name of this asset. See:
<https://cloud.google.com/apis/design/resource_names#relative_resource_name>
Example:
"organizations/{organization_id}/assets/{asset_id}".

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getSecurityCenterProperties

Security Command Center managed properties. These properties are managed by
Security Command Center and cannot be modified by the user.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-security-center/latest/V1.Asset.SecurityCenterProperties|null` |   |

### hasSecurityCenterProperties

### clearSecurityCenterProperties

### setSecurityCenterProperties

Security Command Center managed properties. These properties are managed by
Security Command Center and cannot be modified by the user.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-security-center/latest/V1.Asset.SecurityCenterProperties` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getResourceProperties

Resource managed properties. These properties are managed and defined by
the Google Cloud resource and cannot be modified by the user.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Internal/MapField` |   |

### setResourceProperties

Resource managed properties. These properties are managed and defined by
the Google Cloud resource and cannot be modified by the user.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `array|https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Internal/MapField` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getSecurityMarks

User specified security marks. These marks are entirely managed by the user
and come from the SecurityMarks resource that belongs to the asset.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-security-center/latest/V1.SecurityMarks|null` |   |

### hasSecurityMarks

### clearSecurityMarks

### setSecurityMarks

User specified security marks. These marks are entirely managed by the user
and come from the SecurityMarks resource that belongs to the asset.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-security-center/latest/V1.SecurityMarks` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getCreateTime

The time at which the asset was created in Security Command Center.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp|null` |   |

### hasCreateTime

### clearCreateTime

### setCreateTime

The time at which the asset was created in Security Command Center.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getUpdateTime

The time at which the asset was last updated or added in Cloud SCC.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp|null` |   |

### hasUpdateTime

### clearUpdateTime

### setUpdateTime

The time at which the asset was last updated or added in Cloud SCC.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/Timestamp` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getIamPolicy

Cloud IAM Policy information associated with the Google Cloud resource
described by the Security Command Center asset. This information is managed
and defined by the Google Cloud resource and cannot be modified by the
user.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-security-center/latest/V1.Asset.IamPolicy|null` |   |

### hasIamPolicy

### clearIamPolicy

### setIamPolicy

Cloud IAM Policy information associated with the Google Cloud resource
described by the Security Command Center asset. This information is managed
and defined by the Google Cloud resource and cannot be modified by the
user.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-security-center/latest/V1.Asset.IamPolicy` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getCanonicalName

The canonical name of the resource. It's either
"organizations/{organization_id}/assets/{asset_id}",
"folders/{folder_id}/assets/{asset_id}" or
"projects/{project_number}/assets/{asset_id}", depending on the closest CRM
ancestor of the resource.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` |   |

### setCanonicalName

The canonical name of the resource. It's either
"organizations/{organization_id}/assets/{asset_id}",
"folders/{folder_id}/assets/{asset_id}" or
"projects/{project_number}/assets/{asset_id}", depending on the closest CRM
ancestor of the resource.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |