diff --git a/Functions/samples/V1/CloudFunctionsServiceClient/call_function.php b/Functions/samples/V1/CloudFunctionsServiceClient/call_function.php deleted file mode 100644 index a3d393ca6aa6..000000000000 --- a/Functions/samples/V1/CloudFunctionsServiceClient/call_function.php +++ /dev/null @@ -1,75 +0,0 @@ -callFunction($formattedName, $data); - 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 = CloudFunctionsServiceClient::cloudFunctionName( - '[PROJECT]', - '[LOCATION]', - '[FUNCTION]' - ); - $data = '[DATA]'; - - call_function_sample($formattedName, $data); -} -// [END cloudfunctions_v1_generated_CloudFunctionsService_CallFunction_sync] diff --git a/Functions/samples/V1/CloudFunctionsServiceClient/create_function.php b/Functions/samples/V1/CloudFunctionsServiceClient/create_function.php deleted file mode 100644 index 6ee7f320bde0..000000000000 --- a/Functions/samples/V1/CloudFunctionsServiceClient/create_function.php +++ /dev/null @@ -1,84 +0,0 @@ -createFunction($formattedLocation, $function); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var CloudFunction $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 -{ - $formattedLocation = CloudFunctionsServiceClient::locationName('[PROJECT]', '[LOCATION]'); - - create_function_sample($formattedLocation); -} -// [END cloudfunctions_v1_generated_CloudFunctionsService_CreateFunction_sync] diff --git a/Functions/samples/V1/CloudFunctionsServiceClient/delete_function.php b/Functions/samples/V1/CloudFunctionsServiceClient/delete_function.php deleted file mode 100644 index 08e1b649f859..000000000000 --- a/Functions/samples/V1/CloudFunctionsServiceClient/delete_function.php +++ /dev/null @@ -1,81 +0,0 @@ -deleteFunction($formattedName); - $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 = CloudFunctionsServiceClient::cloudFunctionName( - '[PROJECT]', - '[LOCATION]', - '[FUNCTION]' - ); - - delete_function_sample($formattedName); -} -// [END cloudfunctions_v1_generated_CloudFunctionsService_DeleteFunction_sync] diff --git a/Functions/samples/V1/CloudFunctionsServiceClient/generate_download_url.php b/Functions/samples/V1/CloudFunctionsServiceClient/generate_download_url.php deleted file mode 100644 index 37dd4e46ff28..000000000000 --- a/Functions/samples/V1/CloudFunctionsServiceClient/generate_download_url.php +++ /dev/null @@ -1,57 +0,0 @@ -generateDownloadUrl(); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END cloudfunctions_v1_generated_CloudFunctionsService_GenerateDownloadUrl_sync] diff --git a/Functions/samples/V1/CloudFunctionsServiceClient/generate_upload_url.php b/Functions/samples/V1/CloudFunctionsServiceClient/generate_upload_url.php deleted file mode 100644 index dc957a8616c5..000000000000 --- a/Functions/samples/V1/CloudFunctionsServiceClient/generate_upload_url.php +++ /dev/null @@ -1,77 +0,0 @@ -generateUploadUrl(); - printf('Response data: %s' . PHP_EOL, $response->serializeToJsonString()); - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END cloudfunctions_v1_generated_CloudFunctionsService_GenerateUploadUrl_sync] diff --git a/Functions/samples/V1/CloudFunctionsServiceClient/get_function.php b/Functions/samples/V1/CloudFunctionsServiceClient/get_function.php deleted file mode 100644 index 502ceb6661ad..000000000000 --- a/Functions/samples/V1/CloudFunctionsServiceClient/get_function.php +++ /dev/null @@ -1,70 +0,0 @@ -getFunction($formattedName); - 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 = CloudFunctionsServiceClient::cloudFunctionName( - '[PROJECT]', - '[LOCATION]', - '[FUNCTION]' - ); - - get_function_sample($formattedName); -} -// [END cloudfunctions_v1_generated_CloudFunctionsService_GetFunction_sync] diff --git a/Functions/samples/V1/CloudFunctionsServiceClient/get_iam_policy.php b/Functions/samples/V1/CloudFunctionsServiceClient/get_iam_policy.php deleted file mode 100644 index c646d846d9b0..000000000000 --- a/Functions/samples/V1/CloudFunctionsServiceClient/get_iam_policy.php +++ /dev/null @@ -1,68 +0,0 @@ -getIamPolicy($resource); - 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); -} -// [END cloudfunctions_v1_generated_CloudFunctionsService_GetIamPolicy_sync] diff --git a/Functions/samples/V1/CloudFunctionsServiceClient/list_functions.php b/Functions/samples/V1/CloudFunctionsServiceClient/list_functions.php deleted file mode 100644 index dc9ca9d04dc8..000000000000 --- a/Functions/samples/V1/CloudFunctionsServiceClient/list_functions.php +++ /dev/null @@ -1,58 +0,0 @@ -listFunctions(); - - /** @var CloudFunction $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()); - } -} -// [END cloudfunctions_v1_generated_CloudFunctionsService_ListFunctions_sync] diff --git a/Functions/samples/V1/CloudFunctionsServiceClient/list_locations.php b/Functions/samples/V1/CloudFunctionsServiceClient/list_locations.php deleted file mode 100644 index b20fdc6fff24..000000000000 --- a/Functions/samples/V1/CloudFunctionsServiceClient/list_locations.php +++ /dev/null @@ -1,58 +0,0 @@ -listLocations(); - - /** @var Location $element */ - foreach ($response as $element) { - printf('Element data: %s' . PHP_EOL, $element->serializeToJsonString()); - } - } catch (ApiException $ex) { - printf('Call failed with message: %s' . PHP_EOL, $ex->getMessage()); - } -} -// [END cloudfunctions_v1_generated_CloudFunctionsService_ListLocations_sync] diff --git a/Functions/samples/V1/CloudFunctionsServiceClient/set_iam_policy.php b/Functions/samples/V1/CloudFunctionsServiceClient/set_iam_policy.php deleted file mode 100644 index a61c2fc54824..000000000000 --- a/Functions/samples/V1/CloudFunctionsServiceClient/set_iam_policy.php +++ /dev/null @@ -1,70 +0,0 @@ -setIamPolicy($resource, $policy); - 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); -} -// [END cloudfunctions_v1_generated_CloudFunctionsService_SetIamPolicy_sync] diff --git a/Functions/samples/V1/CloudFunctionsServiceClient/test_iam_permissions.php b/Functions/samples/V1/CloudFunctionsServiceClient/test_iam_permissions.php deleted file mode 100644 index 369fbf023303..000000000000 --- a/Functions/samples/V1/CloudFunctionsServiceClient/test_iam_permissions.php +++ /dev/null @@ -1,77 +0,0 @@ -testIamPermissions($resource, $permissions); - 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); -} -// [END cloudfunctions_v1_generated_CloudFunctionsService_TestIamPermissions_sync] diff --git a/Functions/samples/V1/CloudFunctionsServiceClient/update_function.php b/Functions/samples/V1/CloudFunctionsServiceClient/update_function.php deleted file mode 100644 index 9ca61fbb7526..000000000000 --- a/Functions/samples/V1/CloudFunctionsServiceClient/update_function.php +++ /dev/null @@ -1,68 +0,0 @@ -updateFunction($function); - $response->pollUntilComplete(); - - if ($response->operationSucceeded()) { - /** @var CloudFunction $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()); - } -} -// [END cloudfunctions_v1_generated_CloudFunctionsService_UpdateFunction_sync]