class GlobalForwardingRules extends Resource (View source)

The "globalForwardingRules" collection of methods.

Typical usage is:

 $computeService = new Google\Service\Compute(...);
 $globalForwardingRules = $computeService->globalForwardingRules;

Methods

delete(string $project, string $forwardingRule, array $optParams = [])

Deletes the specified GlobalForwardingRule resource.

get(string $project, string $forwardingRule, array $optParams = [])

Returns the specified GlobalForwardingRule resource. Gets a list of available forwarding rules by making a list() request. (globalForwardingRules.get)

insert(string $project, ForwardingRule $postBody, array $optParams = [])

Creates a GlobalForwardingRule resource in the specified project using the data included in the request. (globalForwardingRules.insert)

listGlobalForwardingRules(string $project, array $optParams = [])

Retrieves a list of GlobalForwardingRule resources available to the specified project. (globalForwardingRules.listGlobalForwardingRules)

patch(string $project, string $forwardingRule, ForwardingRule $postBody, array $optParams = [])

Updates the specified forwarding rule with the data included in the request.

setLabels(string $project, string $resource, GlobalSetLabelsRequest $postBody, array $optParams = [])

Sets the labels on the specified resource. To learn more about labels, read the Labeling resources documentation. (globalForwardingRules.setLabels)

setTarget(string $project, string $forwardingRule, TargetReference $postBody, array $optParams = [])

Changes target URL for the GlobalForwardingRule resource. The new target should be of the same type as the old target.

Details

Operation delete(string $project, string $forwardingRule, array $optParams = [])

Deletes the specified GlobalForwardingRule resource.

(globalForwardingRules.delete)

Parameters

string $project

Project ID for this request.

string $forwardingRule

Name of the ForwardingRule resource to delete.

array $optParams

Optional parameters.

Return Value

Operation

Exceptions

Exception

ForwardingRule get(string $project, string $forwardingRule, array $optParams = [])

Returns the specified GlobalForwardingRule resource. Gets a list of available forwarding rules by making a list() request. (globalForwardingRules.get)

Parameters

string $project

Project ID for this request.

string $forwardingRule

Name of the ForwardingRule resource to return.

array $optParams

Optional parameters.

Return Value

ForwardingRule

Exceptions

Exception

Operation insert(string $project, ForwardingRule $postBody, array $optParams = [])

Creates a GlobalForwardingRule resource in the specified project using the data included in the request. (globalForwardingRules.insert)

Parameters

string $project

Project ID for this request.

ForwardingRule $postBody
array $optParams

Optional parameters.

Return Value

Operation

Exceptions

Exception

ForwardingRuleList listGlobalForwardingRules(string $project, array $optParams = [])

Retrieves a list of GlobalForwardingRule resources available to the specified project. (globalForwardingRules.listGlobalForwardingRules)

Parameters

string $project

Project ID for this request.

array $optParams

Optional parameters.

Return Value

ForwardingRuleList

Exceptions

Exception

Operation patch(string $project, string $forwardingRule, ForwardingRule $postBody, array $optParams = [])

Updates the specified forwarding rule with the data included in the request.

This method supports PATCH semantics and uses the JSON merge patch format and processing rules. Currently, you can only patch the network_tier field. (globalForwardingRules.patch)

Parameters

string $project

Project ID for this request.

string $forwardingRule

Name of the ForwardingRule resource to patch.

ForwardingRule $postBody
array $optParams

Optional parameters.

Return Value

Operation

Exceptions

Exception

Operation setLabels(string $project, string $resource, GlobalSetLabelsRequest $postBody, array $optParams = [])

Sets the labels on the specified resource. To learn more about labels, read the Labeling resources documentation. (globalForwardingRules.setLabels)

Parameters

string $project

Project ID for this request.

string $resource

Name or id of the resource for this request.

GlobalSetLabelsRequest $postBody
array $optParams

Optional parameters.

Return Value

Operation

Exceptions

Exception

Operation setTarget(string $project, string $forwardingRule, TargetReference $postBody, array $optParams = [])

Changes target URL for the GlobalForwardingRule resource. The new target should be of the same type as the old target.

(globalForwardingRules.setTarget)

Parameters

string $project

Project ID for this request.

string $forwardingRule

Name of the ForwardingRule resource in which target is to be set.

TargetReference $postBody
array $optParams

Optional parameters.

Return Value

Operation

Exceptions

Exception