0.5.3 (latest) 0.4.4 0.3.0 0.2.1 0.1.4 Reference documentation and code samples for the Google Cloud Api Hub V1 Client class Dependency.

A dependency resource defined in the API hub describes a dependency directed
from a consumer to a supplier entity. A dependency can be defined between two
[Operations](https://docs.cloud.google.com/php/docs/reference/cloud-apihub/latest/V1.ApiOperation) or between
an [Operation](https://docs.cloud.google.com/php/docs/reference/cloud-apihub/latest/V1.ApiOperation) and [External
API](https://docs.cloud.google.com/php/docs/reference/cloud-apihub/latest/V1.ExternalApi).

Generated from protobuf message `google.cloud.apihub.v1.Dependency`

## Namespace

Google \\ Cloud \\ ApiHub \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ name` | `string` Identifier. The name of the dependency in the API Hub. Format: `projects/{project}/locations/{location}/dependencies/{dependency}` |
| `↳ consumer` | `https://docs.cloud.google.com/php/docs/reference/cloud-apihub/latest/V1.DependencyEntityReference` Required. Immutable. The entity acting as the consumer in the dependency. |
| `↳ supplier` | `https://docs.cloud.google.com/php/docs/reference/cloud-apihub/latest/V1.DependencyEntityReference` Required. Immutable. The entity acting as the supplier in the dependency. |
| `↳ state` | `int` Output only. State of the dependency. |
| `↳ description` | `string` Optional. Human readable description corresponding of the dependency. |
| `↳ discovery_mode` | `int` Output only. Discovery mode of the dependency. |
| `↳ error_detail` | `https://docs.cloud.google.com/php/docs/reference/cloud-apihub/latest/V1.DependencyErrorDetail` Output only. Error details of a dependency if the system has detected it internally. |
| `↳ create_time` | `Google\Protobuf\Timestamp` Output only. The time at which the dependency was created. |
| `↳ update_time` | `Google\Protobuf\Timestamp` Output only. The time at which the dependency was last updated. |
| `↳ attributes` | `array|Google\Protobuf\Internal\MapField` Optional. The list of user defined attributes associated with the dependency resource. The key is the attribute name. It will be of the format: `projects/{project}/locations/{location}/attributes/{attribute}`. The value is the attribute values associated with the resource. |

### getName

Identifier. The name of the dependency in the API Hub.

Format: `projects/{project}/locations/{location}/dependencies/{dependency}`

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

### setName

Identifier. The name of the dependency in the API Hub.

Format: `projects/{project}/locations/{location}/dependencies/{dependency}`

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

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

### getConsumer

Required. Immutable. The entity acting as the consumer in the dependency.

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

### hasConsumer

### clearConsumer

### setConsumer

Required. Immutable. The entity acting as the consumer in the dependency.

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

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

### getSupplier

Required. Immutable. The entity acting as the supplier in the dependency.

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

### hasSupplier

### clearSupplier

### setSupplier

Required. Immutable. The entity acting as the supplier in the dependency.

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

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

### getState

Output only. State of the dependency.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `int` | Enum of type [State](https://docs.cloud.google.com/php/docs/reference/cloud-apihub/latest/V1.Dependency.State). |

### setState

Output only. State of the dependency.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `int` Enum of type [State](https://docs.cloud.google.com/php/docs/reference/cloud-apihub/latest/V1.Dependency.State). |

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

### getDescription

Optional. Human readable description corresponding of the dependency.

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

### setDescription

Optional. Human readable description corresponding of the dependency.

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

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

### getDiscoveryMode

Output only. Discovery mode of the dependency.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `int` | Enum of type [DiscoveryMode](https://docs.cloud.google.com/php/docs/reference/cloud-apihub/latest/V1.Dependency.DiscoveryMode). |

### setDiscoveryMode

Output only. Discovery mode of the dependency.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `int` Enum of type [DiscoveryMode](https://docs.cloud.google.com/php/docs/reference/cloud-apihub/latest/V1.Dependency.DiscoveryMode). |

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

### getErrorDetail

Output only. Error details of a dependency if the system has detected it
internally.

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

### hasErrorDetail

### clearErrorDetail

### setErrorDetail

Output only. Error details of a dependency if the system has detected it
internally.

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

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

### getCreateTime

Output only. The time at which the dependency was created.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `Google\Protobuf\Timestamp|null` |   |

### hasCreateTime

### clearCreateTime

### setCreateTime

Output only. The time at which the dependency was created.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `Google\Protobuf\Timestamp` |

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

### getUpdateTime

Output only. The time at which the dependency was last updated.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `Google\Protobuf\Timestamp|null` |   |

### hasUpdateTime

### clearUpdateTime

### setUpdateTime

Output only. The time at which the dependency was last updated.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `Google\Protobuf\Timestamp` |

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

### getAttributes

Optional. The list of user defined attributes associated with the
dependency resource. The key is the attribute name. It will be of the
format: `projects/{project}/locations/{location}/attributes/{attribute}`.

The value is the attribute values associated with the resource.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `Google\Protobuf\Internal\MapField` |   |

### setAttributes

Optional. The list of user defined attributes associated with the
dependency resource. The key is the attribute name. It will be of the
format: `projects/{project}/locations/{location}/attributes/{attribute}`.

The value is the attribute values associated with the resource.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `array|Google\Protobuf\Internal\MapField` |

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