class ProjectsLocationsServiceLbPolicies extends Resource (View source)

The "serviceLbPolicies" collection of methods.

Typical usage is:

 $networkservicesService = new Google\Service\NetworkServices(...);
 $serviceLbPolicies = $networkservicesService->projects_locations_serviceLbPolicies;

Methods

create(string $parent, ServiceLbPolicy $postBody, array $optParams = [])

Creates a new ServiceLbPolicy in a given project and location.

delete(string $name, array $optParams = [])

Deletes a single ServiceLbPolicy. (serviceLbPolicies.delete)

get(string $name, array $optParams = [])

Gets details of a single ServiceLbPolicy. (serviceLbPolicies.get)

getIamPolicy(string $resource, array $optParams = [])

Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.

listProjectsLocationsServiceLbPolicies(string $parent, array $optParams = [])

Lists ServiceLbPolicies in a given project and location.

patch(string $name, ServiceLbPolicy $postBody, array $optParams = [])

Updates the parameters of a single ServiceLbPolicy. (serviceLbPolicies.patch)

setIamPolicy(string $resource, SetIamPolicyRequest $postBody, array $optParams = [])

Sets the access control policy on the specified resource. Replaces any existing policy. Can return NOT_FOUND, INVALID_ARGUMENT, and PERMISSION_DENIED errors. (serviceLbPolicies.setIamPolicy)

testIamPermissions(string $resource, TestIamPermissionsRequest $postBody, array $optParams = [])

Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a NOT_FOUND error. Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking.

Details

Operation create(string $parent, ServiceLbPolicy $postBody, array $optParams = [])

Creates a new ServiceLbPolicy in a given project and location.

(serviceLbPolicies.create)

Parameters

string $parent

Required. The parent resource of the ServiceLbPolicy. Must be in the format projects/{project}/locations/{location}.

ServiceLbPolicy $postBody
array $optParams

Optional parameters.

Return Value

Operation

Exceptions

Exception

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

Deletes a single ServiceLbPolicy. (serviceLbPolicies.delete)

Parameters

string $name

Required. A name of the ServiceLbPolicy to delete. Must be in the format projects/{project}/locations/{location}/serviceLbPolicies.

array $optParams

Optional parameters.

Return Value

Operation

Exceptions

Exception

ServiceLbPolicy get(string $name, array $optParams = [])

Gets details of a single ServiceLbPolicy. (serviceLbPolicies.get)

Parameters

string $name

Required. A name of the ServiceLbPolicy to get. Must be in the format projects/{project}/locations/{location}/serviceLbPolicies.

array $optParams

Optional parameters.

Return Value

ServiceLbPolicy

Exceptions

Exception

Policy getIamPolicy(string $resource, array $optParams = [])

Gets the access control policy for a resource. Returns an empty policy if the resource exists and does not have a policy set.

(serviceLbPolicies.getIamPolicy)

Parameters

string $resource

REQUIRED: The resource for which the policy is being requested. See Resource names for the appropriate value for this field.

array $optParams

Optional parameters.

Return Value

Policy

Exceptions

Exception

ListServiceLbPoliciesResponse listProjectsLocationsServiceLbPolicies(string $parent, array $optParams = [])

Lists ServiceLbPolicies in a given project and location.

(serviceLbPolicies.listProjectsLocationsServiceLbPolicies)

Parameters

string $parent

Required. The project and location from which the ServiceLbPolicies should be listed, specified in the format projects/{project}/locations/{location}.

array $optParams

Optional parameters.

Return Value

ListServiceLbPoliciesResponse

Exceptions

Exception

Operation patch(string $name, ServiceLbPolicy $postBody, array $optParams = [])

Updates the parameters of a single ServiceLbPolicy. (serviceLbPolicies.patch)

Parameters

string $name

Required. Name of the ServiceLbPolicy resource. It matches pattern projects/{project}/locations/{location}/serviceLbPolicies/{s ervice_lb_policy_name}.

ServiceLbPolicy $postBody
array $optParams

Optional parameters.

Return Value

Operation

Exceptions

Exception

Policy setIamPolicy(string $resource, SetIamPolicyRequest $postBody, array $optParams = [])

Sets the access control policy on the specified resource. Replaces any existing policy. Can return NOT_FOUND, INVALID_ARGUMENT, and PERMISSION_DENIED errors. (serviceLbPolicies.setIamPolicy)

Parameters

string $resource

REQUIRED: The resource for which the policy is being specified. See Resource names for the appropriate value for this field.

SetIamPolicyRequest $postBody
array $optParams

Optional parameters.

Return Value

Policy

Exceptions

Exception

TestIamPermissionsResponse testIamPermissions(string $resource, TestIamPermissionsRequest $postBody, array $optParams = [])

Returns permissions that a caller has on the specified resource. If the resource does not exist, this will return an empty set of permissions, not a NOT_FOUND error. Note: This operation is designed to be used for building permission-aware UIs and command-line tools, not for authorization checking.

This operation may "fail open" without warning. (serviceLbPolicies.testIamPermissions)

Parameters

string $resource

REQUIRED: The resource for which the policy detail is being requested. See Resource names for the appropriate value for this field.

TestIamPermissionsRequest $postBody
array $optParams

Optional parameters.

Return Value

TestIamPermissionsResponse

Exceptions

Exception