class ProjectsLocationsCatalogsControls extends Resource (View source)

The "controls" collection of methods.

Typical usage is:

 $retailService = new Google\Service\CloudRetail(...);
 $controls = $retailService->projects_locations_catalogs_controls;

Methods

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

Creates a Control. If the Control to create already exists, an ALREADY_EXISTS error is returned. (controls.create)

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

Deletes a Control. If the Control to delete does not exist, a NOT_FOUND error is returned. (controls.delete)

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

Gets a Control. (controls.get)

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

Lists all Controls by their parent Catalog.

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

Updates a Control. Control cannot be set to a different oneof field, if so an INVALID_ARGUMENT is returned. If the Control to update does not exist, a NOT_FOUND error is returned. (controls.patch)

Details

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

Creates a Control. If the Control to create already exists, an ALREADY_EXISTS error is returned. (controls.create)

Parameters

string $parent

Required. Full resource name of parent catalog. Format: projects/{project_number}/locations/{location_id}/catalogs/{catalog_id}

GoogleCloudRetailV2Control $postBody
array $optParams

Optional parameters.

Return Value

GoogleCloudRetailV2Control

Exceptions

Exception

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

Deletes a Control. If the Control to delete does not exist, a NOT_FOUND error is returned. (controls.delete)

Parameters

string $name

Required. The resource name of the Control to delete. Format: projects/{project_number}/locations/{location_id}/catalogs/{catalog_ id}/controls/{control_id}

array $optParams

Optional parameters.

Return Value

GoogleProtobufEmpty

Exceptions

Exception

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

Gets a Control. (controls.get)

Parameters

string $name

Required. The resource name of the Control to get. Format: projects/{project_number}/locations/{location_id}/catalogs/{catalog_ id}/controls/{control_id}

array $optParams

Optional parameters.

Return Value

GoogleCloudRetailV2Control

Exceptions

Exception

GoogleCloudRetailV2ListControlsResponse listProjectsLocationsCatalogsControls(string $parent, array $optParams = [])

Lists all Controls by their parent Catalog.

(controls.listProjectsLocationsCatalogsControls)

Parameters

string $parent

Required. The catalog resource name. Format: projects/{project_number}/locations/{location_id}/catalogs/{catalog_id}

array $optParams

Optional parameters.

Return Value

GoogleCloudRetailV2ListControlsResponse

Exceptions

Exception

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

Updates a Control. Control cannot be set to a different oneof field, if so an INVALID_ARGUMENT is returned. If the Control to update does not exist, a NOT_FOUND error is returned. (controls.patch)

Parameters

string $name

Immutable. Fully qualified name projects/locations/global/catalogs/controls

GoogleCloudRetailV2Control $postBody
array $optParams

Optional parameters.

Return Value

GoogleCloudRetailV2Control

Exceptions

Exception