# Google Cloud Dataplex V1 Client - Class DataplexServiceClient (1.14.0)

1.14.0 (latest) 1.13.0 1.12.0 1.11.0 1.10.0 1.9.1 1.8.0 1.7.1 1.6.1 1.4.0 1.3.0 1.2.1 1.1.1 1.0.1 0.16.1 0.15.1 0.14.0 0.13.0 0.12.0 0.11.1 0.10.0 0.9.0 0.8.0 0.7.0 0.6.0 0.5.1 0.4.0 0.3.0 0.2.3 0.1.6 Reference documentation and code samples for the Google Cloud Dataplex V1 Client class DataplexServiceClient.

Service Description: Dataplex service provides data lakes as a service. The primary resources
offered by this service are Lakes, Zones and Assets which collectively allow
a data administrator to organize, manage, secure and catalog data across
their organization located across cloud projects in a variety of storage
systems including Cloud Storage and BigQuery.

This class provides the ability to make remote calls to the backing service through method
calls that map to API methods.

Many parameters require resource names to be formatted in a particular way. To
assist with these names, this class includes a format method for each type of
name, and additionally a parseName method to extract the individual identifiers
contained within formatted names that are returned by the API.

## Namespace

Google \\ Cloud \\ Dataplex \\ V1 \\ Client

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `options` | `array|https://docs.cloud.google.com/php/docs/reference/gax/latest/Options.ClientOptions.html` Optional. Options for configuring the service API wrapper. |
| `↳ apiEndpoint` | `string` The address of the API remote host. May optionally include the port, formatted as " |
| `↳ credentials` | `https://docs.cloud.google.com/php/docs/reference/auth/latest/FetchAuthTokenInterface.html|https://docs.cloud.google.com/php/docs/reference/gax/latest/CredentialsWrapper.html` This option should only be used with a pre-constructed [Google\\Auth\\FetchAuthTokenInterface](https://docs.cloud.google.com/php/docs/reference/auth/latest/FetchAuthTokenInterface.html) or [Google\\ApiCore\\CredentialsWrapper](https://docs.cloud.google.com/php/docs/reference/gax/latest/CredentialsWrapper.html) object. Note that when one of these objects are provided, any settings in $credentialsConfig will be ignored. **Important** : If you are providing a path to a credentials file, or a decoded credentials file as a PHP array, this usage is now DEPRECATED. Providing an unvalidated credential configuration to Google APIs can compromise the security of your systems and data. It is recommended to create the credentials explicitly `use Google\Auth\Credentials\ServiceAccountCredentials; use Google\Cloud\Dataplex\V1\DataplexServiceClient; $creds = new ServiceAccountCredentials($scopes, $json); $options = new DataplexServiceClient(['credentials' => $creds]);` <https://cloud.google.com/docs/authentication/external/externally-sourced-credentials> |
| `↳ credentialsConfig` | `array` Options used to configure credentials, including auth token caching, for the client. For a full list of supporting configuration options, see [Google\\ApiCore\\CredentialsWrapper::build()](https://docs.cloud.google.com/php/docs/reference/gax/latest/CredentialsWrapper.html#_Google_ApiCore_CredentialsWrapper__build__) . |
| `↳ disableRetries` | `bool` Determines whether or not retries defined by the client configuration should be disabled. Defaults to `false`. |
| `↳ clientConfig` | `string|array` Client method configuration, including retry settings. This option can be either a path to a JSON file, or a PHP array containing the decoded JSON data. By default this settings points to the default client config file, which is provided in the resources folder. |
| `↳ transport` | `string|https://docs.cloud.google.com/php/docs/reference/gax/latest/Transport.TransportInterface.html` The transport used for executing network requests. May be either the string `rest` or `grpc`. Defaults to `grpc` if gRPC support is detected on the system. *Advanced usage* : Additionally, it is possible to pass in an already instantiated [Google\\ApiCore\\Transport\\TransportInterface](https://docs.cloud.google.com/php/docs/reference/gax/latest/Transport.TransportInterface.html) object. Note that when this object is provided, any settings in $transportConfig, and any $apiEndpoint setting, will be ignored. |
| `↳ transportConfig` | `array` Configuration options that will be used to construct the transport. Options for each supported transport type should be passed in a key for that transport. For example: $transportConfig = \[ 'grpc' =\> \[...\], 'rest' =\> \[...\], \]; See the [Google\\ApiCore\\Transport\\GrpcTransport::build()](https://docs.cloud.google.com/php/docs/reference/gax/latest/Transport.GrpcTransport.html#_Google_ApiCore_Transport_GrpcTransport__build__) and [Google\\ApiCore\\Transport\\RestTransport::build()](https://docs.cloud.google.com/php/docs/reference/gax/latest/Transport.RestTransport.html#_Google_ApiCore_Transport_RestTransport__build__) methods for the supported options. |
| `↳ clientCertSource` | `callable` A callable which returns the client cert as a string. This can be used to provide a certificate and private key to the transport layer for mTLS. |
| `↳ logger` | `false|Psr\Log\LoggerInterface` A PSR-3 compliant logger. If set to false, logging is disabled, ignoring the 'GOOGLE_SDK_PHP_LOGGING' environment flag |
| `↳ universeDomain` | `string` The service domain for the client. Defaults to 'googleapis.com'. |

### cancelJob

Cancel jobs running for the task resource.

The async variant is [DataplexServiceClient::cancelJobAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__cancelJobAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.CancelJobRequest` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

**Example**

    use Google\ApiCore\ApiException;
    use Google\Cloud\Dataplex\V1\CancelJobRequest;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;

    /**
     * @param string $formattedName The resource name of the job:
     *                              `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/task/{task_id}/job/{job_id}`. Please see
     *                              {@see DataplexServiceClient::jobName()} for help formatting this field.
     */
    function cancel_job_sample(string $formattedName): void
    {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $request = (new CancelJobRequest())
            ->setName($formattedName);

        // Call the API and handle any network failures.
        try {
            $dataplexServiceClient->cancelJob($request);
            printf('Call completed successfully.' . PHP_EOL);
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $formattedName = DataplexServiceClient::jobName(
            '[PROJECT]',
            '[LOCATION]',
            '[LAKE]',
            '[TASK]',
            '[JOB]'
        );

        cancel_job_sample($formattedName);
    }

### createAsset

Creates an asset resource.

The async variant is [DataplexServiceClient::createAssetAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__createAssetAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.CreateAssetRequest` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/gax/latest/OperationResponse.html<https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Asset>` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\ApiCore\OperationResponse;
    use Google\Cloud\Dataplex\V1\Asset;
    use Google\Cloud\Dataplex\V1\Asset\ResourceSpec;
    use Google\Cloud\Dataplex\V1\Asset\ResourceSpec\Type;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Dataplex\V1\CreateAssetRequest;
    use Google\Rpc\Status;

    /**
     * @param string $formattedParent       The resource name of the parent zone:
     *                                      `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}`. Please see
     *                                      {@see DataplexServiceClient::zoneName()} for help formatting this field.
     * @param string $assetId               Asset identifier.
     *                                      This ID will be used to generate names such as table names when publishing
     *                                      metadata to Hive Metastore and BigQuery.
     *                                      * Must contain only lowercase letters, numbers and hyphens.
     *                                      * Must start with a letter.
     *                                      * Must end with a number or a letter.
     *                                      * Must be between 1-63 characters.
     *                                      * Must be unique within the zone.
     * @param int    $assetResourceSpecType Immutable. Type of resource.
     */
    function create_asset_sample(
        string $formattedParent,
        string $assetId,
        int $assetResourceSpecType
    ): void {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $assetResourceSpec = (new ResourceSpec())
            ->setType($assetResourceSpecType);
        $asset = (new Asset())
            ->setResourceSpec($assetResourceSpec);
        $request = (new CreateAssetRequest())
            ->setParent($formattedParent)
            ->setAssetId($assetId)
            ->setAsset($asset);

        // Call the API and handle any network failures.
        try {
            /** @var OperationResponse $response */
            $response = $dataplexServiceClient->createAsset($request);
            $response->pollUntilComplete();

            if ($response->operationSucceeded()) {
                /** @var Asset $result */
                $result = $response->getResult();
                printf('Operation successful with response data: %s' . PHP_EOL, $result->serializeToJsonString());
            } else {
                /** @var Status $error */
                $error = $response->getError();
                printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString());
            }
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $formattedParent = DataplexServiceClient::zoneName('[PROJECT]', '[LOCATION]', '[LAKE]', '[ZONE]');
        $assetId = '[ASSET_ID]';
        $assetResourceSpecType = Type::TYPE_UNSPECIFIED;

        create_asset_sample($formattedParent, $assetId, $assetResourceSpecType);
    }

### createLake

Creates a lake resource.

The async variant is [DataplexServiceClient::createLakeAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__createLakeAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.CreateLakeRequest` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/gax/latest/OperationResponse.html<https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Lake>` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\ApiCore\OperationResponse;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Dataplex\V1\CreateLakeRequest;
    use Google\Cloud\Dataplex\V1\Lake;
    use Google\Rpc\Status;

    /**
     * @param string $formattedParent The resource name of the lake location, of the form:
     *                                projects/{project_number}/locations/{location_id}
     *                                where `location_id` refers to a Google Cloud region. Please see
     *                                {@see DataplexServiceClient::locationName()} for help formatting this field.
     * @param string $lakeId          Lake identifier.
     *                                This ID will be used to generate names such as database and dataset names
     *                                when publishing metadata to Hive Metastore and BigQuery.
     *                                * Must contain only lowercase letters, numbers and hyphens.
     *                                * Must start with a letter.
     *                                * Must end with a number or a letter.
     *                                * Must be between 1-63 characters.
     *                                * Must be unique within the customer project / location.
     */
    function create_lake_sample(string $formattedParent, string $lakeId): void
    {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $lake = new Lake();
        $request = (new CreateLakeRequest())
            ->setParent($formattedParent)
            ->setLakeId($lakeId)
            ->setLake($lake);

        // Call the API and handle any network failures.
        try {
            /** @var OperationResponse $response */
            $response = $dataplexServiceClient->createLake($request);
            $response->pollUntilComplete();

            if ($response->operationSucceeded()) {
                /** @var Lake $result */
                $result = $response->getResult();
                printf('Operation successful with response data: %s' . PHP_EOL, $result->serializeToJsonString());
            } else {
                /** @var Status $error */
                $error = $response->getError();
                printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString());
            }
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $formattedParent = DataplexServiceClient::locationName('[PROJECT]', '[LOCATION]');
        $lakeId = '[LAKE_ID]';

        create_lake_sample($formattedParent, $lakeId);
    }

### createTask

Creates a task resource within a lake.

The async variant is [DataplexServiceClient::createTaskAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__createTaskAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.CreateTaskRequest` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/gax/latest/OperationResponse.html<https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Task>` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\ApiCore\OperationResponse;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Dataplex\V1\CreateTaskRequest;
    use Google\Cloud\Dataplex\V1\Task;
    use Google\Cloud\Dataplex\V1\Task\ExecutionSpec;
    use Google\Cloud\Dataplex\V1\Task\TriggerSpec;
    use Google\Cloud\Dataplex\V1\Task\TriggerSpec\Type;
    use Google\Rpc\Status;

    /**
     * @param string $formattedParent                 The resource name of the parent lake:
     *                                                `projects/{project_number}/locations/{location_id}/lakes/{lake_id}`. Please see
     *                                                {@see DataplexServiceClient::lakeName()} for help formatting this field.
     * @param string $taskId                          Task identifier.
     * @param int    $taskTriggerSpecType             Immutable. Trigger type of the user-specified Task.
     * @param string $taskExecutionSpecServiceAccount Service account to use to execute a task.
     *                                                If not provided, the default Compute service account for the project is
     *                                                used.
     */
    function create_task_sample(
        string $formattedParent,
        string $taskId,
        int $taskTriggerSpecType,
        string $taskExecutionSpecServiceAccount
    ): void {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $taskTriggerSpec = (new TriggerSpec())
            ->setType($taskTriggerSpecType);
        $taskExecutionSpec = (new ExecutionSpec())
            ->setServiceAccount($taskExecutionSpecServiceAccount);
        $task = (new Task())
            ->setTriggerSpec($taskTriggerSpec)
            ->setExecutionSpec($taskExecutionSpec);
        $request = (new CreateTaskRequest())
            ->setParent($formattedParent)
            ->setTaskId($taskId)
            ->setTask($task);

        // Call the API and handle any network failures.
        try {
            /** @var OperationResponse $response */
            $response = $dataplexServiceClient->createTask($request);
            $response->pollUntilComplete();

            if ($response->operationSucceeded()) {
                /** @var Task $result */
                $result = $response->getResult();
                printf('Operation successful with response data: %s' . PHP_EOL, $result->serializeToJsonString());
            } else {
                /** @var Status $error */
                $error = $response->getError();
                printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString());
            }
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $formattedParent = DataplexServiceClient::lakeName('[PROJECT]', '[LOCATION]', '[LAKE]');
        $taskId = '[TASK_ID]';
        $taskTriggerSpecType = Type::TYPE_UNSPECIFIED;
        $taskExecutionSpecServiceAccount = '[SERVICE_ACCOUNT]';

        create_task_sample(
            $formattedParent,
            $taskId,
            $taskTriggerSpecType,
            $taskExecutionSpecServiceAccount
        );
    }

### createZone

Creates a zone resource within a lake.

The async variant is [DataplexServiceClient::createZoneAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__createZoneAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.CreateZoneRequest` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/gax/latest/OperationResponse.html<https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Zone>` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\ApiCore\OperationResponse;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Dataplex\V1\CreateZoneRequest;
    use Google\Cloud\Dataplex\V1\Zone;
    use Google\Cloud\Dataplex\V1\Zone\ResourceSpec;
    use Google\Cloud\Dataplex\V1\Zone\ResourceSpec\LocationType;
    use Google\Cloud\Dataplex\V1\Zone\Type;
    use Google\Rpc\Status;

    /**
     * @param string $formattedParent              The resource name of the parent lake:
     *                                             `projects/{project_number}/locations/{location_id}/lakes/{lake_id}`. Please see
     *                                             {@see DataplexServiceClient::lakeName()} for help formatting this field.
     * @param string $zoneId                       Zone identifier.
     *                                             This ID will be used to generate names such as database and dataset names
     *                                             when publishing metadata to Hive Metastore and BigQuery.
     *                                             * Must contain only lowercase letters, numbers and hyphens.
     *                                             * Must start with a letter.
     *                                             * Must end with a number or a letter.
     *                                             * Must be between 1-63 characters.
     *                                             * Must be unique across all lakes from all locations in a project.
     *                                             * Must not be one of the reserved IDs (i.e. "default", "global-temp")
     * @param int    $zoneType                     Immutable. The type of the zone.
     * @param int    $zoneResourceSpecLocationType Immutable. The location type of the resources that are allowed
     *                                             to be attached to the assets within this zone.
     */
    function create_zone_sample(
        string $formattedParent,
        string $zoneId,
        int $zoneType,
        int $zoneResourceSpecLocationType
    ): void {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $zoneResourceSpec = (new ResourceSpec())
            ->setLocationType($zoneResourceSpecLocationType);
        $zone = (new Zone())
            ->setType($zoneType)
            ->setResourceSpec($zoneResourceSpec);
        $request = (new CreateZoneRequest())
            ->setParent($formattedParent)
            ->setZoneId($zoneId)
            ->setZone($zone);

        // Call the API and handle any network failures.
        try {
            /** @var OperationResponse $response */
            $response = $dataplexServiceClient->createZone($request);
            $response->pollUntilComplete();

            if ($response->operationSucceeded()) {
                /** @var Zone $result */
                $result = $response->getResult();
                printf('Operation successful with response data: %s' . PHP_EOL, $result->serializeToJsonString());
            } else {
                /** @var Status $error */
                $error = $response->getError();
                printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString());
            }
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $formattedParent = DataplexServiceClient::lakeName('[PROJECT]', '[LOCATION]', '[LAKE]');
        $zoneId = '[ZONE_ID]';
        $zoneType = Type::TYPE_UNSPECIFIED;
        $zoneResourceSpecLocationType = LocationType::LOCATION_TYPE_UNSPECIFIED;

        create_zone_sample($formattedParent, $zoneId, $zoneType, $zoneResourceSpecLocationType);
    }

### deleteAsset

Deletes an asset resource. The referenced storage resource is detached
(default) or deleted based on the associated Lifecycle policy.

The async variant is [DataplexServiceClient::deleteAssetAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__deleteAssetAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.DeleteAssetRequest` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/gax/latest/OperationResponse.html<null>` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\ApiCore\OperationResponse;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Dataplex\V1\DeleteAssetRequest;
    use Google\Rpc\Status;

    /**
     * @param string $formattedName The resource name of the asset:
     *                              `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}/assets/{asset_id}`. Please see
     *                              {@see DataplexServiceClient::assetName()} for help formatting this field.
     */
    function delete_asset_sample(string $formattedName): void
    {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $request = (new DeleteAssetRequest())
            ->setName($formattedName);

        // Call the API and handle any network failures.
        try {
            /** @var OperationResponse $response */
            $response = $dataplexServiceClient->deleteAsset($request);
            $response->pollUntilComplete();

            if ($response->operationSucceeded()) {
                printf('Operation completed successfully.' . PHP_EOL);
            } else {
                /** @var Status $error */
                $error = $response->getError();
                printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString());
            }
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $formattedName = DataplexServiceClient::assetName(
            '[PROJECT]',
            '[LOCATION]',
            '[LAKE]',
            '[ZONE]',
            '[ASSET]'
        );

        delete_asset_sample($formattedName);
    }

### deleteLake

Deletes a lake resource. All zones within the lake must be deleted before
the lake can be deleted.

The async variant is [DataplexServiceClient::deleteLakeAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__deleteLakeAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.DeleteLakeRequest` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/gax/latest/OperationResponse.html<null>` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\ApiCore\OperationResponse;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Dataplex\V1\DeleteLakeRequest;
    use Google\Rpc\Status;

    /**
     * @param string $formattedName The resource name of the lake:
     *                              `projects/{project_number}/locations/{location_id}/lakes/{lake_id}`. Please see
     *                              {@see DataplexServiceClient::lakeName()} for help formatting this field.
     */
    function delete_lake_sample(string $formattedName): void
    {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $request = (new DeleteLakeRequest())
            ->setName($formattedName);

        // Call the API and handle any network failures.
        try {
            /** @var OperationResponse $response */
            $response = $dataplexServiceClient->deleteLake($request);
            $response->pollUntilComplete();

            if ($response->operationSucceeded()) {
                printf('Operation completed successfully.' . PHP_EOL);
            } else {
                /** @var Status $error */
                $error = $response->getError();
                printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString());
            }
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $formattedName = DataplexServiceClient::lakeName('[PROJECT]', '[LOCATION]', '[LAKE]');

        delete_lake_sample($formattedName);
    }

### deleteTask

Delete the task resource.

The async variant is [DataplexServiceClient::deleteTaskAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__deleteTaskAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.DeleteTaskRequest` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/gax/latest/OperationResponse.html<null>` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\ApiCore\OperationResponse;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Dataplex\V1\DeleteTaskRequest;
    use Google\Rpc\Status;

    /**
     * @param string $formattedName The resource name of the task:
     *                              `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/task/{task_id}`. Please see
     *                              {@see DataplexServiceClient::taskName()} for help formatting this field.
     */
    function delete_task_sample(string $formattedName): void
    {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $request = (new DeleteTaskRequest())
            ->setName($formattedName);

        // Call the API and handle any network failures.
        try {
            /** @var OperationResponse $response */
            $response = $dataplexServiceClient->deleteTask($request);
            $response->pollUntilComplete();

            if ($response->operationSucceeded()) {
                printf('Operation completed successfully.' . PHP_EOL);
            } else {
                /** @var Status $error */
                $error = $response->getError();
                printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString());
            }
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $formattedName = DataplexServiceClient::taskName('[PROJECT]', '[LOCATION]', '[LAKE]', '[TASK]');

        delete_task_sample($formattedName);
    }

### deleteZone

Deletes a zone resource. All assets within a zone must be deleted before
the zone can be deleted.

The async variant is [DataplexServiceClient::deleteZoneAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__deleteZoneAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.DeleteZoneRequest` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/gax/latest/OperationResponse.html<null>` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\ApiCore\OperationResponse;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Dataplex\V1\DeleteZoneRequest;
    use Google\Rpc\Status;

    /**
     * @param string $formattedName The resource name of the zone:
     *                              `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}`. Please see
     *                              {@see DataplexServiceClient::zoneName()} for help formatting this field.
     */
    function delete_zone_sample(string $formattedName): void
    {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $request = (new DeleteZoneRequest())
            ->setName($formattedName);

        // Call the API and handle any network failures.
        try {
            /** @var OperationResponse $response */
            $response = $dataplexServiceClient->deleteZone($request);
            $response->pollUntilComplete();

            if ($response->operationSucceeded()) {
                printf('Operation completed successfully.' . PHP_EOL);
            } else {
                /** @var Status $error */
                $error = $response->getError();
                printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString());
            }
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $formattedName = DataplexServiceClient::zoneName('[PROJECT]', '[LOCATION]', '[LAKE]', '[ZONE]');

        delete_zone_sample($formattedName);
    }

### getAsset

Retrieves an asset resource.

The async variant is [DataplexServiceClient::getAssetAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__getAssetAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.GetAssetRequest` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Asset` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\Cloud\Dataplex\V1\Asset;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Dataplex\V1\GetAssetRequest;

    /**
     * @param string $formattedName The resource name of the asset:
     *                              `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}/assets/{asset_id}`. Please see
     *                              {@see DataplexServiceClient::assetName()} for help formatting this field.
     */
    function get_asset_sample(string $formattedName): void
    {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $request = (new GetAssetRequest())
            ->setName($formattedName);

        // Call the API and handle any network failures.
        try {
            /** @var Asset $response */
            $response = $dataplexServiceClient->getAsset($request);
            printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString());
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $formattedName = DataplexServiceClient::assetName(
            '[PROJECT]',
            '[LOCATION]',
            '[LAKE]',
            '[ZONE]',
            '[ASSET]'
        );

        get_asset_sample($formattedName);
    }

### getJob

Get job resource.

The async variant is [DataplexServiceClient::getJobAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__getJobAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.GetJobRequest` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Job` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Dataplex\V1\GetJobRequest;
    use Google\Cloud\Dataplex\V1\Job;

    /**
     * @param string $formattedName The resource name of the job:
     *                              `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/tasks/{task_id}/jobs/{job_id}`. Please see
     *                              {@see DataplexServiceClient::jobName()} for help formatting this field.
     */
    function get_job_sample(string $formattedName): void
    {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $request = (new GetJobRequest())
            ->setName($formattedName);

        // Call the API and handle any network failures.
        try {
            /** @var Job $response */
            $response = $dataplexServiceClient->getJob($request);
            printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString());
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $formattedName = DataplexServiceClient::jobName(
            '[PROJECT]',
            '[LOCATION]',
            '[LAKE]',
            '[TASK]',
            '[JOB]'
        );

        get_job_sample($formattedName);
    }

### getLake

Retrieves a lake resource.

The async variant is [DataplexServiceClient::getLakeAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__getLakeAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.GetLakeRequest` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Lake` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Dataplex\V1\GetLakeRequest;
    use Google\Cloud\Dataplex\V1\Lake;

    /**
     * @param string $formattedName The resource name of the lake:
     *                              `projects/{project_number}/locations/{location_id}/lakes/{lake_id}`. Please see
     *                              {@see DataplexServiceClient::lakeName()} for help formatting this field.
     */
    function get_lake_sample(string $formattedName): void
    {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $request = (new GetLakeRequest())
            ->setName($formattedName);

        // Call the API and handle any network failures.
        try {
            /** @var Lake $response */
            $response = $dataplexServiceClient->getLake($request);
            printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString());
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $formattedName = DataplexServiceClient::lakeName('[PROJECT]', '[LOCATION]', '[LAKE]');

        get_lake_sample($formattedName);
    }

### getTask

Get task resource.

The async variant is [DataplexServiceClient::getTaskAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__getTaskAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.GetTaskRequest` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Task` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Dataplex\V1\GetTaskRequest;
    use Google\Cloud\Dataplex\V1\Task;

    /**
     * @param string $formattedName The resource name of the task:
     *                              `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/tasks/{tasks_id}`. Please see
     *                              {@see DataplexServiceClient::taskName()} for help formatting this field.
     */
    function get_task_sample(string $formattedName): void
    {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $request = (new GetTaskRequest())
            ->setName($formattedName);

        // Call the API and handle any network failures.
        try {
            /** @var Task $response */
            $response = $dataplexServiceClient->getTask($request);
            printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString());
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $formattedName = DataplexServiceClient::taskName('[PROJECT]', '[LOCATION]', '[LAKE]', '[TASK]');

        get_task_sample($formattedName);
    }

### getZone

Retrieves a zone resource.

The async variant is [DataplexServiceClient::getZoneAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__getZoneAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.GetZoneRequest` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Zone` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Dataplex\V1\GetZoneRequest;
    use Google\Cloud\Dataplex\V1\Zone;

    /**
     * @param string $formattedName The resource name of the zone:
     *                              `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}`. Please see
     *                              {@see DataplexServiceClient::zoneName()} for help formatting this field.
     */
    function get_zone_sample(string $formattedName): void
    {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $request = (new GetZoneRequest())
            ->setName($formattedName);

        // Call the API and handle any network failures.
        try {
            /** @var Zone $response */
            $response = $dataplexServiceClient->getZone($request);
            printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString());
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $formattedName = DataplexServiceClient::zoneName('[PROJECT]', '[LOCATION]', '[LAKE]', '[ZONE]');

        get_zone_sample($formattedName);
    }

### listAssetActions

Lists action resources in an asset.

The async variant is [DataplexServiceClient::listAssetActionsAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__listAssetActionsAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.ListAssetActionsRequest` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/gax/latest/PagedListResponse.html` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\ApiCore\PagedListResponse;
    use Google\Cloud\Dataplex\V1\Action;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Dataplex\V1\ListAssetActionsRequest;

    /**
     * @param string $formattedParent The resource name of the parent asset:
     *                                `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}/assets/{asset_id}`. Please see
     *                                {@see DataplexServiceClient::assetName()} for help formatting this field.
     */
    function list_asset_actions_sample(string $formattedParent): void
    {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $request = (new ListAssetActionsRequest())
            ->setParent($formattedParent);

        // Call the API and handle any network failures.
        try {
            /** @var PagedListResponse $response */
            $response = $dataplexServiceClient->listAssetActions($request);

            /** @var Action $element */
            foreach ($response as $element) {
                printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString());
            }
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $formattedParent = DataplexServiceClient::assetName(
            '[PROJECT]',
            '[LOCATION]',
            '[LAKE]',
            '[ZONE]',
            '[ASSET]'
        );

        list_asset_actions_sample($formattedParent);
    }

### listAssets

Lists asset resources in a zone.

The async variant is [DataplexServiceClient::listAssetsAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__listAssetsAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.ListAssetsRequest` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/gax/latest/PagedListResponse.html` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\ApiCore\PagedListResponse;
    use Google\Cloud\Dataplex\V1\Asset;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Dataplex\V1\ListAssetsRequest;

    /**
     * @param string $formattedParent The resource name of the parent zone:
     *                                `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}`. Please see
     *                                {@see DataplexServiceClient::zoneName()} for help formatting this field.
     */
    function list_assets_sample(string $formattedParent): void
    {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $request = (new ListAssetsRequest())
            ->setParent($formattedParent);

        // Call the API and handle any network failures.
        try {
            /** @var PagedListResponse $response */
            $response = $dataplexServiceClient->listAssets($request);

            /** @var Asset $element */
            foreach ($response as $element) {
                printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString());
            }
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $formattedParent = DataplexServiceClient::zoneName('[PROJECT]', '[LOCATION]', '[LAKE]', '[ZONE]');

        list_assets_sample($formattedParent);
    }

### listJobs

Lists Jobs under the given task.

The async variant is [DataplexServiceClient::listJobsAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__listJobsAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.ListJobsRequest` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/gax/latest/PagedListResponse.html` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\ApiCore\PagedListResponse;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Dataplex\V1\Job;
    use Google\Cloud\Dataplex\V1\ListJobsRequest;

    /**
     * @param string $formattedParent The resource name of the parent environment:
     *                                `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/tasks/{task_id}`. Please see
     *                                {@see DataplexServiceClient::taskName()} for help formatting this field.
     */
    function list_jobs_sample(string $formattedParent): void
    {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $request = (new ListJobsRequest())
            ->setParent($formattedParent);

        // Call the API and handle any network failures.
        try {
            /** @var PagedListResponse $response */
            $response = $dataplexServiceClient->listJobs($request);

            /** @var Job $element */
            foreach ($response as $element) {
                printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString());
            }
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $formattedParent = DataplexServiceClient::taskName('[PROJECT]', '[LOCATION]', '[LAKE]', '[TASK]');

        list_jobs_sample($formattedParent);
    }

### listLakeActions

Lists action resources in a lake.

The async variant is [DataplexServiceClient::listLakeActionsAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__listLakeActionsAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.ListLakeActionsRequest` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/gax/latest/PagedListResponse.html` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\ApiCore\PagedListResponse;
    use Google\Cloud\Dataplex\V1\Action;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Dataplex\V1\ListLakeActionsRequest;

    /**
     * @param string $formattedParent The resource name of the parent lake:
     *                                `projects/{project_number}/locations/{location_id}/lakes/{lake_id}`. Please see
     *                                {@see DataplexServiceClient::lakeName()} for help formatting this field.
     */
    function list_lake_actions_sample(string $formattedParent): void
    {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $request = (new ListLakeActionsRequest())
            ->setParent($formattedParent);

        // Call the API and handle any network failures.
        try {
            /** @var PagedListResponse $response */
            $response = $dataplexServiceClient->listLakeActions($request);

            /** @var Action $element */
            foreach ($response as $element) {
                printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString());
            }
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $formattedParent = DataplexServiceClient::lakeName('[PROJECT]', '[LOCATION]', '[LAKE]');

        list_lake_actions_sample($formattedParent);
    }

### listLakes

Lists lake resources in a project and location.

The async variant is [DataplexServiceClient::listLakesAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__listLakesAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.ListLakesRequest` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/gax/latest/PagedListResponse.html` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\ApiCore\PagedListResponse;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Dataplex\V1\Lake;
    use Google\Cloud\Dataplex\V1\ListLakesRequest;

    /**
     * @param string $formattedParent The resource name of the lake location, of the form:
     *                                `projects/{project_number}/locations/{location_id}`
     *                                where `location_id` refers to a Google Cloud region. Please see
     *                                {@see DataplexServiceClient::locationName()} for help formatting this field.
     */
    function list_lakes_sample(string $formattedParent): void
    {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $request = (new ListLakesRequest())
            ->setParent($formattedParent);

        // Call the API and handle any network failures.
        try {
            /** @var PagedListResponse $response */
            $response = $dataplexServiceClient->listLakes($request);

            /** @var Lake $element */
            foreach ($response as $element) {
                printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString());
            }
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $formattedParent = DataplexServiceClient::locationName('[PROJECT]', '[LOCATION]');

        list_lakes_sample($formattedParent);
    }

### listTasks

Lists tasks under the given lake.

The async variant is [DataplexServiceClient::listTasksAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__listTasksAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.ListTasksRequest` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/gax/latest/PagedListResponse.html` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\ApiCore\PagedListResponse;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Dataplex\V1\ListTasksRequest;
    use Google\Cloud\Dataplex\V1\Task;

    /**
     * @param string $formattedParent The resource name of the parent lake:
     *                                `projects/{project_number}/locations/{location_id}/lakes/{lake_id}`. Please see
     *                                {@see DataplexServiceClient::lakeName()} for help formatting this field.
     */
    function list_tasks_sample(string $formattedParent): void
    {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $request = (new ListTasksRequest())
            ->setParent($formattedParent);

        // Call the API and handle any network failures.
        try {
            /** @var PagedListResponse $response */
            $response = $dataplexServiceClient->listTasks($request);

            /** @var Task $element */
            foreach ($response as $element) {
                printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString());
            }
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $formattedParent = DataplexServiceClient::lakeName('[PROJECT]', '[LOCATION]', '[LAKE]');

        list_tasks_sample($formattedParent);
    }

### listZoneActions

Lists action resources in a zone.

The async variant is [DataplexServiceClient::listZoneActionsAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__listZoneActionsAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.ListZoneActionsRequest` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/gax/latest/PagedListResponse.html` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\ApiCore\PagedListResponse;
    use Google\Cloud\Dataplex\V1\Action;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Dataplex\V1\ListZoneActionsRequest;

    /**
     * @param string $formattedParent The resource name of the parent zone:
     *                                `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/zones/{zone_id}`. Please see
     *                                {@see DataplexServiceClient::zoneName()} for help formatting this field.
     */
    function list_zone_actions_sample(string $formattedParent): void
    {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $request = (new ListZoneActionsRequest())
            ->setParent($formattedParent);

        // Call the API and handle any network failures.
        try {
            /** @var PagedListResponse $response */
            $response = $dataplexServiceClient->listZoneActions($request);

            /** @var Action $element */
            foreach ($response as $element) {
                printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString());
            }
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $formattedParent = DataplexServiceClient::zoneName('[PROJECT]', '[LOCATION]', '[LAKE]', '[ZONE]');

        list_zone_actions_sample($formattedParent);
    }

### listZones

Lists zone resources in a lake.

The async variant is [DataplexServiceClient::listZonesAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__listZonesAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.ListZonesRequest` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/gax/latest/PagedListResponse.html` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\ApiCore\PagedListResponse;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Dataplex\V1\ListZonesRequest;
    use Google\Cloud\Dataplex\V1\Zone;

    /**
     * @param string $formattedParent The resource name of the parent lake:
     *                                `projects/{project_number}/locations/{location_id}/lakes/{lake_id}`. Please see
     *                                {@see DataplexServiceClient::lakeName()} for help formatting this field.
     */
    function list_zones_sample(string $formattedParent): void
    {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $request = (new ListZonesRequest())
            ->setParent($formattedParent);

        // Call the API and handle any network failures.
        try {
            /** @var PagedListResponse $response */
            $response = $dataplexServiceClient->listZones($request);

            /** @var Zone $element */
            foreach ($response as $element) {
                printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString());
            }
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $formattedParent = DataplexServiceClient::lakeName('[PROJECT]', '[LOCATION]', '[LAKE]');

        list_zones_sample($formattedParent);
    }

### runTask

Run an on demand execution of a Task.

The async variant is [DataplexServiceClient::runTaskAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__runTaskAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.RunTaskRequest` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.RunTaskResponse` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Dataplex\V1\RunTaskRequest;
    use Google\Cloud\Dataplex\V1\RunTaskResponse;

    /**
     * @param string $formattedName The resource name of the task:
     *                              `projects/{project_number}/locations/{location_id}/lakes/{lake_id}/tasks/{task_id}`. Please see
     *                              {@see DataplexServiceClient::taskName()} for help formatting this field.
     */
    function run_task_sample(string $formattedName): void
    {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $request = (new RunTaskRequest())
            ->setName($formattedName);

        // Call the API and handle any network failures.
        try {
            /** @var RunTaskResponse $response */
            $response = $dataplexServiceClient->runTask($request);
            printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString());
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $formattedName = DataplexServiceClient::taskName('[PROJECT]', '[LOCATION]', '[LAKE]', '[TASK]');

        run_task_sample($formattedName);
    }

### updateAsset

Updates an asset resource.

The async variant is [DataplexServiceClient::updateAssetAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__updateAssetAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.UpdateAssetRequest` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/gax/latest/OperationResponse.html<https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Asset>` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\ApiCore\OperationResponse;
    use Google\Cloud\Dataplex\V1\Asset;
    use Google\Cloud\Dataplex\V1\Asset\ResourceSpec;
    use Google\Cloud\Dataplex\V1\Asset\ResourceSpec\Type;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Dataplex\V1\UpdateAssetRequest;
    use Google\Protobuf\FieldMask;
    use Google\Rpc\Status;

    /**
     * @param int $assetResourceSpecType Immutable. Type of resource.
     */
    function update_asset_sample(int $assetResourceSpecType): void
    {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $updateMask = new FieldMask();
        $assetResourceSpec = (new ResourceSpec())
            ->setType($assetResourceSpecType);
        $asset = (new Asset())
            ->setResourceSpec($assetResourceSpec);
        $request = (new UpdateAssetRequest())
            ->setUpdateMask($updateMask)
            ->setAsset($asset);

        // Call the API and handle any network failures.
        try {
            /** @var OperationResponse $response */
            $response = $dataplexServiceClient->updateAsset($request);
            $response->pollUntilComplete();

            if ($response->operationSucceeded()) {
                /** @var Asset $result */
                $result = $response->getResult();
                printf('Operation successful with response data: %s' . PHP_EOL, $result->serializeToJsonString());
            } else {
                /** @var Status $error */
                $error = $response->getError();
                printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString());
            }
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $assetResourceSpecType = Type::TYPE_UNSPECIFIED;

        update_asset_sample($assetResourceSpecType);
    }

### updateLake

Updates a lake resource.

The async variant is [DataplexServiceClient::updateLakeAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__updateLakeAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.UpdateLakeRequest` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/gax/latest/OperationResponse.html<https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Lake>` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\ApiCore\OperationResponse;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Dataplex\V1\Lake;
    use Google\Cloud\Dataplex\V1\UpdateLakeRequest;
    use Google\Protobuf\FieldMask;
    use Google\Rpc\Status;

    /**
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function update_lake_sample(): void
    {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $updateMask = new FieldMask();
        $lake = new Lake();
        $request = (new UpdateLakeRequest())
            ->setUpdateMask($updateMask)
            ->setLake($lake);

        // Call the API and handle any network failures.
        try {
            /** @var OperationResponse $response */
            $response = $dataplexServiceClient->updateLake($request);
            $response->pollUntilComplete();

            if ($response->operationSucceeded()) {
                /** @var Lake $result */
                $result = $response->getResult();
                printf('Operation successful with response data: %s' . PHP_EOL, $result->serializeToJsonString());
            } else {
                /** @var Status $error */
                $error = $response->getError();
                printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString());
            }
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

### updateTask

Update the task resource.

The async variant is [DataplexServiceClient::updateTaskAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__updateTaskAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.UpdateTaskRequest` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/gax/latest/OperationResponse.html<https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Task>` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\ApiCore\OperationResponse;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Dataplex\V1\Task;
    use Google\Cloud\Dataplex\V1\Task\ExecutionSpec;
    use Google\Cloud\Dataplex\V1\Task\TriggerSpec;
    use Google\Cloud\Dataplex\V1\Task\TriggerSpec\Type;
    use Google\Cloud\Dataplex\V1\UpdateTaskRequest;
    use Google\Protobuf\FieldMask;
    use Google\Rpc\Status;

    /**
     * @param int    $taskTriggerSpecType             Immutable. Trigger type of the user-specified Task.
     * @param string $taskExecutionSpecServiceAccount Service account to use to execute a task.
     *                                                If not provided, the default Compute service account for the project is
     *                                                used.
     */
    function update_task_sample(
        int $taskTriggerSpecType,
        string $taskExecutionSpecServiceAccount
    ): void {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $updateMask = new FieldMask();
        $taskTriggerSpec = (new TriggerSpec())
            ->setType($taskTriggerSpecType);
        $taskExecutionSpec = (new ExecutionSpec())
            ->setServiceAccount($taskExecutionSpecServiceAccount);
        $task = (new Task())
            ->setTriggerSpec($taskTriggerSpec)
            ->setExecutionSpec($taskExecutionSpec);
        $request = (new UpdateTaskRequest())
            ->setUpdateMask($updateMask)
            ->setTask($task);

        // Call the API and handle any network failures.
        try {
            /** @var OperationResponse $response */
            $response = $dataplexServiceClient->updateTask($request);
            $response->pollUntilComplete();

            if ($response->operationSucceeded()) {
                /** @var Task $result */
                $result = $response->getResult();
                printf('Operation successful with response data: %s' . PHP_EOL, $result->serializeToJsonString());
            } else {
                /** @var Status $error */
                $error = $response->getError();
                printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString());
            }
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $taskTriggerSpecType = Type::TYPE_UNSPECIFIED;
        $taskExecutionSpecServiceAccount = '[SERVICE_ACCOUNT]';

        update_task_sample($taskTriggerSpecType, $taskExecutionSpecServiceAccount);
    }

### updateZone

Updates a zone resource.

The async variant is [DataplexServiceClient::updateZoneAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__updateZoneAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.UpdateZoneRequest` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/gax/latest/OperationResponse.html<https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Zone>` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\ApiCore\OperationResponse;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Dataplex\V1\UpdateZoneRequest;
    use Google\Cloud\Dataplex\V1\Zone;
    use Google\Cloud\Dataplex\V1\Zone\ResourceSpec;
    use Google\Cloud\Dataplex\V1\Zone\ResourceSpec\LocationType;
    use Google\Cloud\Dataplex\V1\Zone\Type;
    use Google\Protobuf\FieldMask;
    use Google\Rpc\Status;

    /**
     * @param int $zoneType                     Immutable. The type of the zone.
     * @param int $zoneResourceSpecLocationType Immutable. The location type of the resources that are allowed
     *                                          to be attached to the assets within this zone.
     */
    function update_zone_sample(int $zoneType, int $zoneResourceSpecLocationType): void
    {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $updateMask = new FieldMask();
        $zoneResourceSpec = (new ResourceSpec())
            ->setLocationType($zoneResourceSpecLocationType);
        $zone = (new Zone())
            ->setType($zoneType)
            ->setResourceSpec($zoneResourceSpec);
        $request = (new UpdateZoneRequest())
            ->setUpdateMask($updateMask)
            ->setZone($zone);

        // Call the API and handle any network failures.
        try {
            /** @var OperationResponse $response */
            $response = $dataplexServiceClient->updateZone($request);
            $response->pollUntilComplete();

            if ($response->operationSucceeded()) {
                /** @var Zone $result */
                $result = $response->getResult();
                printf('Operation successful with response data: %s' . PHP_EOL, $result->serializeToJsonString());
            } else {
                /** @var Status $error */
                $error = $response->getError();
                printf('Operation failed with error data: %s' . PHP_EOL, $error->serializeToJsonString());
            }
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $zoneType = Type::TYPE_UNSPECIFIED;
        $zoneResourceSpecLocationType = LocationType::LOCATION_TYPE_UNSPECIFIED;

        update_zone_sample($zoneType, $zoneResourceSpecLocationType);
    }

### getLocation

Gets information about a location.

The async variant is [DataplexServiceClient::getLocationAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__getLocationAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/common-protos/latest/Cloud.Location.GetLocationRequest.html` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/common-protos/latest/Cloud.Location.Location.html` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Location\GetLocationRequest;
    use Google\Cloud\Location\Location;

    /**
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function get_location_sample(): void
    {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $request = new GetLocationRequest();

        // Call the API and handle any network failures.
        try {
            /** @var Location $response */
            $response = $dataplexServiceClient->getLocation($request);
            printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString());
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

### listLocations

Lists information about the supported locations for this service.

This method lists locations based on the resource scope provided in
the [ListLocationsRequest.name](https://docs.cloud.google.com/php/docs/reference/common-protos/latest/Cloud.Location.ListLocationsRequest.html#_Google_Cloud_Location_ListLocationsRequest__getName__) field: \*
*Global locations* *: If `name` is empty, the method lists the
public locations available to all projects. \* \*\*Project-specific
locations* \*: If `name` follows the format
`projects/{project}`, the method lists locations visible to that
specific project. This includes public, private, or other
project-specific locations enabled for the project.

For gRPC and client library implementations, the resource name is
passed as the `name` field. For direct service calls, the resource
name is
incorporated into the request path based on the specific service
implementation and version.

The async variant is [DataplexServiceClient::listLocationsAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__listLocationsAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/common-protos/latest/Cloud.Location.ListLocationsRequest.html` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/gax/latest/PagedListResponse.html` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\ApiCore\PagedListResponse;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Location\ListLocationsRequest;
    use Google\Cloud\Location\Location;

    /**
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function list_locations_sample(): void
    {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $request = new ListLocationsRequest();

        // Call the API and handle any network failures.
        try {
            /** @var PagedListResponse $response */
            $response = $dataplexServiceClient->listLocations($request);

            /** @var Location $element */
            foreach ($response as $element) {
                printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString());
            }
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

### getIamPolicy

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

The async variant is [DataplexServiceClient::getIamPolicyAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__getIamPolicyAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/common-protos/latest/Cloud.Iam.V1.GetIamPolicyRequest.html` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/common-protos/latest/Cloud.Iam.V1.Policy.html` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Iam\V1\GetIamPolicyRequest;
    use Google\Cloud\Iam\V1\Policy;

    /**
     * @param string $resource REQUIRED: The resource for which the policy is being requested.
     *                         See the operation documentation for the appropriate value for this field.
     */
    function get_iam_policy_sample(string $resource): void
    {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $request = (new GetIamPolicyRequest())
            ->setResource($resource);

        // Call the API and handle any network failures.
        try {
            /** @var Policy $response */
            $response = $dataplexServiceClient->getIamPolicy($request);
            printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString());
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $resource = '[RESOURCE]';

        get_iam_policy_sample($resource);
    }

### setIamPolicy

Sets the access control policy on the specified resource. Replaces
any existing policy.

Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED`
errors.

The async variant is [DataplexServiceClient::setIamPolicyAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__setIamPolicyAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/common-protos/latest/Cloud.Iam.V1.SetIamPolicyRequest.html` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/common-protos/latest/Cloud.Iam.V1.Policy.html` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Iam\V1\Policy;
    use Google\Cloud\Iam\V1\SetIamPolicyRequest;

    /**
     * @param string $resource REQUIRED: The resource for which the policy is being specified.
     *                         See the operation documentation for the appropriate value for this field.
     */
    function set_iam_policy_sample(string $resource): void
    {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $policy = new Policy();
        $request = (new SetIamPolicyRequest())
            ->setResource($resource)
            ->setPolicy($policy);

        // Call the API and handle any network failures.
        try {
            /** @var Policy $response */
            $response = $dataplexServiceClient->setIamPolicy($request);
            printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString());
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $resource = '[RESOURCE]';

        set_iam_policy_sample($resource);
    }

### testIamPermissions

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.

The async variant is [DataplexServiceClient::testIamPermissionsAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Client.DataplexServiceClient#_Google_Cloud_Dataplex_V1_Client_DataplexServiceClient__testIamPermissionsAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/common-protos/latest/Cloud.Iam.V1.TestIamPermissionsRequest.html` A request to house fields associated with the call. |
| `callOptions` | `array` Optional. |
| `↳ retrySettings` | `https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html|array` Retry settings to use for this call. Can be a [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) object, or an associative array of retry settings parameters. See the documentation on [Google\\ApiCore\\RetrySettings](https://docs.cloud.google.com/php/docs/reference/gax/latest/RetrySettings.html) for example usage. |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/common-protos/latest/Cloud.Iam.V1.TestIamPermissionsResponse.html` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\Cloud\Dataplex\V1\Client\DataplexServiceClient;
    use Google\Cloud\Iam\V1\TestIamPermissionsRequest;
    use Google\Cloud\Iam\V1\TestIamPermissionsResponse;

    /**
     * @param string $resource           REQUIRED: The resource for which the policy detail is being requested.
     *                                   See the operation documentation for the appropriate value for this field.
     * @param string $permissionsElement The set of permissions to check for the `resource`. Permissions with
     *                                   wildcards (such as '*' or 'storage.*') are not allowed. For more
     *                                   information see
     *                                   [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
     */
    function test_iam_permissions_sample(string $resource, string $permissionsElement): void
    {
        // Create a client.
        $dataplexServiceClient = new DataplexServiceClient();

        // Prepare the request message.
        $permissions = [$permissionsElement,];
        $request = (new TestIamPermissionsRequest())
            ->setResource($resource)
            ->setPermissions($permissions);

        // Call the API and handle any network failures.
        try {
            /** @var TestIamPermissionsResponse $response */
            $response = $dataplexServiceClient->testIamPermissions($request);
            printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString());
        } catch (ApiException $ex) {
            printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage());
        }
    }

    /**
     * Helper to execute the sample.
     *
     * This sample has been automatically generated and should be regarded as a code
     * template only. It will require modifications to work:
     *  - It may require correct/in-range values for request initialization.
     *  - It may require specifying regional endpoints when creating the service client,
     *    please see the apiEndpoint client configuration option for more details.
     */
    function callSample(): void
    {
        $resource = '[RESOURCE]';
        $permissionsElement = '[PERMISSIONS]';

        test_iam_permissions_sample($resource, $permissionsElement);
    }

### cancelJobAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.CancelJobRequest` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<void>` |   |

### createAssetAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.CreateAssetRequest` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/gax/latest/OperationResponse.html>` |   |

### createLakeAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.CreateLakeRequest` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/gax/latest/OperationResponse.html>` |   |

### createTaskAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.CreateTaskRequest` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/gax/latest/OperationResponse.html>` |   |

### createZoneAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.CreateZoneRequest` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/gax/latest/OperationResponse.html>` |   |

### deleteAssetAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.DeleteAssetRequest` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/gax/latest/OperationResponse.html>` |   |

### deleteLakeAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.DeleteLakeRequest` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/gax/latest/OperationResponse.html>` |   |

### deleteTaskAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.DeleteTaskRequest` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/gax/latest/OperationResponse.html>` |   |

### deleteZoneAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.DeleteZoneRequest` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/gax/latest/OperationResponse.html>` |   |

### getAssetAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.GetAssetRequest` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Asset>` |   |

### getJobAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.GetJobRequest` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Job>` |   |

### getLakeAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.GetLakeRequest` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Lake>` |   |

### getTaskAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.GetTaskRequest` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Task>` |   |

### getZoneAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.GetZoneRequest` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.Zone>` |   |

### listAssetActionsAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.ListAssetActionsRequest` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/gax/latest/PagedListResponse.html>` |   |

### listAssetsAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.ListAssetsRequest` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/gax/latest/PagedListResponse.html>` |   |

### listJobsAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.ListJobsRequest` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/gax/latest/PagedListResponse.html>` |   |

### listLakeActionsAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.ListLakeActionsRequest` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/gax/latest/PagedListResponse.html>` |   |

### listLakesAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.ListLakesRequest` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/gax/latest/PagedListResponse.html>` |   |

### listTasksAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.ListTasksRequest` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/gax/latest/PagedListResponse.html>` |   |

### listZoneActionsAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.ListZoneActionsRequest` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/gax/latest/PagedListResponse.html>` |   |

### listZonesAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.ListZonesRequest` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/gax/latest/PagedListResponse.html>` |   |

### runTaskAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.RunTaskRequest` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.RunTaskResponse>` |   |

### updateAssetAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.UpdateAssetRequest` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/gax/latest/OperationResponse.html>` |   |

### updateLakeAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.UpdateLakeRequest` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/gax/latest/OperationResponse.html>` |   |

### updateTaskAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.UpdateTaskRequest` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/gax/latest/OperationResponse.html>` |   |

### updateZoneAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-dataplex/latest/V1.UpdateZoneRequest` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/gax/latest/OperationResponse.html>` |   |

### getLocationAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/common-protos/latest/Cloud.Location.GetLocationRequest.html` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/common-protos/latest/Cloud.Location.Location.html>` |   |

### listLocationsAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/common-protos/latest/Cloud.Location.ListLocationsRequest.html` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/gax/latest/PagedListResponse.html>` |   |

### getIamPolicyAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/common-protos/latest/Cloud.Iam.V1.GetIamPolicyRequest.html` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/common-protos/latest/Cloud.Iam.V1.Policy.html>` |   |

### setIamPolicyAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/common-protos/latest/Cloud.Iam.V1.SetIamPolicyRequest.html` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/common-protos/latest/Cloud.Iam.V1.Policy.html>` |   |

### testIamPermissionsAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/common-protos/latest/Cloud.Iam.V1.TestIamPermissionsRequest.html` |
| `optionalArgs` | `array` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.aws.amazon.com/aws-sdk-php/v3/api/class-GuzzleHttp.Promise.Promise.html<https://docs.cloud.google.com/php/docs/reference/common-protos/latest/Cloud.Iam.V1.TestIamPermissionsResponse.html>` |   |

### getOperationsClient

Return an OperationsClient object with the same endpoint as $this.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `Google\LongRunning\Client\OperationsClient` |   |

### resumeOperation

Resume an existing long running operation that was previously started by a long
running API method. If $methodName is not provided, or does not match a long
running API method, then the operation can still be resumed, but the
OperationResponse object will not deserialize the final response.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `operationName` | `string` The name of the long running operation |
| `methodName` | `string` The name of the method used to start the operation |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/gax/latest/OperationResponse.html` |   |

### static::assetName

Formats a string containing the fully-qualified path to represent a asset
resource.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `project` | `string` |
| `location` | `string` |
| `lake` | `string` |
| `zone` | `string` |
| `asset` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` | The formatted asset resource. |

### static::jobName

Formats a string containing the fully-qualified path to represent a job
resource.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `project` | `string` |
| `location` | `string` |
| `lake` | `string` |
| `task` | `string` |
| `job` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` | The formatted job resource. |

### static::lakeName

Formats a string containing the fully-qualified path to represent a lake
resource.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `project` | `string` |
| `location` | `string` |
| `lake` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` | The formatted lake resource. |

### static::locationName

Formats a string containing the fully-qualified path to represent a location
resource.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `project` | `string` |
| `location` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` | The formatted location resource. |

### static::taskName

Formats a string containing the fully-qualified path to represent a task
resource.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `project` | `string` |
| `location` | `string` |
| `lake` | `string` |
| `task` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` | The formatted task resource. |

### static::zoneName

Formats a string containing the fully-qualified path to represent a zone
resource.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `project` | `string` |
| `location` | `string` |
| `lake` | `string` |
| `zone` | `string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` | The formatted zone resource. |

### static::parseName

Parses a formatted name string and returns an associative array of the components in the name.

The following name formats are supported:
Template: Pattern

- asset: projects/{project}/locations/{location}/lakes/{lake}/zones/{zone}/assets/{asset}
- job: projects/{project}/locations/{location}/lakes/{lake}/tasks/{task}/jobs/{job}
- lake: projects/{project}/locations/{location}/lakes/{lake}
- location: projects/{project}/locations/{location}
- task: projects/{project}/locations/{location}/lakes/{lake}/tasks/{task}
- zone: projects/{project}/locations/{location}/lakes/{lake}/zones/{zone}

The optional $template argument can be supplied to specify a particular pattern,
and must match one of the templates listed above. If no $template argument is
provided, or if the $template argument does not match one of the templates
listed, then parseName will check each of the supported templates, and return
the first match.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `formattedName` | `string` The formatted name string |
| `template` | `?string` Optional name of template to match |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `array` | An associative array from name component IDs to component values. |