# Google Cloud Storage Control V2 Client - Class StorageControlClient (1.9.0)

1.9.0 (latest) 1.8.0 1.7.0 1.6.3 1.5.0 1.4.1 1.3.0 1.1.0 1.0.3 0.2.1 0.1.1 Reference documentation and code samples for the Google Cloud Storage Control V2 Client class StorageControlClient.

Service Description: StorageControl service includes selected control plane operations.

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 \\ Storage \\ Control \\ V2 \\ 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\Storage\Control\V2\StorageControlClient; $creds = new ServiceAccountCredentials($scopes, $json); $options = new StorageControlClient(['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'. |

### createAnywhereCache

Creates an Anywhere Cache instance.

The async variant is [StorageControlClient::createAnywhereCacheAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__createAnywhereCacheAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.CreateAnywhereCacheRequest` 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-storage-control/latest/V2.AnywhereCache>` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\ApiCore\OperationResponse;
    use Google\Cloud\Storage\Control\V2\AnywhereCache;
    use Google\Cloud\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\CreateAnywhereCacheRequest;
    use Google\Rpc\Status;

    /**
     * @param string $formattedParent The bucket to which this cache belongs.
     *                                Format: `projects/{project}/buckets/{bucket}`
     *                                Please see {@see StorageControlClient::bucketName()} for help formatting this field.
     */
    function create_anywhere_cache_sample(string $formattedParent): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

        // Prepare the request message.
        $anywhereCache = new AnywhereCache();
        $request = (new CreateAnywhereCacheRequest())
            ->setParent($formattedParent)
            ->setAnywhereCache($anywhereCache);

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

            if ($response->operationSucceeded()) {
                /** @var AnywhereCache $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 = StorageControlClient::bucketName('[PROJECT]', '[BUCKET]');

        create_anywhere_cache_sample($formattedParent);
    }

### createFolder

Creates a new folder. This operation is only applicable to a hierarchical
namespace enabled bucket.

The async variant is [StorageControlClient::createFolderAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__createFolderAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.CreateFolderRequest` 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-storage-control/latest/V2.Folder` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\Cloud\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\CreateFolderRequest;
    use Google\Cloud\Storage\Control\V2\Folder;

    /**
     * @param string $formattedParent Name of the bucket in which the folder will reside. The bucket
     *                                must be a hierarchical namespace enabled bucket. Please see
     *                                {@see StorageControlClient::bucketName()} for help formatting this field.
     * @param string $folderId        The full name of a folder, including all its parent folders.
     *                                Folders use single '/' characters as a delimiter.
     *                                The folder_id must end with a slash.
     *                                For example, the folder_id of "books/biographies/" would create a new
     *                                "biographies/" folder under the "books/" folder.
     */
    function create_folder_sample(string $formattedParent, string $folderId): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

        // Prepare the request message.
        $folder = new Folder();
        $request = (new CreateFolderRequest())
            ->setParent($formattedParent)
            ->setFolder($folder)
            ->setFolderId($folderId);

        // Call the API and handle any network failures.
        try {
            /** @var Folder $response */
            $response = $storageControlClient->createFolder($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
    {
        $formattedParent = StorageControlClient::bucketName('[PROJECT]', '[BUCKET]');
        $folderId = '[FOLDER_ID]';

        create_folder_sample($formattedParent, $folderId);
    }

### createManagedFolder

Creates a new managed folder.

The async variant is [StorageControlClient::createManagedFolderAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__createManagedFolderAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.CreateManagedFolderRequest` 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-storage-control/latest/V2.ManagedFolder` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\Cloud\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\CreateManagedFolderRequest;
    use Google\Cloud\Storage\Control\V2\ManagedFolder;

    /**
     * @param string $formattedParent Name of the bucket this managed folder belongs to. Please see
     *                                {@see StorageControlClient::bucketName()} for help formatting this field.
     * @param string $managedFolderId The name of the managed folder. It uses a single `/` as delimiter
     *                                and leading and trailing `/` are allowed.
     */
    function create_managed_folder_sample(string $formattedParent, string $managedFolderId): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

        // Prepare the request message.
        $managedFolder = new ManagedFolder();
        $request = (new CreateManagedFolderRequest())
            ->setParent($formattedParent)
            ->setManagedFolder($managedFolder)
            ->setManagedFolderId($managedFolderId);

        // Call the API and handle any network failures.
        try {
            /** @var ManagedFolder $response */
            $response = $storageControlClient->createManagedFolder($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
    {
        $formattedParent = StorageControlClient::bucketName('[PROJECT]', '[BUCKET]');
        $managedFolderId = '[MANAGED_FOLDER_ID]';

        create_managed_folder_sample($formattedParent, $managedFolderId);
    }

### deleteFolder

Permanently deletes an empty folder. This operation is only applicable to a
hierarchical namespace enabled bucket.

The async variant is [StorageControlClient::deleteFolderAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__deleteFolderAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.DeleteFolderRequest` 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\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\DeleteFolderRequest;

    /**
     * @param string $formattedName Name of the folder.
     *                              Format: `projects/{project}/buckets/{bucket}/folders/{folder}`
     *                              Please see {@see StorageControlClient::folderName()} for help formatting this field.
     */
    function delete_folder_sample(string $formattedName): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

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

        // Call the API and handle any network failures.
        try {
            $storageControlClient->deleteFolder($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 = StorageControlClient::folderName('[PROJECT]', '[BUCKET]', '[FOLDER]');

        delete_folder_sample($formattedName);
    }

### deleteFolderRecursive

Deletes a folder recursively. This operation is only applicable to a
hierarchical namespace enabled bucket.

The async variant is [StorageControlClient::deleteFolderRecursiveAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__deleteFolderRecursiveAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.DeleteFolderRecursiveRequest` 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\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\DeleteFolderRecursiveRequest;
    use Google\Rpc\Status;

    /**
     * @param string $formattedName Name of the folder being deleted, however all of its contents
     *                              will be deleted too. Format:
     *                              `projects/{project}/buckets/{bucket}/folders/{folder}`
     *                              Please see {@see StorageControlClient::folderName()} for help formatting this field.
     */
    function delete_folder_recursive_sample(string $formattedName): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

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

        // Call the API and handle any network failures.
        try {
            /** @var OperationResponse $response */
            $response = $storageControlClient->deleteFolderRecursive($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 = StorageControlClient::folderName('[PROJECT]', '[BUCKET]', '[FOLDER]');

        delete_folder_recursive_sample($formattedName);
    }

### deleteManagedFolder

Permanently deletes an empty managed folder.

The async variant is [StorageControlClient::deleteManagedFolderAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__deleteManagedFolderAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.DeleteManagedFolderRequest` 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\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\DeleteManagedFolderRequest;

    /**
     * @param string $formattedName Name of the managed folder.
     *                              Format:
     *                              `projects/{project}/buckets/{bucket}/managedFolders/{managedFolder}`
     *                              Please see {@see StorageControlClient::managedFolderName()} for help formatting this field.
     */
    function delete_managed_folder_sample(string $formattedName): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

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

        // Call the API and handle any network failures.
        try {
            $storageControlClient->deleteManagedFolder($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 = StorageControlClient::managedFolderName(
            '[PROJECT]',
            '[BUCKET]',
            '[MANAGED_FOLDER]'
        );

        delete_managed_folder_sample($formattedName);
    }

### disableAnywhereCache

Disables an Anywhere Cache instance. A disabled instance is read-only. The
disablement could be revoked by calling ResumeAnywhereCache. The cache
instance will be deleted automatically if it remains in the disabled state
for at least one hour.

The async variant is [StorageControlClient::disableAnywhereCacheAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__disableAnywhereCacheAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.DisableAnywhereCacheRequest` 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-storage-control/latest/V2.AnywhereCache` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\Cloud\Storage\Control\V2\AnywhereCache;
    use Google\Cloud\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\DisableAnywhereCacheRequest;

    /**
     * @param string $formattedName The name field in the request should be:
     *                              `projects/{project}/buckets/{bucket}/anywhereCaches/{anywhere_cache}`
     *                              Please see {@see StorageControlClient::anywhereCacheName()} for help formatting this field.
     */
    function disable_anywhere_cache_sample(string $formattedName): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

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

        // Call the API and handle any network failures.
        try {
            /** @var AnywhereCache $response */
            $response = $storageControlClient->disableAnywhereCache($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 = StorageControlClient::anywhereCacheName(
            '[PROJECT]',
            '[BUCKET]',
            '[ANYWHERE_CACHE]'
        );

        disable_anywhere_cache_sample($formattedName);
    }

### getAnywhereCache

Gets an Anywhere Cache instance.

The async variant is [StorageControlClient::getAnywhereCacheAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__getAnywhereCacheAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.GetAnywhereCacheRequest` 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-storage-control/latest/V2.AnywhereCache` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\Cloud\Storage\Control\V2\AnywhereCache;
    use Google\Cloud\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\GetAnywhereCacheRequest;

    /**
     * @param string $formattedName The name field in the request should be:
     *                              `projects/{project}/buckets/{bucket}/anywhereCaches/{anywhere_cache}`
     *                              Please see {@see StorageControlClient::anywhereCacheName()} for help formatting this field.
     */
    function get_anywhere_cache_sample(string $formattedName): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

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

        // Call the API and handle any network failures.
        try {
            /** @var AnywhereCache $response */
            $response = $storageControlClient->getAnywhereCache($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 = StorageControlClient::anywhereCacheName(
            '[PROJECT]',
            '[BUCKET]',
            '[ANYWHERE_CACHE]'
        );

        get_anywhere_cache_sample($formattedName);
    }

### getFolder

Returns metadata for the specified folder. This operation is only
applicable to a hierarchical namespace enabled bucket.

The async variant is [StorageControlClient::getFolderAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__getFolderAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.GetFolderRequest` 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-storage-control/latest/V2.Folder` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\Cloud\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\Folder;
    use Google\Cloud\Storage\Control\V2\GetFolderRequest;

    /**
     * @param string $formattedName Name of the folder.
     *                              Format: `projects/{project}/buckets/{bucket}/folders/{folder}`
     *                              Please see {@see StorageControlClient::folderName()} for help formatting this field.
     */
    function get_folder_sample(string $formattedName): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

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

        // Call the API and handle any network failures.
        try {
            /** @var Folder $response */
            $response = $storageControlClient->getFolder($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 = StorageControlClient::folderName('[PROJECT]', '[BUCKET]', '[FOLDER]');

        get_folder_sample($formattedName);
    }

### getFolderIntelligenceConfig

Returns the Folder scoped singleton IntelligenceConfig resource.

The async variant is
[StorageControlClient::getFolderIntelligenceConfigAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__getFolderIntelligenceConfigAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.GetFolderIntelligenceConfigRequest` 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-storage-control/latest/V2.IntelligenceConfig` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\Cloud\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\GetFolderIntelligenceConfigRequest;
    use Google\Cloud\Storage\Control\V2\IntelligenceConfig;

    /**
     * @param string $formattedName The name of the `IntelligenceConfig` resource associated with
     *                              your folder.
     *
     *                              Format: `folders/{id}/locations/global/intelligenceConfig`
     *                              Please see {@see StorageControlClient::intelligenceConfigName()} for help formatting this field.
     */
    function get_folder_intelligence_config_sample(string $formattedName): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

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

        // Call the API and handle any network failures.
        try {
            /** @var IntelligenceConfig $response */
            $response = $storageControlClient->getFolderIntelligenceConfig($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 = StorageControlClient::intelligenceConfigName('[FOLDER]', '[LOCATION]');

        get_folder_intelligence_config_sample($formattedName);
    }

### getIamPolicy

Gets the IAM policy for a specified bucket.

The `resource` field in the request should be
`projects/_/buckets/{bucket}` for a bucket, or
`projects/_/buckets/{bucket}/managedFolders/{managedFolder}`
for a managed folder.

The async variant is [StorageControlClient::getIamPolicyAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__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\Iam\V1\GetIamPolicyRequest;
    use Google\Cloud\Iam\V1\Policy;
    use Google\Cloud\Storage\Control\V2\Client\StorageControlClient;

    /**
     * @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.
        $storageControlClient = new StorageControlClient();

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

        // Call the API and handle any network failures.
        try {
            /** @var Policy $response */
            $response = $storageControlClient->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);
    }

### getIntelligenceFinding

Gets the `IntelligenceFinding` for a project.

The async variant is [StorageControlClient::getIntelligenceFindingAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__getIntelligenceFindingAsync__)
.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.GetIntelligenceFindingRequest` 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-storage-control/latest/V2.IntelligenceFinding` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\Cloud\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\GetIntelligenceFindingRequest;
    use Google\Cloud\Storage\Control\V2\IntelligenceFinding;

    /**
     * @param string $formattedName The name of the `IntelligenceFinding` resource.
     *
     *                              Format:
     *                              `projects/{project}/locations/{location}/intelligenceFindings/{intelligence_finding}`
     *                              Please see {@see StorageControlClient::intelligenceFindingName()} for help formatting this field.
     */
    function get_intelligence_finding_sample(string $formattedName): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

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

        // Call the API and handle any network failures.
        try {
            /** @var IntelligenceFinding $response */
            $response = $storageControlClient->getIntelligenceFinding($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 = StorageControlClient::intelligenceFindingName(
            '[PROJECT]',
            '[LOCATION]',
            '[INTELLIGENCE_FINDING]'
        );

        get_intelligence_finding_sample($formattedName);
    }

### getIntelligenceFindingRevision

Gets the `IntelligenceFindingRevision` resource.

The async variant is
[StorageControlClient::getIntelligenceFindingRevisionAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__getIntelligenceFindingRevisionAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.GetIntelligenceFindingRevisionRequest` 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-storage-control/latest/V2.IntelligenceFindingRevision` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\Cloud\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\GetIntelligenceFindingRevisionRequest;
    use Google\Cloud\Storage\Control\V2\IntelligenceFindingRevision;

    /**
     * @param string $formattedName The name of the `IntelligenceFindingRevision` resource.
     *                              ## Format:
     *
     *                              `projects/{project}/locations/{location}/intelligenceFindings/{intelligence_finding}/revisions/{revision}`
     *                              Please see {@see StorageControlClient::intelligenceFindingRevisionName()} for help formatting this field.
     */
    function get_intelligence_finding_revision_sample(string $formattedName): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

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

        // Call the API and handle any network failures.
        try {
            /** @var IntelligenceFindingRevision $response */
            $response = $storageControlClient->getIntelligenceFindingRevision($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 = StorageControlClient::intelligenceFindingRevisionName(
            '[PROJECT]',
            '[LOCATION]',
            '[INTELLIGENCE_FINDING]',
            '[REVISION]'
        );

        get_intelligence_finding_revision_sample($formattedName);
    }

### getManagedFolder

Returns metadata for the specified managed folder.

The async variant is [StorageControlClient::getManagedFolderAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__getManagedFolderAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.GetManagedFolderRequest` 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-storage-control/latest/V2.ManagedFolder` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\Cloud\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\GetManagedFolderRequest;
    use Google\Cloud\Storage\Control\V2\ManagedFolder;

    /**
     * @param string $formattedName Name of the managed folder.
     *                              Format:
     *                              `projects/{project}/buckets/{bucket}/managedFolders/{managedFolder}`
     *                              Please see {@see StorageControlClient::managedFolderName()} for help formatting this field.
     */
    function get_managed_folder_sample(string $formattedName): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

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

        // Call the API and handle any network failures.
        try {
            /** @var ManagedFolder $response */
            $response = $storageControlClient->getManagedFolder($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 = StorageControlClient::managedFolderName(
            '[PROJECT]',
            '[BUCKET]',
            '[MANAGED_FOLDER]'
        );

        get_managed_folder_sample($formattedName);
    }

### getOrganizationIntelligenceConfig

Returns the Organization scoped singleton IntelligenceConfig resource.

The async variant is
[StorageControlClient::getOrganizationIntelligenceConfigAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__getOrganizationIntelligenceConfigAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.GetOrganizationIntelligenceConfigRequest` 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-storage-control/latest/V2.IntelligenceConfig` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\Cloud\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\GetOrganizationIntelligenceConfigRequest;
    use Google\Cloud\Storage\Control\V2\IntelligenceConfig;

    /**
     * @param string $formattedName The name of the `IntelligenceConfig` resource associated with
     *                              your organization.
     *
     *                              Format: `organizations/{org_id}/locations/global/intelligenceConfig`
     *                              Please see {@see StorageControlClient::intelligenceConfigName()} for help formatting this field.
     */
    function get_organization_intelligence_config_sample(string $formattedName): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

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

        // Call the API and handle any network failures.
        try {
            /** @var IntelligenceConfig $response */
            $response = $storageControlClient->getOrganizationIntelligenceConfig($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 = StorageControlClient::intelligenceConfigName('[FOLDER]', '[LOCATION]');

        get_organization_intelligence_config_sample($formattedName);
    }

### getProjectIntelligenceConfig

Returns the Project scoped singleton IntelligenceConfig resource.

The async variant is
[StorageControlClient::getProjectIntelligenceConfigAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__getProjectIntelligenceConfigAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.GetProjectIntelligenceConfigRequest` 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-storage-control/latest/V2.IntelligenceConfig` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\Cloud\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\GetProjectIntelligenceConfigRequest;
    use Google\Cloud\Storage\Control\V2\IntelligenceConfig;

    /**
     * @param string $formattedName The name of the `IntelligenceConfig` resource associated with
     *                              your project.
     *
     *                              Format: `projects/{id}/locations/global/intelligenceConfig`
     *                              Please see {@see StorageControlClient::intelligenceConfigName()} for help formatting this field.
     */
    function get_project_intelligence_config_sample(string $formattedName): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

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

        // Call the API and handle any network failures.
        try {
            /** @var IntelligenceConfig $response */
            $response = $storageControlClient->getProjectIntelligenceConfig($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 = StorageControlClient::intelligenceConfigName('[FOLDER]', '[LOCATION]');

        get_project_intelligence_config_sample($formattedName);
    }

### getStorageLayout

Returns the storage layout configuration for a given bucket.

The async variant is [StorageControlClient::getStorageLayoutAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__getStorageLayoutAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.GetStorageLayoutRequest` 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-storage-control/latest/V2.StorageLayout` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\Cloud\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\GetStorageLayoutRequest;
    use Google\Cloud\Storage\Control\V2\StorageLayout;

    /**
     * @param string $formattedName The name of the StorageLayout resource.
     *                              Format: `projects/{project}/buckets/{bucket}/storageLayout`
     *                              Please see {@see StorageControlClient::storageLayoutName()} for help formatting this field.
     */
    function get_storage_layout_sample(string $formattedName): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

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

        // Call the API and handle any network failures.
        try {
            /** @var StorageLayout $response */
            $response = $storageControlClient->getStorageLayout($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 = StorageControlClient::storageLayoutName('[PROJECT]', '[BUCKET]');

        get_storage_layout_sample($formattedName);
    }

### listAnywhereCaches

Lists Anywhere Cache instances for a given bucket.

The async variant is [StorageControlClient::listAnywhereCachesAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__listAnywhereCachesAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.ListAnywhereCachesRequest` 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\Storage\Control\V2\AnywhereCache;
    use Google\Cloud\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\ListAnywhereCachesRequest;

    /**
     * @param string $formattedParent The bucket to which this cache belongs. Please see
     *                                {@see StorageControlClient::bucketName()} for help formatting this field.
     */
    function list_anywhere_caches_sample(string $formattedParent): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

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

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

            /** @var AnywhereCache $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 = StorageControlClient::bucketName('[PROJECT]', '[BUCKET]');

        list_anywhere_caches_sample($formattedParent);
    }

### listFolders

Retrieves a list of folders. This operation is only applicable to a
hierarchical namespace enabled bucket.

The async variant is [StorageControlClient::listFoldersAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__listFoldersAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.ListFoldersRequest` 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\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\Folder;
    use Google\Cloud\Storage\Control\V2\ListFoldersRequest;

    /**
     * @param string $formattedParent Name of the bucket in which to look for folders. The bucket must
     *                                be a hierarchical namespace enabled bucket. Please see
     *                                {@see StorageControlClient::bucketName()} for help formatting this field.
     */
    function list_folders_sample(string $formattedParent): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

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

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

            /** @var Folder $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 = StorageControlClient::bucketName('[PROJECT]', '[BUCKET]');

        list_folders_sample($formattedParent);
    }

### listIntelligenceFindingRevisions

Lists all the revisions of an `IntelligenceFinding` resource.

The async variant is
[StorageControlClient::listIntelligenceFindingRevisionsAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__listIntelligenceFindingRevisionsAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.ListIntelligenceFindingRevisionsRequest` 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\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\IntelligenceFindingRevision;
    use Google\Cloud\Storage\Control\V2\ListIntelligenceFindingRevisionsRequest;

    /**
     * @param string $formattedParent The parent of the `IntelligenceFindingRevision` resource.
     *                                ## Format:
     *
     *                                `projects/{project}/locations/{location}/intelligenceFindings/{intelligence_finding}`
     *                                Please see {@see StorageControlClient::intelligenceFindingName()} for help formatting this field.
     */
    function list_intelligence_finding_revisions_sample(string $formattedParent): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

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

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

            /** @var IntelligenceFindingRevision $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 = StorageControlClient::intelligenceFindingName(
            '[PROJECT]',
            '[LOCATION]',
            '[INTELLIGENCE_FINDING]'
        );

        list_intelligence_finding_revisions_sample($formattedParent);
    }

### listIntelligenceFindings

Lists the `IntelligenceFinding` resources for the specified project.

The async variant is
[StorageControlClient::listIntelligenceFindingsAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__listIntelligenceFindingsAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.ListIntelligenceFindingsRequest` 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\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\IntelligenceFinding;
    use Google\Cloud\Storage\Control\V2\ListIntelligenceFindingsRequest;

    /**
     * @param string $formattedParent The parent of the `IntelligenceFinding` resource.
     *
     *                                Format: `projects/{project}/locations/{location}`
     *                                Please see {@see StorageControlClient::locationName()} for help formatting this field.
     */
    function list_intelligence_findings_sample(string $formattedParent): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

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

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

            /** @var IntelligenceFinding $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 = StorageControlClient::locationName('[PROJECT]', '[LOCATION]');

        list_intelligence_findings_sample($formattedParent);
    }

### listManagedFolders

Retrieves a list of managed folders for a given bucket.

The async variant is [StorageControlClient::listManagedFoldersAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__listManagedFoldersAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.ListManagedFoldersRequest` 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\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\ListManagedFoldersRequest;
    use Google\Cloud\Storage\Control\V2\ManagedFolder;

    /**
     * @param string $formattedParent Name of the bucket this managed folder belongs to. Please see
     *                                {@see StorageControlClient::bucketName()} for help formatting this field.
     */
    function list_managed_folders_sample(string $formattedParent): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

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

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

            /** @var ManagedFolder $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 = StorageControlClient::bucketName('[PROJECT]', '[BUCKET]');

        list_managed_folders_sample($formattedParent);
    }

### pauseAnywhereCache

Pauses an Anywhere Cache instance.

The async variant is [StorageControlClient::pauseAnywhereCacheAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__pauseAnywhereCacheAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.PauseAnywhereCacheRequest` 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-storage-control/latest/V2.AnywhereCache` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\Cloud\Storage\Control\V2\AnywhereCache;
    use Google\Cloud\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\PauseAnywhereCacheRequest;

    /**
     * @param string $formattedName The name field in the request should be:
     *                              `projects/{project}/buckets/{bucket}/anywhereCaches/{anywhere_cache}`
     *                              Please see {@see StorageControlClient::anywhereCacheName()} for help formatting this field.
     */
    function pause_anywhere_cache_sample(string $formattedName): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

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

        // Call the API and handle any network failures.
        try {
            /** @var AnywhereCache $response */
            $response = $storageControlClient->pauseAnywhereCache($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 = StorageControlClient::anywhereCacheName(
            '[PROJECT]',
            '[BUCKET]',
            '[ANYWHERE_CACHE]'
        );

        pause_anywhere_cache_sample($formattedName);
    }

### renameFolder

Renames a source folder to a destination folder. This operation is only
applicable to a hierarchical namespace enabled bucket. During a rename, the
source and destination folders are locked until the long running operation
completes.

The async variant is [StorageControlClient::renameFolderAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__renameFolderAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.RenameFolderRequest` 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-storage-control/latest/V2.Folder>` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\ApiCore\OperationResponse;
    use Google\Cloud\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\Folder;
    use Google\Cloud\Storage\Control\V2\RenameFolderRequest;
    use Google\Rpc\Status;

    /**
     * @param string $formattedName       Name of the source folder being renamed.
     *                                    Format: `projects/{project}/buckets/{bucket}/folders/{folder}`
     *                                    Please see {@see StorageControlClient::folderName()} for help formatting this field.
     * @param string $destinationFolderId The destination folder ID, e.g. `foo/bar/`.
     */
    function rename_folder_sample(string $formattedName, string $destinationFolderId): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

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

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

            if ($response->operationSucceeded()) {
                /** @var Folder $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
    {
        $formattedName = StorageControlClient::folderName('[PROJECT]', '[BUCKET]', '[FOLDER]');
        $destinationFolderId = '[DESTINATION_FOLDER_ID]';

        rename_folder_sample($formattedName, $destinationFolderId);
    }

### resumeAnywhereCache

Resumes a disabled or paused Anywhere Cache instance.

The async variant is [StorageControlClient::resumeAnywhereCacheAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__resumeAnywhereCacheAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.ResumeAnywhereCacheRequest` 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-storage-control/latest/V2.AnywhereCache` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\Cloud\Storage\Control\V2\AnywhereCache;
    use Google\Cloud\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\ResumeAnywhereCacheRequest;

    /**
     * @param string $formattedName The name field in the request should be:
     *                              `projects/{project}/buckets/{bucket}/anywhereCaches/{anywhere_cache}`
     *                              Please see {@see StorageControlClient::anywhereCacheName()} for help formatting this field.
     */
    function resume_anywhere_cache_sample(string $formattedName): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

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

        // Call the API and handle any network failures.
        try {
            /** @var AnywhereCache $response */
            $response = $storageControlClient->resumeAnywhereCache($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 = StorageControlClient::anywhereCacheName(
            '[PROJECT]',
            '[BUCKET]',
            '[ANYWHERE_CACHE]'
        );

        resume_anywhere_cache_sample($formattedName);
    }

### setIamPolicy

Updates an IAM policy for the specified bucket.

The `resource` field in the request should be
`projects/_/buckets/{bucket}` for a bucket, or
`projects/_/buckets/{bucket}/managedFolders/{managedFolder}`
for a managed folder.

The async variant is [StorageControlClient::setIamPolicyAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__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\Iam\V1\Policy;
    use Google\Cloud\Iam\V1\SetIamPolicyRequest;
    use Google\Cloud\Storage\Control\V2\Client\StorageControlClient;

    /**
     * @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.
        $storageControlClient = new StorageControlClient();

        // 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 = $storageControlClient->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);
    }

### summarizeIntelligenceFindings

Summarize the intelligence findings for the specified scope(org, folder or
project).

The async variant is
[StorageControlClient::summarizeIntelligenceFindingsAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__summarizeIntelligenceFindingsAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.SummarizeIntelligenceFindingsRequest` 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\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\FindingSummary;
    use Google\Cloud\Storage\Control\V2\SummarizeIntelligenceFindingsRequest;

    /**
     * @param string $parent The scope to summarize the findings for.
     *                       Format:
     *                       - `organizations/{organization}/locations/{location}`
     *                       - `folders/{folder}/locations/{location}`
     *                       - `projects/{project}/locations/{location}`
     */
    function summarize_intelligence_findings_sample(string $parent): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

        // Prepare the request message.
        $request = (new SummarizeIntelligenceFindingsRequest())
            ->setParent($parent);

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

            /** @var FindingSummary $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
    {
        $parent = '[PARENT]';

        summarize_intelligence_findings_sample($parent);
    }

### testIamPermissions

Tests a set of permissions on the given bucket, object, or managed folder
to see which, if any, are held by the caller.

The `resource` field in the request should be
`projects/_/buckets/{bucket}` for a bucket,
`projects/_/buckets/{bucket}/objects/{object}` for an object, or
`projects/_/buckets/{bucket}/managedFolders/{managedFolder}`
for a managed folder.

The async variant is [StorageControlClient::testIamPermissionsAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__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\Iam\V1\TestIamPermissionsRequest;
    use Google\Cloud\Iam\V1\TestIamPermissionsResponse;
    use Google\Cloud\Storage\Control\V2\Client\StorageControlClient;

    /**
     * @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.
        $storageControlClient = new StorageControlClient();

        // 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 = $storageControlClient->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);
    }

### updateAnywhereCache

Updates an Anywhere Cache instance. Mutable fields include `ttl` and
`admission_policy`.

The async variant is [StorageControlClient::updateAnywhereCacheAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__updateAnywhereCacheAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.UpdateAnywhereCacheRequest` 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-storage-control/latest/V2.AnywhereCache>` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\ApiCore\OperationResponse;
    use Google\Cloud\Storage\Control\V2\AnywhereCache;
    use Google\Cloud\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\UpdateAnywhereCacheRequest;
    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_anywhere_cache_sample(): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

        // Prepare the request message.
        $anywhereCache = new AnywhereCache();
        $updateMask = new FieldMask();
        $request = (new UpdateAnywhereCacheRequest())
            ->setAnywhereCache($anywhereCache)
            ->setUpdateMask($updateMask);

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

            if ($response->operationSucceeded()) {
                /** @var AnywhereCache $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());
        }
    }

### updateFolderIntelligenceConfig

Updates the Folder scoped singleton IntelligenceConfig resource.

The async variant is
[StorageControlClient::updateFolderIntelligenceConfigAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__updateFolderIntelligenceConfigAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.UpdateFolderIntelligenceConfigRequest` 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-storage-control/latest/V2.IntelligenceConfig` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\Cloud\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\IntelligenceConfig;
    use Google\Cloud\Storage\Control\V2\UpdateFolderIntelligenceConfigRequest;
    use Google\Protobuf\FieldMask;

    /**
     * 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_folder_intelligence_config_sample(): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

        // Prepare the request message.
        $intelligenceConfig = new IntelligenceConfig();
        $updateMask = new FieldMask();
        $request = (new UpdateFolderIntelligenceConfigRequest())
            ->setIntelligenceConfig($intelligenceConfig)
            ->setUpdateMask($updateMask);

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

### updateOrganizationIntelligenceConfig

Updates the Organization scoped singleton IntelligenceConfig resource.

The async variant is
[StorageControlClient::updateOrganizationIntelligenceConfigAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__updateOrganizationIntelligenceConfigAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.UpdateOrganizationIntelligenceConfigRequest` 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-storage-control/latest/V2.IntelligenceConfig` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\Cloud\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\IntelligenceConfig;
    use Google\Cloud\Storage\Control\V2\UpdateOrganizationIntelligenceConfigRequest;
    use Google\Protobuf\FieldMask;

    /**
     * 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_organization_intelligence_config_sample(): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

        // Prepare the request message.
        $intelligenceConfig = new IntelligenceConfig();
        $updateMask = new FieldMask();
        $request = (new UpdateOrganizationIntelligenceConfigRequest())
            ->setIntelligenceConfig($intelligenceConfig)
            ->setUpdateMask($updateMask);

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

### updateProjectIntelligenceConfig

Updates the Project scoped singleton IntelligenceConfig resource.

The async variant is
[StorageControlClient::updateProjectIntelligenceConfigAsync()](https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.Client.StorageControlClient#_Google_Cloud_Storage_Control_V2_Client_StorageControlClient__updateProjectIntelligenceConfigAsync__) .

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.UpdateProjectIntelligenceConfigRequest` 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-storage-control/latest/V2.IntelligenceConfig` |   |

**Example**

    use Google\ApiCore\ApiException;
    use Google\Cloud\Storage\Control\V2\Client\StorageControlClient;
    use Google\Cloud\Storage\Control\V2\IntelligenceConfig;
    use Google\Cloud\Storage\Control\V2\UpdateProjectIntelligenceConfigRequest;
    use Google\Protobuf\FieldMask;

    /**
     * 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_project_intelligence_config_sample(): void
    {
        // Create a client.
        $storageControlClient = new StorageControlClient();

        // Prepare the request message.
        $intelligenceConfig = new IntelligenceConfig();
        $updateMask = new FieldMask();
        $request = (new UpdateProjectIntelligenceConfigRequest())
            ->setIntelligenceConfig($intelligenceConfig)
            ->setUpdateMask($updateMask);

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

### createAnywhereCacheAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.CreateAnywhereCacheRequest` |
| `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>` |   |

### createFolderAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.CreateFolderRequest` |
| `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-storage-control/latest/V2.Folder>` |   |

### createManagedFolderAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.CreateManagedFolderRequest` |
| `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-storage-control/latest/V2.ManagedFolder>` |   |

### deleteFolderAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.DeleteFolderRequest` |
| `optionalArgs` | `array` |

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

### deleteFolderRecursiveAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.DeleteFolderRecursiveRequest` |
| `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>` |   |

### deleteManagedFolderAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.DeleteManagedFolderRequest` |
| `optionalArgs` | `array` |

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

### disableAnywhereCacheAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.DisableAnywhereCacheRequest` |
| `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-storage-control/latest/V2.AnywhereCache>` |   |

### getAnywhereCacheAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.GetAnywhereCacheRequest` |
| `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-storage-control/latest/V2.AnywhereCache>` |   |

### getFolderAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.GetFolderRequest` |
| `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-storage-control/latest/V2.Folder>` |   |

### getFolderIntelligenceConfigAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.GetFolderIntelligenceConfigRequest` |
| `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-storage-control/latest/V2.IntelligenceConfig>` |   |

### 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>` |   |

### getIntelligenceFindingAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.GetIntelligenceFindingRequest` |
| `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-storage-control/latest/V2.IntelligenceFinding>` |   |

### getIntelligenceFindingRevisionAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.GetIntelligenceFindingRevisionRequest` |
| `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-storage-control/latest/V2.IntelligenceFindingRevision>` |   |

### getManagedFolderAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.GetManagedFolderRequest` |
| `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-storage-control/latest/V2.ManagedFolder>` |   |

### getOrganizationIntelligenceConfigAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.GetOrganizationIntelligenceConfigRequest` |
| `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-storage-control/latest/V2.IntelligenceConfig>` |   |

### getProjectIntelligenceConfigAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.GetProjectIntelligenceConfigRequest` |
| `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-storage-control/latest/V2.IntelligenceConfig>` |   |

### getStorageLayoutAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.GetStorageLayoutRequest` |
| `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-storage-control/latest/V2.StorageLayout>` |   |

### listAnywhereCachesAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.ListAnywhereCachesRequest` |
| `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>` |   |

### listFoldersAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.ListFoldersRequest` |
| `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>` |   |

### listIntelligenceFindingRevisionsAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.ListIntelligenceFindingRevisionsRequest` |
| `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>` |   |

### listIntelligenceFindingsAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.ListIntelligenceFindingsRequest` |
| `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>` |   |

### listManagedFoldersAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.ListManagedFoldersRequest` |
| `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>` |   |

### pauseAnywhereCacheAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.PauseAnywhereCacheRequest` |
| `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-storage-control/latest/V2.AnywhereCache>` |   |

### renameFolderAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.RenameFolderRequest` |
| `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>` |   |

### resumeAnywhereCacheAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.ResumeAnywhereCacheRequest` |
| `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-storage-control/latest/V2.AnywhereCache>` |   |

### 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>` |   |

### summarizeIntelligenceFindingsAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.SummarizeIntelligenceFindingsRequest` |
| `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>` |   |

### 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>` |   |

### updateAnywhereCacheAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.UpdateAnywhereCacheRequest` |
| `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>` |   |

### updateFolderIntelligenceConfigAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.UpdateFolderIntelligenceConfigRequest` |
| `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-storage-control/latest/V2.IntelligenceConfig>` |   |

### updateOrganizationIntelligenceConfigAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.UpdateOrganizationIntelligenceConfigRequest` |
| `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-storage-control/latest/V2.IntelligenceConfig>` |   |

### updateProjectIntelligenceConfigAsync

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `request` | `https://docs.cloud.google.com/php/docs/reference/cloud-storage-control/latest/V2.UpdateProjectIntelligenceConfigRequest` |
| `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-storage-control/latest/V2.IntelligenceConfig>` |   |

### 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::anywhereCacheName

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

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `project` | `string` |
| `bucket` | `string` |
| `anywhereCache` | `string` |

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

### static::bucketName

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

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

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

### static::folderName

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

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `project` | `string` |
| `bucket` | `string` |
| `folder` | `string` |

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

### static::folderLocationIntelligenceConfigName

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

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

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

### static::intelligenceConfigName

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

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

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

### static::intelligenceFindingName

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

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

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

### static::intelligenceFindingRevisionName

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

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

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` | The formatted intelligence_finding_revision 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::managedFolderName

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

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `project` | `string` |
| `bucket` | `string` |
| `managedFolder` | `string` |

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

### static::orgLocationIntelligenceConfigName

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

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

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

### static::projectLocationIntelligenceConfigName

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

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

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

### static::storageLayoutName

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

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

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `string` | The formatted storage_layout 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

- anywhereCache: projects/{project}/buckets/{bucket}/anywhereCaches/{anywhere_cache}
- bucket: projects/{project}/buckets/{bucket}
- folder: projects/{project}/buckets/{bucket}/folders/{folder=\*\*}
- folderLocationIntelligenceConfig: folders/{folder}/locations/{location}/intelligenceConfig
- intelligenceConfig: folders/{folder}/locations/{location}/intelligenceConfig
- intelligenceFinding: projects/{project}/locations/{location}/intelligenceFindings/{intelligence_finding}
- intelligenceFindingRevision: projects/{project}/locations/{location}/intelligenceFindings/{intelligence_finding}/revisions/{revision}
- location: projects/{project}/locations/{location}
- managedFolder: projects/{project}/buckets/{bucket}/managedFolders/{managed_folder=\*\*}
- orgLocationIntelligenceConfig: organizations/{org}/locations/{location}/intelligenceConfig
- projectLocationIntelligenceConfig: projects/{project}/locations/{location}/intelligenceConfig
- storageLayout: projects/{project}/buckets/{bucket}/storageLayout

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. |