# Google Cloud Network Security V1 Client - Class Target (1.4.0)

1.4.0 (latest) 1.3.0 1.2.3 1.1.0 1.0.4 0.6.5 0.5.2 0.4.1 0.3.7 Reference documentation and code samples for the Google Cloud Network Security V1 Client class Target.

Specifies the set of targets to which this policy should be applied to.

Generated from protobuf message `google.cloud.networksecurity.v1.AuthzPolicy.Target`

## Namespace

Google \\ Cloud \\ NetworkSecurity \\ V1 \\ AuthzPolicy

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ load_balancing_scheme` | `int` Optional. All gateways and forwarding rules referenced by this policy and extensions must share the same load balancing scheme. Required only when targeting forwarding rules. If targeting Secure Web Proxy, this field must be `INTERNAL_MANAGED` or not specified. Must not be specified when targeting Agent Gateway. Supported values: `INTERNAL_MANAGED` and `EXTERNAL_MANAGED`. For more information, refer to [Backend services overview](https://cloud.google.com/load-balancing/docs/backend-service). |
| `↳ resources` | `string[]` Required. A list of references to the Forwarding Rules, Secure Web Proxy Gateways, or Agent Gateways on which this policy will be applied. |

### getLoadBalancingScheme

Optional. All gateways and forwarding rules referenced by this policy and
extensions must share the same load balancing scheme. Required only when
targeting forwarding rules. If targeting Secure Web Proxy, this field
must be `INTERNAL_MANAGED` or not specified. Must not be specified
when targeting Agent Gateway. Supported values:
`INTERNAL_MANAGED` and `EXTERNAL_MANAGED`. For more information, refer
to [Backend services
overview](https://cloud.google.com/load-balancing/docs/backend-service).

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `int` | Enum of type [LoadBalancingScheme](https://docs.cloud.google.com/php/docs/reference/cloud-network-security/latest/V1.AuthzPolicy.LoadBalancingScheme). |

### setLoadBalancingScheme

Optional. All gateways and forwarding rules referenced by this policy and
extensions must share the same load balancing scheme. Required only when
targeting forwarding rules. If targeting Secure Web Proxy, this field
must be `INTERNAL_MANAGED` or not specified. Must not be specified
when targeting Agent Gateway. Supported values:
`INTERNAL_MANAGED` and `EXTERNAL_MANAGED`. For more information, refer
to [Backend services
overview](https://cloud.google.com/load-balancing/docs/backend-service).

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

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

### getResources

Required. A list of references to the Forwarding Rules, Secure Web Proxy
Gateways, or Agent Gateways on which this policy will be applied.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/RepeatedField<string>` |   |

### setResources

Required. A list of references to the Forwarding Rules, Secure Web Proxy
Gateways, or Agent Gateways on which this policy will be applied.

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

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